MCPcopy Create free account
hub / github.com/TheThingsNetwork/lorawan-stack / NewWithIdentifiersAndData

Method NewWithIdentifiersAndData

pkg/events/builder.go:62–71  ·  view source on GitHub ↗
(ctx context.Context, ids EntityIdentifiers, data any)

Source from the content-addressed store, hash-verified

60}
61
62func (b *builder) NewWithIdentifiersAndData(ctx context.Context, ids EntityIdentifiers, data any) Event {
63 e := local(b.New(ctx))
64 if ids != nil {
65 e.innerEvent.Identifiers = append(e.innerEvent.Identifiers, ids.GetEntityIdentifiers())
66 }
67 if data != nil {
68 e.data = data
69 }
70 return e
71}
72
73func (b *builder) BindData(data any) Builder {
74 return b.With(WithData(data))

Callers

nothing calls this directly

Calls 3

NewMethod · 0.95
localFunction · 0.85
GetEntityIdentifiersMethod · 0.65

Tested by

no test coverage detected