diff options
Diffstat (limited to 'tools/aapt2/Util.h')
-rw-r--r-- | tools/aapt2/Util.h | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/tools/aapt2/Util.h b/tools/aapt2/Util.h index 6015d82..9cdb152 100644 --- a/tools/aapt2/Util.h +++ b/tools/aapt2/Util.h @@ -78,6 +78,23 @@ StringPiece16::const_iterator findNonAlphaNumericAndNotInSet(const StringPiece16 const StringPiece16& allowedChars); /** + * Tests that the string is a valid Java class name. + */ +bool isJavaClassName(const StringPiece16& str); + +/** + * Converts the class name to a fully qualified class name from the given `package`. Ex: + * + * asdf --> package.asdf + * .asdf --> package.asdf + * .a.b --> package.a.b + * asdf.adsf --> asdf.adsf + */ +Maybe<std::u16string> getFullyQualifiedClassName(const StringPiece16& package, + const StringPiece16& className); + + +/** * Makes a std::unique_ptr<> with the template parameter inferred by the compiler. * This will be present in C++14 and can be removed then. */ |