MCPcopy
hub / github.com/canopy-network/canopy / commitIDKey

Method commitIDKey

store/store.go:413–415  ·  view source on GitHub ↗

commitIDKey() returns the key for the commitID at a specific version

(version uint64)

Source from the content-addressed store, hash-verified

411
412// commitIDKey() returns the key for the commitID at a specific version
413func (s *Store) commitIDKey(version uint64) []byte {
414 return append(stateCommitIDPrefix, lib.JoinLenPrefix(fmt.Appendf(nil, "%d", version))...)
415}
416
417// getCommitID() retrieves the CommitID value for the specified version from the database
418func (s *Store) getCommitID(version uint64) (id lib.CommitID, err lib.ErrorI) {

Callers 2

getCommitIDMethod · 0.95
setCommitIDMethod · 0.95

Calls 1

JoinLenPrefixFunction · 0.92

Tested by

no test coverage detected