-
Notifications
You must be signed in to change notification settings - Fork 0
/
environment.go
45 lines (36 loc) · 960 Bytes
/
environment.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
package types
import "time"
type Environment struct {
ID string `json:"id" yaml:"id" `
Name string `json:"name" yaml:"name" `
ProjectID string `json:"-" yaml:"-"`
CreatedAt time.Time `json:"createdAt" yaml:"createdAt"`
UpdatedAt time.Time `json:"updatedAt" yaml:"updatedAt"`
}
type CreateEnvironment struct {
Name string `json:"name"`
internal bool
}
func (in *CreateEnvironment) SetInternal(internal bool) {
in.internal = internal
}
func (in CreateEnvironment) Internal() bool {
return in.internal
}
type CreatedEnvironment struct {
ID string `json:"id" yaml:"id"`
CreatedAt time.Time `json:"createdAt" yaml:"createdAt"`
Membership Membership `json:"membership" yaml:"membership"`
}
type Environments struct {
Items []Environment
EndCursor *string
}
type EnvironmentsParams struct {
Last *uint
Before *string
Name *string
}
type UpdateEnvironment struct {
Name *string `json:"name"`
}