NewHashStructure Returns a new NewHashStructure
(options config.Options)
| 32 | |
| 33 | // NewHashStructure Returns a new NewHashStructure |
| 34 | func NewHashStructure(options config.Options) (*HashStructure, error) { |
| 35 | db, err := engine.NewDB(options) |
| 36 | if err != nil { |
| 37 | return nil, err |
| 38 | } |
| 39 | return &HashStructure{db: db}, nil |
| 40 | } |
| 41 | |
| 42 | // HSet sets the string value of a hash field in the HashStructure. |
| 43 | // It takes the key, field, and value as input and stores the value in the specified hash field. |