-
Notifications
You must be signed in to change notification settings - Fork 26
Expand file tree
/
Copy pathhelpers_gen.go
More file actions
151 lines (132 loc) · 6.08 KB
/
helpers_gen.go
File metadata and controls
151 lines (132 loc) · 6.08 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
// Code generated by acp-go-generator; DO NOT EDIT.
package acp
// NewPlanUpdateContentItems constructs a PlanUpdateContent using the 'items' variant.
func NewPlanUpdateContentItems(id PlanId, entries []PlanEntry) PlanUpdateContent {
return PlanUpdateContent{Items: &PlanUpdateContentItems{
Entries: entries,
Id: id,
Type: "items",
}}
}
// NewPlanUpdateContentFile constructs a PlanUpdateContent using the 'file' variant.
func NewPlanUpdateContentFile(id PlanId, uri string) PlanUpdateContent {
return PlanUpdateContent{File: &PlanUpdateContentFile{
Id: id,
Type: "file",
Uri: uri,
}}
}
// NewPlanUpdateContentMarkdown constructs a PlanUpdateContent using the 'markdown' variant.
func NewPlanUpdateContentMarkdown(id PlanId, content string) PlanUpdateContent {
return PlanUpdateContent{Markdown: &PlanUpdateContentMarkdown{
Content: content,
Id: id,
Type: "markdown",
}}
}
// NewRequestPermissionOutcomeCancelled constructs a RequestPermissionOutcome using the 'cancelled' variant.
func NewRequestPermissionOutcomeCancelled() RequestPermissionOutcome {
return RequestPermissionOutcome{Cancelled: &RequestPermissionOutcomeCancelled{Outcome: "cancelled"}}
}
// NewRequestPermissionOutcomeSelected constructs a RequestPermissionOutcome using the 'selected' variant.
func NewRequestPermissionOutcomeSelected(optionId PermissionOptionId) RequestPermissionOutcome {
return RequestPermissionOutcome{Selected: &RequestPermissionOutcomeSelected{
OptionId: optionId,
Outcome: "selected",
}}
}
// NewSessionConfigOptionSelect constructs a SessionConfigOption using the 'select' variant.
func NewSessionConfigOptionSelect(currentValue SessionConfigValueId, options SessionConfigSelectOptions) SessionConfigOption {
return SessionConfigOption{Select: &SessionConfigOptionSelect{
CurrentValue: currentValue,
Options: options,
Type: "select",
}}
}
// NewSessionConfigOptionBoolean constructs a SessionConfigOption using the 'boolean' variant.
func NewSessionConfigOptionBoolean(currentValue bool) SessionConfigOption {
return SessionConfigOption{Boolean: &SessionConfigOptionBoolean{
CurrentValue: currentValue,
Type: "boolean",
}}
}
// NewUnstableCreateElicitationRequestForm constructs a UnstableCreateElicitationRequest using the 'form' variant.
func NewUnstableCreateElicitationRequestForm(requestedSchema UnstableElicitationSchema) UnstableCreateElicitationRequest {
return UnstableCreateElicitationRequest{Form: &UnstableCreateElicitationForm{
Mode: "form",
RequestedSchema: requestedSchema,
}}
}
// NewUnstableCreateElicitationRequestUrl constructs a UnstableCreateElicitationRequest using the 'url' variant.
func NewUnstableCreateElicitationRequestUrl(elicitationId UnstableElicitationId, url string) UnstableCreateElicitationRequest {
return UnstableCreateElicitationRequest{Url: &UnstableCreateElicitationUrl{
ElicitationId: elicitationId,
Mode: "url",
Url: url,
}}
}
// NewUnstableCreateElicitationResponseAccept constructs a UnstableCreateElicitationResponse using the 'accept' variant.
func NewUnstableCreateElicitationResponseAccept() UnstableCreateElicitationResponse {
return UnstableCreateElicitationResponse{Accept: &UnstableCreateElicitationAccept{Action: "accept"}}
}
// NewUnstableCreateElicitationResponseDecline constructs a UnstableCreateElicitationResponse using the 'decline' variant.
func NewUnstableCreateElicitationResponseDecline() UnstableCreateElicitationResponse {
return UnstableCreateElicitationResponse{Decline: &UnstableCreateElicitationDecline{Action: "decline"}}
}
// NewUnstableCreateElicitationResponseCancel constructs a UnstableCreateElicitationResponse using the 'cancel' variant.
func NewUnstableCreateElicitationResponseCancel() UnstableCreateElicitationResponse {
return UnstableCreateElicitationResponse{Cancel: &UnstableCreateElicitationCancel{Action: "cancel"}}
}
// NewUnstableNesSuggestionEdit constructs a UnstableNesSuggestion using the 'edit' variant.
func NewUnstableNesSuggestionEdit(id string, uri string, edits []UnstableNesTextEdit) UnstableNesSuggestion {
return UnstableNesSuggestion{Edit: &UnstableNesSuggestionEdit{
Edits: edits,
Id: id,
Kind: "edit",
Uri: uri,
}}
}
// NewUnstableNesSuggestionJump constructs a UnstableNesSuggestion using the 'jump' variant.
func NewUnstableNesSuggestionJump(id string, uri string, position UnstablePosition) UnstableNesSuggestion {
return UnstableNesSuggestion{Jump: &UnstableNesSuggestionJump{
Id: id,
Kind: "jump",
Position: position,
Uri: uri,
}}
}
// NewUnstableNesSuggestionRename constructs a UnstableNesSuggestion using the 'rename' variant.
func NewUnstableNesSuggestionRename(id string, uri string, position UnstablePosition, newName string) UnstableNesSuggestion {
return UnstableNesSuggestion{Rename: &UnstableNesSuggestionRename{
Id: id,
Kind: "rename",
NewName: newName,
Position: position,
Uri: uri,
}}
}
// NewUnstableNesSuggestionSearchAndReplace constructs a UnstableNesSuggestion using the 'searchAndReplace' variant.
func NewUnstableNesSuggestionSearchAndReplace(id string, uri string, search string, replace string) UnstableNesSuggestion {
return UnstableNesSuggestion{SearchAndReplace: &UnstableNesSuggestionSearchAndReplace{
Id: id,
Kind: "searchAndReplace",
Replace: replace,
Search: search,
Uri: uri,
}}
}
// NewUnstableSessionConfigOptionSelect constructs a UnstableSessionConfigOption using the 'select' variant.
func NewUnstableSessionConfigOptionSelect(currentValue SessionConfigValueId, options SessionConfigSelectOptions) UnstableSessionConfigOption {
return UnstableSessionConfigOption{Select: &UnstableSessionConfigOptionSelect{
CurrentValue: currentValue,
Options: options,
Type: "select",
}}
}
// NewUnstableSessionConfigOptionBoolean constructs a UnstableSessionConfigOption using the 'boolean' variant.
func NewUnstableSessionConfigOptionBoolean(currentValue bool) UnstableSessionConfigOption {
return UnstableSessionConfigOption{Boolean: &UnstableSessionConfigOptionBoolean{
CurrentValue: currentValue,
Type: "boolean",
}}
}