velodrome/transform/plugins/states.go
func (m *MultiState) ReceiveEvent(eventName, label string, t time.Time) (State, bool) {
	oneChanged := false
	for i := range m.states {
		state, changed := m.states[i].ReceiveEvent(eventName, label, t)
		if changed {
			oneChanged = true
		}
		m.states[i] = state

	}
	return m, oneChanged
}
func (m *MultiState) ReceiveEvent(eventName, label string, t time.Time) (State, bool) {
	oneChanged := false
	for i := range m.states {
		state, changed := m.states[i].ReceiveEvent(eventName, label, t)
		if changed {
			oneChanged = true
		}
		m.states[i] = state

	}
	return m, oneChanged
}
func ( m * MultiState ) ReceiveEvent ( eventName , label string , t time . Time ) ( State , bool ) { oneChanged := false for i := range m . states { state , changed := m . states [ i ] . ReceiveEvent ( eventName , label , t ) if changed { oneChanged = true } m . states [ i ] = state } return m , oneChanged }
// ReceiveEvent will send the event to each individual state, and update
// them if they change.
ReceiveEvent will send the event to each individual state and update them if they change .