Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Model ¶
type Model struct { Keyid string `model:"keyid,VARCHAR(63) PRIMARY KEY" query:"keyid,getoneeq,keyid;updeq,keyid;deleq,keyid"` Userid string `model:"userid,VARCHAR(31) NOT NULL;index" query:"userid,deleq,userid"` AuthTags rank.Rank KeyHash string `model:"keyhash,VARCHAR(127) NOT NULL" query:"keyhash"` Name string `model:"name,VARCHAR(255)" query:"name"` Desc string `model:"description,VARCHAR(255)" query:"description"` Time int64 `model:"time,BIGINT NOT NULL" query:"time,getgroupeq,userid"` // contains filtered or unexported fields }
type Repo ¶
type Repo interface { New(userid string, authtags rank.Rank, name, desc string) (*Model, string, error) ValidateKey(key string, m *Model) (bool, error) RehashKey(m *Model) (string, error) GetByID(keyid string) (*Model, error) GetUserKeys(userid string, limit, offset int) ([]Model, error) GetUserKeyIDs(userid string, limit, offset int) ([]string, error) Insert(m *Model) error Update(m *Model) error Delete(m *Model) error DeleteUserKeys(userid string) error Setup() error }
Click to show internal directories.
Click to hide internal directories.