MCPcopy Create free account
hub / github.com/SolarLune/masterplan / ForEach

Method ForEach

stack.go:283–289  ·  view source on GitHub ↗
(filterFunc func(card *Card) bool)

Source from the content-addressed store, hash-verified

281}
282
283func (stack *Stack) ForEach(filterFunc func(card *Card) bool) {
284 for _, card := range stack.All() {
285 if !filterFunc(card) {
286 return
287 }
288 }
289}
290
291func (stack *Stack) All() []*Card {
292 return append(append(stack.Head(), stack.Card), stack.Tail()...)

Callers 2

PostDrawMethod · 0.80
DeserializeMethod · 0.80

Calls 1

AllMethod · 0.95

Tested by

no test coverage detected