MCPcopy Index your code
hub / github.com/callstack/agent-device / upsertAndroidStringPref

Function upsertAndroidStringPref

src/daemon/runtime-hints.ts:232–235  ·  view source on GitHub ↗
(xml: string, key: string, value: string)

Source from the content-addressed store, hash-verified

230}
231
232function upsertAndroidStringPref(xml: string, key: string, value: string): string {
233 const entry = ` <string name="${escapeXmlText(key)}">${escapeXmlText(value)}</string>`;
234 return insertAndroidPrefEntry(removeAndroidPrefEntry(xml, key), entry);
235}
236
237function upsertAndroidBooleanPref(xml: string, key: string, value: boolean): string {
238 const entry = ` <boolean name="${escapeXmlText(key)}" value="${value ? 'true' : 'false'}" />`;

Callers 1

applyAndroidRuntimeHintsFunction · 0.85

Calls 3

escapeXmlTextFunction · 0.85
insertAndroidPrefEntryFunction · 0.85
removeAndroidPrefEntryFunction · 0.85

Tested by

no test coverage detected