summaryrefslogtreecommitdiffstats
path: root/vendor/go.mau.fi/libsignal/state/store/MessageKeyStore.go
blob: fea2eed093196d145c97cfc41157b8b5b8a4eb76 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
package store

import (
	"go.mau.fi/libsignal/keys/message"
)

// MessageKey store is an interface describing the optional local storage
// of message keys.
type MessageKey interface {
	// Load a local message key by id
	LoadMessageKey(keyID uint32) *message.Keys

	// Store a local message key
	StoreMessageKey(keyID uint32, key *message.Keys)

	// Check to see if the store contains a message key with id.
	ContainsMessageKey(keyID uint32) bool

	// Delete a message key from local storage.
	RemoveMessageKey(keyID uint32)
}