MCPcopy
hub / github.com/OpenNHP/opennhp / TokenEntry

Interface TokenEntry

nhp/common/tokenstore.go:12–14  ·  view source on GitHub ↗

TokenEntry is an interface for token entries that have an expiration time. Both AccessEntry (AC) and ACTokenEntry (Server) implement this interface.

Source from the content-addressed store, hash-verified

10// TokenEntry is an interface for token entries that have an expiration time.
11// Both AccessEntry (AC) and ACTokenEntry (Server) implement this interface.
12type TokenEntry interface {
13 GetExpireTime() time.Time
14}
15
16// TokenStore is a generic two-level map for efficient token storage.
17// The first level is indexed by the first character of the token for fast lookup.

Callers 1

CleanExpiredMethod · 0.65

Implementers 3

testEntrynhp/test/tokenstore_test.go
ACTokenEntryendpoints/server/tokenstore.go
AccessEntryendpoints/ac/tokenstore.go

Calls

no outgoing calls

Tested by

no test coverage detected