Home
last modified time | relevance | path

Searched refs:StringHelper (Results 1 – 25 of 25) sorted by relevance

/system/tools/hidl/test/host_utils_test/
Dmain.cpp24 using ::android::StringHelper;
29 EXPECT_TRUE(StringHelper::EndsWith("", "")); in TEST_F()
30 EXPECT_TRUE(StringHelper::EndsWith("a", "")); in TEST_F()
31 EXPECT_TRUE(StringHelper::EndsWith("b", "b")); in TEST_F()
32 EXPECT_TRUE(StringHelper::EndsWith("ab", "b")); in TEST_F()
33 EXPECT_TRUE(StringHelper::EndsWith("ab", "ab")); in TEST_F()
34 EXPECT_TRUE(StringHelper::EndsWith("abcd", "bcd")); in TEST_F()
35 EXPECT_TRUE(StringHelper::EndsWith("abcd", "abcd")); in TEST_F()
36 EXPECT_TRUE(StringHelper::EndsWith("abcdefghijk", "ijk")); in TEST_F()
37 EXPECT_TRUE(StringHelper::EndsWith("abcdefghijk", "bcdefghijk")); in TEST_F()
[all …]
/system/tools/hidl/c2hal/
DDeclaration.cpp40 mName = StringHelper::RTrim(mName, "_t"); in forceCamelCase()
41 mName = StringHelper::ToCamelCase(mName); in forceCamelCase()
45 mName = StringHelper::RTrim(mName, "_t"); in forcePascalCase()
46 mName = StringHelper::ToPascalCase(mName); in forcePascalCase()
50 mName = StringHelper::RTrim(mName, "_t"); in forceUpperSnakeCase()
51 mName = StringHelper::ToUpperSnakeCase(mName); in forceUpperSnakeCase()
DExpression.cpp92 std::string toString(StringHelper::Case atomCase) override { in toString()
120 std::string toString(StringHelper::Case atomCase) override { in toString()
122 return mIsId ? StringHelper::ToCase(atomCase, mValue) : mValue; in toString()
144 std::string toString(StringHelper::Case atomCase) override { in toString()
167 std::string toString(StringHelper::Case atomCase) override { in toString()
192 std::string toString(StringHelper::Case atomCase) override { in toString()
215 std::string toString(StringHelper::Case atomCase) override { in toString()
242 std::string toString(StringHelper::Case atomCase) override { in toString()
DExpression.h82 virtual std::string toString(StringHelper::Case atomCase = StringHelper::kNoCase) = 0;
DEnumVarDeclaration.cpp47 out << " = " << mExpression->toString(StringHelper::kUpperSnakeCase); in generateSource()
DType.cpp146 std::string baseName = StringHelper::RTrim(id, "_t"); in getHidlType()
147 ss << StringHelper::ToPascalCase(baseName); in getHidlType()
/system/tools/hidl/host_utils/
DStringHelper.cpp39 std::string StringHelper::Uppercase(const std::string &in) { in Uppercase()
49 std::string StringHelper::Lowercase(const std::string &in) { in Lowercase()
59 std::string StringHelper::Capitalize(const std::string &in) { in Capitalize()
94 void StringHelper::Tokenize(const std::string& in, std::vector<std::string>* vec) { in Tokenize()
138 std::string StringHelper::ToCamelCase(const std::string &in) { in ToCamelCase()
153 std::string StringHelper::ToPascalCase(const std::string &in) { in ToPascalCase()
162 std::string StringHelper::ToUpperSnakeCase(const std::string &in) { in ToUpperSnakeCase()
171 std::string StringHelper::ToLowerSnakeCase(const std::string &in) { in ToLowerSnakeCase()
180 std::string StringHelper::ToCase(StringHelper::Case c, const std::string &in) { in ToCase()
197 bool StringHelper::EndsWith(const std::string &in, const std::string &suffix) { in EndsWith()
[all …]
DAndroid.bp31 "StringHelper.cpp",
/system/tools/hidl/lint/lints/
DnamingConventions.cpp51 std::string desiredName = StringHelper::ToPascalCase(definedName); in namingConventions()
67 if (StringHelper::ToCamelCase(memberName) != memberName) { in namingConventions()
72 << StringHelper::ToCamelCase(memberName) in namingConventions()
79 if (StringHelper::ToUpperSnakeCase(ev->name()) != ev->name()) { in namingConventions()
83 << StringHelper::ToUpperSnakeCase(ev->name()) in namingConventions()
DmethodVersions.cpp54 if (nameWithoutVersion != StringHelper::ToCamelCase(nameWithoutVersion)) { in checkMethodVersion()
98 if (method->name() != StringHelper::ToCamelCase(method->name())) { in methodVersions()
DenumMaxAndAll.cpp46 base::Split(StringHelper::Uppercase(ev->name()), "_"); in enumValueNames()
DmethodDocComment.cpp39 line = StringHelper::LTrim(line, prefix); in getFirstWordAfterPrefix()
47 line = StringHelper::LTrimAll(line, " "); in getFirstWordAfterPrefix()
/system/tools/hidl/host_utils/include/hidl-util/
DStringHelper.h26 struct StringHelper { struct
82 StringHelper() = delete;
/system/tools/hidl/
Dhidl-gen_l.ll54 #include <hidl-util/StringHelper.h>
88 str = StringHelper::LTrim(str, "/");
89 bool isDoc = StringHelper::StartsWith(str, "**");
90 str = StringHelper::LTrimAll(str, "*");
91 str = StringHelper::RTrim(str, "/");
92 str = StringHelper::RTrimAll(str, "*");
DCoordinator.cpp53 if (!mRootPath.empty() && !StringHelper::EndsWith(mRootPath, "/")) { in setRootPath()
205 out << StringHelper::LTrim(forFile, mOutputPath) << ": \\\n"; in writeDepFile()
386 if (StringHelper::StartsWith(path, "/") || mRootPath.empty()) { in makeAbsolute()
394 return StringHelper::LTrim(filename, mRootPath); in makeRelative()
422 std::string suffix = StringHelper::LTrim(fqName.package(), packageRoot->root.package()); in getPackagePath()
423 suffix = StringHelper::LTrim(suffix, "."); in getPackagePath()
426 StringHelper::SplitString(suffix, '.', &suffixComponents); in getPackagePath()
430 components.push_back(StringHelper::RTrimAll(packageRoot->path, "/")); in getPackagePath()
435 *path = StringHelper::JoinStrings(components, "/") + "/"; in getPackagePath()
DAnnotation.cpp116 out << StringHelper::JoinStrings(values, ", "); in dump()
DScope.cpp97 CHECK(FQName::parse(StringHelper::JoinStrings(names, "."), &innerName)); in lookupType()
Dhidl-gen_y.yy38 #include <hidl-util/StringHelper.h>
176 if (StringHelper::StartsWith(identifier, "_hidl_")) {
181 if (StringHelper::StartsWith(identifier, "hidl_")) {
186 if (StringHelper::EndsWith(identifier, "_cb")) {
Dmain.cpp968 guard += StringHelper::Uppercase(packageFQName.tokenName()); in generateExportHeaderForPackage()
1261 return StringHelper::LTrim(fqName.name(), "types.") + ".java"; in __anon226c43a01802()
DgenerateCpp.cpp46 guard += StringHelper::Uppercase(mPackage.tokenName()); in makeHeaderGuard()
48 guard += StringHelper::Uppercase(baseName); in makeHeaderGuard()
DInterface.cpp737 if (StringHelper::EndsWith(definedName(), "Callback")) { in getVtsType()
DAST.cpp513 std::string path = StringHelper::JoinStrings(pathComponents, "."); in makeFullName()
/system/tools/hidl/hidl2aidl/
DAidlHelper.cpp57 names.push_back(StringHelper::Capitalize(name)); in getAidlName()
59 return StringHelper::JoinStrings(names, ""); in getAidlName()
DAidlTranslate.cpp137 out << "out.set" << StringHelper::Capitalize(field.field->name()) in namedTypeTranslation()
320 out << "out.set" << StringHelper::Capitalize(field.fullName) << "(" << cast in simpleTranslation()
DAidlInterface.cpp147 const std::string uppercase = StringHelper::Uppercase(typeName); in shouldWarnStatusType()