LocaleStorage class abstract

Contract for persisting user locale selection across browser sessions.

Pure-Dart interface. In browser environments, adapters can implement this using window.localStorage without introducing browser dependencies into core logic. In SSR or test environments, InMemoryLocaleStorage provides an in-memory fallback.

See also:

Constructors

LocaleStorage()

Properties

hashCode → int
The hash code for this object.
no setterinherited
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited

Methods

load() → Future<String?>
Loads the persisted locale identifier, or null if none saved.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
save(String locale) → Future<void>
Persists locale for future application sessions.
toString() → String
A string representation of this object.
inherited

Operators

operator ==(Object other) → bool
The equality operator.
inherited