Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/GoEdgeLab/EdgeNode
/ Has
Method
Has
internal/utils/sets/set_fixed.go:47–53 ·
view source on GitHub ↗
(item any)
Source
from the content-addressed store, hash-verified
45
}
46
47
func
(this *FixedSet) Has(item any) bool {
48
this.locker.RLock()
49
defer
this.locker.RUnlock()
50
51
_, ok := this.m[item]
52
return
ok
53
}
54
55
func
(this *FixedSet) Size() int {
56
this.locker.RLock()
Callers
2
TestNewFixedSet
Function · 0.45
BenchmarkFixedSet_Has
Function · 0.45
Calls
2
RLock
Method · 0.80
RUnlock
Method · 0.80
Tested by
2
TestNewFixedSet
Function · 0.36
BenchmarkFixedSet_Has
Function · 0.36