-
Notifications
You must be signed in to change notification settings - Fork 8
/
models.go
57 lines (49 loc) · 1.08 KB
/
models.go
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
// Code generated by sqlc. DO NOT EDIT.
package db
import (
"database/sql"
"fmt"
"time"
"github.com/tabbed/pqtype"
)
type ChannelPriority string
const (
ChannelPriorityHigh ChannelPriority = "high"
ChannelPriorityNormal ChannelPriority = "normal"
ChannelPriorityLow ChannelPriority = "low"
ChannelPriorityDisabled ChannelPriority = "disabled"
)
func (e *ChannelPriority) Scan(src interface{}) error {
switch s := src.(type) {
case []byte:
*e = ChannelPriority(s)
case string:
*e = ChannelPriority(s)
default:
return fmt.Errorf("unsupported scan type for ChannelPriority: %T", src)
}
return nil
}
type Channel struct {
ID int32
CreatedAt time.Time
URL string
ClaimID string
Priority ChannelPriority
}
type Video struct {
ID int32
CreatedAt time.Time
UpdatedAt sql.NullTime
AccessedAt time.Time
AccessCount sql.NullInt32
TID string
URL string
SDHash string
Channel string
Storage string
Path string
Size int64
Checksum sql.NullString
Manifest pqtype.NullRawMessage
}