Get retrieves the value associated with `key`; returns []byte if key exists
(key []byte)
| 120 | |
| 121 | // Get retrieves the value associated with `key`; returns []byte if key exists |
| 122 | func (fds *FlyDbStore) Get(key []byte) ([]byte, error) { |
| 123 | if len(key) == 0 { |
| 124 | return nil, _const.ErrKeyIsEmpty |
| 125 | } |
| 126 | val, err := fds.conn.Get(key) |
| 127 | if err != nil { |
| 128 | return nil, err |
| 129 | } |
| 130 | return val, nil |
| 131 | } |
| 132 | |
| 133 | // SetUint64 is used to set Uint64 value for `key` |
| 134 | func (fds *FlyDbStore) SetUint64(key []byte, val uint64) error { |