Table of Contents

Class LoginMixin

Namespace
Akavache
Assembly
Akavache.Core.dll

Helper methods that assist with login operations and storing related data.

public static class LoginMixin
Inheritance
LoginMixin

Methods

EraseLogin(ISecureBlobCache, string)

Erases the login associated with the specified host.

public static IObservable<Unit> EraseLogin(this ISecureBlobCache blobCache, string host = "default")

Parameters

blobCache ISecureBlobCache

The blob cache where to erase the data.

host string

The host associated with the data.

Returns

IObservable<Unit>

A observable which signals when the erase is completed.

GetLoginAsync(ISecureBlobCache, string)

Returns the currently cached user/password. If the cache does not contain a user/password, this returns an Observable which OnError's with KeyNotFoundException.

public static IObservable<LoginInfo> GetLoginAsync(this ISecureBlobCache blobCache, string host = "default")

Parameters

blobCache ISecureBlobCache

The blob cache where to get the data.

host string

The host associated with the data.

Returns

IObservable<LoginInfo>

A Future result representing the user/password Tuple.

SaveLogin(ISecureBlobCache, string, string, string, DateTimeOffset?)

Save a user/password combination in a secure blob cache. Note that this method only allows exactly one user/pass combo to be saved, calling this more than once will overwrite the previous entry.

public static IObservable<Unit> SaveLogin(this ISecureBlobCache blobCache, string user, string password, string host = "default", DateTimeOffset? absoluteExpiration = null)

Parameters

blobCache ISecureBlobCache

The blob cache where to store the data.

user string

The user name to save.

password string

The associated password.

host string

The host to associate with the data.

absoluteExpiration DateTimeOffset?

An optional expiration date.

Returns

IObservable<Unit>

A observable which signals when the insert is completed.