MCPcopy Index your code
hub / github.com/nutsdb/nutsdb / NewMessage

Function NewMessage

watch_manager.go:73–90  ·  view source on GitHub ↗
(bucketName core.BucketName, key string, value []byte, flag DataFlag, timestamp uint64, options ...MessageOptions)

Source from the content-addressed store, hash-verified

71}
72
73func NewMessage(bucketName core.BucketName, key string, value []byte, flag DataFlag, timestamp uint64, options ...MessageOptions) *Message {
74 var priority MessagePriority
75 // default priority is medium
76 priority = MessagePriorityMedium
77
78 if len(options) > 0 {
79 priority = options[0].Priority
80 }
81
82 return &Message{
83 BucketName: bucketName,
84 Key: key,
85 Value: value,
86 Flag: flag,
87 Timestamp: timestamp,
88 priority: priority,
89 }
90}
91
92func NewWatchOptions() *WatchOptions {
93 return &WatchOptions{

Callers 10

wmSendMessageFunction · 0.85
wmSendMessagesFunction · 0.85
wmStartSenderFunction · 0.85
sendUpdatedEntriesMethod · 0.85
runVictimCollectorMethod · 0.85

Calls

no outgoing calls

Tested by 8

wmSendMessageFunction · 0.68
wmSendMessagesFunction · 0.68
wmStartSenderFunction · 0.68