- Sort Score
- Result 10 results
- Languages All
Results 1 - 5 of 5 for NewTargetIDSet (0.09 sec)
-
internal/config/lambda/event/targetidset.go
func (set TargetIDSet) Difference(sset TargetIDSet) TargetIDSet { nset := NewTargetIDSet() for k := range set { if _, ok := sset[k]; !ok { nset.add(k) } } return nset } // NewTargetIDSet - creates new TargetID set with given TargetIDs. func NewTargetIDSet(targetIDs ...TargetID) TargetIDSet { set := make(TargetIDSet) for _, targetID := range targetIDs {
Registered: Sun Nov 03 19:28:11 UTC 2024 - Last Modified: Thu Jan 18 07:03:17 UTC 2024 - 1.9K bytes - Viewed (0) -
internal/event/targetidset.go
func (set TargetIDSet) Difference(sset TargetIDSet) TargetIDSet { nset := NewTargetIDSet() for k := range set { if _, ok := sset[k]; !ok { nset.add(k) } } return nset } // NewTargetIDSet - creates new TargetID set with given TargetIDs. func NewTargetIDSet(targetIDs ...TargetID) TargetIDSet { set := make(TargetIDSet) for _, targetID := range targetIDs {
Registered: Sun Nov 03 19:28:11 UTC 2024 - Last Modified: Thu Jan 18 07:03:17 UTC 2024 - 1.9K bytes - Viewed (0) -
internal/event/rulesmap_test.go
expectedResult TargetIDSet }{ {rulesMapCase1, ObjectCreatedPut, "2010/photo.jpg", NewTargetIDSet()}, {rulesMapCase2, ObjectCreatedPut, "2010/photo.jpg", NewTargetIDSet(TargetID{"1", "webhook"})}, {rulesMapCase3, ObjectCreatedPut, "2000/photo.png", NewTargetIDSet()}, {rulesMapCase4, ObjectCreatedPut, "2000/photo.png", NewTargetIDSet(TargetID{"2", "amqp"})}, } for i, testCase := range testCases {
Registered: Sun Nov 03 19:28:11 UTC 2024 - Last Modified: Fri Jan 05 18:43:06 UTC 2024 - 6.8K bytes - Viewed (0) -
internal/event/rules.go
return pattern } // Rules - event rules type Rules map[string]TargetIDSet // Add - adds pattern and target ID. func (rules Rules) Add(pattern string, targetID TargetID) { rules[pattern] = NewTargetIDSet(targetID).Union(rules[pattern]) } // MatchSimple - returns true one of the matching object name in rules. func (rules Rules) MatchSimple(objectName string) bool { for pattern := range rules {
Registered: Sun Nov 03 19:28:11 UTC 2024 - Last Modified: Fri May 24 23:05:23 UTC 2024 - 2.7K bytes - Viewed (0) -
cmd/event-notification.go
} // RemoveAllBucketTargets - closes and removes all notification targets. func (evnot *EventNotifier) RemoveAllBucketTargets() { evnot.Lock() defer evnot.Unlock() targetIDSet := event.NewTargetIDSet() for k := range evnot.targetList.TargetMap() { targetIDSet[k] = struct{}{} } evnot.targetList.Remove(targetIDSet) } // Send - sends the event to all registered notification targets
Registered: Sun Nov 03 19:28:11 UTC 2024 - Last Modified: Fri Jun 21 22:22:24 UTC 2024 - 7.7K bytes - Viewed (0)