-
Notifications
You must be signed in to change notification settings - Fork 14
Expand file tree
/
Copy pathdocs.go
More file actions
494 lines (332 loc) · 18.3 KB
/
Copy pathdocs.go
File metadata and controls
494 lines (332 loc) · 18.3 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
// Code generated by tools/generator. DO NOT EDIT.
/*
Copyright 2024 The CDEvents Authors
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
SPDX-License-Identifier: Apache-2.0
*/
// Package v03 contains method to create events that belong to the
// CDEvents specification v0.5.x
package v05
import "github.com/cdevents/sdk-go/pkg/api"
var SpecVersion = "0.5.1"
type ArtifactDeletedEvent = api.ArtifactDeletedEventV0_2_0
type ArtifactDeletedSubject = api.ArtifactDeletedSubjectV0_2_0
func NewArtifactDeletedEvent() (*ArtifactDeletedEvent, error) {
return api.NewArtifactDeletedEventV0_2_0(SpecVersion)
}
var ArtifactDeletedEventType = api.ArtifactDeletedEventTypeV0_2_0
type ArtifactDownloadedEvent = api.ArtifactDownloadedEventV0_2_0
type ArtifactDownloadedSubject = api.ArtifactDownloadedSubjectV0_2_0
func NewArtifactDownloadedEvent() (*ArtifactDownloadedEvent, error) {
return api.NewArtifactDownloadedEventV0_2_0(SpecVersion)
}
var ArtifactDownloadedEventType = api.ArtifactDownloadedEventTypeV0_2_0
type ArtifactPackagedEvent = api.ArtifactPackagedEventV0_3_0
type ArtifactPackagedSubject = api.ArtifactPackagedSubjectV0_3_0
// ArtifactArtifactSubjectContentSbomV0_3_0 holds the content of a Sbom field in the content
type ArtifactPackagedSubjectContentSbom = api.ArtifactPackagedSubjectContentSbomV0_3_0
func NewArtifactPackagedEvent() (*ArtifactPackagedEvent, error) {
return api.NewArtifactPackagedEventV0_3_0(SpecVersion)
}
var ArtifactPackagedEventType = api.ArtifactPackagedEventTypeV0_3_0
type ArtifactPublishedEvent = api.ArtifactPublishedEventV0_3_0
type ArtifactPublishedSubject = api.ArtifactPublishedSubjectV0_3_0
// ArtifactArtifactSubjectContentSbomV0_3_0 holds the content of a Sbom field in the content
type ArtifactPublishedSubjectContentSbom = api.ArtifactPublishedSubjectContentSbomV0_3_0
func NewArtifactPublishedEvent() (*ArtifactPublishedEvent, error) {
return api.NewArtifactPublishedEventV0_3_0(SpecVersion)
}
var ArtifactPublishedEventType = api.ArtifactPublishedEventTypeV0_3_0
type ArtifactSignedEvent = api.ArtifactSignedEventV0_3_0
type ArtifactSignedSubject = api.ArtifactSignedSubjectV0_3_0
func NewArtifactSignedEvent() (*ArtifactSignedEvent, error) {
return api.NewArtifactSignedEventV0_3_0(SpecVersion)
}
var ArtifactSignedEventType = api.ArtifactSignedEventTypeV0_3_0
type BranchCreatedEvent = api.BranchCreatedEventV0_3_0
type BranchCreatedSubject = api.BranchCreatedSubjectV0_3_0
func NewBranchCreatedEvent() (*BranchCreatedEvent, error) {
return api.NewBranchCreatedEventV0_3_0(SpecVersion)
}
var BranchCreatedEventType = api.BranchCreatedEventTypeV0_3_0
type BranchDeletedEvent = api.BranchDeletedEventV0_3_0
type BranchDeletedSubject = api.BranchDeletedSubjectV0_3_0
func NewBranchDeletedEvent() (*BranchDeletedEvent, error) {
return api.NewBranchDeletedEventV0_3_0(SpecVersion)
}
var BranchDeletedEventType = api.BranchDeletedEventTypeV0_3_0
type BuildFinishedEvent = api.BuildFinishedEventV0_3_0
type BuildFinishedSubject = api.BuildFinishedSubjectV0_3_0
func NewBuildFinishedEvent() (*BuildFinishedEvent, error) {
return api.NewBuildFinishedEventV0_3_0(SpecVersion)
}
var BuildFinishedEventType = api.BuildFinishedEventTypeV0_3_0
type BuildQueuedEvent = api.BuildQueuedEventV0_3_0
type BuildQueuedSubject = api.BuildQueuedSubjectV0_3_0
func NewBuildQueuedEvent() (*BuildQueuedEvent, error) {
return api.NewBuildQueuedEventV0_3_0(SpecVersion)
}
var BuildQueuedEventType = api.BuildQueuedEventTypeV0_3_0
type BuildStartedEvent = api.BuildStartedEventV0_3_0
type BuildStartedSubject = api.BuildStartedSubjectV0_3_0
func NewBuildStartedEvent() (*BuildStartedEvent, error) {
return api.NewBuildStartedEventV0_3_0(SpecVersion)
}
var BuildStartedEventType = api.BuildStartedEventTypeV0_3_0
type ChangeAbandonedEvent = api.ChangeAbandonedEventV0_3_0
type ChangeAbandonedSubject = api.ChangeAbandonedSubjectV0_3_0
func NewChangeAbandonedEvent() (*ChangeAbandonedEvent, error) {
return api.NewChangeAbandonedEventV0_3_0(SpecVersion)
}
var ChangeAbandonedEventType = api.ChangeAbandonedEventTypeV0_3_0
type ChangeCreatedEvent = api.ChangeCreatedEventV0_4_0
type ChangeCreatedSubject = api.ChangeCreatedSubjectV0_4_0
func NewChangeCreatedEvent() (*ChangeCreatedEvent, error) {
return api.NewChangeCreatedEventV0_4_0(SpecVersion)
}
var ChangeCreatedEventType = api.ChangeCreatedEventTypeV0_4_0
type ChangeMergedEvent = api.ChangeMergedEventV0_3_0
type ChangeMergedSubject = api.ChangeMergedSubjectV0_3_0
func NewChangeMergedEvent() (*ChangeMergedEvent, error) {
return api.NewChangeMergedEventV0_3_0(SpecVersion)
}
var ChangeMergedEventType = api.ChangeMergedEventTypeV0_3_0
type ChangeReviewedEvent = api.ChangeReviewedEventV0_3_0
type ChangeReviewedSubject = api.ChangeReviewedSubjectV0_3_0
func NewChangeReviewedEvent() (*ChangeReviewedEvent, error) {
return api.NewChangeReviewedEventV0_3_0(SpecVersion)
}
var ChangeReviewedEventType = api.ChangeReviewedEventTypeV0_3_0
type ChangeUpdatedEvent = api.ChangeUpdatedEventV0_3_0
type ChangeUpdatedSubject = api.ChangeUpdatedSubjectV0_3_0
func NewChangeUpdatedEvent() (*ChangeUpdatedEvent, error) {
return api.NewChangeUpdatedEventV0_3_0(SpecVersion)
}
var ChangeUpdatedEventType = api.ChangeUpdatedEventTypeV0_3_0
type EnvironmentCreatedEvent = api.EnvironmentCreatedEventV0_3_0
type EnvironmentCreatedSubject = api.EnvironmentCreatedSubjectV0_3_0
func NewEnvironmentCreatedEvent() (*EnvironmentCreatedEvent, error) {
return api.NewEnvironmentCreatedEventV0_3_0(SpecVersion)
}
var EnvironmentCreatedEventType = api.EnvironmentCreatedEventTypeV0_3_0
type EnvironmentDeletedEvent = api.EnvironmentDeletedEventV0_3_0
type EnvironmentDeletedSubject = api.EnvironmentDeletedSubjectV0_3_0
func NewEnvironmentDeletedEvent() (*EnvironmentDeletedEvent, error) {
return api.NewEnvironmentDeletedEventV0_3_0(SpecVersion)
}
var EnvironmentDeletedEventType = api.EnvironmentDeletedEventTypeV0_3_0
type EnvironmentModifiedEvent = api.EnvironmentModifiedEventV0_3_0
type EnvironmentModifiedSubject = api.EnvironmentModifiedSubjectV0_3_0
func NewEnvironmentModifiedEvent() (*EnvironmentModifiedEvent, error) {
return api.NewEnvironmentModifiedEventV0_3_0(SpecVersion)
}
var EnvironmentModifiedEventType = api.EnvironmentModifiedEventTypeV0_3_0
type IncidentDetectedEvent = api.IncidentDetectedEventV0_3_0
type IncidentDetectedSubject = api.IncidentDetectedSubjectV0_3_0
func NewIncidentDetectedEvent() (*IncidentDetectedEvent, error) {
return api.NewIncidentDetectedEventV0_3_0(SpecVersion)
}
var IncidentDetectedEventType = api.IncidentDetectedEventTypeV0_3_0
type IncidentReportedEvent = api.IncidentReportedEventV0_3_0
type IncidentReportedSubject = api.IncidentReportedSubjectV0_3_0
func NewIncidentReportedEvent() (*IncidentReportedEvent, error) {
return api.NewIncidentReportedEventV0_3_0(SpecVersion)
}
var IncidentReportedEventType = api.IncidentReportedEventTypeV0_3_0
type IncidentResolvedEvent = api.IncidentResolvedEventV0_3_0
type IncidentResolvedSubject = api.IncidentResolvedSubjectV0_3_0
func NewIncidentResolvedEvent() (*IncidentResolvedEvent, error) {
return api.NewIncidentResolvedEventV0_3_0(SpecVersion)
}
var IncidentResolvedEventType = api.IncidentResolvedEventTypeV0_3_0
type PipelineRunFinishedEvent = api.PipelineRunFinishedEventV0_3_0
type PipelineRunFinishedSubject = api.PipelineRunFinishedSubjectV0_3_0
func NewPipelineRunFinishedEvent() (*PipelineRunFinishedEvent, error) {
return api.NewPipelineRunFinishedEventV0_3_0(SpecVersion)
}
var PipelineRunFinishedEventType = api.PipelineRunFinishedEventTypeV0_3_0
type PipelineRunQueuedEvent = api.PipelineRunQueuedEventV0_3_0
type PipelineRunQueuedSubject = api.PipelineRunQueuedSubjectV0_3_0
func NewPipelineRunQueuedEvent() (*PipelineRunQueuedEvent, error) {
return api.NewPipelineRunQueuedEventV0_3_0(SpecVersion)
}
var PipelineRunQueuedEventType = api.PipelineRunQueuedEventTypeV0_3_0
type PipelineRunStartedEvent = api.PipelineRunStartedEventV0_3_0
type PipelineRunStartedSubject = api.PipelineRunStartedSubjectV0_3_0
func NewPipelineRunStartedEvent() (*PipelineRunStartedEvent, error) {
return api.NewPipelineRunStartedEventV0_3_0(SpecVersion)
}
var PipelineRunStartedEventType = api.PipelineRunStartedEventTypeV0_3_0
type RepositoryCreatedEvent = api.RepositoryCreatedEventV0_3_0
type RepositoryCreatedSubject = api.RepositoryCreatedSubjectV0_3_0
func NewRepositoryCreatedEvent() (*RepositoryCreatedEvent, error) {
return api.NewRepositoryCreatedEventV0_3_0(SpecVersion)
}
var RepositoryCreatedEventType = api.RepositoryCreatedEventTypeV0_3_0
type RepositoryDeletedEvent = api.RepositoryDeletedEventV0_3_0
type RepositoryDeletedSubject = api.RepositoryDeletedSubjectV0_3_0
func NewRepositoryDeletedEvent() (*RepositoryDeletedEvent, error) {
return api.NewRepositoryDeletedEventV0_3_0(SpecVersion)
}
var RepositoryDeletedEventType = api.RepositoryDeletedEventTypeV0_3_0
type RepositoryModifiedEvent = api.RepositoryModifiedEventV0_3_0
type RepositoryModifiedSubject = api.RepositoryModifiedSubjectV0_3_0
func NewRepositoryModifiedEvent() (*RepositoryModifiedEvent, error) {
return api.NewRepositoryModifiedEventV0_3_0(SpecVersion)
}
var RepositoryModifiedEventType = api.RepositoryModifiedEventTypeV0_3_0
type ServiceDeployedEvent = api.ServiceDeployedEventV0_3_0
type ServiceDeployedSubject = api.ServiceDeployedSubjectV0_3_0
func NewServiceDeployedEvent() (*ServiceDeployedEvent, error) {
return api.NewServiceDeployedEventV0_3_0(SpecVersion)
}
var ServiceDeployedEventType = api.ServiceDeployedEventTypeV0_3_0
type ServicePublishedEvent = api.ServicePublishedEventV0_3_0
type ServicePublishedSubject = api.ServicePublishedSubjectV0_3_0
func NewServicePublishedEvent() (*ServicePublishedEvent, error) {
return api.NewServicePublishedEventV0_3_0(SpecVersion)
}
var ServicePublishedEventType = api.ServicePublishedEventTypeV0_3_0
type ServiceRemovedEvent = api.ServiceRemovedEventV0_3_0
type ServiceRemovedSubject = api.ServiceRemovedSubjectV0_3_0
func NewServiceRemovedEvent() (*ServiceRemovedEvent, error) {
return api.NewServiceRemovedEventV0_3_0(SpecVersion)
}
var ServiceRemovedEventType = api.ServiceRemovedEventTypeV0_3_0
type ServiceRolledbackEvent = api.ServiceRolledbackEventV0_3_0
type ServiceRolledbackSubject = api.ServiceRolledbackSubjectV0_3_0
func NewServiceRolledbackEvent() (*ServiceRolledbackEvent, error) {
return api.NewServiceRolledbackEventV0_3_0(SpecVersion)
}
var ServiceRolledbackEventType = api.ServiceRolledbackEventTypeV0_3_0
type ServiceUpgradedEvent = api.ServiceUpgradedEventV0_3_0
type ServiceUpgradedSubject = api.ServiceUpgradedSubjectV0_3_0
func NewServiceUpgradedEvent() (*ServiceUpgradedEvent, error) {
return api.NewServiceUpgradedEventV0_3_0(SpecVersion)
}
var ServiceUpgradedEventType = api.ServiceUpgradedEventTypeV0_3_0
type TaskRunFinishedEvent = api.TaskRunFinishedEventV0_3_0
type TaskRunFinishedSubject = api.TaskRunFinishedSubjectV0_3_0
func NewTaskRunFinishedEvent() (*TaskRunFinishedEvent, error) {
return api.NewTaskRunFinishedEventV0_3_0(SpecVersion)
}
var TaskRunFinishedEventType = api.TaskRunFinishedEventTypeV0_3_0
type TaskRunStartedEvent = api.TaskRunStartedEventV0_3_0
type TaskRunStartedSubject = api.TaskRunStartedSubjectV0_3_0
func NewTaskRunStartedEvent() (*TaskRunStartedEvent, error) {
return api.NewTaskRunStartedEventV0_3_0(SpecVersion)
}
var TaskRunStartedEventType = api.TaskRunStartedEventTypeV0_3_0
type TestCaseRunFinishedEvent = api.TestCaseRunFinishedEventV0_3_0
type TestCaseRunFinishedSubject = api.TestCaseRunFinishedSubjectV0_3_0
// TestCaseRunTestCaseRunSubjectContentTestCaseV0_3_0 holds the content of a TestCase field in the content
type TestCaseRunFinishedSubjectContentTestCase = api.TestCaseRunFinishedSubjectContentTestCaseV0_3_0
func NewTestCaseRunFinishedEvent() (*TestCaseRunFinishedEvent, error) {
return api.NewTestCaseRunFinishedEventV0_3_0(SpecVersion)
}
var TestCaseRunFinishedEventType = api.TestCaseRunFinishedEventTypeV0_3_0
type TestCaseRunQueuedEvent = api.TestCaseRunQueuedEventV0_3_0
type TestCaseRunQueuedSubject = api.TestCaseRunQueuedSubjectV0_3_0
// TestCaseRunTestCaseRunSubjectContentTestCaseV0_3_0 holds the content of a TestCase field in the content
type TestCaseRunQueuedSubjectContentTestCase = api.TestCaseRunQueuedSubjectContentTestCaseV0_3_0
// TestCaseRunTestCaseRunSubjectContentTriggerV0_3_0 holds the content of a Trigger field in the content
type TestCaseRunQueuedSubjectContentTrigger = api.TestCaseRunQueuedSubjectContentTriggerV0_3_0
func NewTestCaseRunQueuedEvent() (*TestCaseRunQueuedEvent, error) {
return api.NewTestCaseRunQueuedEventV0_3_0(SpecVersion)
}
var TestCaseRunQueuedEventType = api.TestCaseRunQueuedEventTypeV0_3_0
type TestCaseRunSkippedEvent = api.TestCaseRunSkippedEventV0_2_0
type TestCaseRunSkippedSubject = api.TestCaseRunSkippedSubjectV0_2_0
// TestCaseRunTestCaseRunSubjectContentTestCaseV0_2_0 holds the content of a TestCase field in the content
type TestCaseRunSkippedSubjectContentTestCase = api.TestCaseRunSkippedSubjectContentTestCaseV0_2_0
func NewTestCaseRunSkippedEvent() (*TestCaseRunSkippedEvent, error) {
return api.NewTestCaseRunSkippedEventV0_2_0(SpecVersion)
}
var TestCaseRunSkippedEventType = api.TestCaseRunSkippedEventTypeV0_2_0
type TestCaseRunStartedEvent = api.TestCaseRunStartedEventV0_3_0
type TestCaseRunStartedSubject = api.TestCaseRunStartedSubjectV0_3_0
// TestCaseRunTestCaseRunSubjectContentTestCaseV0_3_0 holds the content of a TestCase field in the content
type TestCaseRunStartedSubjectContentTestCase = api.TestCaseRunStartedSubjectContentTestCaseV0_3_0
// TestCaseRunTestCaseRunSubjectContentTriggerV0_3_0 holds the content of a Trigger field in the content
type TestCaseRunStartedSubjectContentTrigger = api.TestCaseRunStartedSubjectContentTriggerV0_3_0
func NewTestCaseRunStartedEvent() (*TestCaseRunStartedEvent, error) {
return api.NewTestCaseRunStartedEventV0_3_0(SpecVersion)
}
var TestCaseRunStartedEventType = api.TestCaseRunStartedEventTypeV0_3_0
type TestOutputPublishedEvent = api.TestOutputPublishedEventV0_3_0
type TestOutputPublishedSubject = api.TestOutputPublishedSubjectV0_3_0
func NewTestOutputPublishedEvent() (*TestOutputPublishedEvent, error) {
return api.NewTestOutputPublishedEventV0_3_0(SpecVersion)
}
var TestOutputPublishedEventType = api.TestOutputPublishedEventTypeV0_3_0
type TestSuiteRunFinishedEvent = api.TestSuiteRunFinishedEventV0_3_0
type TestSuiteRunFinishedSubject = api.TestSuiteRunFinishedSubjectV0_3_0
// TestSuiteRunTestSuiteRunSubjectContentTestSuiteV0_3_0 holds the content of a TestSuite field in the content
type TestSuiteRunFinishedSubjectContentTestSuite = api.TestSuiteRunFinishedSubjectContentTestSuiteV0_3_0
func NewTestSuiteRunFinishedEvent() (*TestSuiteRunFinishedEvent, error) {
return api.NewTestSuiteRunFinishedEventV0_3_0(SpecVersion)
}
var TestSuiteRunFinishedEventType = api.TestSuiteRunFinishedEventTypeV0_3_0
type TestSuiteRunQueuedEvent = api.TestSuiteRunQueuedEventV0_3_0
type TestSuiteRunQueuedSubject = api.TestSuiteRunQueuedSubjectV0_3_0
// TestSuiteRunTestSuiteRunSubjectContentTestSuiteV0_3_0 holds the content of a TestSuite field in the content
type TestSuiteRunQueuedSubjectContentTestSuite = api.TestSuiteRunQueuedSubjectContentTestSuiteV0_3_0
// TestSuiteRunTestSuiteRunSubjectContentTriggerV0_3_0 holds the content of a Trigger field in the content
type TestSuiteRunQueuedSubjectContentTrigger = api.TestSuiteRunQueuedSubjectContentTriggerV0_3_0
func NewTestSuiteRunQueuedEvent() (*TestSuiteRunQueuedEvent, error) {
return api.NewTestSuiteRunQueuedEventV0_3_0(SpecVersion)
}
var TestSuiteRunQueuedEventType = api.TestSuiteRunQueuedEventTypeV0_3_0
type TestSuiteRunStartedEvent = api.TestSuiteRunStartedEventV0_3_0
type TestSuiteRunStartedSubject = api.TestSuiteRunStartedSubjectV0_3_0
// TestSuiteRunTestSuiteRunSubjectContentTestSuiteV0_3_0 holds the content of a TestSuite field in the content
type TestSuiteRunStartedSubjectContentTestSuite = api.TestSuiteRunStartedSubjectContentTestSuiteV0_3_0
// TestSuiteRunTestSuiteRunSubjectContentTriggerV0_3_0 holds the content of a Trigger field in the content
type TestSuiteRunStartedSubjectContentTrigger = api.TestSuiteRunStartedSubjectContentTriggerV0_3_0
func NewTestSuiteRunStartedEvent() (*TestSuiteRunStartedEvent, error) {
return api.NewTestSuiteRunStartedEventV0_3_0(SpecVersion)
}
var TestSuiteRunStartedEventType = api.TestSuiteRunStartedEventTypeV0_3_0
type TicketClosedEvent = api.TicketClosedEventV0_2_0
type TicketClosedSubject = api.TicketClosedSubjectV0_2_0
func NewTicketClosedEvent() (*TicketClosedEvent, error) {
return api.NewTicketClosedEventV0_2_0(SpecVersion)
}
var TicketClosedEventType = api.TicketClosedEventTypeV0_2_0
type TicketCreatedEvent = api.TicketCreatedEventV0_2_0
type TicketCreatedSubject = api.TicketCreatedSubjectV0_2_0
func NewTicketCreatedEvent() (*TicketCreatedEvent, error) {
return api.NewTicketCreatedEventV0_2_0(SpecVersion)
}
var TicketCreatedEventType = api.TicketCreatedEventTypeV0_2_0
type TicketUpdatedEvent = api.TicketUpdatedEventV0_2_0
type TicketUpdatedSubject = api.TicketUpdatedSubjectV0_2_0
func NewTicketUpdatedEvent() (*TicketUpdatedEvent, error) {
return api.NewTicketUpdatedEventV0_2_0(SpecVersion)
}
var TicketUpdatedEventType = api.TicketUpdatedEventTypeV0_2_0
type CustomTypeEvent = api.CustomTypeEventV0_5_1
type CustomTypeSubject = api.CustomTypeSubjectV0_5_1
func NewCustomTypeEvent() (*CustomTypeEvent, error) {
return api.NewCustomTypeEventV0_5_1(SpecVersion)
}
var CustomTypeEventType = api.CustomTypeEventTypeV0_5_1
// NewFromJsonBytes builds a new CDEventReader from a JSON string as []bytes
// This works by unmarshalling the context first, extracting the event type and using
// that to unmarshal the rest of the event into the correct object.
// It assumes the context can be unmarshalled in a `Context` object.
func NewFromJsonBytes(event []byte) (api.CDEventV04, error) {
return api.NewFromJsonBytesContext[api.CDEventV04](event, CDEventsByUnversionedTypes)
}
// Build a new CDEventReader from a JSON string
func NewFromJsonString(event string) (api.CDEventV04, error) {
return NewFromJsonBytes([]byte(event))
}