Home
last modified time | relevance | path

Searched refs:tokens (Results 1 – 16 of 16) sorted by relevance

/cts/suite/audio_quality/lib/src/task/
DTaskSound.cpp64 std::unique_ptr<std::vector<android::String8> > tokens(StringUtil::split(type, ':')); in run() local
65 if (tokens.get() == NULL) { in run()
70 if (StringUtil::compare(tokens->at(0), "file") == 0) { in run()
71 if (tokens->size() != 2) { in run()
72 LOGE("Wrong number of parameters %d", tokens->size()); in run()
74 buffer = Buffer::loadFromFile(tokens->at(1)); in run()
75 } else if (StringUtil::compare(tokens->at(0), "sin") == 0) { in run()
76 if (tokens->size() != 4) { in run()
77 LOGE("Wrong number of parameters %d", tokens->size()); in run()
79 int amplitude = atoi(tokens->at(1).string()); in run()
[all …]
DTaskProcess.cpp254 std::vector<android::String8>& tokens = *(paramTokens.get()); in parseParams() local
255 for (size_t i = 0; i < tokens.size(); i++) { in parseParams()
256 std::unique_ptr<std::vector<android::String8>> itemTokens(StringUtil::split(tokens[i], in parseParams()
300 std::vector<android::String8>* tokens = tokenPtr.get(); in parseAttribute() local
301 if (tokens == NULL) { in parseAttribute()
305 if (tokens->size() != 2) { in parseAttribute()
309 if (StringUtil::compare(tokens->at(0), "builtin") == 0) { in parseAttribute()
311 } else if (StringUtil::compare(tokens->at(0), "script") == 0) { in parseAttribute()
317 mName.append(tokens->at(1)); in parseAttribute()
/cts/suite/audio_quality/test/
DStringUtilTest.cpp56 std::vector<android::String8>* tokens = StringUtil::split(str, ':'); in TEST_F() local
57 ASSERT_TRUE(tokens != NULL); in TEST_F()
58 ASSERT_TRUE(tokens->size() == 4); in TEST_F()
59 ASSERT_TRUE(StringUtil::compare(tokens->at(0), "hello") == 0); in TEST_F()
60 ASSERT_TRUE(StringUtil::compare(tokens->at(1), "there") == 0); in TEST_F()
61 ASSERT_TRUE(StringUtil::compare(tokens->at(2), "break") == 0); in TEST_F()
62 ASSERT_TRUE(StringUtil::compare(tokens->at(3), "this") == 0); in TEST_F()
63 delete tokens; in TEST_F()
/cts/tests/tests/text/src/android/text/util/cts/
DRfc822TokenizerTest.java131 Rfc822Token[] tokens = Rfc822Tokenizer.tokenize(""); in testTokenize() local
132 assertEquals(0, tokens.length); in testTokenize()
135 tokens = Rfc822Tokenizer.tokenize(text); in testTokenize()
136 assertEquals(2, tokens.length); in testTokenize()
137 verifyLocalAssertEquals(tokens[0], "Berg", "berg\\@example.com", "home"); in testTokenize()
138 verifyLocalAssertEquals(tokens[1], null, "tom\\@example.com", "work"); in testTokenize()
141 tokens = Rfc822Tokenizer.tokenize(text); in testTokenize()
142 assertEquals(2, tokens.length); in testTokenize()
143 verifyLocalAssertEquals(tokens[0], "Foo Bar", "foo\\@example.com", "something"); in testTokenize()
144 verifyLocalAssertEquals(tokens[1], null, "blah\\@example.com", "something"); in testTokenize()
/cts/hostsidetests/devicepolicy/src/com/android/cts/devicepolicy/
DBaseDevicePolicyTest.java335 String[] tokens = lines[i].split("\\{|\\}|:"); in getUserFlags() local
337 tokens.length == 4 || tokens.length == 5); in getUserFlags()
339 if (Integer.parseInt(tokens[1]) == userId) { in getUserFlags()
340 return Integer.parseInt(tokens[3], 16); in getUserFlags()
595 String[] tokens = feature.split(":"); in hasDeviceFeature() local
597 tokens.length > 1); in hasDeviceFeature()
598 assertEquals(feature, "feature", tokens[0]); in hasDeviceFeature()
599 mAvailableFeatures.add(tokens[1]); in hasDeviceFeature()
634 String[] tokens = commandOutput.split("\\s+"); in createUser() local
635 assertTrue(tokens.length > 0); in createUser()
[all …]
/cts/tools/release-parser/src/com/android/cts/releaseparser/
DTestSuiteTradefedParser.java161 String[] tokens = ln.split(" = "); in parseFile() local
162 switch (tokens[0]) { in parseFile()
164 mBuildNumber = tokens[1]; in parseFile()
167 mTargetArch = tokens[1]; in parseFile()
170 mName = tokens[1]; in parseFile()
173 mFullname = tokens[1]; in parseFile()
176 mVersion = tokens[1]; in parseFile()
/cts/hostsidetests/media/src/android/media/cts/
DBaseMultiUserTest.java186 String[] tokens = commandOutput.split("\\s+"); in createAndStartUser() local
187 assertTrue(tokens.length > 0); in createAndStartUser()
188 assertEquals("Success:", tokens[0]); in createAndStartUser()
189 int userId = Integer.parseInt(tokens[tokens.length-1]); in createAndStartUser()
360 String[] tokens = feature.split(":"); in hasDeviceFeature() local
363 tokens.length > 1); in hasDeviceFeature()
364 assertEquals(feature, "feature", tokens[0]); in hasDeviceFeature()
365 mAvailableFeatures.add(tokens[1]); in hasDeviceFeature()
/cts/tests/tests/jni/src/android/jni/cts/
DLinkerNamespacesHelper.java121 String[] tokens = line.split(" "); in readPublicLibrariesFile() local
122 if (tokens.length < 1 || tokens.length > 3) { in readPublicLibrariesFile()
125 String soname = tokens[0]; in readPublicLibrariesFile()
127 int i = tokens.length; in readPublicLibrariesFile()
129 if (tokens[i].equals("nopreload")) { in readPublicLibrariesFile()
132 else if (tokens[i].equals("32") || tokens[i].equals("64")) { in readPublicLibrariesFile()
137 bitness = tokens[i].equals("32") ? Bitness.ONLY_32 : Bitness.ONLY_64; in readPublicLibrariesFile()
139 throw new RuntimeException("Unrecognized token '" + tokens[i] + in readPublicLibrariesFile()
/cts/suite/audio_quality/lib/src/
DStringUtil.cpp26 std::vector<android::String8>* tokens = new std::vector<android::String8>(); in split() local
31 tokens->push_back(substr(str, lastTokenEnd, i - lastTokenEnd)); in split()
37 tokens->push_back(substr(str, lastTokenEnd, str.length() - lastTokenEnd)); in split()
39 return tokens; in split()
/cts/hostsidetests/apex/src/android/apex/cts/
DApexTest.java129 String[] tokens = mountInfoLine.split(" "); in MountEntry() local
130 if (tokens.length < 5) { in MountEntry()
133 mountId = Integer.parseInt(tokens[0]); in MountEntry()
134 mountPoint = tokens[4]; in MountEntry()
/cts/hostsidetests/tv/src/com/android/cts/tv/
DTvInputManagerHostTest.java141 String[] tokens = feature.split(":"); in hasDeviceFeature() local
143 tokens.length > 1); in hasDeviceFeature()
144 assertEquals(feature, "feature", tokens[0]); in hasDeviceFeature()
145 mAvailableFeatures.add(tokens[1]); in hasDeviceFeature()
/cts/tests/tests/media/src/android/media/cts/
DMediaSession2ServiceTest.java205 final List<Session2Token> tokens = new ArrayList<>(); in testOnGetSession_returnsDifferentSessions() local
211 tokens.add(session.getToken()); in testOnGetSession_returnsDifferentSessions()
224 assertEquals(2, tokens.size()); in testOnGetSession_returnsDifferentSessions()
225 assertEquals(tokens.get(0), controller1.getConnectedToken()); in testOnGetSession_returnsDifferentSessions()
226 assertEquals(tokens.get(1), controller2.getConnectedToken()); in testOnGetSession_returnsDifferentSessions()
DMediaSessionManagerTest.java399 private boolean listContainsToken(List<Session2Token> tokens, Session2Token token) { in listContainsToken() argument
400 for (int i = 0; i < tokens.size(); i++) { in listContainsToken()
401 if (tokens.get(i).equals(token)) { in listContainsToken()
513 public void onSession2TokensChanged(List<Session2Token> tokens) { in onSession2TokensChanged() argument
514 mTokens = tokens; in onSession2TokensChanged()
DMediaPlayerTest.java471 StringTokenizer tokens = new StringTokenizer(plainText.trim(), ":");
472 int subtitleTrackIndex = Integer.parseInt(tokens.nextToken());
473 int startMs = Integer.parseInt(tokens.nextToken());
/cts/tests/tests/text/src/android/text/method/cts/
DEditorState.java88 final String[] tokens = string.split(" +"); in setByString() local
89 for (String token : tokens) { in setByString()
/cts/hostsidetests/numberblocking/src/com/android/cts/numberblocking/hostside/
DNumberBlockingTest.java245 String[] tokens = commandOutput.split("\\n"); in getUserSerialNumber() local
246 for (String token : tokens) { in getUserSerialNumber()