aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/tools/android/java/com/google/devtools/build/android/DataResource.java
Commit message (Collapse)AuthorAge
* Automatic formatting cleanup of Android *.java files.Gravatar jingwen2017-12-18
| | | | | RELNOTES: None. PiperOrigin-RevId: 179425421
* Further Refactoring/Yak ShavingGravatar corysmith2017-05-15
| | | | | | | | | * Extract the FieldInitializer with placeholder ids from the AndroidResourceClassWriter * Extract a resource sink interface from the AndroidResourceClassWriter (a little renaming, the change isn't actually that big.) RELNOTES: None PiperOrigin-RevId: 156053478
* Remove MergingExceptionGravatar corysmith2017-05-04
| | | | | | | Fixes https://github.com/bazelbuild/bazel/issues/2709 RELNOTES: None. PiperOrigin-RevId: 155097576
* Cleanup unthrown exceptions.Gravatar Googler2017-01-13
| | | | | | -- PiperOrigin-RevId: 144360540 MOS_MIGRATED_REVID=144360540
* unknown commit of 5: Fixing the merge warning messages in transitive library ↵Gravatar Googler2016-12-01
| | | | | | | | | overwrites. Record the sources are overwritten during merging. -- MOS_MIGRATED_REVID=140654137
* Add a resource merger state -> R class writer.Gravatar Googler2016-07-22
| | | | | | | | | | | | | | | | Collects the R class fields from the new merger's internal state, and then writes out either an R.java or R.class. TBD which to use. One concern is that users may want the javadoc. If so, perhaps this could generate the R.class, and then aapt could generate the srcjar off of the build critical path. Refactor the RClassGenerator to make it easier to use from merger state (vs from R.txt). -- MOS_MIGRATED_REVID=128181306
* 4.99 of 5: Fix styleable combining.Gravatar Googler2016-05-10
| | | | | | | Changes non-overwriting resources (id and styleable) to combine on duplication. This change ignores the issue of multiple sources, which will be addressed in a later cl. -- MOS_MIGRATED_REVID=121840285
* 4.8 of 5: Xml Fixes for Merger IntegrationGravatar Googler2016-05-04
| | | | | | | | | | | | | | * SimpleXmlResourceValue records all attributes except name. (I'd like to toss description, just as soon as I know I can -- bloats the serialized form.) * Added handling for <item> to SimpleXmlResourceValue: this can be used as placeholders, or (apparently) mostly unvalidated value definitions. * drawable can be used to put in colored backgrounds in a values.xml * Strings, Plurals, need to read sub tags such as xliff as string * <eat-comment/> and <skip/> need to be handled: we ignore them as all comments are eaten right now; and skip appears to be for localization diffs * xml parser must be resilient to random characters in resources defined in values. * Handles the <resource> not <resources> coding mistake gracefully. * Supports a <public> declaration. This feature is more wildly used than the nonexistant documentation suggests. -- MOS_MIGRATED_REVID=121490019
* 4.25 of 5: Writing of UnwrittenMergedAndroidDataGravatar Googler2016-04-07
| | | | | | | | | | | Introduces the AndroidDataWriter and AndroidDataWritingVisitor to abstract the io operations from the data classes. Necessary refactoring to the stubbed write method on DataValue in DataAsset.writeAsset and DataResource.writeResource. New interface for the AttributeValues to reflect the simplifications of writing Resource Attributes. Of special note is the fact all xml is written into a single file, values.xml. This is following the Gradle convention and aapt has demonstrated a preference of only reading a values.xml and ignoring all other xml files in the values directory. Unless profiling demonstrates an advantage to writing multiple files (which I doubt), this merger carries on this convention. -- MOS_MIGRATED_REVID=119066611
* 3.74 of 5: Remove DataKey from DataValue, FileDataResource and XmlDataResource.Gravatar Googler2016-03-30
| | | | | | | This is mostly mechanical, cleaning up the vestigal marks of combining the value and key. The only mildly odd change is making the OverwritableConsumer and NonOverwritableConsumer package visible, for testing purposes. -- MOS_MIGRATED_REVID=118474980
* 3.73 of 5: Convert xml parsing to use the map based storageGravatar Googler2016-03-30
| | | | | | | | | Introduces two new interfaces: DataValue, which compliments DataKey and allows a cleaner interface MergeConflict AndroidDataSet.KeyValueConsumer, abstraction that allows a common interface for consuming parsed resources, which is a lot cleanr for DataValue as well. -- MOS_MIGRATED_REVID=118466739
* Part 3.5 of 5: AssetsGravatar Googler2016-03-25
| | | | | | | Adds support for parsing and merging assets. This introduces the DataKey and DataAsset interfaces which allow reuse of the FileDataResource for assets, the RelativeAssetPath which acts as a DataKey for assets (the relative asset path is the path that the asset will reside inside the final apk.) It also extends the AndroidDataSetBuilder to handle the creation of assets, and cleans up the interface a little. -- MOS_MIGRATED_REVID=118060379
* Part 3 of 5: Merging semantics.Gravatar Googler2016-03-18
| | | | | | | | | Introduces the AndroidDataMerger, MergeConflict, and UnwrittenMergedAndroidData which is the entry point in the AndroidResourceProcessing *AndroidData lifecycle. Also, refactors the AndroidDataSet parsing of resources, making it functionally immutable. -- MOS_MIGRATED_REVID=117492690
* Part 1 of 5: Optimize the resource merge process, Introductions.Gravatar Googler2016-02-24
Introduces the AndroidDataSet, a holder for DataResources, that will be the building blocks of the revised merging system. Also introduces a DataResource implementations: * FileDataResource, which represent non-value resources. These do not need to derive the resource symbols they provide. This will replace the current ResourceSet, ResourceMerger, and ResourceMergerWriter with more efficient (e.g. fewer copied files) operations. -- MOS_MIGRATED_REVID=115455426