// AddEvents forwards the events to SignalFx.
178309
func (h *HTTPSink) AddEvents(ctx context.Context, events []*event.Event) (err error) {
	if len(events) == 0 || h.EventEndpoint == "" {
		return nil
	}
	return h.doBottom(ctx, func() (io.Reader, bool, error) {
		return h.encodePostBodyProtobufV2Events(events)
	}, "application/x-protobuf", h.EventEndpoint, datapointAndEventResponseValidator)
}
1247104
func (s *SetCognitoEventsInput) SetEvents(v map[string]*string) *SetCognitoEventsInput {
	s.Events = v
	return s
}
606484
func (h *eventHub) processEvents() {
	for {
		select {
		case connection := <-h.register:
			h.connections.Register(connection)
		case connection := <-h.unregister:
			h.connections.Unregister(connection)
		case msg := <-h.broadcast:
			h.connections.Broadcast(msg)
		}
	}
}
913870
func (s *LambdaFunctionConfiguration) SetEvents(v []*string) *LambdaFunctionConfiguration {
	s.Events = v
	return s
}
1081659
func (c *CircularBuffer) Events() []Event {
	c.Lock()
	defer c.Unlock()
	return c.eventsCopy()
}
335257
func (s *EventsBatch) SetEvents(v map[string]*Event) *EventsBatch {
	s.Events = v
	return s
}
1159227
func (s *CloudFunctionConfiguration) SetEvents(v []*string) *CloudFunctionConfiguration {
	s.Events = v
	return s
}
658683
func (p *Parser) handleEvents(rawEvents <-chan []string, send chan<- event.Event, wg *sync.WaitGroup) {
	defer wg.Done()
	// TODO: spin up a group of goroutines to do this
	for rawEvent := range rawEvents {
		ev := p.handleEvent(rawEvent)
		if ev != nil {
			send <- *ev
		}
	}
}
495621
func (r *Renderer) RenderEvents(eventCh <-chan *TaskEvent) {
	for event := range eventCh {
		r.RenderEvent(event)
	}
}
301393
func (form FormImpl) AddEventHandler(evt string, f HandlerFunc) Form {
	if form.trans == nil {
		form.trans = map[string]HandlerFunc{}
	}
	form.trans[evt] = f
	return form
}
848460
func (w *WithDimensions) AddEvents(ctx context.Context, events []*event.Event, next Sink) error {
	return next.AddEvents(ctx, w.appendDimensionsEvents(events))
}
1081614
func (e *RateLimitErrorLogging) AddEvents(ctx context.Context, points []*event.Event, next Sink) error {
	err := next.AddEvents(ctx, points)
	e.throttleLog(err)
	return err
}
405328
func (s *Session) addEventHandler(eventHandler EventHandler) func() {
	s.handlersMu.Lock()
	defer s.handlersMu.Unlock()

	if s.handlers == nil {
		s.handlers = map[string][]*eventHandlerInstance{}
	}

	ehi := &eventHandlerInstance{eventHandler}
	s.handlers[eventHandler.Type()] = append(s.handlers[eventHandler.Type()], ehi)

	return func() {
		s.removeEventHandlerInstance(eventHandler.Type(), ehi)
	}
}
432797
func (a *AdditionalSpanTags) AddEvents(ctx context.Context, events []*event.Event) error {
	return a.next.AddEvents(ctx, events)
}
1340673
func (s *GetExecutionHistoryOutput) SetEvents(v []*HistoryEvent) *GetExecutionHistoryOutput {
	s.Events = v
	return s
}
1054824
func (s *AutoRollbackConfiguration) SetEvents(v []*string) *AutoRollbackConfiguration {
	s.Events = v
	return s
}
1029582
func (v *version) Events() EventInformer {
	return &eventInformer{factory: v.factory, namespace: v.namespace, tweakListOptions: v.tweakListOptions}
}