示例#1
0
文件: gregor.go 项目: qbit/client
func (g *gregorHandler) notifyFavoritesChanged(ctx context.Context, uid gregor.UID) error {
	kbUID, err := keybase1.UIDFromString(hex.EncodeToString(uid.Bytes()))
	if err != nil {
		return err
	}
	g.G().NotifyRouter.HandleFavoritesChanged(kbUID)
	return nil
}
示例#2
0
文件: factory.go 项目: qbit/client
func (o ObjFactory) MakeReminderID(u gregor.UID, msgid gregor.MsgID, seqno int) (gregor.ReminderID, error) {
	return ReminderID{Uid_: u.Bytes(), MsgID_: msgid.Bytes(), Seqno_: seqno}, nil
}
示例#3
0
func (db *LevelDBStorageEngine) Load(user gregor.UID) ([]byte, error) {
	return db.Get(user.Bytes(), nil)
}
示例#4
0
func (db *LevelDBStorageEngine) Store(user gregor.UID, value []byte) error {
	return db.Put(user.Bytes(), value, nil)
}
示例#5
0
文件: gregor.go 项目: qbit/client
func dbKey(u gregor.UID) libkb.DbKey {
	return libkb.DbKey{Typ: libkb.DBGregor, Key: hex.EncodeToString(u.Bytes())}
}
示例#6
0
文件: mem_sm.go 项目: qbit/client
func uidToString(u gregor.UID) string {
	return hex.EncodeToString(u.Bytes())
}