MCPcopy Create free account
hub / github.com/CyanogenMod/android_frameworks_base / appendComment

Method appendComment

tools/aapt/ResourceTable.cpp:1998–2020  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1996}
1997
1998bool ResourceTable::appendComment(const String16& package,
1999 const String16& type,
2000 const String16& name,
2001 const String16& comment,
2002 bool onlyIfEmpty)
2003{
2004 if (comment.size() <= 0) {
2005 return true;
2006 }
2007
2008 sp<Package> p = mPackages.valueFor(package);
2009 if (p != NULL) {
2010 sp<Type> t = p->getTypes().valueFor(type);
2011 if (t != NULL) {
2012 sp<ConfigList> c = t->getConfigs().valueFor(name);
2013 if (c != NULL) {
2014 c->appendComment(comment, onlyIfEmpty);
2015 return true;
2016 }
2017 }
2018 }
2019 return false;
2020}
2021
2022bool ResourceTable::appendTypeComment(const String16& package,
2023 const String16& type,

Callers 3

createIfNeededMethod · 0.45
compileResourceFileFunction · 0.45
addSymbolsMethod · 0.45

Calls 3

String16Class · 0.70
sizeMethod · 0.65
appendMethod · 0.65

Tested by

no test coverage detected