Documentation
¶
Index ¶
- func NewInCache(db account.Store) account.Store
- type Cache
- func (c *Cache) BatchSetNextAirdropTimestamp(ctx context.Context, ts time.Time, userIDs ...*commonpb.UserId) error
- func (c *Cache) Bind(ctx context.Context, userID *commonpb.UserId, pubKey *commonpb.PublicKey) (*commonpb.UserId, error)
- func (c *Cache) ExtendAirdropEligibility(ctx context.Context, userID *commonpb.UserId, until time.Time) error
- func (c *Cache) GetAirdropEligibilityTimestamp(ctx context.Context, userID *commonpb.UserId) (time.Time, error)
- func (c *Cache) GetNextAirdropTimestamp(ctx context.Context, userID *commonpb.UserId) (time.Time, error)
- func (c *Cache) GetPubKeys(ctx context.Context, userID *commonpb.UserId) ([]*commonpb.PublicKey, error)
- func (c *Cache) GetUserId(ctx context.Context, pubKey *commonpb.PublicKey) (*commonpb.UserId, error)
- func (c *Cache) GetUsersToAirdrop(ctx context.Context, at time.Time) ([]*commonpb.UserId, error)
- func (c *Cache) IsAuthorized(ctx context.Context, userID *commonpb.UserId, pubKey *commonpb.PublicKey) (bool, error)
- func (c *Cache) IsRegistered(ctx context.Context, userID *commonpb.UserId) (bool, error)
- func (c *Cache) IsStaff(ctx context.Context, userID *commonpb.UserId) (bool, error)
- func (c *Cache) RemoveKey(ctx context.Context, userID *commonpb.UserId, pubKey *commonpb.PublicKey) error
- func (c *Cache) SetRegistrationFlag(ctx context.Context, userID *commonpb.UserId, isRegistered bool) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Cache ¶
type Cache struct {
// contains filtered or unexported fields
}
func (*Cache) BatchSetNextAirdropTimestamp ¶
func (*Cache) ExtendAirdropEligibility ¶
func (*Cache) GetAirdropEligibilityTimestamp ¶
func (*Cache) GetNextAirdropTimestamp ¶
func (*Cache) GetPubKeys ¶
func (*Cache) GetUsersToAirdrop ¶
func (*Cache) IsAuthorized ¶
func (*Cache) IsRegistered ¶
Click to show internal directories.
Click to hide internal directories.