aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/tools/android/java/com/google/devtools/build/android/FullyQualifiedName.java
Commit message (Collapse)AuthorAge
* Generate a separate psuedo locale .flat file only for default locale on ↵Gravatar corysmith2018-05-08
| | | | | | | values resources. RELNOTES:None PiperOrigin-RevId: 195821595
* Extract Qualifiers class for reuse.Gravatar corysmith2018-05-07
| | | | | | | | | | | | Also, introduce caching for duplicated qualifiers. Rolling Forward: Fixed attempting to parse non-resource directories with dashes as resource directories. Added test for this case. RELNOTES: None PiperOrigin-RevId: 195658978
* Internal changeGravatar Googler2018-05-03
| | | | PiperOrigin-RevId: 195321054
* Extract Qualifiers class for reuse.Gravatar corysmith2018-05-03
| | | | | | | Also, introduce caching for duplicated qualifiers. RELNOTES:None PiperOrigin-RevId: 195313195
* Remove use of bare Immutable{List,Map,Set} Builder classes.Gravatar jcater2018-04-20
| | | | | | Always use the more-qualified class name for clarity at the site of use. There are too many classes named Builder. PiperOrigin-RevId: 193649193
* Update ApkSubject to use the AndroidCompiledDataDeserializer for proto apks.Gravatar corysmith2018-04-19
| | | | | | | Minor fixes to the AndroidCompiledDataDeserializer RELNOTES: None PiperOrigin-RevId: 193535766
* Automated rollback of commit e8bed799d59526541afa2a0e9ef5d4c49e3ba390.Gravatar corysmith2018-04-03
| | | | | | | | | | | | | | | | | | | | | | *** Reason for rollback *** Rolling forward with improved handling and testing for Styleables, and correct package management. *** Original change description *** Automated rollback of commit a76f7db51a90cc2e35c1d66782056c310729eef0. *** Reason for rollback *** Breaks Kix. *** Original change description *** Modify the .flat decompilation to account for multiple configurations by converting the aapt2 proto ConfigValue to a FolderConfiguration. Adds new aapt2 compiled deserialization test. RELNOTES: None PiperOrigin-RevId: 191444658
* Automated rollback of commit f672a31b8b19baab95373e4f2f6d110aa8b8f0fb.Gravatar corysmith2018-02-16
| | | | | | | | | | | | | *** Reason for rollback *** Unclassified general breakages in tests. Rolling back for further investigation. *** Original change description *** Normalized the serialization proto to save space and allow greater versatility in storage. RELNOTES: None PiperOrigin-RevId: 186057879
* Normalized the serialization proto to save space and allow greater ↵Gravatar corysmith2018-02-16
| | | | | | | versatility in storage. RELNOTES: None PiperOrigin-RevId: 186036607
* Add support for the <type>/<package>:<name> method of declaring resources.Gravatar corysmith2017-08-30
| | | | | RELNOTES: None PiperOrigin-RevId: 166899690
* Validate and Link libraries action for aapt2Gravatar corysmith2017-08-14
| | | | | RELNOTES: None PiperOrigin-RevId: 165012084
* Android: fix path bugs and enable tests on WindowsGravatar Laszlo Csomor2017-07-10
| | | | | | | | | | | | | | Now all tests under //src/test/j/c/g/devtools/build/android/...:* pass on Windows, yay! Also adjust test sizes as advised by Bazel (using --test_verbose_timeout_warnings). See https://github.com/bazelbuild/bazel/issues/3264 Change-Id: I3f1f4978306bdedaf805149295daa413d2248fbb PiperOrigin-RevId: 161373699
* Fix bug with combining resource attributes. Attributes were reporting that ↵Gravatar apell2017-05-26
| | | | | | | they were over-writable in all cases instead of differentiating by attribute type. RELNOTES: None. PiperOrigin-RevId: 156999284
* Add <resources> attribute processing to the Android resource processing ↵Gravatar Andrew Pellegrini2017-03-14
| | | | | | | | toolchain. -- PiperOrigin-RevId: 149963021 MOS_MIGRATED_REVID=149963021
* Update android_ide_common to 25.0.0 and clean up FolderConfigsGravatar Googler2016-10-07
| | | | | | | | | | | Older android_ide_common does not handle BCP 47, so we update the code to handle that and remove most of the workarounds. This also pulls in a fix for 3-letter locales, unblocks resource shrinking whitelisting, etc. -- MOS_MIGRATED_REVID=135396457
* Restore anydpi support, working around the lack of FolderConfig support.Gravatar Googler2016-09-01
| | | | | -- MOS_MIGRATED_REVID=131853638
* Handle public tags in merger -> R.class writerGravatar Googler2016-08-17
| | | | | | | | | | | | | | | Developers do use public tags, and before this change it would assert in the AndroidResourceClassWriter as an unhandled ResourceType. We probably didn't want to write out a R.public.field anyway. Also, handle public tags with the same name, but different type. They get mapped to the same FQN, so use the combining mechanism to keep track of the different types and ids. -- MOS_MIGRATED_REVID=130395089
* Improve resource DataKey serialization perf a bitGravatar Googler2016-07-27
| | | | | | | | | | | | | | | | Address the TODO about using toString in the TreeMap comparator by using DataKey#compareTo. Also, use the entrySet to iterate K-V pairs instead of calling get(key). Synthetic benchmark w/ 10000 random keys: Before: 260ms to serialize After: 33ms to serialize Less of a difference when there are few keys. -- MOS_MIGRATED_REVID=128469407
* 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
* Remove anydpi support to improve backwards compatibility.Gravatar Googler2016-07-15
| | | | | -- MOS_MIGRATED_REVID=127466889
* Remove .9 from nine-patch FullyQualifiedNamesGravatar Googler2016-07-07
| | | | | | | | | | | | | | | | In the end, foo.9.png should result in an R.java field R.drawable.foo (not R.drawable.foo_9). Also, given foo.9.png and foo.png, aapt will give an error: res/drawable/foo.png:0: error: Resource entry foo is already defined. res/drawable/foo.9.png:0: Originally defined here. So it seems like we should generate a merge conflict warning as well. Adjust FQN accordingly. -- MOS_MIGRATED_REVID=126693820
* Record whether the attr is defined or referenced in the styleable. Despite ↵Gravatar Googler2016-06-29
| | | | | | | the functional equality, the definition type of the attribute has direct impact on the order in which the attribute appears in the styleable array. -- MOS_MIGRATED_REVID=126126122
* Rollback of commit d3cccae7b663d5defea2943509b0d9d245279830.Gravatar Googler2016-05-23
| | | | | | | | | | | | | | | | | | | | | | | *** Reason for rollback *** Rolling forward with api tolerance. *** Original change description *** Automated [] rollback of commit 941ef4d96d85e114eb6cca2fc0f646578ab0ef27. *** Reason for rollback *** Breaks Bazel due to internal patch for Round qualifier. *** Original change description *** * Adds handling for anydpi and watch, two unsupported qualifiers in FolderConfiguration. * Handles resources nested in directories. * Makes the resource processing resilient to invalid qualifiers. -- MOS_MIGRATED_REVID=122910358
* Rollback of commit 941ef4d96d85e114eb6cca2fc0f646578ab0ef27.Gravatar Googler2016-05-19
| | | | | | | | | | | | | | | *** Reason for rollback *** Breaks Bazel due to internal patch for Round qualifier. *** Original change description *** * Adds handling for anydpi and watch, two unsupported qualifiers in FolderConfiguration. * Handles resources nested in directories. * Makes the resource processing resilient to invalid qualifiers. -- MOS_MIGRATED_REVID=122747030
* * Adds handling for anydpi and watch, two unsupported qualifiers in ↵Gravatar Googler2016-05-19
| | | | | | | | | | FolderConfiguration. * Handles resources nested in directories. * Makes the resource processing resilient to invalid qualifiers. -- MOS_MIGRATED_REVID=122688529
* Handle b+.{2}+{3,4} qualifiers, as well as mobile country code and mobile ↵Gravatar Googler2016-05-18
| | | | | | | network code qualifiers. -- MOS_MIGRATED_REVID=122591469
* Switch the qualifier parsing to use FolderConfiguration. There is some extra ↵Gravatar Googler2016-05-17
| | | | | | | processing due to the missing support for ll-{3,4}, which should be removed with the android-ide-common update. -- MOS_MIGRATED_REVID=122536342
* Memory Optimizations:Gravatar Googler2016-05-16
| | | | | | | | * Cache the FullyQualifiedName instances. Due to a very high number of duplicated resource keys, all FullyQualifiedNames should be effectively interned. * Presume xliff in all resources. Inlining the xmlns is a bit costly. -- MOS_MIGRATED_REVID=122375955
* Add mpdi and ldpi to the v4 adjustment of qualifiers.Gravatar Googler2016-05-10
| | | | | -- MOS_MIGRATED_REVID=121949151
* 4.99 of 5: Cleanup.Gravatar Googler2016-05-05
| | | | | | | Cleans up a few warts from the last few changes. -- MOS_MIGRATED_REVID=121588557
* 4.85 of 5: DataKey fixes for integrationGravatar Googler2016-05-04
| | | | | | | | | * values directories now respect qualifiers (whoops.) * qualifiers must deal with 3-4 letter region codes * qualifiers must add api version for normalization -- MOS_MIGRATED_REVID=121417370
* 4 of 5: Serialization of UnwrittenMergedAndroidData.Gravatar Googler2016-04-20
| | | | | | | | | | | Adding AndroidDataSerializer, the serialize_format proto, and KeyValueConsumers (utility class for keeping consumers straight). The serializtion is a bit more manual as previous experience has proven to me that simply writing all the resources into a proto map and pulling them out is not performant in the least. So, the serializer stores each message independent, the keys and then the values allowing for potential lazy loading and other optimizations in the future. Also adds tests for parsing and writing style resources. -- MOS_MIGRATED_REVID=120274904
* 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
* 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 2 of 5: Optimize the resource merge process, XmlProcessing.Gravatar Googler2016-03-08
| | | | | | | Introduces the XmlDataResource and all the associated cruft that comes with parsing Android Resource value xmls: XmlValues, XmlValue. -- MOS_MIGRATED_REVID=116540181
* 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