Refactor StorageMap to BlobList
This commit is contained in:
parent
d594cd89b7
commit
d1e4431514
10 changed files with 285 additions and 111 deletions
|
@ -47,6 +47,11 @@ func (id ID) EqualString(other string) (bool, error) {
|
|||
return id.Equal(ID(s)), nil
|
||||
}
|
||||
|
||||
// Compare compares this ID to another one, returning -1, 0, or 1.
|
||||
func (id ID) Compare(other ID) int {
|
||||
return bytes.Compare(other, id)
|
||||
}
|
||||
|
||||
func (id ID) MarshalJSON() ([]byte, error) {
|
||||
return json.Marshal(id.String())
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue