MCPcopy Create free account
hub / github.com/couchbase/sync_gateway / GetSyncCas

Method GetSyncCas

db/document.go:645–652  ·  view source on GitHub ↗

Converts the string hex encoding that's stored in the sync metadata to a uint64 cas value

()

Source from the content-addressed store, hash-verified

643
644// Converts the string hex encoding that's stored in the sync metadata to a uint64 cas value
645func (s *SyncData) GetSyncCas() uint64 {
646
647 if s.Cas == "" {
648 return 0
649 }
650
651 return base.HexCasToUint64(s.Cas)
652}
653
654func HasUserXattrChanged(userXattr []byte, prevUserXattrHash string) bool {
655 // If hash is empty but userXattr is not empty an xattr has been added. Import

Callers 3

IsSGWriteMethod · 0.95
TestParseDocumentCasFunction · 0.95
IsSGWriteMethod · 0.80

Calls 1

HexCasToUint64Function · 0.92

Tested by 1

TestParseDocumentCasFunction · 0.76