Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type DeviceInfoResolver ¶
type Session ¶
type Session interface { SetCustomerDetails(id string, isNew bool) SetOtpData(uuid string) SetFakeNow(fakeNow time.Time) GetFixedCacheVersions() map[string]string SetFixedCacheVersions(versions map[string]string) GetCurrentCacheVersions() map[string]string SetCurrentCacheVersions(versions map[string]string) GetOtpData() string GetIsNoCustomer() bool GetIsCustomerNew() bool GetCustomerId() string HasFakeNow() bool GetNow() time.Time GetId() string SetLang(lang string) GetLang() string SetTermsApproval(termsApproval bool) GetTermsApproval() bool SetDeviceInfo(hardware, runtime, os, deviceModel, browserType, appVersion, osVersion string) GetDeviceInfo() DeviceInfoResolver SetReferrer(string) GetReferrer() string }
type SessionRepo ¶
type SessionRepo interface { GetUserSessionByTokenToStruct(context context.Context, token string, dest interface{}) (bool, error) InsertOrUpdate(ctx context.Context, id string, obj interface{}) error GetCacheVersions(ctx context.Context, now time.Time, filterAction string, filterType string) (map[string]string, error) GetCollectionsFilterActions(ctx context.Context, filterAction string) ([]string, error) }
type SessionResolver ¶
type SessionResolver interface { SetDataToContext(c context.Context, cSession Session) (context.Context, error) GetSessionById(c context.Context, id string) (bool, Session, error) GetTokenDataValueAsString(c context.Context, key string) (string, error) NewSession(id string) Session SaveSession(c context.Context, cSession Session) error GetCurrentSession(c context.Context) (Session, error) FreezeCacheVersionsForSession(c context.Context, curSession Session, action string, cacheType string) error UnFreezeCacheVersionsForSession(c context.Context, curSession Session, action string) error IsObsolete(c context.Context, sessionId string) (bool, error) }
type SessionResolverBuilder ¶
type SessionResolverBuilder interface { SetRepo(repo SessionRepo) SessionResolverBuilder Build() (SessionResolver, error) }
Click to show internal directories.
Click to hide internal directories.