Home
last modified time | relevance | path

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

123456

/frameworks/base/cmds/uiautomator/library/core-src/com/android/uiautomator/core/
DAccessibilityNodeInfoDumper.java90 XmlSerializer serializer = Xml.newSerializer(); in dumpWindowToFile() local
92 serializer.setOutput(stringWriter); in dumpWindowToFile()
93 serializer.startDocument("UTF-8", true); in dumpWindowToFile()
94 serializer.startTag("", "hierarchy"); in dumpWindowToFile()
95 serializer.attribute("", "rotation", Integer.toString(rotation)); in dumpWindowToFile()
96 dumpNodeRec(root, serializer, 0, width, height); in dumpWindowToFile()
97 serializer.endTag("", "hierarchy"); in dumpWindowToFile()
98 serializer.endDocument(); in dumpWindowToFile()
123 XmlSerializer serializer = Xml.newSerializer(); in dumpWindowsToFile() local
125 serializer.setOutput(stringWriter); in dumpWindowsToFile()
[all …]
/frameworks/base/libs/WindowManager/Shell/src/com/android/wm/shell/bubbles/storage/
DBubbleXmlHelper.kt53 val serializer: XmlSerializer = FastXmlSerializer() in <lambda>() constant
54 serializer.setOutput(stream, StandardCharsets.UTF_8.name()) in <lambda>()
55 serializer.startDocument(null, true) in <lambda>()
56 serializer.startTag(null, TAG_BUBBLES) in <lambda>()
57 serializer.attribute(null, ATTR_VERSION, CURRENT_VERSION.toString()) in <lambda>()
61 serializer.startTag(null, TAG_BUBBLES) in <lambda>()
62 serializer.attribute(null, ATTR_USER_ID, k.toString()) in <lambda>()
63 v.forEach { b -> writeXmlEntry(serializer, b) } in <lambda>()
64 serializer.endTag(null, TAG_BUBBLES) in <lambda>()
66 serializer.endTag(null, TAG_BUBBLES) in <lambda>()
[all …]
/frameworks/base/services/core/java/com/android/server/display/
DPersistentDataStore.java492 TypedXmlSerializer serializer = Xml.resolveSerializer(os); in save() local
493 saveToXml(serializer); in save()
494 serializer.flush(); in save()
587 private void saveToXml(TypedXmlSerializer serializer) throws IOException { in saveToXml() argument
588 serializer.startDocument(null, true); in saveToXml()
589 serializer.setFeature("http://xmlpull.org/v1/doc/features.html#indent-output", true); in saveToXml()
590 serializer.startTag(null, TAG_DISPLAY_MANAGER_STATE); in saveToXml()
591 serializer.startTag(null, TAG_REMEMBERED_WIFI_DISPLAYS); in saveToXml()
593 serializer.startTag(null, TAG_WIFI_DISPLAY); in saveToXml()
594 serializer.attribute(null, ATTR_DEVICE_ADDRESS, display.getDeviceAddress()); in saveToXml()
[all …]
/frameworks/opt/net/ims/tests/src/com/android/ims/rcs/uce/presence/pidfparser/pidf/
DBasicTest.java70 XmlSerializer serializer = getXmlSerializer(writer); in testSerializingWithBasicOpen() local
73 serializer.startDocument(PidfParserConstant.ENCODING_UTF_8, true); in testSerializingWithBasicOpen()
74 basic.serialize(serializer); in testSerializingWithBasicOpen()
75 serializer.endDocument(); in testSerializingWithBasicOpen()
76 serializer.flush(); in testSerializingWithBasicOpen()
89 XmlSerializer serializer = getXmlSerializer(writer); in testSerializingWithBasicClosed() local
92 serializer.startDocument(PidfParserConstant.ENCODING_UTF_8, true); in testSerializingWithBasicClosed()
93 basic.serialize(serializer); in testSerializingWithBasicClosed()
94 serializer.endDocument(); in testSerializingWithBasicClosed()
95 serializer.flush(); in testSerializingWithBasicClosed()
[all …]
DNoteTest.java72 XmlSerializer serializer = getXmlSerializer(writer); in testSerializing() local
75 serializer.startDocument(PidfParserConstant.ENCODING_UTF_8, true); in testSerializing()
76 note.serialize(serializer); in testSerializing()
77 serializer.endDocument(); in testSerializing()
78 serializer.flush(); in testSerializing()
127 XmlSerializer serializer = factory.newSerializer(); in getXmlSerializer() local
128 serializer.setOutput(writer); in getXmlSerializer()
129 serializer.setPrefix("", PidfConstant.NAMESPACE); in getXmlSerializer()
130 return serializer; in getXmlSerializer()
DStatusTest.java73 XmlSerializer serializer = getXmlSerializer(writer); in testSerializing() local
76 serializer.startDocument(PidfParserConstant.ENCODING_UTF_8, true); in testSerializing()
77 status.serialize(serializer); in testSerializing()
78 serializer.endDocument(); in testSerializing()
79 serializer.flush(); in testSerializing()
125 XmlSerializer serializer = factory.newSerializer(); in getXmlSerializer() local
126 serializer.setOutput(writer); in getXmlSerializer()
127 serializer.setPrefix("", PidfConstant.NAMESPACE); in getXmlSerializer()
128 return serializer; in getXmlSerializer()
DContactTest.java74 XmlSerializer serializer = getXmlSerializer(writer); in testSerializing() local
77 serializer.startDocument(PidfParserConstant.ENCODING_UTF_8, true); in testSerializing()
78 contact.serialize(serializer); in testSerializing()
79 serializer.endDocument(); in testSerializing()
80 serializer.flush(); in testSerializing()
129 XmlSerializer serializer = factory.newSerializer(); in getXmlSerializer() local
130 serializer.setOutput(writer); in getXmlSerializer()
131 serializer.setPrefix("", PidfConstant.NAMESPACE); in getXmlSerializer()
132 return serializer; in getXmlSerializer()
DTimestampTest.java73 XmlSerializer serializer = getXmlSerializer(writer); in testSerializing() local
76 serializer.startDocument(PidfParserConstant.ENCODING_UTF_8, true); in testSerializing()
77 timestampElement.serialize(serializer); in testSerializing()
78 serializer.endDocument(); in testSerializing()
79 serializer.flush(); in testSerializing()
129 XmlSerializer serializer = factory.newSerializer(); in getXmlSerializer() local
130 serializer.setOutput(writer); in getXmlSerializer()
131 serializer.setPrefix("", PidfConstant.NAMESPACE); in getXmlSerializer()
132 return serializer; in getXmlSerializer()
/frameworks/base/services/core/java/com/android/server/tv/
DPersistentDataStore.java198 TypedXmlSerializer serializer = Xml.resolveSerializer(os); in save() local
199 saveToXml(serializer); in save()
200 serializer.flush(); in save()
263 private void saveToXml(TypedXmlSerializer serializer) throws IOException { in saveToXml() argument
264 serializer.startDocument(null, true); in saveToXml()
265 serializer.setFeature("http://xmlpull.org/v1/doc/features.html#indent-output", true); in saveToXml()
266 serializer.startTag(null, TAG_TV_INPUT_MANAGER_STATE); in saveToXml()
267 serializer.startTag(null, TAG_BLOCKED_RATINGS); in saveToXml()
270 serializer.startTag(null, TAG_RATING); in saveToXml()
271 serializer.attribute(null, ATTR_STRING, rating.flattenToString()); in saveToXml()
[all …]
/frameworks/base/apct-tests/perftests/core/src/android/libcore/
DXmlSerializePerfTest.java72 XmlSerializer serializer = (XmlSerializer) ctor.newInstance(); in serializeRandomXml() local
75 serializer.setOutput(w); in serializeRandomXml()
79 serializer.startDocument("UTF-8", true); in serializeRandomXml()
82 serializer.endTag("aaaaaa", "bbbbbb"); in serializeRandomXml()
86 serializer.startTag("aaaaaa", "bbbbbb"); in serializeRandomXml()
89 serializer.startTag("aaaaaa", "bbbbbb"); in serializeRandomXml()
92 serializer.attribute("aaaaaa", "cccccc", "dddddd"); in serializeRandomXml()
94 serializer.endTag("aaaaaa", "bbbbbb"); in serializeRandomXml()
96 while (r.nextDouble() < writeChance1) serializer.text(toWrite, 0, 5); in serializeRandomXml()
97 while (r.nextDouble() < writeChance2) serializer.text("Textxtsxtxtxt "); in serializeRandomXml()
[all …]
/frameworks/base/services/companion/java/com/android/server/companion/
DSystemDataTransferRequestDataStore.java176 final TypedXmlSerializer serializer = Xml.resolveSerializer(out); in writeRequestsForUser()
177 serializer.setFeature( in writeRequestsForUser()
179 serializer.startDocument(null, true); in writeRequestsForUser()
180 writeRequests(serializer, requests); in writeRequestsForUser()
181 serializer.endDocument(); in writeRequestsForUser()
186 private void writeRequests(@NonNull TypedXmlSerializer serializer, in writeRequests() argument
188 serializer.startTag(null, XML_TAG_REQUESTS); in writeRequests()
191 writeRequest(serializer, request); in writeRequests()
194 serializer.endTag(null, XML_TAG_REQUESTS); in writeRequests()
197 private void writeRequest(@NonNull TypedXmlSerializer serializer, in writeRequest() argument
[all …]
DPersistentDataStore.java353 final TypedXmlSerializer serializer = Xml.resolveSerializer(out); in persistStateToFileLocked()
354 serializer.setFeature( in persistStateToFileLocked()
357 serializer.startDocument(null, true); in persistStateToFileLocked()
358 serializer.startTag(null, XML_TAG_STATE); in persistStateToFileLocked()
359 writeIntAttribute(serializer, in persistStateToFileLocked()
362 writeAssociations(serializer, associations); in persistStateToFileLocked()
363 writePreviouslyUsedIds(serializer, previouslyUsedIdsPerPackage); in persistStateToFileLocked()
365 serializer.endTag(null, XML_TAG_STATE); in persistStateToFileLocked()
366 serializer.endDocument(); in persistStateToFileLocked()
494 final XmlSerializer serializer = parent.startTag(null, XML_TAG_ASSOCIATIONS); in writeAssociations() local
[all …]
/frameworks/base/services/core/java/com/android/server/input/
DPersistentDataStore.java240 TypedXmlSerializer serializer = Xml.resolveSerializer(os); in save() local
241 saveToXml(serializer); in save()
242 serializer.flush(); in save()
288 private void saveToXml(TypedXmlSerializer serializer) throws IOException { in saveToXml() argument
289 serializer.startDocument(null, true); in saveToXml()
290 serializer.setFeature("http://xmlpull.org/v1/doc/features.html#indent-output", true); in saveToXml()
291 serializer.startTag(null, "input-manager-state"); in saveToXml()
292 serializer.startTag(null, "input-devices"); in saveToXml()
296 serializer.startTag(null, "input-device"); in saveToXml()
297 serializer.attribute(null, "descriptor", descriptor); in saveToXml()
[all …]
/frameworks/opt/net/ims/src/java/com/android/ims/rcs/uce/presence/pidfparser/capabilities/
DDuplex.java104 public void serialize(XmlSerializer serializer) throws IOException { in serialize() argument
110 serializer.startTag(namespace, elementName); in serialize()
112 serializer.startTag(namespace, ELEMENT_SUPPORTED); in serialize()
113 serializer.startTag(namespace, supportedType); in serialize()
114 serializer.endTag(namespace, supportedType); in serialize()
115 serializer.endTag(namespace, ELEMENT_SUPPORTED); in serialize()
118 serializer.startTag(namespace, ELEMENT_NOT_SUPPORTED); in serialize()
119 serializer.startTag(namespace, notSupportedType); in serialize()
120 serializer.endTag(namespace, notSupportedType); in serialize()
121 serializer.endTag(namespace, ELEMENT_NOT_SUPPORTED); in serialize()
[all …]
/frameworks/opt/net/ims/tests/src/com/android/ims/rcs/uce/presence/pidfparser/capabilities/
DAudioTest.java71 XmlSerializer serializer = getXmlSerializer(writer); in testSerializing() local
74 serializer.startDocument(PidfParserConstant.ENCODING_UTF_8, true); in testSerializing()
75 audio.serialize(serializer); in testSerializing()
76 serializer.endDocument(); in testSerializing()
77 serializer.flush(); in testSerializing()
129 XmlSerializer serializer = factory.newSerializer(); in getXmlSerializer() local
130 serializer.setOutput(writer); in getXmlSerializer()
131 serializer.setPrefix("", PidfConstant.NAMESPACE); in getXmlSerializer()
132 serializer.setPrefix("caps", CapsConstant.NAMESPACE); in getXmlSerializer()
133 return serializer; in getXmlSerializer()
DVideoTest.java71 XmlSerializer serializer = getXmlSerializer(writer); in testSerializing() local
74 serializer.startDocument(PidfParserConstant.ENCODING_UTF_8, true); in testSerializing()
75 video.serialize(serializer); in testSerializing()
76 serializer.endDocument(); in testSerializing()
77 serializer.flush(); in testSerializing()
129 XmlSerializer serializer = factory.newSerializer(); in getXmlSerializer() local
130 serializer.setOutput(writer); in getXmlSerializer()
131 serializer.setPrefix("", PidfConstant.NAMESPACE); in getXmlSerializer()
132 serializer.setPrefix("caps", CapsConstant.NAMESPACE); in getXmlSerializer()
133 return serializer; in getXmlSerializer()
DDuplexTest.java74 XmlSerializer serializer = getXmlSerializer(writer); in testSerializing() local
77 serializer.startDocument(PidfParserConstant.ENCODING_UTF_8, true); in testSerializing()
78 duplex.serialize(serializer); in testSerializing()
79 serializer.endDocument(); in testSerializing()
80 serializer.flush(); in testSerializing()
141 XmlSerializer serializer = factory.newSerializer(); in getXmlSerializer() local
142 serializer.setOutput(writer); in getXmlSerializer()
143 serializer.setPrefix("", PidfConstant.NAMESPACE); in getXmlSerializer()
144 serializer.setPrefix("caps", CapsConstant.NAMESPACE); in getXmlSerializer()
145 return serializer; in getXmlSerializer()
/frameworks/opt/net/ims/tests/src/com/android/ims/rcs/uce/presence/pidfparser/omapres/
DDescriptionTest.java73 XmlSerializer serializer = getXmlSerializer(writer); in testSerializing() local
76 serializer.startDocument(PidfParserConstant.ENCODING_UTF_8, true); in testSerializing()
77 description.serialize(serializer); in testSerializing()
78 serializer.endDocument(); in testSerializing()
79 serializer.flush(); in testSerializing()
133 XmlSerializer serializer = factory.newSerializer(); in getXmlSerializer() local
134 serializer.setOutput(writer); in getXmlSerializer()
135 serializer.setPrefix("", PidfConstant.NAMESPACE); in getXmlSerializer()
136 serializer.setPrefix("op", OmaPresConstant.NAMESPACE); in getXmlSerializer()
137 return serializer; in getXmlSerializer()
DVersionTest.java74 XmlSerializer serializer = getXmlSerializer(writer); in testSerializing() local
77 serializer.startDocument(PidfParserConstant.ENCODING_UTF_8, true); in testSerializing()
78 version.serialize(serializer); in testSerializing()
79 serializer.endDocument(); in testSerializing()
80 serializer.flush(); in testSerializing()
134 XmlSerializer serializer = factory.newSerializer(); in getXmlSerializer() local
135 serializer.setOutput(writer); in getXmlSerializer()
136 serializer.setPrefix("", PidfConstant.NAMESPACE); in getXmlSerializer()
137 serializer.setPrefix("op", OmaPresConstant.NAMESPACE); in getXmlSerializer()
138 return serializer; in getXmlSerializer()
DServiceIdTest.java73 XmlSerializer serializer = getXmlSerializer(writer); in testSerializing() local
76 serializer.startDocument(PidfParserConstant.ENCODING_UTF_8, true); in testSerializing()
77 serviceId.serialize(serializer); in testSerializing()
78 serializer.endDocument(); in testSerializing()
79 serializer.flush(); in testSerializing()
133 XmlSerializer serializer = factory.newSerializer(); in getXmlSerializer() local
134 serializer.setOutput(writer); in getXmlSerializer()
135 serializer.setPrefix("", PidfConstant.NAMESPACE); in getXmlSerializer()
136 serializer.setPrefix("op", OmaPresConstant.NAMESPACE); in getXmlSerializer()
137 return serializer; in getXmlSerializer()
DServiceDescriptionTest.java79 XmlSerializer serializer = getXmlSerializer(writer); in testSerializing() local
82 serializer.startDocument(PidfParserConstant.ENCODING_UTF_8, true); in testSerializing()
83 serviceDescription.serialize(serializer); in testSerializing()
84 serializer.endDocument(); in testSerializing()
85 serializer.flush(); in testSerializing()
144 XmlSerializer serializer = factory.newSerializer(); in getXmlSerializer() local
145 serializer.setOutput(writer); in getXmlSerializer()
146 serializer.setPrefix("", PidfConstant.NAMESPACE); in getXmlSerializer()
147 serializer.setPrefix("op", OmaPresConstant.NAMESPACE); in getXmlSerializer()
148 return serializer; in getXmlSerializer()
/frameworks/base/services/core/java/com/android/server/biometrics/sensors/fingerprint/
DFingerprintUserState.java74 protected void doWriteState(@NonNull TypedXmlSerializer serializer) throws Exception { in doWriteState() argument
81 serializer.startTag(null, TAG_FINGERPRINTS); in doWriteState()
86 serializer.startTag(null, TAG_FINGERPRINT); in doWriteState()
87 serializer.attributeInt(null, ATTR_FINGER_ID, fp.getBiometricId()); in doWriteState()
88 serializer.attribute(null, ATTR_NAME, fp.getName().toString()); in doWriteState()
89 serializer.attributeInt(null, ATTR_GROUP_ID, fp.getGroupId()); in doWriteState()
90 serializer.attributeLong(null, ATTR_DEVICE_ID, fp.getDeviceId()); in doWriteState()
91 serializer.endTag(null, TAG_FINGERPRINT); in doWriteState()
94 serializer.endTag(null, TAG_FINGERPRINTS); in doWriteState()
/frameworks/base/services/core/java/com/android/server/pm/
DPackageSignatures.java56 void writeXml(TypedXmlSerializer serializer, String tagName, in writeXml() argument
61 serializer.startTag(null, tagName); in writeXml()
62 serializer.attributeInt(null, "count", mSigningDetails.getSignatures().length); in writeXml()
63 serializer.attributeInt(null, "schemeVersion", mSigningDetails.getSignatureSchemeVersion()); in writeXml()
64 writeCertsListXml(serializer, writtenSignatures, mSigningDetails.getSignatures(), false); in writeXml()
68 serializer.startTag(null, "pastSigs"); in writeXml()
69 serializer.attributeInt(null, "count", in writeXml()
71 writeCertsListXml(serializer, writtenSignatures, in writeXml()
73 serializer.endTag(null, "pastSigs"); in writeXml()
75 serializer.endTag(null, tagName); in writeXml()
[all …]
/frameworks/base/packages/PackageInstaller/src/com/android/packageinstaller/
DEventResultPersister.java240 XmlSerializer serializer = Xml.newSerializer(); in writeState() local
241 serializer.setOutput(stream, StandardCharsets.UTF_8.name()); in writeState()
242 serializer.startDocument(null, true); in writeState()
243 serializer.setFeature( in writeState()
245 serializer.startTag(null, "results"); in writeState()
246 serializer.attribute(null, "counter", Integer.toString(counter)); in writeState()
250 serializer.startTag(null, "result"); in writeState()
251 serializer.attribute(null, "id", in writeState()
253 serializer.attribute(null, "status", in writeState()
255 serializer.attribute(null, "legacyStatus", in writeState()
[all …]
/frameworks/base/packages/PrintSpooler/src/com/android/printspooler/model/
DPrintSpoolerService.java924 XmlSerializer serializer = new FastXmlSerializer(); in doWriteStateLocked() local
925 serializer.setOutput(out, StandardCharsets.UTF_8.name()); in doWriteStateLocked()
926 serializer.startDocument(null, true); in doWriteStateLocked()
927 serializer.startTag(null, TAG_SPOOLER); in doWriteStateLocked()
939 serializer.startTag(null, TAG_JOB); in doWriteStateLocked()
941 serializer.attribute(null, ATTR_ID, printJob.getId().flattenToString()); in doWriteStateLocked()
942 serializer.attribute(null, ATTR_LABEL, printJob.getLabel().toString()); in doWriteStateLocked()
943 serializer.attribute(null, ATTR_STATE, String.valueOf(printJob.getState())); in doWriteStateLocked()
944 serializer.attribute(null, ATTR_APP_ID, String.valueOf(printJob.getAppId())); in doWriteStateLocked()
947 serializer.attribute(null, ATTR_TAG, tag); in doWriteStateLocked()
[all …]

123456