summaryrefslogtreecommitdiff
path: root/tools/aapt2/ResourceUtils.h
diff options
context:
space:
mode:
author Adam Lesinski <adamlesinski@google.com> 2015-11-16 17:35:44 -0800
committer Adam Lesinski <adamlesinski@google.com> 2015-11-19 14:46:53 -0800
commit467f171315f9c2037fcd3eb5edcfabc40671bf7b (patch)
tree3b14762e3d9e42a660479d0d5722883b391f835b /tools/aapt2/ResourceUtils.h
parentabf83cbe4f63cd76043aab89cd0e08525560fea2 (diff)
AAPT2: Fail compiling when private symbols are referenced
Also moved some XML specific stuff into its own directory, and refactored ReferenceLinker a bit. Change-Id: I912247a82023c1bbf72dc191fbdaf62858cbec0c
Diffstat (limited to 'tools/aapt2/ResourceUtils.h')
-rw-r--r--tools/aapt2/ResourceUtils.h7
1 files changed, 7 insertions, 0 deletions
diff --git a/tools/aapt2/ResourceUtils.h b/tools/aapt2/ResourceUtils.h
index 34daa66b1546..f93a4c762706 100644
--- a/tools/aapt2/ResourceUtils.h
+++ b/tools/aapt2/ResourceUtils.h
@@ -39,6 +39,13 @@ namespace ResourceUtils {
bool extractResourceName(const StringPiece16& str, StringPiece16* outPackage,
StringPiece16* outType, StringPiece16* outEntry);
+/**
+ * Returns true if the string was parsed as a resource name ([*][package:]type/name), with
+ * `outResource` set to the parsed resource name and `outPrivate` set to true if a '*' prefix
+ * was present.
+ */
+bool parseResourceName(const StringPiece16& str, ResourceNameRef* outResource, bool* outPrivate);
+
/*
* Returns true if the string was parsed as a reference (@[+][package:]type/name), with
* `outReference` set to the parsed reference.