forked from Scalr/go-scalr
/
type_helpers.go
41 lines (33 loc) · 1000 Bytes
/
type_helpers.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
package scalr
// Bool returns a pointer to the given bool
func Bool(v bool) *bool {
return &v
}
// Category returns a pointer to the given category type.
func Category(v CategoryType) *CategoryType {
return &v
}
// Int returns a pointer to the given int.
func Int(v int) *int {
return &v
}
// Int64 returns a pointer to the given int64.
func Int64(v int64) *int64 {
return &v
}
// String returns a pointer to the given string.
func String(v string) *string {
return &v
}
// WorkspaceExecutionModePtr returns a pointer to the given execution mode
func WorkspaceExecutionModePtr(v WorkspaceExecutionMode) *WorkspaceExecutionMode {
return &v
}
// AutoQueueRunsModePtr returns a pointer to the given auto queue runs mode
func AutoQueueRunsModePtr(v WorkspaceAutoQueueRuns) *WorkspaceAutoQueueRuns {
return &v
}
// ServiceAccountStatusPtr returns a pointer to the given service account status value.
func ServiceAccountStatusPtr(v ServiceAccountStatus) *ServiceAccountStatus {
return &v
}