Share via


Preference.PersistString(String) Method

Definition

Attempts to persist a String if this Preference is persistent.

[Android.Runtime.Register("persistString", "(Ljava/lang/String;)Z", "GetPersistString_Ljava_lang_String_Handler")]
protected virtual bool PersistString (string? value);
[<Android.Runtime.Register("persistString", "(Ljava/lang/String;)Z", "GetPersistString_Ljava_lang_String_Handler")>]
abstract member PersistString : string -> bool
override this.PersistString : string -> bool

Parameters

value
String

The value to persist.

Returns

True if this Preference is persistent. (This is not whether the value was persisted, since we may not necessarily commit if there will be a batch commit later.)

Attributes

Remarks

Attempts to persist a String if this Preference is persistent.

Java documentation for android.preference.Preference.persistString(java.lang.String).

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

Applies to

See also