Home
last modified time | relevance | path

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

1234

/cts/tests/tests/text/src/android/text/cts/
DSelectionTest.java29 SpannableStringBuilder builder = new SpannableStringBuilder(text); in testGetSelectionStart() local
30 assertEquals(-1, Selection.getSelectionStart(builder)); in testGetSelectionStart()
32 Selection.setSelection(builder, 3, 8); in testGetSelectionStart()
33 assertEquals(3, Selection.getSelectionStart(builder)); in testGetSelectionStart()
35 Selection.setSelection(builder, 3, 9); in testGetSelectionStart()
36 assertEquals(3, Selection.getSelectionStart(builder)); in testGetSelectionStart()
38 Selection.setSelection(builder, 5, 7); in testGetSelectionStart()
39 assertEquals(5, Selection.getSelectionStart(builder)); in testGetSelectionStart()
46 SpannableStringBuilder builder = new SpannableStringBuilder(text); in testGetSelectionEnd() local
47 assertEquals(-1, Selection.getSelectionEnd(builder)); in testGetSelectionEnd()
[all …]
DSpannableStringBuilderTest.java87 SpannableStringBuilder builder = new SpannableStringBuilder("spannable string"); in testGetSpanFlags() local
88 assertEquals(0, builder.getSpanFlags(mUnderlineSpan)); in testGetSpanFlags()
90 builder.setSpan(mUnderlineSpan, 2, 4, Spanned.SPAN_INCLUSIVE_INCLUSIVE); in testGetSpanFlags()
91 builder.setSpan(mUnderlineSpan, 0, 1, Spanned.SPAN_EXCLUSIVE_INCLUSIVE); in testGetSpanFlags()
92 builder.setSpan(mStrikethroughSpan, 5, 7, Spanned.SPAN_INCLUSIVE_EXCLUSIVE); in testGetSpanFlags()
94 assertEquals(Spanned.SPAN_EXCLUSIVE_INCLUSIVE, builder.getSpanFlags(mUnderlineSpan)); in testGetSpanFlags()
95 assertEquals(Spanned.SPAN_INCLUSIVE_EXCLUSIVE, builder.getSpanFlags(mStrikethroughSpan)); in testGetSpanFlags()
96 assertEquals(0, builder.getSpanFlags(new Object())); in testGetSpanFlags()
100 SpannableStringBuilder builder = new SpannableStringBuilder("spannable string"); in testNextSpanTransition() local
102 builder.setSpan(mUnderlineSpan, 1, 2, Spanned.SPAN_INCLUSIVE_INCLUSIVE); in testNextSpanTransition()
[all …]
/cts/tools/signature-tools/src/signature/model/impl/
DSigConstructor.java35 StringBuilder builder = new StringBuilder(); in toString() local
36 builder.append(super.toString()); in toString()
37 builder.append(" "); in toString()
38 builder.append(Modifier.toString(getModifiers())); in toString()
40 builder.append("<"); in toString()
41 builder.append(ModelUtil.separate(getTypeParameters(), ", ")); in toString()
42 builder.append("> "); in toString()
44 builder.append(getName()); in toString()
45 builder.append("("); in toString()
46 builder.append(getParameters().isEmpty() ? "" : ModelUtil.separate( in toString()
[all …]
DSigMethod.java51 StringBuilder builder = new StringBuilder(); in toString() local
52 builder.append(Modifier.toString(method.getModifiers())); in toString()
53 builder.append(method.getReturnType()); in toString()
54 builder.append(" "); in toString()
57 builder.append("<"); in toString()
58 builder in toString()
61 builder.append("> "); in toString()
63 builder.append(method.getName()); in toString()
64 builder.append("("); in toString()
65 builder.append(method.getParameters().isEmpty() ? "" : ModelUtil in toString()
[all …]
DSigAnnotation.java55 StringBuilder builder = new StringBuilder(); in toString() local
56 builder.append("@"); in toString()
57 builder.append(getType()); in toString()
59 builder.append("{"); in toString()
61 builder.append("\n"); in toString()
62 builder.append(element.toString()); in toString()
64 builder.append("}"); in toString()
66 return builder.toString(); in toString()
DSigField.java63 StringBuilder builder = new StringBuilder(); in toString() local
65 builder.append(super.toString()); in toString()
66 builder.append("\n"); in toString()
68 builder.append(Modifier.toString(getModifiers())); in toString()
69 builder.append(getType().toString()); in toString()
70 builder.append(" "); in toString()
71 builder.append(getName()); in toString()
72 return builder.toString(); in toString()
DSigParameter.java40 StringBuilder builder = new StringBuilder(); in toString() local
41 builder.append(super.toString()); in toString()
42 builder.append(" "); in toString()
43 builder.append(getType().toString()); in toString()
44 return builder.toString(); in toString()
DSigWildcardType.java85 StringBuilder builder = new StringBuilder(); in toString() local
86 builder.append("?"); in toString()
88 builder.append(" "); in toString()
89 builder.append(" super "); in toString()
90 builder.append(thiz.getLowerBound()); in toString()
93 builder.append(" extends "); in toString()
94 builder.append(thiz.getUpperBounds()); in toString()
96 return builder.toString(); in toString()
DSigAnnotationElement.java48 StringBuilder builder = new StringBuilder(); in toString() local
49 builder.append(getDeclaringField().getName()); in toString()
50 builder.append(" = "); in toString()
51 builder.append(getValue()); in toString()
52 return builder.toString(); in toString()
DSigParameterizedType.java110 StringBuilder builder = new StringBuilder(); in toString() local
112 builder.append(type.getOwnerType().toString()); in toString()
113 builder.append("::"); in toString()
115 builder.append(type.getRawType()); in toString()
116 builder.append("<"); in toString()
117 builder.append(ModelUtil.separate(type.getTypeArguments(), ", ")); in toString()
118 builder.append(">"); in toString()
119 return builder.toString(); in toString()
DSigTypeVariableDefinition.java60 StringBuilder builder = new StringBuilder(); in toString() local
61 builder.append(name); in toString()
63 builder.append(ModelUtil.separate(getUpperBounds(), ", ")); in toString()
66 builder.append(getUpperBounds().get(0)); in toString()
69 return builder.toString(); in toString()
/cts/tests/uiautomator/test-apps/CtsUiAutomatorApp/src/com/android/cts/uiautomator/
DTest2DetailFragment.java50 AlertDialog.Builder builder = new AlertDialog.Builder(getActivity()); in onOptionsItemSelected() local
51 builder.setTitle(R.string.dialog_title_result); in onOptionsItemSelected()
52 builder.setMessage(item.getTitle()); in onOptionsItemSelected()
53 builder.setPositiveButton(R.string.OK, null); in onOptionsItemSelected()
54 AlertDialog diag = builder.create(); in onOptionsItemSelected()
71 AlertDialog.Builder builder = new AlertDialog.Builder(getActivity()); in onCreateView()
72 builder.setTitle(R.string.dialog_title_result); in onCreateView()
73 builder.setPositiveButton(R.string.OK, null); in onCreateView()
74 builder.setMessage(R.string.button1); in onCreateView()
75 AlertDialog diag = builder.create(); in onCreateView()
[all …]
DTest3DetailFragment.java62 AlertDialog.Builder builder = new AlertDialog.Builder(getActivity()); in onOptionsItemSelected() local
63 builder.setTitle(R.string.dialog_title_result); in onOptionsItemSelected()
64 builder.setMessage(item.getTitle()); in onOptionsItemSelected()
65 builder.setPositiveButton(R.string.OK, null); in onOptionsItemSelected()
66 AlertDialog diag = builder.create(); in onOptionsItemSelected()
102 AlertDialog.Builder builder = new AlertDialog.Builder(getActivity()); in onCreateView()
103 builder.setTitle(R.string.test3_dialog_title); in onCreateView()
104 builder.setPositiveButton(R.string.OK, null); in onCreateView()
108 builder.setMessage("" + (mCurrentTime - inputTime)); in onCreateView()
110 builder.setMessage("<NO DATA>"); in onCreateView()
[all …]
/cts/tools/dex-tools/src/dex/reader/
DTypeFormatter.java92 StringBuilder builder = new StringBuilder(); in format() local
96 builder.append(separator); in format()
98 builder.append(element.toString()); in format()
101 return builder.toString(); in format()
106 StringBuilder builder = new StringBuilder(); in formatDexFile() local
107 builder.append("----------------DEX_FILE--------------\n\n"); in formatDexFile()
108 builder.append("Filename: ").append(file.getName()); in formatDexFile()
109 builder.append("\n-----------DEFINED_CLASSES------------\n\n"); in formatDexFile()
111 builder.append("\n________________CLASS________________\n\n"); in formatDexFile()
112 builder.append(dexClass); in formatDexFile()
[all …]
DDexAnnotationImpl.java69 StringBuilder builder = new StringBuilder(); in toString() local
70 builder.append("@"); in toString()
71 builder.append(formatter.format(encodedAnnotation.getTypeName())); in toString()
73 builder.append(" ("); in toString()
75 builder.append(value.toString()); in toString()
76 builder.append(" "); in toString()
78 builder.append(")"); in toString()
80 return builder.toString(); in toString()
DDexFieldImpl.java95 StringBuilder builder = new StringBuilder(); in toString() local
96 builder.append(formatter.formatAnnotations(getAnnotations())); in toString()
97 builder.append(Modifier.toString(getModifiers())); in toString()
98 builder.append(" "); in toString()
99 builder.append(formatter.format(getType())); in toString()
100 builder.append(" "); in toString()
101 builder.append(getName()); in toString()
102 return builder.toString(); in toString()
DDexMethodImpl.java141 StringBuilder builder = new StringBuilder(); in toString() local
142 builder.append(formatter.formatAnnotations(getAnnotations())); in toString()
143 builder.append(Modifier.toString(getModifiers())); in toString()
144 builder.append(" "); in toString()
145 builder.append(formatter.format(getReturnType())); in toString()
146 builder.append(" "); in toString()
147 builder.append(getName()); in toString()
148 builder.append("("); in toString()
151 builder.append(formatter.formatAnnotations(dexParameter in toString()
153 builder.append(formatter.format(dexParameter.getTypeName())); in toString()
[all …]
/cts/libs/commonutil/src/com/android/cts/util/
DReportLog.java83 StringBuilder builder = new StringBuilder(); in doPrintArray() local
86 builder.append(testId); in doPrintArray()
87 builder.append(LOG_ELEM_SEPARATOR); in doPrintArray()
88 builder.append(message); in doPrintArray()
89 builder.append(LOG_ELEM_SEPARATOR); in doPrintArray()
90 builder.append(type.getXmlString()); in doPrintArray()
91 builder.append(LOG_ELEM_SEPARATOR); in doPrintArray()
92 builder.append(unit.getXmlString()); in doPrintArray()
93 builder.append(LOG_ELEM_SEPARATOR); in doPrintArray()
95 builder.append(v); in doPrintArray()
[all …]
/cts/tests/tests/hardware/src/android/hardware/cts/helpers/
DTestSensorEventListener.java197 StringBuilder builder = new StringBuilder(); in logCollectedEventsToFile() local
198 builder.append("Sensor='").append(mEnvironment.getSensor()).append("', "); in logCollectedEventsToFile()
199 builder.append("SamplingRateOverloaded=") in logCollectedEventsToFile()
201 builder.append("RequestedSamplingPeriod=") in logCollectedEventsToFile()
203 builder.append("MaxReportLatency=") in logCollectedEventsToFile()
213 builder.append("\n"); in logCollectedEventsToFile()
214 builder.append("AP wake-up time=").append(deviceWakeUpTimeMs).append("ms"); in logCollectedEventsToFile()
217 builder.append("\n"); in logCollectedEventsToFile()
218 builder.append("Timestamp=").append(event.timestamp/1000000).append("ms, "); in logCollectedEventsToFile()
219 builder.append("ReceivedTimestamp=").append(event.receivedTimestamp/1000000). in logCollectedEventsToFile()
[all …]
/cts/tools/signature-tools/src/signature/compare/model/impl/
DSigDelta.java81 StringBuilder builder = new StringBuilder(); in toString() local
82 builder.append(getClass().getSimpleName()); in toString()
83 builder.append(":\n"); in toString()
95 builder.append("from: "); in toString()
96 builder.append(from); in toString()
97 builder.append("\nto: "); in toString()
98 builder.append(to); in toString()
99 builder.append("\n"); in toString()
106 builder.append(field.getName()); in toString()
107 builder.append(":\n"); in toString()
[all …]
/cts/tools/cts-api-coverage/src/com/android/cts/apicoverage/
DTextReport.java88 StringBuilder builder = new StringBuilder(" [") in printConstructor() local
95 builder.append(parameterTypes.get(i)); in printConstructor()
97 builder.append(", "); in printConstructor()
100 out.println(builder.append(")")); in printConstructor()
104 StringBuilder builder = new StringBuilder(" [") in printMethod() local
109 builder.append("abstract "); in printMethod()
112 builder.append("static "); in printMethod()
115 builder.append("final "); in printMethod()
117 builder.append(method.getReturnType()).append(" ") in printMethod()
122 builder.append(parameterTypes.get(i)); in printMethod()
[all …]
/cts/suite/cts/deviceTests/videoperf/src/com/android/cts/videoperf/
DCodecInfo.java98 StringBuilder builder = new StringBuilder(); in printIntArray() local
99 builder.append(msg); in printIntArray()
100 builder.append(":"); in printIntArray()
102 builder.append(Integer.toHexString(e)); in printIntArray()
103 builder.append(","); in printIntArray()
105 builder.deleteCharAt(builder.length() - 1); in printIntArray()
106 Log.i(TAG, builder.toString()); in printIntArray()
/cts/apps/CtsVerifier/src/com/android/cts/verifier/nfc/hce/
DBaseEmulatorActivity.java89 AlertDialog.Builder builder = new AlertDialog.Builder(this); in makePaymentDefault() local
90 builder.setTitle("Note"); in makePaymentDefault()
91 builder.setMessage(stringId); in makePaymentDefault()
93 builder.setPositiveButton("OK", new DialogInterface.OnClickListener() { in makePaymentDefault()
102 builder.show(); in makePaymentDefault()
173 AlertDialog.Builder builder = new AlertDialog.Builder(this); in onActivityResult() local
174 builder.setTitle("Test failed."); in onActivityResult()
175 builder.setMessage("The service was not made the default service according " + in onActivityResult()
178 builder.setPositiveButton("OK", null); in onActivityResult()
179 builder.show(); in onActivityResult()
[all …]
/cts/tests/tests/net/src/android/net/cts/
DUri_BuilderTest.java26 Builder builder = uri.buildUpon(); in testBuilderOperations() local
27 uri = builder.appendPath("p2").build(); in testBuilderOperations()
33 assertEquals(uri.toString(), builder.toString()); in testBuilderOperations()
36 builder = uri.buildUpon(); in testBuilderOperations()
37 uri = builder.build(); in testBuilderOperations()
40 assertEquals(uri.toString(), builder.toString()); in testBuilderOperations()
/cts/common/util/src/com/android/compatibility/common/util/
DReportLog.java103 StringBuilder builder = new StringBuilder() in toEncodedString() local
115 builder.append(value).append(" "); in toEncodedString()
117 return builder.toString(); in toEncodedString()
217 StringBuilder builder = new StringBuilder(); in toEncodedString() local
218 builder.append(mSummary.toEncodedString()); in toEncodedString()
219 builder.append(SUMMARY_SEPARATOR); in toEncodedString()
221 builder.append(result.toEncodedString()); in toEncodedString()
222 builder.append(LOG_SEPARATOR); in toEncodedString()
225 if (builder.length() >= LOG_SEPARATOR.length()) { in toEncodedString()
226 builder.delete(builder.length() - LOG_SEPARATOR.length(), builder.length()); in toEncodedString()
[all …]

1234