// Code generated by "callbackgen -type Stream"; DO NOT EDIT.

package coinbase

import ()

func (s *Stream) OnErrorMessage(cb func(m *ErrorMessage)) {
	s.errorMessageCallbacks = append(s.errorMessageCallbacks, cb)
}

func (s *Stream) EmitErrorMessage(m *ErrorMessage) {
	for _, cb := range s.errorMessageCallbacks {
		cb(m)
	}
}

func (s *Stream) OnSubscriptions(cb func(m *SubscriptionsMessage)) {
	s.subscriptionsCallbacks = append(s.subscriptionsCallbacks, cb)
}

func (s *Stream) EmitSubscriptions(m *SubscriptionsMessage) {
	for _, cb := range s.subscriptionsCallbacks {
		cb(m)
	}
}

func (s *Stream) OnStatusMessage(cb func(m *StatusMessage)) {
	s.statusMessageCallbacks = append(s.statusMessageCallbacks, cb)
}

func (s *Stream) EmitStatusMessage(m *StatusMessage) {
	for _, cb := range s.statusMessageCallbacks {
		cb(m)
	}
}

func (s *Stream) OnAuctionMessage(cb func(m *AuctionMessage)) {
	s.auctionMessageCallbacks = append(s.auctionMessageCallbacks, cb)
}

func (s *Stream) EmitAuctionMessage(m *AuctionMessage) {
	for _, cb := range s.auctionMessageCallbacks {
		cb(m)
	}
}

func (s *Stream) OnRfqMessage(cb func(m *RfqMessage)) {
	s.rfqMessageCallbacks = append(s.rfqMessageCallbacks, cb)
}

func (s *Stream) EmitRfqMessage(m *RfqMessage) {
	for _, cb := range s.rfqMessageCallbacks {
		cb(m)
	}
}

func (s *Stream) OnTickerMessage(cb func(m *TickerMessage)) {
	s.tickerMessageCallbacks = append(s.tickerMessageCallbacks, cb)
}

func (s *Stream) EmitTickerMessage(m *TickerMessage) {
	for _, cb := range s.tickerMessageCallbacks {
		cb(m)
	}
}

func (s *Stream) OnReceivedMessage(cb func(m *ReceivedMessage)) {
	s.receivedMessageCallbacks = append(s.receivedMessageCallbacks, cb)
}

func (s *Stream) EmitReceivedMessage(m *ReceivedMessage) {
	for _, cb := range s.receivedMessageCallbacks {
		cb(m)
	}
}

func (s *Stream) OnOpenMessage(cb func(m *OpenMessage)) {
	s.openMessageCallbacks = append(s.openMessageCallbacks, cb)
}

func (s *Stream) EmitOpenMessage(m *OpenMessage) {
	for _, cb := range s.openMessageCallbacks {
		cb(m)
	}
}

func (s *Stream) OnDoneMessage(cb func(m *DoneMessage)) {
	s.doneMessageCallbacks = append(s.doneMessageCallbacks, cb)
}

func (s *Stream) EmitDoneMessage(m *DoneMessage) {
	for _, cb := range s.doneMessageCallbacks {
		cb(m)
	}
}

func (s *Stream) OnMatchMessage(cb func(m *MatchMessage)) {
	s.matchMessageCallbacks = append(s.matchMessageCallbacks, cb)
}

func (s *Stream) EmitMatchMessage(m *MatchMessage) {
	for _, cb := range s.matchMessageCallbacks {
		cb(m)
	}
}

func (s *Stream) OnChangeMessage(cb func(m *ChangeMessage)) {
	s.changeMessageCallbacks = append(s.changeMessageCallbacks, cb)
}

func (s *Stream) EmitChangeMessage(m *ChangeMessage) {
	for _, cb := range s.changeMessageCallbacks {
		cb(m)
	}
}

func (s *Stream) OnActivateMessage(cb func(m *ActivateMessage)) {
	s.activateMessageCallbacks = append(s.activateMessageCallbacks, cb)
}

func (s *Stream) EmitActivateMessage(m *ActivateMessage) {
	for _, cb := range s.activateMessageCallbacks {
		cb(m)
	}
}

func (s *Stream) OnBalanceMessage(cb func(m *BalanceMessage)) {
	s.balanceMessageCallbacks = append(s.balanceMessageCallbacks, cb)
}

func (s *Stream) EmitBalanceMessage(m *BalanceMessage) {
	for _, cb := range s.balanceMessageCallbacks {
		cb(m)
	}
}

func (s *Stream) OnOrderbookSnapshotMessage(cb func(m *OrderBookSnapshotMessage)) {
	s.orderbookSnapshotMessageCallbacks = append(s.orderbookSnapshotMessageCallbacks, cb)
}

func (s *Stream) EmitOrderbookSnapshotMessage(m *OrderBookSnapshotMessage) {
	for _, cb := range s.orderbookSnapshotMessageCallbacks {
		cb(m)
	}
}

func (s *Stream) OnOrderbookUpdateMessage(cb func(m *OrderBookUpdateMessage)) {
	s.orderbookUpdateMessageCallbacks = append(s.orderbookUpdateMessageCallbacks, cb)
}

func (s *Stream) EmitOrderbookUpdateMessage(m *OrderBookUpdateMessage) {
	for _, cb := range s.orderbookUpdateMessageCallbacks {
		cb(m)
	}
}
