Go · 40069 bytes Raw Blame History
1 // Code generated by sqlc. DO NOT EDIT.
2 // versions:
3 // sqlc v1.31.1
4
5 package checksdb
6
7 import (
8 "database/sql/driver"
9 "fmt"
10 "net/netip"
11
12 "github.com/jackc/pgx/v5/pgtype"
13 )
14
15 type CheckConclusion string
16
17 const (
18 CheckConclusionSuccess CheckConclusion = "success"
19 CheckConclusionFailure CheckConclusion = "failure"
20 CheckConclusionNeutral CheckConclusion = "neutral"
21 CheckConclusionCancelled CheckConclusion = "cancelled"
22 CheckConclusionSkipped CheckConclusion = "skipped"
23 CheckConclusionTimedOut CheckConclusion = "timed_out"
24 CheckConclusionActionRequired CheckConclusion = "action_required"
25 CheckConclusionStale CheckConclusion = "stale"
26 )
27
28 func (e *CheckConclusion) Scan(src interface{}) error {
29 switch s := src.(type) {
30 case []byte:
31 *e = CheckConclusion(s)
32 case string:
33 *e = CheckConclusion(s)
34 default:
35 return fmt.Errorf("unsupported scan type for CheckConclusion: %T", src)
36 }
37 return nil
38 }
39
40 type NullCheckConclusion struct {
41 CheckConclusion CheckConclusion
42 Valid bool // Valid is true if CheckConclusion is not NULL
43 }
44
45 // Scan implements the Scanner interface.
46 func (ns *NullCheckConclusion) Scan(value interface{}) error {
47 if value == nil {
48 ns.CheckConclusion, ns.Valid = "", false
49 return nil
50 }
51 ns.Valid = true
52 return ns.CheckConclusion.Scan(value)
53 }
54
55 // Value implements the driver Valuer interface.
56 func (ns NullCheckConclusion) Value() (driver.Value, error) {
57 if !ns.Valid {
58 return nil, nil
59 }
60 return string(ns.CheckConclusion), nil
61 }
62
63 type CheckStatus string
64
65 const (
66 CheckStatusQueued CheckStatus = "queued"
67 CheckStatusInProgress CheckStatus = "in_progress"
68 CheckStatusCompleted CheckStatus = "completed"
69 CheckStatusPending CheckStatus = "pending"
70 )
71
72 func (e *CheckStatus) Scan(src interface{}) error {
73 switch s := src.(type) {
74 case []byte:
75 *e = CheckStatus(s)
76 case string:
77 *e = CheckStatus(s)
78 default:
79 return fmt.Errorf("unsupported scan type for CheckStatus: %T", src)
80 }
81 return nil
82 }
83
84 type NullCheckStatus struct {
85 CheckStatus CheckStatus
86 Valid bool // Valid is true if CheckStatus is not NULL
87 }
88
89 // Scan implements the Scanner interface.
90 func (ns *NullCheckStatus) Scan(value interface{}) error {
91 if value == nil {
92 ns.CheckStatus, ns.Valid = "", false
93 return nil
94 }
95 ns.Valid = true
96 return ns.CheckStatus.Scan(value)
97 }
98
99 // Value implements the driver Valuer interface.
100 func (ns NullCheckStatus) Value() (driver.Value, error) {
101 if !ns.Valid {
102 return nil, nil
103 }
104 return string(ns.CheckStatus), nil
105 }
106
107 type CollabRole string
108
109 const (
110 CollabRoleRead CollabRole = "read"
111 CollabRoleTriage CollabRole = "triage"
112 CollabRoleWrite CollabRole = "write"
113 CollabRoleMaintain CollabRole = "maintain"
114 CollabRoleAdmin CollabRole = "admin"
115 )
116
117 func (e *CollabRole) Scan(src interface{}) error {
118 switch s := src.(type) {
119 case []byte:
120 *e = CollabRole(s)
121 case string:
122 *e = CollabRole(s)
123 default:
124 return fmt.Errorf("unsupported scan type for CollabRole: %T", src)
125 }
126 return nil
127 }
128
129 type NullCollabRole struct {
130 CollabRole CollabRole
131 Valid bool // Valid is true if CollabRole is not NULL
132 }
133
134 // Scan implements the Scanner interface.
135 func (ns *NullCollabRole) Scan(value interface{}) error {
136 if value == nil {
137 ns.CollabRole, ns.Valid = "", false
138 return nil
139 }
140 ns.Valid = true
141 return ns.CollabRole.Scan(value)
142 }
143
144 // Value implements the driver Valuer interface.
145 func (ns NullCollabRole) Value() (driver.Value, error) {
146 if !ns.Valid {
147 return nil, nil
148 }
149 return string(ns.CollabRole), nil
150 }
151
152 type IssueKind string
153
154 const (
155 IssueKindIssue IssueKind = "issue"
156 IssueKindPr IssueKind = "pr"
157 )
158
159 func (e *IssueKind) Scan(src interface{}) error {
160 switch s := src.(type) {
161 case []byte:
162 *e = IssueKind(s)
163 case string:
164 *e = IssueKind(s)
165 default:
166 return fmt.Errorf("unsupported scan type for IssueKind: %T", src)
167 }
168 return nil
169 }
170
171 type NullIssueKind struct {
172 IssueKind IssueKind
173 Valid bool // Valid is true if IssueKind is not NULL
174 }
175
176 // Scan implements the Scanner interface.
177 func (ns *NullIssueKind) Scan(value interface{}) error {
178 if value == nil {
179 ns.IssueKind, ns.Valid = "", false
180 return nil
181 }
182 ns.Valid = true
183 return ns.IssueKind.Scan(value)
184 }
185
186 // Value implements the driver Valuer interface.
187 func (ns NullIssueKind) Value() (driver.Value, error) {
188 if !ns.Valid {
189 return nil, nil
190 }
191 return string(ns.IssueKind), nil
192 }
193
194 type IssueRefSource string
195
196 const (
197 IssueRefSourceCommentBody IssueRefSource = "comment_body"
198 IssueRefSourceIssueBody IssueRefSource = "issue_body"
199 IssueRefSourceCommitMessage IssueRefSource = "commit_message"
200 )
201
202 func (e *IssueRefSource) Scan(src interface{}) error {
203 switch s := src.(type) {
204 case []byte:
205 *e = IssueRefSource(s)
206 case string:
207 *e = IssueRefSource(s)
208 default:
209 return fmt.Errorf("unsupported scan type for IssueRefSource: %T", src)
210 }
211 return nil
212 }
213
214 type NullIssueRefSource struct {
215 IssueRefSource IssueRefSource
216 Valid bool // Valid is true if IssueRefSource is not NULL
217 }
218
219 // Scan implements the Scanner interface.
220 func (ns *NullIssueRefSource) Scan(value interface{}) error {
221 if value == nil {
222 ns.IssueRefSource, ns.Valid = "", false
223 return nil
224 }
225 ns.Valid = true
226 return ns.IssueRefSource.Scan(value)
227 }
228
229 // Value implements the driver Valuer interface.
230 func (ns NullIssueRefSource) Value() (driver.Value, error) {
231 if !ns.Valid {
232 return nil, nil
233 }
234 return string(ns.IssueRefSource), nil
235 }
236
237 type IssueState string
238
239 const (
240 IssueStateOpen IssueState = "open"
241 IssueStateClosed IssueState = "closed"
242 )
243
244 func (e *IssueState) Scan(src interface{}) error {
245 switch s := src.(type) {
246 case []byte:
247 *e = IssueState(s)
248 case string:
249 *e = IssueState(s)
250 default:
251 return fmt.Errorf("unsupported scan type for IssueState: %T", src)
252 }
253 return nil
254 }
255
256 type NullIssueState struct {
257 IssueState IssueState
258 Valid bool // Valid is true if IssueState is not NULL
259 }
260
261 // Scan implements the Scanner interface.
262 func (ns *NullIssueState) Scan(value interface{}) error {
263 if value == nil {
264 ns.IssueState, ns.Valid = "", false
265 return nil
266 }
267 ns.Valid = true
268 return ns.IssueState.Scan(value)
269 }
270
271 // Value implements the driver Valuer interface.
272 func (ns NullIssueState) Value() (driver.Value, error) {
273 if !ns.Valid {
274 return nil, nil
275 }
276 return string(ns.IssueState), nil
277 }
278
279 type IssueStateReason string
280
281 const (
282 IssueStateReasonCompleted IssueStateReason = "completed"
283 IssueStateReasonNotPlanned IssueStateReason = "not_planned"
284 IssueStateReasonReopened IssueStateReason = "reopened"
285 IssueStateReasonDuplicate IssueStateReason = "duplicate"
286 )
287
288 func (e *IssueStateReason) Scan(src interface{}) error {
289 switch s := src.(type) {
290 case []byte:
291 *e = IssueStateReason(s)
292 case string:
293 *e = IssueStateReason(s)
294 default:
295 return fmt.Errorf("unsupported scan type for IssueStateReason: %T", src)
296 }
297 return nil
298 }
299
300 type NullIssueStateReason struct {
301 IssueStateReason IssueStateReason
302 Valid bool // Valid is true if IssueStateReason is not NULL
303 }
304
305 // Scan implements the Scanner interface.
306 func (ns *NullIssueStateReason) Scan(value interface{}) error {
307 if value == nil {
308 ns.IssueStateReason, ns.Valid = "", false
309 return nil
310 }
311 ns.Valid = true
312 return ns.IssueStateReason.Scan(value)
313 }
314
315 // Value implements the driver Valuer interface.
316 func (ns NullIssueStateReason) Value() (driver.Value, error) {
317 if !ns.Valid {
318 return nil, nil
319 }
320 return string(ns.IssueStateReason), nil
321 }
322
323 type MilestoneState string
324
325 const (
326 MilestoneStateOpen MilestoneState = "open"
327 MilestoneStateClosed MilestoneState = "closed"
328 )
329
330 func (e *MilestoneState) Scan(src interface{}) error {
331 switch s := src.(type) {
332 case []byte:
333 *e = MilestoneState(s)
334 case string:
335 *e = MilestoneState(s)
336 default:
337 return fmt.Errorf("unsupported scan type for MilestoneState: %T", src)
338 }
339 return nil
340 }
341
342 type NullMilestoneState struct {
343 MilestoneState MilestoneState
344 Valid bool // Valid is true if MilestoneState is not NULL
345 }
346
347 // Scan implements the Scanner interface.
348 func (ns *NullMilestoneState) Scan(value interface{}) error {
349 if value == nil {
350 ns.MilestoneState, ns.Valid = "", false
351 return nil
352 }
353 ns.Valid = true
354 return ns.MilestoneState.Scan(value)
355 }
356
357 // Value implements the driver Valuer interface.
358 func (ns NullMilestoneState) Value() (driver.Value, error) {
359 if !ns.Valid {
360 return nil, nil
361 }
362 return string(ns.MilestoneState), nil
363 }
364
365 type NotificationThreadKind string
366
367 const (
368 NotificationThreadKindIssue NotificationThreadKind = "issue"
369 NotificationThreadKindPr NotificationThreadKind = "pr"
370 )
371
372 func (e *NotificationThreadKind) Scan(src interface{}) error {
373 switch s := src.(type) {
374 case []byte:
375 *e = NotificationThreadKind(s)
376 case string:
377 *e = NotificationThreadKind(s)
378 default:
379 return fmt.Errorf("unsupported scan type for NotificationThreadKind: %T", src)
380 }
381 return nil
382 }
383
384 type NullNotificationThreadKind struct {
385 NotificationThreadKind NotificationThreadKind
386 Valid bool // Valid is true if NotificationThreadKind is not NULL
387 }
388
389 // Scan implements the Scanner interface.
390 func (ns *NullNotificationThreadKind) Scan(value interface{}) error {
391 if value == nil {
392 ns.NotificationThreadKind, ns.Valid = "", false
393 return nil
394 }
395 ns.Valid = true
396 return ns.NotificationThreadKind.Scan(value)
397 }
398
399 // Value implements the driver Valuer interface.
400 func (ns NullNotificationThreadKind) Value() (driver.Value, error) {
401 if !ns.Valid {
402 return nil, nil
403 }
404 return string(ns.NotificationThreadKind), nil
405 }
406
407 type OrgPlan string
408
409 const (
410 OrgPlanFree OrgPlan = "free"
411 OrgPlanTeam OrgPlan = "team"
412 OrgPlanEnterprise OrgPlan = "enterprise"
413 )
414
415 func (e *OrgPlan) Scan(src interface{}) error {
416 switch s := src.(type) {
417 case []byte:
418 *e = OrgPlan(s)
419 case string:
420 *e = OrgPlan(s)
421 default:
422 return fmt.Errorf("unsupported scan type for OrgPlan: %T", src)
423 }
424 return nil
425 }
426
427 type NullOrgPlan struct {
428 OrgPlan OrgPlan
429 Valid bool // Valid is true if OrgPlan is not NULL
430 }
431
432 // Scan implements the Scanner interface.
433 func (ns *NullOrgPlan) Scan(value interface{}) error {
434 if value == nil {
435 ns.OrgPlan, ns.Valid = "", false
436 return nil
437 }
438 ns.Valid = true
439 return ns.OrgPlan.Scan(value)
440 }
441
442 // Value implements the driver Valuer interface.
443 func (ns NullOrgPlan) Value() (driver.Value, error) {
444 if !ns.Valid {
445 return nil, nil
446 }
447 return string(ns.OrgPlan), nil
448 }
449
450 type OrgRole string
451
452 const (
453 OrgRoleOwner OrgRole = "owner"
454 OrgRoleMember OrgRole = "member"
455 )
456
457 func (e *OrgRole) Scan(src interface{}) error {
458 switch s := src.(type) {
459 case []byte:
460 *e = OrgRole(s)
461 case string:
462 *e = OrgRole(s)
463 default:
464 return fmt.Errorf("unsupported scan type for OrgRole: %T", src)
465 }
466 return nil
467 }
468
469 type NullOrgRole struct {
470 OrgRole OrgRole
471 Valid bool // Valid is true if OrgRole is not NULL
472 }
473
474 // Scan implements the Scanner interface.
475 func (ns *NullOrgRole) Scan(value interface{}) error {
476 if value == nil {
477 ns.OrgRole, ns.Valid = "", false
478 return nil
479 }
480 ns.Valid = true
481 return ns.OrgRole.Scan(value)
482 }
483
484 // Value implements the driver Valuer interface.
485 func (ns NullOrgRole) Value() (driver.Value, error) {
486 if !ns.Valid {
487 return nil, nil
488 }
489 return string(ns.OrgRole), nil
490 }
491
492 type PrFileStatus string
493
494 const (
495 PrFileStatusAdded PrFileStatus = "added"
496 PrFileStatusModified PrFileStatus = "modified"
497 PrFileStatusDeleted PrFileStatus = "deleted"
498 PrFileStatusRenamed PrFileStatus = "renamed"
499 PrFileStatusCopied PrFileStatus = "copied"
500 )
501
502 func (e *PrFileStatus) Scan(src interface{}) error {
503 switch s := src.(type) {
504 case []byte:
505 *e = PrFileStatus(s)
506 case string:
507 *e = PrFileStatus(s)
508 default:
509 return fmt.Errorf("unsupported scan type for PrFileStatus: %T", src)
510 }
511 return nil
512 }
513
514 type NullPrFileStatus struct {
515 PrFileStatus PrFileStatus
516 Valid bool // Valid is true if PrFileStatus is not NULL
517 }
518
519 // Scan implements the Scanner interface.
520 func (ns *NullPrFileStatus) Scan(value interface{}) error {
521 if value == nil {
522 ns.PrFileStatus, ns.Valid = "", false
523 return nil
524 }
525 ns.Valid = true
526 return ns.PrFileStatus.Scan(value)
527 }
528
529 // Value implements the driver Valuer interface.
530 func (ns NullPrFileStatus) Value() (driver.Value, error) {
531 if !ns.Valid {
532 return nil, nil
533 }
534 return string(ns.PrFileStatus), nil
535 }
536
537 type PrMergeMethod string
538
539 const (
540 PrMergeMethodMerge PrMergeMethod = "merge"
541 PrMergeMethodSquash PrMergeMethod = "squash"
542 PrMergeMethodRebase PrMergeMethod = "rebase"
543 )
544
545 func (e *PrMergeMethod) Scan(src interface{}) error {
546 switch s := src.(type) {
547 case []byte:
548 *e = PrMergeMethod(s)
549 case string:
550 *e = PrMergeMethod(s)
551 default:
552 return fmt.Errorf("unsupported scan type for PrMergeMethod: %T", src)
553 }
554 return nil
555 }
556
557 type NullPrMergeMethod struct {
558 PrMergeMethod PrMergeMethod
559 Valid bool // Valid is true if PrMergeMethod is not NULL
560 }
561
562 // Scan implements the Scanner interface.
563 func (ns *NullPrMergeMethod) Scan(value interface{}) error {
564 if value == nil {
565 ns.PrMergeMethod, ns.Valid = "", false
566 return nil
567 }
568 ns.Valid = true
569 return ns.PrMergeMethod.Scan(value)
570 }
571
572 // Value implements the driver Valuer interface.
573 func (ns NullPrMergeMethod) Value() (driver.Value, error) {
574 if !ns.Valid {
575 return nil, nil
576 }
577 return string(ns.PrMergeMethod), nil
578 }
579
580 type PrMergeableState string
581
582 const (
583 PrMergeableStateUnknown PrMergeableState = "unknown"
584 PrMergeableStateClean PrMergeableState = "clean"
585 PrMergeableStateDirty PrMergeableState = "dirty"
586 PrMergeableStateBlocked PrMergeableState = "blocked"
587 PrMergeableStateBehind PrMergeableState = "behind"
588 )
589
590 func (e *PrMergeableState) Scan(src interface{}) error {
591 switch s := src.(type) {
592 case []byte:
593 *e = PrMergeableState(s)
594 case string:
595 *e = PrMergeableState(s)
596 default:
597 return fmt.Errorf("unsupported scan type for PrMergeableState: %T", src)
598 }
599 return nil
600 }
601
602 type NullPrMergeableState struct {
603 PrMergeableState PrMergeableState
604 Valid bool // Valid is true if PrMergeableState is not NULL
605 }
606
607 // Scan implements the Scanner interface.
608 func (ns *NullPrMergeableState) Scan(value interface{}) error {
609 if value == nil {
610 ns.PrMergeableState, ns.Valid = "", false
611 return nil
612 }
613 ns.Valid = true
614 return ns.PrMergeableState.Scan(value)
615 }
616
617 // Value implements the driver Valuer interface.
618 func (ns NullPrMergeableState) Value() (driver.Value, error) {
619 if !ns.Valid {
620 return nil, nil
621 }
622 return string(ns.PrMergeableState), nil
623 }
624
625 type PrReviewSide string
626
627 const (
628 PrReviewSideLeft PrReviewSide = "left"
629 PrReviewSideRight PrReviewSide = "right"
630 )
631
632 func (e *PrReviewSide) Scan(src interface{}) error {
633 switch s := src.(type) {
634 case []byte:
635 *e = PrReviewSide(s)
636 case string:
637 *e = PrReviewSide(s)
638 default:
639 return fmt.Errorf("unsupported scan type for PrReviewSide: %T", src)
640 }
641 return nil
642 }
643
644 type NullPrReviewSide struct {
645 PrReviewSide PrReviewSide
646 Valid bool // Valid is true if PrReviewSide is not NULL
647 }
648
649 // Scan implements the Scanner interface.
650 func (ns *NullPrReviewSide) Scan(value interface{}) error {
651 if value == nil {
652 ns.PrReviewSide, ns.Valid = "", false
653 return nil
654 }
655 ns.Valid = true
656 return ns.PrReviewSide.Scan(value)
657 }
658
659 // Value implements the driver Valuer interface.
660 func (ns NullPrReviewSide) Value() (driver.Value, error) {
661 if !ns.Valid {
662 return nil, nil
663 }
664 return string(ns.PrReviewSide), nil
665 }
666
667 type PrReviewState string
668
669 const (
670 PrReviewStateComment PrReviewState = "comment"
671 PrReviewStateApprove PrReviewState = "approve"
672 PrReviewStateRequestChanges PrReviewState = "request_changes"
673 )
674
675 func (e *PrReviewState) Scan(src interface{}) error {
676 switch s := src.(type) {
677 case []byte:
678 *e = PrReviewState(s)
679 case string:
680 *e = PrReviewState(s)
681 default:
682 return fmt.Errorf("unsupported scan type for PrReviewState: %T", src)
683 }
684 return nil
685 }
686
687 type NullPrReviewState struct {
688 PrReviewState PrReviewState
689 Valid bool // Valid is true if PrReviewState is not NULL
690 }
691
692 // Scan implements the Scanner interface.
693 func (ns *NullPrReviewState) Scan(value interface{}) error {
694 if value == nil {
695 ns.PrReviewState, ns.Valid = "", false
696 return nil
697 }
698 ns.Valid = true
699 return ns.PrReviewState.Scan(value)
700 }
701
702 // Value implements the driver Valuer interface.
703 func (ns NullPrReviewState) Value() (driver.Value, error) {
704 if !ns.Valid {
705 return nil, nil
706 }
707 return string(ns.PrReviewState), nil
708 }
709
710 type PrincipalKind string
711
712 const (
713 PrincipalKindUser PrincipalKind = "user"
714 PrincipalKindOrg PrincipalKind = "org"
715 )
716
717 func (e *PrincipalKind) Scan(src interface{}) error {
718 switch s := src.(type) {
719 case []byte:
720 *e = PrincipalKind(s)
721 case string:
722 *e = PrincipalKind(s)
723 default:
724 return fmt.Errorf("unsupported scan type for PrincipalKind: %T", src)
725 }
726 return nil
727 }
728
729 type NullPrincipalKind struct {
730 PrincipalKind PrincipalKind
731 Valid bool // Valid is true if PrincipalKind is not NULL
732 }
733
734 // Scan implements the Scanner interface.
735 func (ns *NullPrincipalKind) Scan(value interface{}) error {
736 if value == nil {
737 ns.PrincipalKind, ns.Valid = "", false
738 return nil
739 }
740 ns.Valid = true
741 return ns.PrincipalKind.Scan(value)
742 }
743
744 // Value implements the driver Valuer interface.
745 func (ns NullPrincipalKind) Value() (driver.Value, error) {
746 if !ns.Valid {
747 return nil, nil
748 }
749 return string(ns.PrincipalKind), nil
750 }
751
752 type RepoInitStatus string
753
754 const (
755 RepoInitStatusInitialized RepoInitStatus = "initialized"
756 RepoInitStatusInitPending RepoInitStatus = "init_pending"
757 RepoInitStatusInitFailed RepoInitStatus = "init_failed"
758 )
759
760 func (e *RepoInitStatus) Scan(src interface{}) error {
761 switch s := src.(type) {
762 case []byte:
763 *e = RepoInitStatus(s)
764 case string:
765 *e = RepoInitStatus(s)
766 default:
767 return fmt.Errorf("unsupported scan type for RepoInitStatus: %T", src)
768 }
769 return nil
770 }
771
772 type NullRepoInitStatus struct {
773 RepoInitStatus RepoInitStatus
774 Valid bool // Valid is true if RepoInitStatus is not NULL
775 }
776
777 // Scan implements the Scanner interface.
778 func (ns *NullRepoInitStatus) Scan(value interface{}) error {
779 if value == nil {
780 ns.RepoInitStatus, ns.Valid = "", false
781 return nil
782 }
783 ns.Valid = true
784 return ns.RepoInitStatus.Scan(value)
785 }
786
787 // Value implements the driver Valuer interface.
788 func (ns NullRepoInitStatus) Value() (driver.Value, error) {
789 if !ns.Valid {
790 return nil, nil
791 }
792 return string(ns.RepoInitStatus), nil
793 }
794
795 type RepoVisibility string
796
797 const (
798 RepoVisibilityPublic RepoVisibility = "public"
799 RepoVisibilityPrivate RepoVisibility = "private"
800 )
801
802 func (e *RepoVisibility) Scan(src interface{}) error {
803 switch s := src.(type) {
804 case []byte:
805 *e = RepoVisibility(s)
806 case string:
807 *e = RepoVisibility(s)
808 default:
809 return fmt.Errorf("unsupported scan type for RepoVisibility: %T", src)
810 }
811 return nil
812 }
813
814 type NullRepoVisibility struct {
815 RepoVisibility RepoVisibility
816 Valid bool // Valid is true if RepoVisibility is not NULL
817 }
818
819 // Scan implements the Scanner interface.
820 func (ns *NullRepoVisibility) Scan(value interface{}) error {
821 if value == nil {
822 ns.RepoVisibility, ns.Valid = "", false
823 return nil
824 }
825 ns.Valid = true
826 return ns.RepoVisibility.Scan(value)
827 }
828
829 // Value implements the driver Valuer interface.
830 func (ns NullRepoVisibility) Value() (driver.Value, error) {
831 if !ns.Valid {
832 return nil, nil
833 }
834 return string(ns.RepoVisibility), nil
835 }
836
837 type TeamPrivacy string
838
839 const (
840 TeamPrivacyVisible TeamPrivacy = "visible"
841 TeamPrivacySecret TeamPrivacy = "secret"
842 )
843
844 func (e *TeamPrivacy) Scan(src interface{}) error {
845 switch s := src.(type) {
846 case []byte:
847 *e = TeamPrivacy(s)
848 case string:
849 *e = TeamPrivacy(s)
850 default:
851 return fmt.Errorf("unsupported scan type for TeamPrivacy: %T", src)
852 }
853 return nil
854 }
855
856 type NullTeamPrivacy struct {
857 TeamPrivacy TeamPrivacy
858 Valid bool // Valid is true if TeamPrivacy is not NULL
859 }
860
861 // Scan implements the Scanner interface.
862 func (ns *NullTeamPrivacy) Scan(value interface{}) error {
863 if value == nil {
864 ns.TeamPrivacy, ns.Valid = "", false
865 return nil
866 }
867 ns.Valid = true
868 return ns.TeamPrivacy.Scan(value)
869 }
870
871 // Value implements the driver Valuer interface.
872 func (ns NullTeamPrivacy) Value() (driver.Value, error) {
873 if !ns.Valid {
874 return nil, nil
875 }
876 return string(ns.TeamPrivacy), nil
877 }
878
879 type TeamRepoRole string
880
881 const (
882 TeamRepoRoleRead TeamRepoRole = "read"
883 TeamRepoRoleTriage TeamRepoRole = "triage"
884 TeamRepoRoleWrite TeamRepoRole = "write"
885 TeamRepoRoleMaintain TeamRepoRole = "maintain"
886 TeamRepoRoleAdmin TeamRepoRole = "admin"
887 )
888
889 func (e *TeamRepoRole) Scan(src interface{}) error {
890 switch s := src.(type) {
891 case []byte:
892 *e = TeamRepoRole(s)
893 case string:
894 *e = TeamRepoRole(s)
895 default:
896 return fmt.Errorf("unsupported scan type for TeamRepoRole: %T", src)
897 }
898 return nil
899 }
900
901 type NullTeamRepoRole struct {
902 TeamRepoRole TeamRepoRole
903 Valid bool // Valid is true if TeamRepoRole is not NULL
904 }
905
906 // Scan implements the Scanner interface.
907 func (ns *NullTeamRepoRole) Scan(value interface{}) error {
908 if value == nil {
909 ns.TeamRepoRole, ns.Valid = "", false
910 return nil
911 }
912 ns.Valid = true
913 return ns.TeamRepoRole.Scan(value)
914 }
915
916 // Value implements the driver Valuer interface.
917 func (ns NullTeamRepoRole) Value() (driver.Value, error) {
918 if !ns.Valid {
919 return nil, nil
920 }
921 return string(ns.TeamRepoRole), nil
922 }
923
924 type TeamRole string
925
926 const (
927 TeamRoleMember TeamRole = "member"
928 TeamRoleMaintainer TeamRole = "maintainer"
929 )
930
931 func (e *TeamRole) Scan(src interface{}) error {
932 switch s := src.(type) {
933 case []byte:
934 *e = TeamRole(s)
935 case string:
936 *e = TeamRole(s)
937 default:
938 return fmt.Errorf("unsupported scan type for TeamRole: %T", src)
939 }
940 return nil
941 }
942
943 type NullTeamRole struct {
944 TeamRole TeamRole
945 Valid bool // Valid is true if TeamRole is not NULL
946 }
947
948 // Scan implements the Scanner interface.
949 func (ns *NullTeamRole) Scan(value interface{}) error {
950 if value == nil {
951 ns.TeamRole, ns.Valid = "", false
952 return nil
953 }
954 ns.Valid = true
955 return ns.TeamRole.Scan(value)
956 }
957
958 // Value implements the driver Valuer interface.
959 func (ns NullTeamRole) Value() (driver.Value, error) {
960 if !ns.Valid {
961 return nil, nil
962 }
963 return string(ns.TeamRole), nil
964 }
965
966 type TransferPrincipalKind string
967
968 const (
969 TransferPrincipalKindUser TransferPrincipalKind = "user"
970 TransferPrincipalKindOrg TransferPrincipalKind = "org"
971 )
972
973 func (e *TransferPrincipalKind) Scan(src interface{}) error {
974 switch s := src.(type) {
975 case []byte:
976 *e = TransferPrincipalKind(s)
977 case string:
978 *e = TransferPrincipalKind(s)
979 default:
980 return fmt.Errorf("unsupported scan type for TransferPrincipalKind: %T", src)
981 }
982 return nil
983 }
984
985 type NullTransferPrincipalKind struct {
986 TransferPrincipalKind TransferPrincipalKind
987 Valid bool // Valid is true if TransferPrincipalKind is not NULL
988 }
989
990 // Scan implements the Scanner interface.
991 func (ns *NullTransferPrincipalKind) Scan(value interface{}) error {
992 if value == nil {
993 ns.TransferPrincipalKind, ns.Valid = "", false
994 return nil
995 }
996 ns.Valid = true
997 return ns.TransferPrincipalKind.Scan(value)
998 }
999
1000 // Value implements the driver Valuer interface.
1001 func (ns NullTransferPrincipalKind) Value() (driver.Value, error) {
1002 if !ns.Valid {
1003 return nil, nil
1004 }
1005 return string(ns.TransferPrincipalKind), nil
1006 }
1007
1008 type TransferStatus string
1009
1010 const (
1011 TransferStatusPending TransferStatus = "pending"
1012 TransferStatusAccepted TransferStatus = "accepted"
1013 TransferStatusDeclined TransferStatus = "declined"
1014 TransferStatusCanceled TransferStatus = "canceled"
1015 TransferStatusExpired TransferStatus = "expired"
1016 )
1017
1018 func (e *TransferStatus) Scan(src interface{}) error {
1019 switch s := src.(type) {
1020 case []byte:
1021 *e = TransferStatus(s)
1022 case string:
1023 *e = TransferStatus(s)
1024 default:
1025 return fmt.Errorf("unsupported scan type for TransferStatus: %T", src)
1026 }
1027 return nil
1028 }
1029
1030 type NullTransferStatus struct {
1031 TransferStatus TransferStatus
1032 Valid bool // Valid is true if TransferStatus is not NULL
1033 }
1034
1035 // Scan implements the Scanner interface.
1036 func (ns *NullTransferStatus) Scan(value interface{}) error {
1037 if value == nil {
1038 ns.TransferStatus, ns.Valid = "", false
1039 return nil
1040 }
1041 ns.Valid = true
1042 return ns.TransferStatus.Scan(value)
1043 }
1044
1045 // Value implements the driver Valuer interface.
1046 func (ns NullTransferStatus) Value() (driver.Value, error) {
1047 if !ns.Valid {
1048 return nil, nil
1049 }
1050 return string(ns.TransferStatus), nil
1051 }
1052
1053 type WatchLevel string
1054
1055 const (
1056 WatchLevelAll WatchLevel = "all"
1057 WatchLevelParticipating WatchLevel = "participating"
1058 WatchLevelIgnore WatchLevel = "ignore"
1059 )
1060
1061 func (e *WatchLevel) Scan(src interface{}) error {
1062 switch s := src.(type) {
1063 case []byte:
1064 *e = WatchLevel(s)
1065 case string:
1066 *e = WatchLevel(s)
1067 default:
1068 return fmt.Errorf("unsupported scan type for WatchLevel: %T", src)
1069 }
1070 return nil
1071 }
1072
1073 type NullWatchLevel struct {
1074 WatchLevel WatchLevel
1075 Valid bool // Valid is true if WatchLevel is not NULL
1076 }
1077
1078 // Scan implements the Scanner interface.
1079 func (ns *NullWatchLevel) Scan(value interface{}) error {
1080 if value == nil {
1081 ns.WatchLevel, ns.Valid = "", false
1082 return nil
1083 }
1084 ns.Valid = true
1085 return ns.WatchLevel.Scan(value)
1086 }
1087
1088 // Value implements the driver Valuer interface.
1089 func (ns NullWatchLevel) Value() (driver.Value, error) {
1090 if !ns.Valid {
1091 return nil, nil
1092 }
1093 return string(ns.WatchLevel), nil
1094 }
1095
1096 type AuthAuditLog struct {
1097 ID int64
1098 ActorID pgtype.Int8
1099 Action string
1100 TargetType string
1101 TargetID pgtype.Int8
1102 Meta []byte
1103 CreatedAt pgtype.Timestamptz
1104 }
1105
1106 type AuthThrottle struct {
1107 ID int64
1108 Scope string
1109 Identifier string
1110 Hits int32
1111 WindowStartedAt pgtype.Timestamptz
1112 }
1113
1114 type BranchProtectionRule struct {
1115 ID int64
1116 RepoID int64
1117 Pattern string
1118 PreventForcePush bool
1119 PreventDeletion bool
1120 RequirePrForPush bool
1121 AllowedPusherUserIds []int64
1122 RequireSignedCommits bool
1123 StatusChecksRequired []string
1124 CreatedAt pgtype.Timestamptz
1125 UpdatedAt pgtype.Timestamptz
1126 CreatedByUserID pgtype.Int8
1127 RequiredReviewCount int32
1128 DismissStaleReviewsOnPush bool
1129 RequireCodeOwnerReview bool
1130 DismissStaleStatusChecksOnPush bool
1131 }
1132
1133 type CheckRun struct {
1134 ID int64
1135 SuiteID int64
1136 RepoID int64
1137 HeadSha string
1138 Name string
1139 Status CheckStatus
1140 Conclusion NullCheckConclusion
1141 StartedAt pgtype.Timestamptz
1142 CompletedAt pgtype.Timestamptz
1143 DetailsUrl string
1144 Output []byte
1145 ExternalID pgtype.Text
1146 CreatedAt pgtype.Timestamptz
1147 UpdatedAt pgtype.Timestamptz
1148 }
1149
1150 type CheckSuite struct {
1151 ID int64
1152 RepoID int64
1153 HeadSha string
1154 AppSlug string
1155 Status CheckStatus
1156 Conclusion NullCheckConclusion
1157 CreatedAt pgtype.Timestamptz
1158 UpdatedAt pgtype.Timestamptz
1159 }
1160
1161 type CodeSearchContent struct {
1162 RepoID int64
1163 RefName string
1164 Path string
1165 ContentTsv interface{}
1166 ContentTrgm string
1167 }
1168
1169 type CodeSearchPath struct {
1170 RepoID int64
1171 RefName string
1172 Path string
1173 Tsv interface{}
1174 }
1175
1176 type DomainEvent struct {
1177 ID int64
1178 ActorUserID pgtype.Int8
1179 Kind string
1180 RepoID pgtype.Int8
1181 SourceKind string
1182 SourceID int64
1183 Public bool
1184 Payload []byte
1185 CreatedAt pgtype.Timestamptz
1186 }
1187
1188 type DomainEventsProcessed struct {
1189 Consumer string
1190 LastEventID int64
1191 UpdatedAt pgtype.Timestamptz
1192 }
1193
1194 type EmailVerification struct {
1195 ID int64
1196 UserEmailID int64
1197 TokenHash []byte
1198 ExpiresAt pgtype.Timestamptz
1199 UsedAt pgtype.Timestamptz
1200 CreatedAt pgtype.Timestamptz
1201 }
1202
1203 type Issue struct {
1204 ID int64
1205 RepoID int64
1206 Number int64
1207 Kind IssueKind
1208 Title string
1209 Body string
1210 BodyHtmlCached pgtype.Text
1211 MdPipelineVersion int32
1212 AuthorUserID pgtype.Int8
1213 State IssueState
1214 StateReason NullIssueStateReason
1215 Locked bool
1216 LockReason pgtype.Text
1217 MilestoneID pgtype.Int8
1218 CreatedAt pgtype.Timestamptz
1219 UpdatedAt pgtype.Timestamptz
1220 EditedAt pgtype.Timestamptz
1221 ClosedAt pgtype.Timestamptz
1222 ClosedByUserID pgtype.Int8
1223 }
1224
1225 type IssueAssignee struct {
1226 IssueID int64
1227 UserID int64
1228 AssignedAt pgtype.Timestamptz
1229 AssignedByUserID pgtype.Int8
1230 }
1231
1232 type IssueComment struct {
1233 ID int64
1234 IssueID int64
1235 AuthorUserID pgtype.Int8
1236 Body string
1237 BodyHtmlCached pgtype.Text
1238 MdPipelineVersion int32
1239 CreatedAt pgtype.Timestamptz
1240 UpdatedAt pgtype.Timestamptz
1241 EditedAt pgtype.Timestamptz
1242 }
1243
1244 type IssueEvent struct {
1245 ID int64
1246 IssueID int64
1247 ActorUserID pgtype.Int8
1248 Kind string
1249 Meta []byte
1250 RefTargetID pgtype.Int8
1251 CreatedAt pgtype.Timestamptz
1252 }
1253
1254 type IssueLabel struct {
1255 IssueID int64
1256 LabelID int64
1257 AppliedAt pgtype.Timestamptz
1258 AppliedByUserID pgtype.Int8
1259 }
1260
1261 type IssueReference struct {
1262 ID int64
1263 SourceIssueID pgtype.Int8
1264 TargetIssueID int64
1265 SourceKind IssueRefSource
1266 SourceObjectID pgtype.Int8
1267 CreatedAt pgtype.Timestamptz
1268 }
1269
1270 type IssuesSearch struct {
1271 IssueID int64
1272 RepoID int64
1273 Kind IssueKind
1274 State IssueState
1275 AuthorUserID pgtype.Int8
1276 Tsv interface{}
1277 }
1278
1279 type Job struct {
1280 ID int64
1281 Kind string
1282 Payload []byte
1283 RunAt pgtype.Timestamptz
1284 Attempts int32
1285 MaxAttempts int32
1286 LastError pgtype.Text
1287 LockedBy pgtype.Text
1288 LockedAt pgtype.Timestamptz
1289 CompletedAt pgtype.Timestamptz
1290 FailedAt pgtype.Timestamptz
1291 CreatedAt pgtype.Timestamptz
1292 }
1293
1294 type Label struct {
1295 ID int64
1296 RepoID int64
1297 Name string
1298 Color string
1299 Description string
1300 CreatedAt pgtype.Timestamptz
1301 }
1302
1303 type Meta struct {
1304 Key string
1305 Value []byte
1306 UpdatedAt pgtype.Timestamptz
1307 }
1308
1309 type Milestone struct {
1310 ID int64
1311 RepoID int64
1312 Title string
1313 Description string
1314 State MilestoneState
1315 DueOn pgtype.Timestamptz
1316 CreatedAt pgtype.Timestamptz
1317 ClosedAt pgtype.Timestamptz
1318 }
1319
1320 type Notification struct {
1321 ID int64
1322 RecipientUserID int64
1323 Kind string
1324 Reason string
1325 RepoID pgtype.Int8
1326 ThreadKind NullNotificationThreadKind
1327 ThreadID pgtype.Int8
1328 SourceEventID pgtype.Int8
1329 Unread bool
1330 LastEventAt pgtype.Timestamptz
1331 LastActorUserID pgtype.Int8
1332 Summary []byte
1333 CreatedAt pgtype.Timestamptz
1334 UpdatedAt pgtype.Timestamptz
1335 }
1336
1337 type NotificationEmailLog struct {
1338 ID int64
1339 RecipientUserID int64
1340 NotificationID pgtype.Int8
1341 ThreadKind NullNotificationThreadKind
1342 ThreadID pgtype.Int8
1343 SentAt pgtype.Timestamptz
1344 MessageID pgtype.Text
1345 }
1346
1347 type NotificationThread struct {
1348 RecipientUserID int64
1349 ThreadKind NotificationThreadKind
1350 ThreadID int64
1351 Subscribed bool
1352 Reason string
1353 UpdatedAt pgtype.Timestamptz
1354 }
1355
1356 type Org struct {
1357 ID int64
1358 Slug string
1359 DisplayName string
1360 Description string
1361 AvatarObjectKey pgtype.Text
1362 Location string
1363 Website string
1364 BillingEmail string
1365 Plan OrgPlan
1366 AllowMemberRepoCreate bool
1367 CreatedByUserID pgtype.Int8
1368 SuspendedAt pgtype.Timestamptz
1369 SuspendedReason pgtype.Text
1370 DeletedAt pgtype.Timestamptz
1371 CreatedAt pgtype.Timestamptz
1372 UpdatedAt pgtype.Timestamptz
1373 }
1374
1375 type OrgInvitation struct {
1376 ID int64
1377 OrgID int64
1378 InvitedByUserID pgtype.Int8
1379 TargetUserID pgtype.Int8
1380 TargetEmail pgtype.Text
1381 Role OrgRole
1382 TokenHash []byte
1383 ExpiresAt pgtype.Timestamptz
1384 AcceptedAt pgtype.Timestamptz
1385 DeclinedAt pgtype.Timestamptz
1386 CanceledAt pgtype.Timestamptz
1387 CreatedAt pgtype.Timestamptz
1388 }
1389
1390 type OrgMember struct {
1391 OrgID int64
1392 UserID int64
1393 Role OrgRole
1394 InvitedByUserID pgtype.Int8
1395 JoinedAt pgtype.Timestamptz
1396 }
1397
1398 type PasswordReset struct {
1399 ID int64
1400 UserID int64
1401 TokenHash []byte
1402 ExpiresAt pgtype.Timestamptz
1403 UsedAt pgtype.Timestamptz
1404 CreatedAt pgtype.Timestamptz
1405 }
1406
1407 type PrReview struct {
1408 ID int64
1409 PrIssueID int64
1410 AuthorUserID pgtype.Int8
1411 State PrReviewState
1412 Body string
1413 BodyHtmlCached pgtype.Text
1414 SubmittedAt pgtype.Timestamptz
1415 DismissedAt pgtype.Timestamptz
1416 DismissedByUserID pgtype.Int8
1417 DismissalReason string
1418 }
1419
1420 type PrReviewComment struct {
1421 ID int64
1422 PrIssueID int64
1423 ReviewID pgtype.Int8
1424 AuthorUserID pgtype.Int8
1425 FilePath string
1426 Side PrReviewSide
1427 OriginalCommitSha string
1428 OriginalLine int32
1429 OriginalPosition int32
1430 CurrentPosition pgtype.Int4
1431 Body string
1432 BodyHtmlCached pgtype.Text
1433 InReplyToID pgtype.Int8
1434 Pending bool
1435 ResolvedAt pgtype.Timestamptz
1436 ResolvedByUserID pgtype.Int8
1437 CreatedAt pgtype.Timestamptz
1438 UpdatedAt pgtype.Timestamptz
1439 EditedAt pgtype.Timestamptz
1440 }
1441
1442 type PrReviewRequest struct {
1443 ID int64
1444 PrIssueID int64
1445 RequestedUserID pgtype.Int8
1446 RequestedTeamID pgtype.Int8
1447 RequestedByUserID pgtype.Int8
1448 RequestedAt pgtype.Timestamptz
1449 DismissedAt pgtype.Timestamptz
1450 SatisfiedByReviewID pgtype.Int8
1451 }
1452
1453 type Principal struct {
1454 Slug string
1455 Kind PrincipalKind
1456 ID int64
1457 }
1458
1459 type PullRequest struct {
1460 IssueID int64
1461 BaseRef string
1462 HeadRef string
1463 HeadRepoID int64
1464 BaseOid string
1465 HeadOid string
1466 Draft bool
1467 Mergeable pgtype.Bool
1468 MergeableState PrMergeableState
1469 MergeCommitSha pgtype.Text
1470 MergedAt pgtype.Timestamptz
1471 MergedByUserID pgtype.Int8
1472 MergeMethod NullPrMergeMethod
1473 BaseOidAtMerge pgtype.Text
1474 HeadOidAtMerge pgtype.Text
1475 LastSynchronizedAt pgtype.Timestamptz
1476 }
1477
1478 type PullRequestCommit struct {
1479 PrID int64
1480 Sha string
1481 Position int32
1482 AuthorName string
1483 AuthorEmail string
1484 CommitterName string
1485 CommitterEmail string
1486 Subject string
1487 Body string
1488 AuthoredAt pgtype.Timestamptz
1489 CommittedAt pgtype.Timestamptz
1490 }
1491
1492 type PullRequestFile struct {
1493 PrID int64
1494 Path string
1495 Status PrFileStatus
1496 OldPath pgtype.Text
1497 Additions int32
1498 Deletions int32
1499 Changes int32
1500 }
1501
1502 type PushEvent struct {
1503 ID int64
1504 RepoID int64
1505 PusherUserID pgtype.Int8
1506 BeforeSha string
1507 AfterSha string
1508 Ref string
1509 Protocol string
1510 RequestID string
1511 ProcessedAt pgtype.Timestamptz
1512 CreatedAt pgtype.Timestamptz
1513 }
1514
1515 type Repo struct {
1516 ID int64
1517 OwnerUserID pgtype.Int8
1518 OwnerOrgID pgtype.Int8
1519 Name string
1520 Description string
1521 Visibility RepoVisibility
1522 DefaultBranch string
1523 IsArchived bool
1524 ArchivedAt pgtype.Timestamptz
1525 DeletedAt pgtype.Timestamptz
1526 DiskUsedBytes int64
1527 ForkOfRepoID pgtype.Int8
1528 LicenseKey pgtype.Text
1529 PrimaryLanguage pgtype.Text
1530 HasIssues bool
1531 HasPulls bool
1532 CreatedAt pgtype.Timestamptz
1533 UpdatedAt pgtype.Timestamptz
1534 DefaultBranchOid pgtype.Text
1535 AllowSquashMerge bool
1536 AllowRebaseMerge bool
1537 AllowMergeCommit bool
1538 DefaultMergeMethod PrMergeMethod
1539 StarCount int64
1540 WatcherCount int64
1541 ForkCount int64
1542 InitStatus RepoInitStatus
1543 LastIndexedOid pgtype.Text
1544 }
1545
1546 type RepoCollaborator struct {
1547 RepoID int64
1548 UserID int64
1549 Role CollabRole
1550 AddedAt pgtype.Timestamptz
1551 AddedByUserID pgtype.Int8
1552 }
1553
1554 type RepoIssueCounter struct {
1555 RepoID int64
1556 NextNumber int64
1557 }
1558
1559 type RepoRedirect struct {
1560 OldOwnerUserID pgtype.Int8
1561 OldOwnerOrgID pgtype.Int8
1562 OldName string
1563 RepoID int64
1564 RedirectedAt pgtype.Timestamptz
1565 }
1566
1567 type RepoTopic struct {
1568 RepoID int64
1569 Topic string
1570 CreatedAt pgtype.Timestamptz
1571 }
1572
1573 type RepoTransferRequest struct {
1574 ID int64
1575 RepoID int64
1576 FromUserID int64
1577 ToPrincipalKind TransferPrincipalKind
1578 ToPrincipalID int64
1579 CreatedBy int64
1580 CreatedAt pgtype.Timestamptz
1581 ExpiresAt pgtype.Timestamptz
1582 Status TransferStatus
1583 AcceptedAt pgtype.Timestamptz
1584 DeclinedAt pgtype.Timestamptz
1585 CanceledAt pgtype.Timestamptz
1586 }
1587
1588 type ReposSearch struct {
1589 RepoID int64
1590 Tsv interface{}
1591 }
1592
1593 type Star struct {
1594 UserID int64
1595 RepoID int64
1596 StarredAt pgtype.Timestamptz
1597 }
1598
1599 type Team struct {
1600 ID int64
1601 OrgID int64
1602 Slug string
1603 DisplayName string
1604 Description string
1605 ParentTeamID pgtype.Int8
1606 Privacy TeamPrivacy
1607 CreatedByUserID pgtype.Int8
1608 CreatedAt pgtype.Timestamptz
1609 UpdatedAt pgtype.Timestamptz
1610 }
1611
1612 type TeamMember struct {
1613 TeamID int64
1614 UserID int64
1615 Role TeamRole
1616 AddedByUserID pgtype.Int8
1617 AddedAt pgtype.Timestamptz
1618 }
1619
1620 type TeamRepoAccess struct {
1621 TeamID int64
1622 RepoID int64
1623 Role TeamRepoRole
1624 AddedByUserID pgtype.Int8
1625 AddedAt pgtype.Timestamptz
1626 }
1627
1628 type User struct {
1629 ID int64
1630 Username string
1631 DisplayName string
1632 PrimaryEmailID pgtype.Int8
1633 PasswordHash string
1634 PasswordAlgo string
1635 PasswordUpdatedAt pgtype.Timestamptz
1636 EmailVerified bool
1637 LastLoginAt pgtype.Timestamptz
1638 SuspendedAt pgtype.Timestamptz
1639 SuspendedReason pgtype.Text
1640 DeletedAt pgtype.Timestamptz
1641 CreatedAt pgtype.Timestamptz
1642 UpdatedAt pgtype.Timestamptz
1643 Bio string
1644 Location string
1645 Website string
1646 Company string
1647 Pronouns string
1648 AvatarObjectKey pgtype.Text
1649 Theme string
1650 SessionEpoch int32
1651 }
1652
1653 type UserEmail struct {
1654 ID int64
1655 UserID int64
1656 Email string
1657 IsPrimary bool
1658 Verified bool
1659 VerificationTokenHash []byte
1660 VerificationSentAt pgtype.Timestamptz
1661 VerifiedAt pgtype.Timestamptz
1662 CreatedAt pgtype.Timestamptz
1663 }
1664
1665 type UserNotificationPref struct {
1666 UserID int64
1667 Key string
1668 Value []byte
1669 UpdatedAt pgtype.Timestamptz
1670 }
1671
1672 type UserRecoveryCode struct {
1673 ID int64
1674 UserID int64
1675 CodeHash []byte
1676 UsedAt pgtype.Timestamptz
1677 GeneratedAt pgtype.Timestamptz
1678 CreatedAt pgtype.Timestamptz
1679 }
1680
1681 type UserSshKey struct {
1682 ID int64
1683 UserID int64
1684 Title string
1685 FingerprintSha256 string
1686 KeyType string
1687 KeyBits int32
1688 PublicKey string
1689 LastUsedAt pgtype.Timestamptz
1690 LastUsedIp *netip.Addr
1691 CreatedAt pgtype.Timestamptz
1692 }
1693
1694 type UserToken struct {
1695 ID int64
1696 UserID int64
1697 Name string
1698 TokenHash []byte
1699 TokenPrefix string
1700 Scopes []string
1701 ExpiresAt pgtype.Timestamptz
1702 LastUsedAt pgtype.Timestamptz
1703 LastUsedIp *netip.Addr
1704 RevokedAt pgtype.Timestamptz
1705 CreatedAt pgtype.Timestamptz
1706 }
1707
1708 type UserTotp struct {
1709 ID int64
1710 UserID int64
1711 SecretEncrypted []byte
1712 SecretNonce []byte
1713 ConfirmedAt pgtype.Timestamptz
1714 LastUsedCounter int64
1715 CreatedAt pgtype.Timestamptz
1716 UpdatedAt pgtype.Timestamptz
1717 }
1718
1719 type UsernameRedirect struct {
1720 OldUsername string
1721 UserID int64
1722 ChangedAt pgtype.Timestamptz
1723 }
1724
1725 type UsersSearch struct {
1726 UserID int64
1727 Tsv interface{}
1728 }
1729
1730 type Watch struct {
1731 UserID int64
1732 RepoID int64
1733 Level WatchLevel
1734 UpdatedAt pgtype.Timestamptz
1735 }
1736
1737 type WebhookEventsPending struct {
1738 ID int64
1739 RepoID int64
1740 EventKind string
1741 Payload []byte
1742 CreatedAt pgtype.Timestamptz
1743 }
1744