PersistCookieJar class Null safety

PersistCookieJar is a cookie manager which implements the standard cookie policy declared in RFC. PersistCookieJar persists the cookies in files, so if the application exit, the cookies always exist unless call delete explicitly.

Inheritance

Constructors

PersistCookieJar({bool persistSession = true, bool ignoreExpires = false, Storage? storage})
persistSession: Whether persisting the cookies that without "expires" or "max-age" attribute; If false, the session cookies will be discarded; otherwise, the session cookies will be persisted.

Properties

domainCookies Map<String, Map<String, Map<String, SerializableCookie>>>
read-onlyinherited
DomainsKey String
final
hashCode int
The hash code for this object.
read-onlyinherited
hostCookies Map<String, Map<String, Map<String, SerializableCookie>>>
read-onlyinherited
ignoreExpires bool
finalinherited
IndexKey String
final
persistSession bool
Whether persisting the cookies that without "expires" or "max-age" attribute;
final
runtimeType Type
A representation of the runtime type of the object.
read-onlyinherited
storage Storage
read / write

Methods

delete(Uri uri, [bool withDomainSharedCookie = false]) Future<void>
Delete cookies for specified uri. This API will delete all cookies for the uri.host, it will ignored the uri.path.
override
deleteAll() Future<void>
Delete all cookies files under dir directory and clear them out from RAM
override
forceInit() Future<void>
loadForRequest(Uri uri) Future<List<Cookie>>
Load the cookies for specified uri.
override
noSuchMethod(Invocation invocation) → dynamic
Invoked when a non-existent method or property is accessed.
inherited
saveFromResponse(Uri uri, List<Cookie> cookies) Future<void>
Save the cookies for specified uri.
override
toString() String
A string representation of this object.
inherited

Operators

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