id
int32 0
167k
| repo
stringlengths 5
54
| path
stringlengths 4
155
| func_name
stringlengths 1
118
| original_string
stringlengths 52
85.5k
| language
stringclasses 1
value | code
stringlengths 52
85.5k
| code_tokens
listlengths 21
1.41k
| docstring
stringlengths 6
2.61k
| docstring_tokens
listlengths 3
215
| sha
stringlengths 40
40
| url
stringlengths 85
252
|
---|---|---|---|---|---|---|---|---|---|---|---|
145,300 |
xanzy/go-cloudstack
|
cloudstack/FirewallService.go
|
NewCreateFirewallRuleParams
|
func (s *FirewallService) NewCreateFirewallRuleParams(ipaddressid string, protocol string) *CreateFirewallRuleParams {
p := &CreateFirewallRuleParams{}
p.p = make(map[string]interface{})
p.p["ipaddressid"] = ipaddressid
p.p["protocol"] = protocol
return p
}
|
go
|
func (s *FirewallService) NewCreateFirewallRuleParams(ipaddressid string, protocol string) *CreateFirewallRuleParams {
p := &CreateFirewallRuleParams{}
p.p = make(map[string]interface{})
p.p["ipaddressid"] = ipaddressid
p.p["protocol"] = protocol
return p
}
|
[
"func",
"(",
"s",
"*",
"FirewallService",
")",
"NewCreateFirewallRuleParams",
"(",
"ipaddressid",
"string",
",",
"protocol",
"string",
")",
"*",
"CreateFirewallRuleParams",
"{",
"p",
":=",
"&",
"CreateFirewallRuleParams",
"{",
"}",
"\n",
"p",
".",
"p",
"=",
"make",
"(",
"map",
"[",
"string",
"]",
"interface",
"{",
"}",
")",
"\n",
"p",
".",
"p",
"[",
"\"",
"\"",
"]",
"=",
"ipaddressid",
"\n",
"p",
".",
"p",
"[",
"\"",
"\"",
"]",
"=",
"protocol",
"\n",
"return",
"p",
"\n",
"}"
] |
// You should always use this function to get a new CreateFirewallRuleParams instance,
// as then you are sure you have configured all required params
|
[
"You",
"should",
"always",
"use",
"this",
"function",
"to",
"get",
"a",
"new",
"CreateFirewallRuleParams",
"instance",
"as",
"then",
"you",
"are",
"sure",
"you",
"have",
"configured",
"all",
"required",
"params"
] |
b6f53ed3282d22b6446422879587b0a78e1b0f11
|
https://github.com/xanzy/go-cloudstack/blob/b6f53ed3282d22b6446422879587b0a78e1b0f11/cloudstack/FirewallService.go#L637-L643
|
145,301 |
xanzy/go-cloudstack
|
cloudstack/FirewallService.go
|
CreateFirewallRule
|
func (s *FirewallService) CreateFirewallRule(p *CreateFirewallRuleParams) (*CreateFirewallRuleResponse, error) {
resp, err := s.cs.newRequest("createFirewallRule", p.toURLValues())
if err != nil {
return nil, err
}
var r CreateFirewallRuleResponse
if err := json.Unmarshal(resp, &r); err != nil {
return nil, err
}
// If we have a async client, we need to wait for the async result
if s.cs.async {
b, err := s.cs.GetAsyncJobResult(r.JobID, s.cs.timeout)
if err != nil {
if err == AsyncTimeoutErr {
return &r, err
}
return nil, err
}
b, err = getRawValue(b)
if err != nil {
return nil, err
}
b, err = convertFirewallServiceResponse(b)
if err != nil {
return nil, err
}
if err := json.Unmarshal(b, &r); err != nil {
return nil, err
}
}
return &r, nil
}
|
go
|
func (s *FirewallService) CreateFirewallRule(p *CreateFirewallRuleParams) (*CreateFirewallRuleResponse, error) {
resp, err := s.cs.newRequest("createFirewallRule", p.toURLValues())
if err != nil {
return nil, err
}
var r CreateFirewallRuleResponse
if err := json.Unmarshal(resp, &r); err != nil {
return nil, err
}
// If we have a async client, we need to wait for the async result
if s.cs.async {
b, err := s.cs.GetAsyncJobResult(r.JobID, s.cs.timeout)
if err != nil {
if err == AsyncTimeoutErr {
return &r, err
}
return nil, err
}
b, err = getRawValue(b)
if err != nil {
return nil, err
}
b, err = convertFirewallServiceResponse(b)
if err != nil {
return nil, err
}
if err := json.Unmarshal(b, &r); err != nil {
return nil, err
}
}
return &r, nil
}
|
[
"func",
"(",
"s",
"*",
"FirewallService",
")",
"CreateFirewallRule",
"(",
"p",
"*",
"CreateFirewallRuleParams",
")",
"(",
"*",
"CreateFirewallRuleResponse",
",",
"error",
")",
"{",
"resp",
",",
"err",
":=",
"s",
".",
"cs",
".",
"newRequest",
"(",
"\"",
"\"",
",",
"p",
".",
"toURLValues",
"(",
")",
")",
"\n",
"if",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"var",
"r",
"CreateFirewallRuleResponse",
"\n",
"if",
"err",
":=",
"json",
".",
"Unmarshal",
"(",
"resp",
",",
"&",
"r",
")",
";",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"// If we have a async client, we need to wait for the async result",
"if",
"s",
".",
"cs",
".",
"async",
"{",
"b",
",",
"err",
":=",
"s",
".",
"cs",
".",
"GetAsyncJobResult",
"(",
"r",
".",
"JobID",
",",
"s",
".",
"cs",
".",
"timeout",
")",
"\n",
"if",
"err",
"!=",
"nil",
"{",
"if",
"err",
"==",
"AsyncTimeoutErr",
"{",
"return",
"&",
"r",
",",
"err",
"\n",
"}",
"\n",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"b",
",",
"err",
"=",
"getRawValue",
"(",
"b",
")",
"\n",
"if",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"b",
",",
"err",
"=",
"convertFirewallServiceResponse",
"(",
"b",
")",
"\n",
"if",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"if",
"err",
":=",
"json",
".",
"Unmarshal",
"(",
"b",
",",
"&",
"r",
")",
";",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n",
"}",
"\n\n",
"return",
"&",
"r",
",",
"nil",
"\n",
"}"
] |
// Creates a firewall rule for a given IP address
|
[
"Creates",
"a",
"firewall",
"rule",
"for",
"a",
"given",
"IP",
"address"
] |
b6f53ed3282d22b6446422879587b0a78e1b0f11
|
https://github.com/xanzy/go-cloudstack/blob/b6f53ed3282d22b6446422879587b0a78e1b0f11/cloudstack/FirewallService.go#L646-L683
|
145,302 |
xanzy/go-cloudstack
|
cloudstack/FirewallService.go
|
NewCreatePortForwardingRuleParams
|
func (s *FirewallService) NewCreatePortForwardingRuleParams(ipaddressid string, privateport int, protocol string, publicport int, virtualmachineid string) *CreatePortForwardingRuleParams {
p := &CreatePortForwardingRuleParams{}
p.p = make(map[string]interface{})
p.p["ipaddressid"] = ipaddressid
p.p["privateport"] = privateport
p.p["protocol"] = protocol
p.p["publicport"] = publicport
p.p["virtualmachineid"] = virtualmachineid
return p
}
|
go
|
func (s *FirewallService) NewCreatePortForwardingRuleParams(ipaddressid string, privateport int, protocol string, publicport int, virtualmachineid string) *CreatePortForwardingRuleParams {
p := &CreatePortForwardingRuleParams{}
p.p = make(map[string]interface{})
p.p["ipaddressid"] = ipaddressid
p.p["privateport"] = privateport
p.p["protocol"] = protocol
p.p["publicport"] = publicport
p.p["virtualmachineid"] = virtualmachineid
return p
}
|
[
"func",
"(",
"s",
"*",
"FirewallService",
")",
"NewCreatePortForwardingRuleParams",
"(",
"ipaddressid",
"string",
",",
"privateport",
"int",
",",
"protocol",
"string",
",",
"publicport",
"int",
",",
"virtualmachineid",
"string",
")",
"*",
"CreatePortForwardingRuleParams",
"{",
"p",
":=",
"&",
"CreatePortForwardingRuleParams",
"{",
"}",
"\n",
"p",
".",
"p",
"=",
"make",
"(",
"map",
"[",
"string",
"]",
"interface",
"{",
"}",
")",
"\n",
"p",
".",
"p",
"[",
"\"",
"\"",
"]",
"=",
"ipaddressid",
"\n",
"p",
".",
"p",
"[",
"\"",
"\"",
"]",
"=",
"privateport",
"\n",
"p",
".",
"p",
"[",
"\"",
"\"",
"]",
"=",
"protocol",
"\n",
"p",
".",
"p",
"[",
"\"",
"\"",
"]",
"=",
"publicport",
"\n",
"p",
".",
"p",
"[",
"\"",
"\"",
"]",
"=",
"virtualmachineid",
"\n",
"return",
"p",
"\n",
"}"
] |
// You should always use this function to get a new CreatePortForwardingRuleParams instance,
// as then you are sure you have configured all required params
|
[
"You",
"should",
"always",
"use",
"this",
"function",
"to",
"get",
"a",
"new",
"CreatePortForwardingRuleParams",
"instance",
"as",
"then",
"you",
"are",
"sure",
"you",
"have",
"configured",
"all",
"required",
"params"
] |
b6f53ed3282d22b6446422879587b0a78e1b0f11
|
https://github.com/xanzy/go-cloudstack/blob/b6f53ed3282d22b6446422879587b0a78e1b0f11/cloudstack/FirewallService.go#L856-L865
|
145,303 |
xanzy/go-cloudstack
|
cloudstack/FirewallService.go
|
NewDeleteEgressFirewallRuleParams
|
func (s *FirewallService) NewDeleteEgressFirewallRuleParams(id string) *DeleteEgressFirewallRuleParams {
p := &DeleteEgressFirewallRuleParams{}
p.p = make(map[string]interface{})
p.p["id"] = id
return p
}
|
go
|
func (s *FirewallService) NewDeleteEgressFirewallRuleParams(id string) *DeleteEgressFirewallRuleParams {
p := &DeleteEgressFirewallRuleParams{}
p.p = make(map[string]interface{})
p.p["id"] = id
return p
}
|
[
"func",
"(",
"s",
"*",
"FirewallService",
")",
"NewDeleteEgressFirewallRuleParams",
"(",
"id",
"string",
")",
"*",
"DeleteEgressFirewallRuleParams",
"{",
"p",
":=",
"&",
"DeleteEgressFirewallRuleParams",
"{",
"}",
"\n",
"p",
".",
"p",
"=",
"make",
"(",
"map",
"[",
"string",
"]",
"interface",
"{",
"}",
")",
"\n",
"p",
".",
"p",
"[",
"\"",
"\"",
"]",
"=",
"id",
"\n",
"return",
"p",
"\n",
"}"
] |
// You should always use this function to get a new DeleteEgressFirewallRuleParams instance,
// as then you are sure you have configured all required params
|
[
"You",
"should",
"always",
"use",
"this",
"function",
"to",
"get",
"a",
"new",
"DeleteEgressFirewallRuleParams",
"instance",
"as",
"then",
"you",
"are",
"sure",
"you",
"have",
"configured",
"all",
"required",
"params"
] |
b6f53ed3282d22b6446422879587b0a78e1b0f11
|
https://github.com/xanzy/go-cloudstack/blob/b6f53ed3282d22b6446422879587b0a78e1b0f11/cloudstack/FirewallService.go#L953-L958
|
145,304 |
xanzy/go-cloudstack
|
cloudstack/FirewallService.go
|
DeleteEgressFirewallRule
|
func (s *FirewallService) DeleteEgressFirewallRule(p *DeleteEgressFirewallRuleParams) (*DeleteEgressFirewallRuleResponse, error) {
resp, err := s.cs.newRequest("deleteEgressFirewallRule", p.toURLValues())
if err != nil {
return nil, err
}
var r DeleteEgressFirewallRuleResponse
if err := json.Unmarshal(resp, &r); err != nil {
return nil, err
}
// If we have a async client, we need to wait for the async result
if s.cs.async {
b, err := s.cs.GetAsyncJobResult(r.JobID, s.cs.timeout)
if err != nil {
if err == AsyncTimeoutErr {
return &r, err
}
return nil, err
}
b, err = convertFirewallServiceResponse(b)
if err != nil {
return nil, err
}
if err := json.Unmarshal(b, &r); err != nil {
return nil, err
}
}
return &r, nil
}
|
go
|
func (s *FirewallService) DeleteEgressFirewallRule(p *DeleteEgressFirewallRuleParams) (*DeleteEgressFirewallRuleResponse, error) {
resp, err := s.cs.newRequest("deleteEgressFirewallRule", p.toURLValues())
if err != nil {
return nil, err
}
var r DeleteEgressFirewallRuleResponse
if err := json.Unmarshal(resp, &r); err != nil {
return nil, err
}
// If we have a async client, we need to wait for the async result
if s.cs.async {
b, err := s.cs.GetAsyncJobResult(r.JobID, s.cs.timeout)
if err != nil {
if err == AsyncTimeoutErr {
return &r, err
}
return nil, err
}
b, err = convertFirewallServiceResponse(b)
if err != nil {
return nil, err
}
if err := json.Unmarshal(b, &r); err != nil {
return nil, err
}
}
return &r, nil
}
|
[
"func",
"(",
"s",
"*",
"FirewallService",
")",
"DeleteEgressFirewallRule",
"(",
"p",
"*",
"DeleteEgressFirewallRuleParams",
")",
"(",
"*",
"DeleteEgressFirewallRuleResponse",
",",
"error",
")",
"{",
"resp",
",",
"err",
":=",
"s",
".",
"cs",
".",
"newRequest",
"(",
"\"",
"\"",
",",
"p",
".",
"toURLValues",
"(",
")",
")",
"\n",
"if",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"var",
"r",
"DeleteEgressFirewallRuleResponse",
"\n",
"if",
"err",
":=",
"json",
".",
"Unmarshal",
"(",
"resp",
",",
"&",
"r",
")",
";",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"// If we have a async client, we need to wait for the async result",
"if",
"s",
".",
"cs",
".",
"async",
"{",
"b",
",",
"err",
":=",
"s",
".",
"cs",
".",
"GetAsyncJobResult",
"(",
"r",
".",
"JobID",
",",
"s",
".",
"cs",
".",
"timeout",
")",
"\n",
"if",
"err",
"!=",
"nil",
"{",
"if",
"err",
"==",
"AsyncTimeoutErr",
"{",
"return",
"&",
"r",
",",
"err",
"\n",
"}",
"\n",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"b",
",",
"err",
"=",
"convertFirewallServiceResponse",
"(",
"b",
")",
"\n",
"if",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"if",
"err",
":=",
"json",
".",
"Unmarshal",
"(",
"b",
",",
"&",
"r",
")",
";",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n",
"}",
"\n\n",
"return",
"&",
"r",
",",
"nil",
"\n",
"}"
] |
// Deletes an egress firewall rule
|
[
"Deletes",
"an",
"egress",
"firewall",
"rule"
] |
b6f53ed3282d22b6446422879587b0a78e1b0f11
|
https://github.com/xanzy/go-cloudstack/blob/b6f53ed3282d22b6446422879587b0a78e1b0f11/cloudstack/FirewallService.go#L961-L993
|
145,305 |
xanzy/go-cloudstack
|
cloudstack/FirewallService.go
|
NewDeleteFirewallRuleParams
|
func (s *FirewallService) NewDeleteFirewallRuleParams(id string) *DeleteFirewallRuleParams {
p := &DeleteFirewallRuleParams{}
p.p = make(map[string]interface{})
p.p["id"] = id
return p
}
|
go
|
func (s *FirewallService) NewDeleteFirewallRuleParams(id string) *DeleteFirewallRuleParams {
p := &DeleteFirewallRuleParams{}
p.p = make(map[string]interface{})
p.p["id"] = id
return p
}
|
[
"func",
"(",
"s",
"*",
"FirewallService",
")",
"NewDeleteFirewallRuleParams",
"(",
"id",
"string",
")",
"*",
"DeleteFirewallRuleParams",
"{",
"p",
":=",
"&",
"DeleteFirewallRuleParams",
"{",
"}",
"\n",
"p",
".",
"p",
"=",
"make",
"(",
"map",
"[",
"string",
"]",
"interface",
"{",
"}",
")",
"\n",
"p",
".",
"p",
"[",
"\"",
"\"",
"]",
"=",
"id",
"\n",
"return",
"p",
"\n",
"}"
] |
// You should always use this function to get a new DeleteFirewallRuleParams instance,
// as then you are sure you have configured all required params
|
[
"You",
"should",
"always",
"use",
"this",
"function",
"to",
"get",
"a",
"new",
"DeleteFirewallRuleParams",
"instance",
"as",
"then",
"you",
"are",
"sure",
"you",
"have",
"configured",
"all",
"required",
"params"
] |
b6f53ed3282d22b6446422879587b0a78e1b0f11
|
https://github.com/xanzy/go-cloudstack/blob/b6f53ed3282d22b6446422879587b0a78e1b0f11/cloudstack/FirewallService.go#L1026-L1031
|
145,306 |
xanzy/go-cloudstack
|
cloudstack/FirewallService.go
|
NewDeletePaloAltoFirewallParams
|
func (s *FirewallService) NewDeletePaloAltoFirewallParams(fwdeviceid string) *DeletePaloAltoFirewallParams {
p := &DeletePaloAltoFirewallParams{}
p.p = make(map[string]interface{})
p.p["fwdeviceid"] = fwdeviceid
return p
}
|
go
|
func (s *FirewallService) NewDeletePaloAltoFirewallParams(fwdeviceid string) *DeletePaloAltoFirewallParams {
p := &DeletePaloAltoFirewallParams{}
p.p = make(map[string]interface{})
p.p["fwdeviceid"] = fwdeviceid
return p
}
|
[
"func",
"(",
"s",
"*",
"FirewallService",
")",
"NewDeletePaloAltoFirewallParams",
"(",
"fwdeviceid",
"string",
")",
"*",
"DeletePaloAltoFirewallParams",
"{",
"p",
":=",
"&",
"DeletePaloAltoFirewallParams",
"{",
"}",
"\n",
"p",
".",
"p",
"=",
"make",
"(",
"map",
"[",
"string",
"]",
"interface",
"{",
"}",
")",
"\n",
"p",
".",
"p",
"[",
"\"",
"\"",
"]",
"=",
"fwdeviceid",
"\n",
"return",
"p",
"\n",
"}"
] |
// You should always use this function to get a new DeletePaloAltoFirewallParams instance,
// as then you are sure you have configured all required params
|
[
"You",
"should",
"always",
"use",
"this",
"function",
"to",
"get",
"a",
"new",
"DeletePaloAltoFirewallParams",
"instance",
"as",
"then",
"you",
"are",
"sure",
"you",
"have",
"configured",
"all",
"required",
"params"
] |
b6f53ed3282d22b6446422879587b0a78e1b0f11
|
https://github.com/xanzy/go-cloudstack/blob/b6f53ed3282d22b6446422879587b0a78e1b0f11/cloudstack/FirewallService.go#L1099-L1104
|
145,307 |
xanzy/go-cloudstack
|
cloudstack/FirewallService.go
|
DeletePaloAltoFirewall
|
func (s *FirewallService) DeletePaloAltoFirewall(p *DeletePaloAltoFirewallParams) (*DeletePaloAltoFirewallResponse, error) {
resp, err := s.cs.newRequest("deletePaloAltoFirewall", p.toURLValues())
if err != nil {
return nil, err
}
var r DeletePaloAltoFirewallResponse
if err := json.Unmarshal(resp, &r); err != nil {
return nil, err
}
// If we have a async client, we need to wait for the async result
if s.cs.async {
b, err := s.cs.GetAsyncJobResult(r.JobID, s.cs.timeout)
if err != nil {
if err == AsyncTimeoutErr {
return &r, err
}
return nil, err
}
b, err = convertFirewallServiceResponse(b)
if err != nil {
return nil, err
}
if err := json.Unmarshal(b, &r); err != nil {
return nil, err
}
}
return &r, nil
}
|
go
|
func (s *FirewallService) DeletePaloAltoFirewall(p *DeletePaloAltoFirewallParams) (*DeletePaloAltoFirewallResponse, error) {
resp, err := s.cs.newRequest("deletePaloAltoFirewall", p.toURLValues())
if err != nil {
return nil, err
}
var r DeletePaloAltoFirewallResponse
if err := json.Unmarshal(resp, &r); err != nil {
return nil, err
}
// If we have a async client, we need to wait for the async result
if s.cs.async {
b, err := s.cs.GetAsyncJobResult(r.JobID, s.cs.timeout)
if err != nil {
if err == AsyncTimeoutErr {
return &r, err
}
return nil, err
}
b, err = convertFirewallServiceResponse(b)
if err != nil {
return nil, err
}
if err := json.Unmarshal(b, &r); err != nil {
return nil, err
}
}
return &r, nil
}
|
[
"func",
"(",
"s",
"*",
"FirewallService",
")",
"DeletePaloAltoFirewall",
"(",
"p",
"*",
"DeletePaloAltoFirewallParams",
")",
"(",
"*",
"DeletePaloAltoFirewallResponse",
",",
"error",
")",
"{",
"resp",
",",
"err",
":=",
"s",
".",
"cs",
".",
"newRequest",
"(",
"\"",
"\"",
",",
"p",
".",
"toURLValues",
"(",
")",
")",
"\n",
"if",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"var",
"r",
"DeletePaloAltoFirewallResponse",
"\n",
"if",
"err",
":=",
"json",
".",
"Unmarshal",
"(",
"resp",
",",
"&",
"r",
")",
";",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"// If we have a async client, we need to wait for the async result",
"if",
"s",
".",
"cs",
".",
"async",
"{",
"b",
",",
"err",
":=",
"s",
".",
"cs",
".",
"GetAsyncJobResult",
"(",
"r",
".",
"JobID",
",",
"s",
".",
"cs",
".",
"timeout",
")",
"\n",
"if",
"err",
"!=",
"nil",
"{",
"if",
"err",
"==",
"AsyncTimeoutErr",
"{",
"return",
"&",
"r",
",",
"err",
"\n",
"}",
"\n",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"b",
",",
"err",
"=",
"convertFirewallServiceResponse",
"(",
"b",
")",
"\n",
"if",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"if",
"err",
":=",
"json",
".",
"Unmarshal",
"(",
"b",
",",
"&",
"r",
")",
";",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n",
"}",
"\n\n",
"return",
"&",
"r",
",",
"nil",
"\n",
"}"
] |
// delete a Palo Alto firewall device
|
[
"delete",
"a",
"Palo",
"Alto",
"firewall",
"device"
] |
b6f53ed3282d22b6446422879587b0a78e1b0f11
|
https://github.com/xanzy/go-cloudstack/blob/b6f53ed3282d22b6446422879587b0a78e1b0f11/cloudstack/FirewallService.go#L1107-L1139
|
145,308 |
xanzy/go-cloudstack
|
cloudstack/FirewallService.go
|
NewDeletePortForwardingRuleParams
|
func (s *FirewallService) NewDeletePortForwardingRuleParams(id string) *DeletePortForwardingRuleParams {
p := &DeletePortForwardingRuleParams{}
p.p = make(map[string]interface{})
p.p["id"] = id
return p
}
|
go
|
func (s *FirewallService) NewDeletePortForwardingRuleParams(id string) *DeletePortForwardingRuleParams {
p := &DeletePortForwardingRuleParams{}
p.p = make(map[string]interface{})
p.p["id"] = id
return p
}
|
[
"func",
"(",
"s",
"*",
"FirewallService",
")",
"NewDeletePortForwardingRuleParams",
"(",
"id",
"string",
")",
"*",
"DeletePortForwardingRuleParams",
"{",
"p",
":=",
"&",
"DeletePortForwardingRuleParams",
"{",
"}",
"\n",
"p",
".",
"p",
"=",
"make",
"(",
"map",
"[",
"string",
"]",
"interface",
"{",
"}",
")",
"\n",
"p",
".",
"p",
"[",
"\"",
"\"",
"]",
"=",
"id",
"\n",
"return",
"p",
"\n",
"}"
] |
// You should always use this function to get a new DeletePortForwardingRuleParams instance,
// as then you are sure you have configured all required params
|
[
"You",
"should",
"always",
"use",
"this",
"function",
"to",
"get",
"a",
"new",
"DeletePortForwardingRuleParams",
"instance",
"as",
"then",
"you",
"are",
"sure",
"you",
"have",
"configured",
"all",
"required",
"params"
] |
b6f53ed3282d22b6446422879587b0a78e1b0f11
|
https://github.com/xanzy/go-cloudstack/blob/b6f53ed3282d22b6446422879587b0a78e1b0f11/cloudstack/FirewallService.go#L1172-L1177
|
145,309 |
xanzy/go-cloudstack
|
cloudstack/FirewallService.go
|
NewListEgressFirewallRulesParams
|
func (s *FirewallService) NewListEgressFirewallRulesParams() *ListEgressFirewallRulesParams {
p := &ListEgressFirewallRulesParams{}
p.p = make(map[string]interface{})
return p
}
|
go
|
func (s *FirewallService) NewListEgressFirewallRulesParams() *ListEgressFirewallRulesParams {
p := &ListEgressFirewallRulesParams{}
p.p = make(map[string]interface{})
return p
}
|
[
"func",
"(",
"s",
"*",
"FirewallService",
")",
"NewListEgressFirewallRulesParams",
"(",
")",
"*",
"ListEgressFirewallRulesParams",
"{",
"p",
":=",
"&",
"ListEgressFirewallRulesParams",
"{",
"}",
"\n",
"p",
".",
"p",
"=",
"make",
"(",
"map",
"[",
"string",
"]",
"interface",
"{",
"}",
")",
"\n",
"return",
"p",
"\n",
"}"
] |
// You should always use this function to get a new ListEgressFirewallRulesParams instance,
// as then you are sure you have configured all required params
|
[
"You",
"should",
"always",
"use",
"this",
"function",
"to",
"get",
"a",
"new",
"ListEgressFirewallRulesParams",
"instance",
"as",
"then",
"you",
"are",
"sure",
"you",
"have",
"configured",
"all",
"required",
"params"
] |
b6f53ed3282d22b6446422879587b0a78e1b0f11
|
https://github.com/xanzy/go-cloudstack/blob/b6f53ed3282d22b6446422879587b0a78e1b0f11/cloudstack/FirewallService.go#L1387-L1391
|
145,310 |
xanzy/go-cloudstack
|
cloudstack/FirewallService.go
|
ListEgressFirewallRules
|
func (s *FirewallService) ListEgressFirewallRules(p *ListEgressFirewallRulesParams) (*ListEgressFirewallRulesResponse, error) {
resp, err := s.cs.newRequest("listEgressFirewallRules", p.toURLValues())
if err != nil {
return nil, err
}
resp, err = convertFirewallServiceResponse(resp)
if err != nil {
return nil, err
}
var r ListEgressFirewallRulesResponse
if err := json.Unmarshal(resp, &r); err != nil {
return nil, err
}
return &r, nil
}
|
go
|
func (s *FirewallService) ListEgressFirewallRules(p *ListEgressFirewallRulesParams) (*ListEgressFirewallRulesResponse, error) {
resp, err := s.cs.newRequest("listEgressFirewallRules", p.toURLValues())
if err != nil {
return nil, err
}
resp, err = convertFirewallServiceResponse(resp)
if err != nil {
return nil, err
}
var r ListEgressFirewallRulesResponse
if err := json.Unmarshal(resp, &r); err != nil {
return nil, err
}
return &r, nil
}
|
[
"func",
"(",
"s",
"*",
"FirewallService",
")",
"ListEgressFirewallRules",
"(",
"p",
"*",
"ListEgressFirewallRulesParams",
")",
"(",
"*",
"ListEgressFirewallRulesResponse",
",",
"error",
")",
"{",
"resp",
",",
"err",
":=",
"s",
".",
"cs",
".",
"newRequest",
"(",
"\"",
"\"",
",",
"p",
".",
"toURLValues",
"(",
")",
")",
"\n",
"if",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"resp",
",",
"err",
"=",
"convertFirewallServiceResponse",
"(",
"resp",
")",
"\n",
"if",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"var",
"r",
"ListEgressFirewallRulesResponse",
"\n",
"if",
"err",
":=",
"json",
".",
"Unmarshal",
"(",
"resp",
",",
"&",
"r",
")",
";",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"return",
"&",
"r",
",",
"nil",
"\n",
"}"
] |
// Lists all egress firewall rules for network ID.
|
[
"Lists",
"all",
"egress",
"firewall",
"rules",
"for",
"network",
"ID",
"."
] |
b6f53ed3282d22b6446422879587b0a78e1b0f11
|
https://github.com/xanzy/go-cloudstack/blob/b6f53ed3282d22b6446422879587b0a78e1b0f11/cloudstack/FirewallService.go#L1427-L1444
|
145,311 |
xanzy/go-cloudstack
|
cloudstack/FirewallService.go
|
NewListFirewallRulesParams
|
func (s *FirewallService) NewListFirewallRulesParams() *ListFirewallRulesParams {
p := &ListFirewallRulesParams{}
p.p = make(map[string]interface{})
return p
}
|
go
|
func (s *FirewallService) NewListFirewallRulesParams() *ListFirewallRulesParams {
p := &ListFirewallRulesParams{}
p.p = make(map[string]interface{})
return p
}
|
[
"func",
"(",
"s",
"*",
"FirewallService",
")",
"NewListFirewallRulesParams",
"(",
")",
"*",
"ListFirewallRulesParams",
"{",
"p",
":=",
"&",
"ListFirewallRulesParams",
"{",
"}",
"\n",
"p",
".",
"p",
"=",
"make",
"(",
"map",
"[",
"string",
"]",
"interface",
"{",
"}",
")",
"\n",
"return",
"p",
"\n",
"}"
] |
// You should always use this function to get a new ListFirewallRulesParams instance,
// as then you are sure you have configured all required params
|
[
"You",
"should",
"always",
"use",
"this",
"function",
"to",
"get",
"a",
"new",
"ListFirewallRulesParams",
"instance",
"as",
"then",
"you",
"are",
"sure",
"you",
"have",
"configured",
"all",
"required",
"params"
] |
b6f53ed3282d22b6446422879587b0a78e1b0f11
|
https://github.com/xanzy/go-cloudstack/blob/b6f53ed3282d22b6446422879587b0a78e1b0f11/cloudstack/FirewallService.go#L1635-L1639
|
145,312 |
xanzy/go-cloudstack
|
cloudstack/FirewallService.go
|
NewListPaloAltoFirewallsParams
|
func (s *FirewallService) NewListPaloAltoFirewallsParams() *ListPaloAltoFirewallsParams {
p := &ListPaloAltoFirewallsParams{}
p.p = make(map[string]interface{})
return p
}
|
go
|
func (s *FirewallService) NewListPaloAltoFirewallsParams() *ListPaloAltoFirewallsParams {
p := &ListPaloAltoFirewallsParams{}
p.p = make(map[string]interface{})
return p
}
|
[
"func",
"(",
"s",
"*",
"FirewallService",
")",
"NewListPaloAltoFirewallsParams",
"(",
")",
"*",
"ListPaloAltoFirewallsParams",
"{",
"p",
":=",
"&",
"ListPaloAltoFirewallsParams",
"{",
"}",
"\n",
"p",
".",
"p",
"=",
"make",
"(",
"map",
"[",
"string",
"]",
"interface",
"{",
"}",
")",
"\n",
"return",
"p",
"\n",
"}"
] |
// You should always use this function to get a new ListPaloAltoFirewallsParams instance,
// as then you are sure you have configured all required params
|
[
"You",
"should",
"always",
"use",
"this",
"function",
"to",
"get",
"a",
"new",
"ListPaloAltoFirewallsParams",
"instance",
"as",
"then",
"you",
"are",
"sure",
"you",
"have",
"configured",
"all",
"required",
"params"
] |
b6f53ed3282d22b6446422879587b0a78e1b0f11
|
https://github.com/xanzy/go-cloudstack/blob/b6f53ed3282d22b6446422879587b0a78e1b0f11/cloudstack/FirewallService.go#L1787-L1791
|
145,313 |
xanzy/go-cloudstack
|
cloudstack/FirewallService.go
|
ListPaloAltoFirewalls
|
func (s *FirewallService) ListPaloAltoFirewalls(p *ListPaloAltoFirewallsParams) (*ListPaloAltoFirewallsResponse, error) {
resp, err := s.cs.newRequest("listPaloAltoFirewalls", p.toURLValues())
if err != nil {
return nil, err
}
resp, err = convertFirewallServiceResponse(resp)
if err != nil {
return nil, err
}
var r ListPaloAltoFirewallsResponse
if err := json.Unmarshal(resp, &r); err != nil {
return nil, err
}
return &r, nil
}
|
go
|
func (s *FirewallService) ListPaloAltoFirewalls(p *ListPaloAltoFirewallsParams) (*ListPaloAltoFirewallsResponse, error) {
resp, err := s.cs.newRequest("listPaloAltoFirewalls", p.toURLValues())
if err != nil {
return nil, err
}
resp, err = convertFirewallServiceResponse(resp)
if err != nil {
return nil, err
}
var r ListPaloAltoFirewallsResponse
if err := json.Unmarshal(resp, &r); err != nil {
return nil, err
}
return &r, nil
}
|
[
"func",
"(",
"s",
"*",
"FirewallService",
")",
"ListPaloAltoFirewalls",
"(",
"p",
"*",
"ListPaloAltoFirewallsParams",
")",
"(",
"*",
"ListPaloAltoFirewallsResponse",
",",
"error",
")",
"{",
"resp",
",",
"err",
":=",
"s",
".",
"cs",
".",
"newRequest",
"(",
"\"",
"\"",
",",
"p",
".",
"toURLValues",
"(",
")",
")",
"\n",
"if",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"resp",
",",
"err",
"=",
"convertFirewallServiceResponse",
"(",
"resp",
")",
"\n",
"if",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"var",
"r",
"ListPaloAltoFirewallsResponse",
"\n",
"if",
"err",
":=",
"json",
".",
"Unmarshal",
"(",
"resp",
",",
"&",
"r",
")",
";",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"return",
"&",
"r",
",",
"nil",
"\n",
"}"
] |
// lists Palo Alto firewall devices in a physical network
|
[
"lists",
"Palo",
"Alto",
"firewall",
"devices",
"in",
"a",
"physical",
"network"
] |
b6f53ed3282d22b6446422879587b0a78e1b0f11
|
https://github.com/xanzy/go-cloudstack/blob/b6f53ed3282d22b6446422879587b0a78e1b0f11/cloudstack/FirewallService.go#L1794-L1811
|
145,314 |
xanzy/go-cloudstack
|
cloudstack/FirewallService.go
|
NewListPortForwardingRulesParams
|
func (s *FirewallService) NewListPortForwardingRulesParams() *ListPortForwardingRulesParams {
p := &ListPortForwardingRulesParams{}
p.p = make(map[string]interface{})
return p
}
|
go
|
func (s *FirewallService) NewListPortForwardingRulesParams() *ListPortForwardingRulesParams {
p := &ListPortForwardingRulesParams{}
p.p = make(map[string]interface{})
return p
}
|
[
"func",
"(",
"s",
"*",
"FirewallService",
")",
"NewListPortForwardingRulesParams",
"(",
")",
"*",
"ListPortForwardingRulesParams",
"{",
"p",
":=",
"&",
"ListPortForwardingRulesParams",
"{",
"}",
"\n",
"p",
".",
"p",
"=",
"make",
"(",
"map",
"[",
"string",
"]",
"interface",
"{",
"}",
")",
"\n",
"return",
"p",
"\n",
"}"
] |
// You should always use this function to get a new ListPortForwardingRulesParams instance,
// as then you are sure you have configured all required params
|
[
"You",
"should",
"always",
"use",
"this",
"function",
"to",
"get",
"a",
"new",
"ListPortForwardingRulesParams",
"instance",
"as",
"then",
"you",
"are",
"sure",
"you",
"have",
"configured",
"all",
"required",
"params"
] |
b6f53ed3282d22b6446422879587b0a78e1b0f11
|
https://github.com/xanzy/go-cloudstack/blob/b6f53ed3282d22b6446422879587b0a78e1b0f11/cloudstack/FirewallService.go#L2004-L2008
|
145,315 |
xanzy/go-cloudstack
|
cloudstack/FirewallService.go
|
NewUpdateEgressFirewallRuleParams
|
func (s *FirewallService) NewUpdateEgressFirewallRuleParams(id string) *UpdateEgressFirewallRuleParams {
p := &UpdateEgressFirewallRuleParams{}
p.p = make(map[string]interface{})
p.p["id"] = id
return p
}
|
go
|
func (s *FirewallService) NewUpdateEgressFirewallRuleParams(id string) *UpdateEgressFirewallRuleParams {
p := &UpdateEgressFirewallRuleParams{}
p.p = make(map[string]interface{})
p.p["id"] = id
return p
}
|
[
"func",
"(",
"s",
"*",
"FirewallService",
")",
"NewUpdateEgressFirewallRuleParams",
"(",
"id",
"string",
")",
"*",
"UpdateEgressFirewallRuleParams",
"{",
"p",
":=",
"&",
"UpdateEgressFirewallRuleParams",
"{",
"}",
"\n",
"p",
".",
"p",
"=",
"make",
"(",
"map",
"[",
"string",
"]",
"interface",
"{",
"}",
")",
"\n",
"p",
".",
"p",
"[",
"\"",
"\"",
"]",
"=",
"id",
"\n",
"return",
"p",
"\n",
"}"
] |
// You should always use this function to get a new UpdateEgressFirewallRuleParams instance,
// as then you are sure you have configured all required params
|
[
"You",
"should",
"always",
"use",
"this",
"function",
"to",
"get",
"a",
"new",
"UpdateEgressFirewallRuleParams",
"instance",
"as",
"then",
"you",
"are",
"sure",
"you",
"have",
"configured",
"all",
"required",
"params"
] |
b6f53ed3282d22b6446422879587b0a78e1b0f11
|
https://github.com/xanzy/go-cloudstack/blob/b6f53ed3282d22b6446422879587b0a78e1b0f11/cloudstack/FirewallService.go#L2136-L2141
|
145,316 |
xanzy/go-cloudstack
|
cloudstack/FirewallService.go
|
NewUpdateFirewallRuleParams
|
func (s *FirewallService) NewUpdateFirewallRuleParams(id string) *UpdateFirewallRuleParams {
p := &UpdateFirewallRuleParams{}
p.p = make(map[string]interface{})
p.p["id"] = id
return p
}
|
go
|
func (s *FirewallService) NewUpdateFirewallRuleParams(id string) *UpdateFirewallRuleParams {
p := &UpdateFirewallRuleParams{}
p.p = make(map[string]interface{})
p.p["id"] = id
return p
}
|
[
"func",
"(",
"s",
"*",
"FirewallService",
")",
"NewUpdateFirewallRuleParams",
"(",
"id",
"string",
")",
"*",
"UpdateFirewallRuleParams",
"{",
"p",
":=",
"&",
"UpdateFirewallRuleParams",
"{",
"}",
"\n",
"p",
".",
"p",
"=",
"make",
"(",
"map",
"[",
"string",
"]",
"interface",
"{",
"}",
")",
"\n",
"p",
".",
"p",
"[",
"\"",
"\"",
"]",
"=",
"id",
"\n",
"return",
"p",
"\n",
"}"
] |
// You should always use this function to get a new UpdateFirewallRuleParams instance,
// as then you are sure you have configured all required params
|
[
"You",
"should",
"always",
"use",
"this",
"function",
"to",
"get",
"a",
"new",
"UpdateFirewallRuleParams",
"instance",
"as",
"then",
"you",
"are",
"sure",
"you",
"have",
"configured",
"all",
"required",
"params"
] |
b6f53ed3282d22b6446422879587b0a78e1b0f11
|
https://github.com/xanzy/go-cloudstack/blob/b6f53ed3282d22b6446422879587b0a78e1b0f11/cloudstack/FirewallService.go#L2249-L2254
|
145,317 |
xanzy/go-cloudstack
|
cloudstack/FirewallService.go
|
NewUpdatePortForwardingRuleParams
|
func (s *FirewallService) NewUpdatePortForwardingRuleParams(id string) *UpdatePortForwardingRuleParams {
p := &UpdatePortForwardingRuleParams{}
p.p = make(map[string]interface{})
p.p["id"] = id
return p
}
|
go
|
func (s *FirewallService) NewUpdatePortForwardingRuleParams(id string) *UpdatePortForwardingRuleParams {
p := &UpdatePortForwardingRuleParams{}
p.p = make(map[string]interface{})
p.p["id"] = id
return p
}
|
[
"func",
"(",
"s",
"*",
"FirewallService",
")",
"NewUpdatePortForwardingRuleParams",
"(",
"id",
"string",
")",
"*",
"UpdatePortForwardingRuleParams",
"{",
"p",
":=",
"&",
"UpdatePortForwardingRuleParams",
"{",
"}",
"\n",
"p",
".",
"p",
"=",
"make",
"(",
"map",
"[",
"string",
"]",
"interface",
"{",
"}",
")",
"\n",
"p",
".",
"p",
"[",
"\"",
"\"",
"]",
"=",
"id",
"\n",
"return",
"p",
"\n",
"}"
] |
// You should always use this function to get a new UpdatePortForwardingRuleParams instance,
// as then you are sure you have configured all required params
|
[
"You",
"should",
"always",
"use",
"this",
"function",
"to",
"get",
"a",
"new",
"UpdatePortForwardingRuleParams",
"instance",
"as",
"then",
"you",
"are",
"sure",
"you",
"have",
"configured",
"all",
"required",
"params"
] |
b6f53ed3282d22b6446422879587b0a78e1b0f11
|
https://github.com/xanzy/go-cloudstack/blob/b6f53ed3282d22b6446422879587b0a78e1b0f11/cloudstack/FirewallService.go#L2408-L2413
|
145,318 |
xanzy/go-cloudstack
|
cloudstack/VPNService.go
|
NewAddVpnUserParams
|
func (s *VPNService) NewAddVpnUserParams(password string, username string) *AddVpnUserParams {
p := &AddVpnUserParams{}
p.p = make(map[string]interface{})
p.p["password"] = password
p.p["username"] = username
return p
}
|
go
|
func (s *VPNService) NewAddVpnUserParams(password string, username string) *AddVpnUserParams {
p := &AddVpnUserParams{}
p.p = make(map[string]interface{})
p.p["password"] = password
p.p["username"] = username
return p
}
|
[
"func",
"(",
"s",
"*",
"VPNService",
")",
"NewAddVpnUserParams",
"(",
"password",
"string",
",",
"username",
"string",
")",
"*",
"AddVpnUserParams",
"{",
"p",
":=",
"&",
"AddVpnUserParams",
"{",
"}",
"\n",
"p",
".",
"p",
"=",
"make",
"(",
"map",
"[",
"string",
"]",
"interface",
"{",
"}",
")",
"\n",
"p",
".",
"p",
"[",
"\"",
"\"",
"]",
"=",
"password",
"\n",
"p",
".",
"p",
"[",
"\"",
"\"",
"]",
"=",
"username",
"\n",
"return",
"p",
"\n",
"}"
] |
// You should always use this function to get a new AddVpnUserParams instance,
// as then you are sure you have configured all required params
|
[
"You",
"should",
"always",
"use",
"this",
"function",
"to",
"get",
"a",
"new",
"AddVpnUserParams",
"instance",
"as",
"then",
"you",
"are",
"sure",
"you",
"have",
"configured",
"all",
"required",
"params"
] |
b6f53ed3282d22b6446422879587b0a78e1b0f11
|
https://github.com/xanzy/go-cloudstack/blob/b6f53ed3282d22b6446422879587b0a78e1b0f11/cloudstack/VPNService.go#L96-L102
|
145,319 |
xanzy/go-cloudstack
|
cloudstack/VPNService.go
|
AddVpnUser
|
func (s *VPNService) AddVpnUser(p *AddVpnUserParams) (*AddVpnUserResponse, error) {
resp, err := s.cs.newRequest("addVpnUser", p.toURLValues())
if err != nil {
return nil, err
}
var r AddVpnUserResponse
if err := json.Unmarshal(resp, &r); err != nil {
return nil, err
}
// If we have a async client, we need to wait for the async result
if s.cs.async {
b, err := s.cs.GetAsyncJobResult(r.JobID, s.cs.timeout)
if err != nil {
if err == AsyncTimeoutErr {
return &r, err
}
return nil, err
}
b, err = getRawValue(b)
if err != nil {
return nil, err
}
if err := json.Unmarshal(b, &r); err != nil {
return nil, err
}
}
return &r, nil
}
|
go
|
func (s *VPNService) AddVpnUser(p *AddVpnUserParams) (*AddVpnUserResponse, error) {
resp, err := s.cs.newRequest("addVpnUser", p.toURLValues())
if err != nil {
return nil, err
}
var r AddVpnUserResponse
if err := json.Unmarshal(resp, &r); err != nil {
return nil, err
}
// If we have a async client, we need to wait for the async result
if s.cs.async {
b, err := s.cs.GetAsyncJobResult(r.JobID, s.cs.timeout)
if err != nil {
if err == AsyncTimeoutErr {
return &r, err
}
return nil, err
}
b, err = getRawValue(b)
if err != nil {
return nil, err
}
if err := json.Unmarshal(b, &r); err != nil {
return nil, err
}
}
return &r, nil
}
|
[
"func",
"(",
"s",
"*",
"VPNService",
")",
"AddVpnUser",
"(",
"p",
"*",
"AddVpnUserParams",
")",
"(",
"*",
"AddVpnUserResponse",
",",
"error",
")",
"{",
"resp",
",",
"err",
":=",
"s",
".",
"cs",
".",
"newRequest",
"(",
"\"",
"\"",
",",
"p",
".",
"toURLValues",
"(",
")",
")",
"\n",
"if",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"var",
"r",
"AddVpnUserResponse",
"\n",
"if",
"err",
":=",
"json",
".",
"Unmarshal",
"(",
"resp",
",",
"&",
"r",
")",
";",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"// If we have a async client, we need to wait for the async result",
"if",
"s",
".",
"cs",
".",
"async",
"{",
"b",
",",
"err",
":=",
"s",
".",
"cs",
".",
"GetAsyncJobResult",
"(",
"r",
".",
"JobID",
",",
"s",
".",
"cs",
".",
"timeout",
")",
"\n",
"if",
"err",
"!=",
"nil",
"{",
"if",
"err",
"==",
"AsyncTimeoutErr",
"{",
"return",
"&",
"r",
",",
"err",
"\n",
"}",
"\n",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"b",
",",
"err",
"=",
"getRawValue",
"(",
"b",
")",
"\n",
"if",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"if",
"err",
":=",
"json",
".",
"Unmarshal",
"(",
"b",
",",
"&",
"r",
")",
";",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n",
"}",
"\n\n",
"return",
"&",
"r",
",",
"nil",
"\n",
"}"
] |
// Adds vpn users
|
[
"Adds",
"vpn",
"users"
] |
b6f53ed3282d22b6446422879587b0a78e1b0f11
|
https://github.com/xanzy/go-cloudstack/blob/b6f53ed3282d22b6446422879587b0a78e1b0f11/cloudstack/VPNService.go#L105-L137
|
145,320 |
xanzy/go-cloudstack
|
cloudstack/VPNService.go
|
NewCreateRemoteAccessVpnParams
|
func (s *VPNService) NewCreateRemoteAccessVpnParams(publicipid string) *CreateRemoteAccessVpnParams {
p := &CreateRemoteAccessVpnParams{}
p.p = make(map[string]interface{})
p.p["publicipid"] = publicipid
return p
}
|
go
|
func (s *VPNService) NewCreateRemoteAccessVpnParams(publicipid string) *CreateRemoteAccessVpnParams {
p := &CreateRemoteAccessVpnParams{}
p.p = make(map[string]interface{})
p.p["publicipid"] = publicipid
return p
}
|
[
"func",
"(",
"s",
"*",
"VPNService",
")",
"NewCreateRemoteAccessVpnParams",
"(",
"publicipid",
"string",
")",
"*",
"CreateRemoteAccessVpnParams",
"{",
"p",
":=",
"&",
"CreateRemoteAccessVpnParams",
"{",
"}",
"\n",
"p",
".",
"p",
"=",
"make",
"(",
"map",
"[",
"string",
"]",
"interface",
"{",
"}",
")",
"\n",
"p",
".",
"p",
"[",
"\"",
"\"",
"]",
"=",
"publicipid",
"\n",
"return",
"p",
"\n",
"}"
] |
// You should always use this function to get a new CreateRemoteAccessVpnParams instance,
// as then you are sure you have configured all required params
|
[
"You",
"should",
"always",
"use",
"this",
"function",
"to",
"get",
"a",
"new",
"CreateRemoteAccessVpnParams",
"instance",
"as",
"then",
"you",
"are",
"sure",
"you",
"have",
"configured",
"all",
"required",
"params"
] |
b6f53ed3282d22b6446422879587b0a78e1b0f11
|
https://github.com/xanzy/go-cloudstack/blob/b6f53ed3282d22b6446422879587b0a78e1b0f11/cloudstack/VPNService.go#L233-L238
|
145,321 |
xanzy/go-cloudstack
|
cloudstack/VPNService.go
|
NewCreateVpnConnectionParams
|
func (s *VPNService) NewCreateVpnConnectionParams(s2scustomergatewayid string, s2svpngatewayid string) *CreateVpnConnectionParams {
p := &CreateVpnConnectionParams{}
p.p = make(map[string]interface{})
p.p["s2scustomergatewayid"] = s2scustomergatewayid
p.p["s2svpngatewayid"] = s2svpngatewayid
return p
}
|
go
|
func (s *VPNService) NewCreateVpnConnectionParams(s2scustomergatewayid string, s2svpngatewayid string) *CreateVpnConnectionParams {
p := &CreateVpnConnectionParams{}
p.p = make(map[string]interface{})
p.p["s2scustomergatewayid"] = s2scustomergatewayid
p.p["s2svpngatewayid"] = s2svpngatewayid
return p
}
|
[
"func",
"(",
"s",
"*",
"VPNService",
")",
"NewCreateVpnConnectionParams",
"(",
"s2scustomergatewayid",
"string",
",",
"s2svpngatewayid",
"string",
")",
"*",
"CreateVpnConnectionParams",
"{",
"p",
":=",
"&",
"CreateVpnConnectionParams",
"{",
"}",
"\n",
"p",
".",
"p",
"=",
"make",
"(",
"map",
"[",
"string",
"]",
"interface",
"{",
"}",
")",
"\n",
"p",
".",
"p",
"[",
"\"",
"\"",
"]",
"=",
"s2scustomergatewayid",
"\n",
"p",
".",
"p",
"[",
"\"",
"\"",
"]",
"=",
"s2svpngatewayid",
"\n",
"return",
"p",
"\n",
"}"
] |
// You should always use this function to get a new CreateVpnConnectionParams instance,
// as then you are sure you have configured all required params
|
[
"You",
"should",
"always",
"use",
"this",
"function",
"to",
"get",
"a",
"new",
"CreateVpnConnectionParams",
"instance",
"as",
"then",
"you",
"are",
"sure",
"you",
"have",
"configured",
"all",
"required",
"params"
] |
b6f53ed3282d22b6446422879587b0a78e1b0f11
|
https://github.com/xanzy/go-cloudstack/blob/b6f53ed3282d22b6446422879587b0a78e1b0f11/cloudstack/VPNService.go#L351-L357
|
145,322 |
xanzy/go-cloudstack
|
cloudstack/VPNService.go
|
CreateVpnConnection
|
func (s *VPNService) CreateVpnConnection(p *CreateVpnConnectionParams) (*CreateVpnConnectionResponse, error) {
resp, err := s.cs.newRequest("createVpnConnection", p.toURLValues())
if err != nil {
return nil, err
}
var r CreateVpnConnectionResponse
if err := json.Unmarshal(resp, &r); err != nil {
return nil, err
}
// If we have a async client, we need to wait for the async result
if s.cs.async {
b, err := s.cs.GetAsyncJobResult(r.JobID, s.cs.timeout)
if err != nil {
if err == AsyncTimeoutErr {
return &r, err
}
return nil, err
}
b, err = getRawValue(b)
if err != nil {
return nil, err
}
if err := json.Unmarshal(b, &r); err != nil {
return nil, err
}
}
return &r, nil
}
|
go
|
func (s *VPNService) CreateVpnConnection(p *CreateVpnConnectionParams) (*CreateVpnConnectionResponse, error) {
resp, err := s.cs.newRequest("createVpnConnection", p.toURLValues())
if err != nil {
return nil, err
}
var r CreateVpnConnectionResponse
if err := json.Unmarshal(resp, &r); err != nil {
return nil, err
}
// If we have a async client, we need to wait for the async result
if s.cs.async {
b, err := s.cs.GetAsyncJobResult(r.JobID, s.cs.timeout)
if err != nil {
if err == AsyncTimeoutErr {
return &r, err
}
return nil, err
}
b, err = getRawValue(b)
if err != nil {
return nil, err
}
if err := json.Unmarshal(b, &r); err != nil {
return nil, err
}
}
return &r, nil
}
|
[
"func",
"(",
"s",
"*",
"VPNService",
")",
"CreateVpnConnection",
"(",
"p",
"*",
"CreateVpnConnectionParams",
")",
"(",
"*",
"CreateVpnConnectionResponse",
",",
"error",
")",
"{",
"resp",
",",
"err",
":=",
"s",
".",
"cs",
".",
"newRequest",
"(",
"\"",
"\"",
",",
"p",
".",
"toURLValues",
"(",
")",
")",
"\n",
"if",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"var",
"r",
"CreateVpnConnectionResponse",
"\n",
"if",
"err",
":=",
"json",
".",
"Unmarshal",
"(",
"resp",
",",
"&",
"r",
")",
";",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"// If we have a async client, we need to wait for the async result",
"if",
"s",
".",
"cs",
".",
"async",
"{",
"b",
",",
"err",
":=",
"s",
".",
"cs",
".",
"GetAsyncJobResult",
"(",
"r",
".",
"JobID",
",",
"s",
".",
"cs",
".",
"timeout",
")",
"\n",
"if",
"err",
"!=",
"nil",
"{",
"if",
"err",
"==",
"AsyncTimeoutErr",
"{",
"return",
"&",
"r",
",",
"err",
"\n",
"}",
"\n",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"b",
",",
"err",
"=",
"getRawValue",
"(",
"b",
")",
"\n",
"if",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"if",
"err",
":=",
"json",
".",
"Unmarshal",
"(",
"b",
",",
"&",
"r",
")",
";",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n",
"}",
"\n\n",
"return",
"&",
"r",
",",
"nil",
"\n",
"}"
] |
// Create site to site vpn connection
|
[
"Create",
"site",
"to",
"site",
"vpn",
"connection"
] |
b6f53ed3282d22b6446422879587b0a78e1b0f11
|
https://github.com/xanzy/go-cloudstack/blob/b6f53ed3282d22b6446422879587b0a78e1b0f11/cloudstack/VPNService.go#L360-L392
|
145,323 |
xanzy/go-cloudstack
|
cloudstack/VPNService.go
|
NewCreateVpnCustomerGatewayParams
|
func (s *VPNService) NewCreateVpnCustomerGatewayParams(cidrlist string, esppolicy string, gateway string, ikepolicy string, ipsecpsk string) *CreateVpnCustomerGatewayParams {
p := &CreateVpnCustomerGatewayParams{}
p.p = make(map[string]interface{})
p.p["cidrlist"] = cidrlist
p.p["esppolicy"] = esppolicy
p.p["gateway"] = gateway
p.p["ikepolicy"] = ikepolicy
p.p["ipsecpsk"] = ipsecpsk
return p
}
|
go
|
func (s *VPNService) NewCreateVpnCustomerGatewayParams(cidrlist string, esppolicy string, gateway string, ikepolicy string, ipsecpsk string) *CreateVpnCustomerGatewayParams {
p := &CreateVpnCustomerGatewayParams{}
p.p = make(map[string]interface{})
p.p["cidrlist"] = cidrlist
p.p["esppolicy"] = esppolicy
p.p["gateway"] = gateway
p.p["ikepolicy"] = ikepolicy
p.p["ipsecpsk"] = ipsecpsk
return p
}
|
[
"func",
"(",
"s",
"*",
"VPNService",
")",
"NewCreateVpnCustomerGatewayParams",
"(",
"cidrlist",
"string",
",",
"esppolicy",
"string",
",",
"gateway",
"string",
",",
"ikepolicy",
"string",
",",
"ipsecpsk",
"string",
")",
"*",
"CreateVpnCustomerGatewayParams",
"{",
"p",
":=",
"&",
"CreateVpnCustomerGatewayParams",
"{",
"}",
"\n",
"p",
".",
"p",
"=",
"make",
"(",
"map",
"[",
"string",
"]",
"interface",
"{",
"}",
")",
"\n",
"p",
".",
"p",
"[",
"\"",
"\"",
"]",
"=",
"cidrlist",
"\n",
"p",
".",
"p",
"[",
"\"",
"\"",
"]",
"=",
"esppolicy",
"\n",
"p",
".",
"p",
"[",
"\"",
"\"",
"]",
"=",
"gateway",
"\n",
"p",
".",
"p",
"[",
"\"",
"\"",
"]",
"=",
"ikepolicy",
"\n",
"p",
".",
"p",
"[",
"\"",
"\"",
"]",
"=",
"ipsecpsk",
"\n",
"return",
"p",
"\n",
"}"
] |
// You should always use this function to get a new CreateVpnCustomerGatewayParams instance,
// as then you are sure you have configured all required params
|
[
"You",
"should",
"always",
"use",
"this",
"function",
"to",
"get",
"a",
"new",
"CreateVpnCustomerGatewayParams",
"instance",
"as",
"then",
"you",
"are",
"sure",
"you",
"have",
"configured",
"all",
"required",
"params"
] |
b6f53ed3282d22b6446422879587b0a78e1b0f11
|
https://github.com/xanzy/go-cloudstack/blob/b6f53ed3282d22b6446422879587b0a78e1b0f11/cloudstack/VPNService.go#L582-L591
|
145,324 |
xanzy/go-cloudstack
|
cloudstack/VPNService.go
|
CreateVpnCustomerGateway
|
func (s *VPNService) CreateVpnCustomerGateway(p *CreateVpnCustomerGatewayParams) (*CreateVpnCustomerGatewayResponse, error) {
resp, err := s.cs.newRequest("createVpnCustomerGateway", p.toURLValues())
if err != nil {
return nil, err
}
var r CreateVpnCustomerGatewayResponse
if err := json.Unmarshal(resp, &r); err != nil {
return nil, err
}
// If we have a async client, we need to wait for the async result
if s.cs.async {
b, err := s.cs.GetAsyncJobResult(r.JobID, s.cs.timeout)
if err != nil {
if err == AsyncTimeoutErr {
return &r, err
}
return nil, err
}
b, err = getRawValue(b)
if err != nil {
return nil, err
}
if err := json.Unmarshal(b, &r); err != nil {
return nil, err
}
}
return &r, nil
}
|
go
|
func (s *VPNService) CreateVpnCustomerGateway(p *CreateVpnCustomerGatewayParams) (*CreateVpnCustomerGatewayResponse, error) {
resp, err := s.cs.newRequest("createVpnCustomerGateway", p.toURLValues())
if err != nil {
return nil, err
}
var r CreateVpnCustomerGatewayResponse
if err := json.Unmarshal(resp, &r); err != nil {
return nil, err
}
// If we have a async client, we need to wait for the async result
if s.cs.async {
b, err := s.cs.GetAsyncJobResult(r.JobID, s.cs.timeout)
if err != nil {
if err == AsyncTimeoutErr {
return &r, err
}
return nil, err
}
b, err = getRawValue(b)
if err != nil {
return nil, err
}
if err := json.Unmarshal(b, &r); err != nil {
return nil, err
}
}
return &r, nil
}
|
[
"func",
"(",
"s",
"*",
"VPNService",
")",
"CreateVpnCustomerGateway",
"(",
"p",
"*",
"CreateVpnCustomerGatewayParams",
")",
"(",
"*",
"CreateVpnCustomerGatewayResponse",
",",
"error",
")",
"{",
"resp",
",",
"err",
":=",
"s",
".",
"cs",
".",
"newRequest",
"(",
"\"",
"\"",
",",
"p",
".",
"toURLValues",
"(",
")",
")",
"\n",
"if",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"var",
"r",
"CreateVpnCustomerGatewayResponse",
"\n",
"if",
"err",
":=",
"json",
".",
"Unmarshal",
"(",
"resp",
",",
"&",
"r",
")",
";",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"// If we have a async client, we need to wait for the async result",
"if",
"s",
".",
"cs",
".",
"async",
"{",
"b",
",",
"err",
":=",
"s",
".",
"cs",
".",
"GetAsyncJobResult",
"(",
"r",
".",
"JobID",
",",
"s",
".",
"cs",
".",
"timeout",
")",
"\n",
"if",
"err",
"!=",
"nil",
"{",
"if",
"err",
"==",
"AsyncTimeoutErr",
"{",
"return",
"&",
"r",
",",
"err",
"\n",
"}",
"\n",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"b",
",",
"err",
"=",
"getRawValue",
"(",
"b",
")",
"\n",
"if",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"if",
"err",
":=",
"json",
".",
"Unmarshal",
"(",
"b",
",",
"&",
"r",
")",
";",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n",
"}",
"\n\n",
"return",
"&",
"r",
",",
"nil",
"\n",
"}"
] |
// Creates site to site vpn customer gateway
|
[
"Creates",
"site",
"to",
"site",
"vpn",
"customer",
"gateway"
] |
b6f53ed3282d22b6446422879587b0a78e1b0f11
|
https://github.com/xanzy/go-cloudstack/blob/b6f53ed3282d22b6446422879587b0a78e1b0f11/cloudstack/VPNService.go#L594-L626
|
145,325 |
xanzy/go-cloudstack
|
cloudstack/VPNService.go
|
NewCreateVpnGatewayParams
|
func (s *VPNService) NewCreateVpnGatewayParams(vpcid string) *CreateVpnGatewayParams {
p := &CreateVpnGatewayParams{}
p.p = make(map[string]interface{})
p.p["vpcid"] = vpcid
return p
}
|
go
|
func (s *VPNService) NewCreateVpnGatewayParams(vpcid string) *CreateVpnGatewayParams {
p := &CreateVpnGatewayParams{}
p.p = make(map[string]interface{})
p.p["vpcid"] = vpcid
return p
}
|
[
"func",
"(",
"s",
"*",
"VPNService",
")",
"NewCreateVpnGatewayParams",
"(",
"vpcid",
"string",
")",
"*",
"CreateVpnGatewayParams",
"{",
"p",
":=",
"&",
"CreateVpnGatewayParams",
"{",
"}",
"\n",
"p",
".",
"p",
"=",
"make",
"(",
"map",
"[",
"string",
"]",
"interface",
"{",
"}",
")",
"\n",
"p",
".",
"p",
"[",
"\"",
"\"",
"]",
"=",
"vpcid",
"\n",
"return",
"p",
"\n",
"}"
] |
// You should always use this function to get a new CreateVpnGatewayParams instance,
// as then you are sure you have configured all required params
|
[
"You",
"should",
"always",
"use",
"this",
"function",
"to",
"get",
"a",
"new",
"CreateVpnGatewayParams",
"instance",
"as",
"then",
"you",
"are",
"sure",
"you",
"have",
"configured",
"all",
"required",
"params"
] |
b6f53ed3282d22b6446422879587b0a78e1b0f11
|
https://github.com/xanzy/go-cloudstack/blob/b6f53ed3282d22b6446422879587b0a78e1b0f11/cloudstack/VPNService.go#L687-L692
|
145,326 |
xanzy/go-cloudstack
|
cloudstack/VPNService.go
|
CreateVpnGateway
|
func (s *VPNService) CreateVpnGateway(p *CreateVpnGatewayParams) (*CreateVpnGatewayResponse, error) {
resp, err := s.cs.newRequest("createVpnGateway", p.toURLValues())
if err != nil {
return nil, err
}
var r CreateVpnGatewayResponse
if err := json.Unmarshal(resp, &r); err != nil {
return nil, err
}
// If we have a async client, we need to wait for the async result
if s.cs.async {
b, err := s.cs.GetAsyncJobResult(r.JobID, s.cs.timeout)
if err != nil {
if err == AsyncTimeoutErr {
return &r, err
}
return nil, err
}
b, err = getRawValue(b)
if err != nil {
return nil, err
}
if err := json.Unmarshal(b, &r); err != nil {
return nil, err
}
}
return &r, nil
}
|
go
|
func (s *VPNService) CreateVpnGateway(p *CreateVpnGatewayParams) (*CreateVpnGatewayResponse, error) {
resp, err := s.cs.newRequest("createVpnGateway", p.toURLValues())
if err != nil {
return nil, err
}
var r CreateVpnGatewayResponse
if err := json.Unmarshal(resp, &r); err != nil {
return nil, err
}
// If we have a async client, we need to wait for the async result
if s.cs.async {
b, err := s.cs.GetAsyncJobResult(r.JobID, s.cs.timeout)
if err != nil {
if err == AsyncTimeoutErr {
return &r, err
}
return nil, err
}
b, err = getRawValue(b)
if err != nil {
return nil, err
}
if err := json.Unmarshal(b, &r); err != nil {
return nil, err
}
}
return &r, nil
}
|
[
"func",
"(",
"s",
"*",
"VPNService",
")",
"CreateVpnGateway",
"(",
"p",
"*",
"CreateVpnGatewayParams",
")",
"(",
"*",
"CreateVpnGatewayResponse",
",",
"error",
")",
"{",
"resp",
",",
"err",
":=",
"s",
".",
"cs",
".",
"newRequest",
"(",
"\"",
"\"",
",",
"p",
".",
"toURLValues",
"(",
")",
")",
"\n",
"if",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"var",
"r",
"CreateVpnGatewayResponse",
"\n",
"if",
"err",
":=",
"json",
".",
"Unmarshal",
"(",
"resp",
",",
"&",
"r",
")",
";",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"// If we have a async client, we need to wait for the async result",
"if",
"s",
".",
"cs",
".",
"async",
"{",
"b",
",",
"err",
":=",
"s",
".",
"cs",
".",
"GetAsyncJobResult",
"(",
"r",
".",
"JobID",
",",
"s",
".",
"cs",
".",
"timeout",
")",
"\n",
"if",
"err",
"!=",
"nil",
"{",
"if",
"err",
"==",
"AsyncTimeoutErr",
"{",
"return",
"&",
"r",
",",
"err",
"\n",
"}",
"\n",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"b",
",",
"err",
"=",
"getRawValue",
"(",
"b",
")",
"\n",
"if",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"if",
"err",
":=",
"json",
".",
"Unmarshal",
"(",
"b",
",",
"&",
"r",
")",
";",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n",
"}",
"\n\n",
"return",
"&",
"r",
",",
"nil",
"\n",
"}"
] |
// Creates site to site vpn local gateway
|
[
"Creates",
"site",
"to",
"site",
"vpn",
"local",
"gateway"
] |
b6f53ed3282d22b6446422879587b0a78e1b0f11
|
https://github.com/xanzy/go-cloudstack/blob/b6f53ed3282d22b6446422879587b0a78e1b0f11/cloudstack/VPNService.go#L695-L727
|
145,327 |
xanzy/go-cloudstack
|
cloudstack/VPNService.go
|
NewDeleteRemoteAccessVpnParams
|
func (s *VPNService) NewDeleteRemoteAccessVpnParams(publicipid string) *DeleteRemoteAccessVpnParams {
p := &DeleteRemoteAccessVpnParams{}
p.p = make(map[string]interface{})
p.p["publicipid"] = publicipid
return p
}
|
go
|
func (s *VPNService) NewDeleteRemoteAccessVpnParams(publicipid string) *DeleteRemoteAccessVpnParams {
p := &DeleteRemoteAccessVpnParams{}
p.p = make(map[string]interface{})
p.p["publicipid"] = publicipid
return p
}
|
[
"func",
"(",
"s",
"*",
"VPNService",
")",
"NewDeleteRemoteAccessVpnParams",
"(",
"publicipid",
"string",
")",
"*",
"DeleteRemoteAccessVpnParams",
"{",
"p",
":=",
"&",
"DeleteRemoteAccessVpnParams",
"{",
"}",
"\n",
"p",
".",
"p",
"=",
"make",
"(",
"map",
"[",
"string",
"]",
"interface",
"{",
"}",
")",
"\n",
"p",
".",
"p",
"[",
"\"",
"\"",
"]",
"=",
"publicipid",
"\n",
"return",
"p",
"\n",
"}"
] |
// You should always use this function to get a new DeleteRemoteAccessVpnParams instance,
// as then you are sure you have configured all required params
|
[
"You",
"should",
"always",
"use",
"this",
"function",
"to",
"get",
"a",
"new",
"DeleteRemoteAccessVpnParams",
"instance",
"as",
"then",
"you",
"are",
"sure",
"you",
"have",
"configured",
"all",
"required",
"params"
] |
b6f53ed3282d22b6446422879587b0a78e1b0f11
|
https://github.com/xanzy/go-cloudstack/blob/b6f53ed3282d22b6446422879587b0a78e1b0f11/cloudstack/VPNService.go#L768-L773
|
145,328 |
xanzy/go-cloudstack
|
cloudstack/VPNService.go
|
NewDeleteVpnConnectionParams
|
func (s *VPNService) NewDeleteVpnConnectionParams(id string) *DeleteVpnConnectionParams {
p := &DeleteVpnConnectionParams{}
p.p = make(map[string]interface{})
p.p["id"] = id
return p
}
|
go
|
func (s *VPNService) NewDeleteVpnConnectionParams(id string) *DeleteVpnConnectionParams {
p := &DeleteVpnConnectionParams{}
p.p = make(map[string]interface{})
p.p["id"] = id
return p
}
|
[
"func",
"(",
"s",
"*",
"VPNService",
")",
"NewDeleteVpnConnectionParams",
"(",
"id",
"string",
")",
"*",
"DeleteVpnConnectionParams",
"{",
"p",
":=",
"&",
"DeleteVpnConnectionParams",
"{",
"}",
"\n",
"p",
".",
"p",
"=",
"make",
"(",
"map",
"[",
"string",
"]",
"interface",
"{",
"}",
")",
"\n",
"p",
".",
"p",
"[",
"\"",
"\"",
"]",
"=",
"id",
"\n",
"return",
"p",
"\n",
"}"
] |
// You should always use this function to get a new DeleteVpnConnectionParams instance,
// as then you are sure you have configured all required params
|
[
"You",
"should",
"always",
"use",
"this",
"function",
"to",
"get",
"a",
"new",
"DeleteVpnConnectionParams",
"instance",
"as",
"then",
"you",
"are",
"sure",
"you",
"have",
"configured",
"all",
"required",
"params"
] |
b6f53ed3282d22b6446422879587b0a78e1b0f11
|
https://github.com/xanzy/go-cloudstack/blob/b6f53ed3282d22b6446422879587b0a78e1b0f11/cloudstack/VPNService.go#L836-L841
|
145,329 |
xanzy/go-cloudstack
|
cloudstack/VPNService.go
|
DeleteVpnConnection
|
func (s *VPNService) DeleteVpnConnection(p *DeleteVpnConnectionParams) (*DeleteVpnConnectionResponse, error) {
resp, err := s.cs.newRequest("deleteVpnConnection", p.toURLValues())
if err != nil {
return nil, err
}
var r DeleteVpnConnectionResponse
if err := json.Unmarshal(resp, &r); err != nil {
return nil, err
}
// If we have a async client, we need to wait for the async result
if s.cs.async {
b, err := s.cs.GetAsyncJobResult(r.JobID, s.cs.timeout)
if err != nil {
if err == AsyncTimeoutErr {
return &r, err
}
return nil, err
}
if err := json.Unmarshal(b, &r); err != nil {
return nil, err
}
}
return &r, nil
}
|
go
|
func (s *VPNService) DeleteVpnConnection(p *DeleteVpnConnectionParams) (*DeleteVpnConnectionResponse, error) {
resp, err := s.cs.newRequest("deleteVpnConnection", p.toURLValues())
if err != nil {
return nil, err
}
var r DeleteVpnConnectionResponse
if err := json.Unmarshal(resp, &r); err != nil {
return nil, err
}
// If we have a async client, we need to wait for the async result
if s.cs.async {
b, err := s.cs.GetAsyncJobResult(r.JobID, s.cs.timeout)
if err != nil {
if err == AsyncTimeoutErr {
return &r, err
}
return nil, err
}
if err := json.Unmarshal(b, &r); err != nil {
return nil, err
}
}
return &r, nil
}
|
[
"func",
"(",
"s",
"*",
"VPNService",
")",
"DeleteVpnConnection",
"(",
"p",
"*",
"DeleteVpnConnectionParams",
")",
"(",
"*",
"DeleteVpnConnectionResponse",
",",
"error",
")",
"{",
"resp",
",",
"err",
":=",
"s",
".",
"cs",
".",
"newRequest",
"(",
"\"",
"\"",
",",
"p",
".",
"toURLValues",
"(",
")",
")",
"\n",
"if",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"var",
"r",
"DeleteVpnConnectionResponse",
"\n",
"if",
"err",
":=",
"json",
".",
"Unmarshal",
"(",
"resp",
",",
"&",
"r",
")",
";",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"// If we have a async client, we need to wait for the async result",
"if",
"s",
".",
"cs",
".",
"async",
"{",
"b",
",",
"err",
":=",
"s",
".",
"cs",
".",
"GetAsyncJobResult",
"(",
"r",
".",
"JobID",
",",
"s",
".",
"cs",
".",
"timeout",
")",
"\n",
"if",
"err",
"!=",
"nil",
"{",
"if",
"err",
"==",
"AsyncTimeoutErr",
"{",
"return",
"&",
"r",
",",
"err",
"\n",
"}",
"\n",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"if",
"err",
":=",
"json",
".",
"Unmarshal",
"(",
"b",
",",
"&",
"r",
")",
";",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n",
"}",
"\n\n",
"return",
"&",
"r",
",",
"nil",
"\n",
"}"
] |
// Delete site to site vpn connection
|
[
"Delete",
"site",
"to",
"site",
"vpn",
"connection"
] |
b6f53ed3282d22b6446422879587b0a78e1b0f11
|
https://github.com/xanzy/go-cloudstack/blob/b6f53ed3282d22b6446422879587b0a78e1b0f11/cloudstack/VPNService.go#L844-L871
|
145,330 |
xanzy/go-cloudstack
|
cloudstack/VPNService.go
|
NewDeleteVpnCustomerGatewayParams
|
func (s *VPNService) NewDeleteVpnCustomerGatewayParams(id string) *DeleteVpnCustomerGatewayParams {
p := &DeleteVpnCustomerGatewayParams{}
p.p = make(map[string]interface{})
p.p["id"] = id
return p
}
|
go
|
func (s *VPNService) NewDeleteVpnCustomerGatewayParams(id string) *DeleteVpnCustomerGatewayParams {
p := &DeleteVpnCustomerGatewayParams{}
p.p = make(map[string]interface{})
p.p["id"] = id
return p
}
|
[
"func",
"(",
"s",
"*",
"VPNService",
")",
"NewDeleteVpnCustomerGatewayParams",
"(",
"id",
"string",
")",
"*",
"DeleteVpnCustomerGatewayParams",
"{",
"p",
":=",
"&",
"DeleteVpnCustomerGatewayParams",
"{",
"}",
"\n",
"p",
".",
"p",
"=",
"make",
"(",
"map",
"[",
"string",
"]",
"interface",
"{",
"}",
")",
"\n",
"p",
".",
"p",
"[",
"\"",
"\"",
"]",
"=",
"id",
"\n",
"return",
"p",
"\n",
"}"
] |
// You should always use this function to get a new DeleteVpnCustomerGatewayParams instance,
// as then you are sure you have configured all required params
|
[
"You",
"should",
"always",
"use",
"this",
"function",
"to",
"get",
"a",
"new",
"DeleteVpnCustomerGatewayParams",
"instance",
"as",
"then",
"you",
"are",
"sure",
"you",
"have",
"configured",
"all",
"required",
"params"
] |
b6f53ed3282d22b6446422879587b0a78e1b0f11
|
https://github.com/xanzy/go-cloudstack/blob/b6f53ed3282d22b6446422879587b0a78e1b0f11/cloudstack/VPNService.go#L904-L909
|
145,331 |
xanzy/go-cloudstack
|
cloudstack/VPNService.go
|
DeleteVpnCustomerGateway
|
func (s *VPNService) DeleteVpnCustomerGateway(p *DeleteVpnCustomerGatewayParams) (*DeleteVpnCustomerGatewayResponse, error) {
resp, err := s.cs.newRequest("deleteVpnCustomerGateway", p.toURLValues())
if err != nil {
return nil, err
}
var r DeleteVpnCustomerGatewayResponse
if err := json.Unmarshal(resp, &r); err != nil {
return nil, err
}
// If we have a async client, we need to wait for the async result
if s.cs.async {
b, err := s.cs.GetAsyncJobResult(r.JobID, s.cs.timeout)
if err != nil {
if err == AsyncTimeoutErr {
return &r, err
}
return nil, err
}
if err := json.Unmarshal(b, &r); err != nil {
return nil, err
}
}
return &r, nil
}
|
go
|
func (s *VPNService) DeleteVpnCustomerGateway(p *DeleteVpnCustomerGatewayParams) (*DeleteVpnCustomerGatewayResponse, error) {
resp, err := s.cs.newRequest("deleteVpnCustomerGateway", p.toURLValues())
if err != nil {
return nil, err
}
var r DeleteVpnCustomerGatewayResponse
if err := json.Unmarshal(resp, &r); err != nil {
return nil, err
}
// If we have a async client, we need to wait for the async result
if s.cs.async {
b, err := s.cs.GetAsyncJobResult(r.JobID, s.cs.timeout)
if err != nil {
if err == AsyncTimeoutErr {
return &r, err
}
return nil, err
}
if err := json.Unmarshal(b, &r); err != nil {
return nil, err
}
}
return &r, nil
}
|
[
"func",
"(",
"s",
"*",
"VPNService",
")",
"DeleteVpnCustomerGateway",
"(",
"p",
"*",
"DeleteVpnCustomerGatewayParams",
")",
"(",
"*",
"DeleteVpnCustomerGatewayResponse",
",",
"error",
")",
"{",
"resp",
",",
"err",
":=",
"s",
".",
"cs",
".",
"newRequest",
"(",
"\"",
"\"",
",",
"p",
".",
"toURLValues",
"(",
")",
")",
"\n",
"if",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"var",
"r",
"DeleteVpnCustomerGatewayResponse",
"\n",
"if",
"err",
":=",
"json",
".",
"Unmarshal",
"(",
"resp",
",",
"&",
"r",
")",
";",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"// If we have a async client, we need to wait for the async result",
"if",
"s",
".",
"cs",
".",
"async",
"{",
"b",
",",
"err",
":=",
"s",
".",
"cs",
".",
"GetAsyncJobResult",
"(",
"r",
".",
"JobID",
",",
"s",
".",
"cs",
".",
"timeout",
")",
"\n",
"if",
"err",
"!=",
"nil",
"{",
"if",
"err",
"==",
"AsyncTimeoutErr",
"{",
"return",
"&",
"r",
",",
"err",
"\n",
"}",
"\n",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"if",
"err",
":=",
"json",
".",
"Unmarshal",
"(",
"b",
",",
"&",
"r",
")",
";",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n",
"}",
"\n\n",
"return",
"&",
"r",
",",
"nil",
"\n",
"}"
] |
// Delete site to site vpn customer gateway
|
[
"Delete",
"site",
"to",
"site",
"vpn",
"customer",
"gateway"
] |
b6f53ed3282d22b6446422879587b0a78e1b0f11
|
https://github.com/xanzy/go-cloudstack/blob/b6f53ed3282d22b6446422879587b0a78e1b0f11/cloudstack/VPNService.go#L912-L939
|
145,332 |
xanzy/go-cloudstack
|
cloudstack/VPNService.go
|
NewDeleteVpnGatewayParams
|
func (s *VPNService) NewDeleteVpnGatewayParams(id string) *DeleteVpnGatewayParams {
p := &DeleteVpnGatewayParams{}
p.p = make(map[string]interface{})
p.p["id"] = id
return p
}
|
go
|
func (s *VPNService) NewDeleteVpnGatewayParams(id string) *DeleteVpnGatewayParams {
p := &DeleteVpnGatewayParams{}
p.p = make(map[string]interface{})
p.p["id"] = id
return p
}
|
[
"func",
"(",
"s",
"*",
"VPNService",
")",
"NewDeleteVpnGatewayParams",
"(",
"id",
"string",
")",
"*",
"DeleteVpnGatewayParams",
"{",
"p",
":=",
"&",
"DeleteVpnGatewayParams",
"{",
"}",
"\n",
"p",
".",
"p",
"=",
"make",
"(",
"map",
"[",
"string",
"]",
"interface",
"{",
"}",
")",
"\n",
"p",
".",
"p",
"[",
"\"",
"\"",
"]",
"=",
"id",
"\n",
"return",
"p",
"\n",
"}"
] |
// You should always use this function to get a new DeleteVpnGatewayParams instance,
// as then you are sure you have configured all required params
|
[
"You",
"should",
"always",
"use",
"this",
"function",
"to",
"get",
"a",
"new",
"DeleteVpnGatewayParams",
"instance",
"as",
"then",
"you",
"are",
"sure",
"you",
"have",
"configured",
"all",
"required",
"params"
] |
b6f53ed3282d22b6446422879587b0a78e1b0f11
|
https://github.com/xanzy/go-cloudstack/blob/b6f53ed3282d22b6446422879587b0a78e1b0f11/cloudstack/VPNService.go#L972-L977
|
145,333 |
xanzy/go-cloudstack
|
cloudstack/VPNService.go
|
DeleteVpnGateway
|
func (s *VPNService) DeleteVpnGateway(p *DeleteVpnGatewayParams) (*DeleteVpnGatewayResponse, error) {
resp, err := s.cs.newRequest("deleteVpnGateway", p.toURLValues())
if err != nil {
return nil, err
}
var r DeleteVpnGatewayResponse
if err := json.Unmarshal(resp, &r); err != nil {
return nil, err
}
// If we have a async client, we need to wait for the async result
if s.cs.async {
b, err := s.cs.GetAsyncJobResult(r.JobID, s.cs.timeout)
if err != nil {
if err == AsyncTimeoutErr {
return &r, err
}
return nil, err
}
if err := json.Unmarshal(b, &r); err != nil {
return nil, err
}
}
return &r, nil
}
|
go
|
func (s *VPNService) DeleteVpnGateway(p *DeleteVpnGatewayParams) (*DeleteVpnGatewayResponse, error) {
resp, err := s.cs.newRequest("deleteVpnGateway", p.toURLValues())
if err != nil {
return nil, err
}
var r DeleteVpnGatewayResponse
if err := json.Unmarshal(resp, &r); err != nil {
return nil, err
}
// If we have a async client, we need to wait for the async result
if s.cs.async {
b, err := s.cs.GetAsyncJobResult(r.JobID, s.cs.timeout)
if err != nil {
if err == AsyncTimeoutErr {
return &r, err
}
return nil, err
}
if err := json.Unmarshal(b, &r); err != nil {
return nil, err
}
}
return &r, nil
}
|
[
"func",
"(",
"s",
"*",
"VPNService",
")",
"DeleteVpnGateway",
"(",
"p",
"*",
"DeleteVpnGatewayParams",
")",
"(",
"*",
"DeleteVpnGatewayResponse",
",",
"error",
")",
"{",
"resp",
",",
"err",
":=",
"s",
".",
"cs",
".",
"newRequest",
"(",
"\"",
"\"",
",",
"p",
".",
"toURLValues",
"(",
")",
")",
"\n",
"if",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"var",
"r",
"DeleteVpnGatewayResponse",
"\n",
"if",
"err",
":=",
"json",
".",
"Unmarshal",
"(",
"resp",
",",
"&",
"r",
")",
";",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"// If we have a async client, we need to wait for the async result",
"if",
"s",
".",
"cs",
".",
"async",
"{",
"b",
",",
"err",
":=",
"s",
".",
"cs",
".",
"GetAsyncJobResult",
"(",
"r",
".",
"JobID",
",",
"s",
".",
"cs",
".",
"timeout",
")",
"\n",
"if",
"err",
"!=",
"nil",
"{",
"if",
"err",
"==",
"AsyncTimeoutErr",
"{",
"return",
"&",
"r",
",",
"err",
"\n",
"}",
"\n",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"if",
"err",
":=",
"json",
".",
"Unmarshal",
"(",
"b",
",",
"&",
"r",
")",
";",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n",
"}",
"\n\n",
"return",
"&",
"r",
",",
"nil",
"\n",
"}"
] |
// Delete site to site vpn gateway
|
[
"Delete",
"site",
"to",
"site",
"vpn",
"gateway"
] |
b6f53ed3282d22b6446422879587b0a78e1b0f11
|
https://github.com/xanzy/go-cloudstack/blob/b6f53ed3282d22b6446422879587b0a78e1b0f11/cloudstack/VPNService.go#L980-L1007
|
145,334 |
xanzy/go-cloudstack
|
cloudstack/VPNService.go
|
NewListRemoteAccessVpnsParams
|
func (s *VPNService) NewListRemoteAccessVpnsParams() *ListRemoteAccessVpnsParams {
p := &ListRemoteAccessVpnsParams{}
p.p = make(map[string]interface{})
return p
}
|
go
|
func (s *VPNService) NewListRemoteAccessVpnsParams() *ListRemoteAccessVpnsParams {
p := &ListRemoteAccessVpnsParams{}
p.p = make(map[string]interface{})
return p
}
|
[
"func",
"(",
"s",
"*",
"VPNService",
")",
"NewListRemoteAccessVpnsParams",
"(",
")",
"*",
"ListRemoteAccessVpnsParams",
"{",
"p",
":=",
"&",
"ListRemoteAccessVpnsParams",
"{",
"}",
"\n",
"p",
".",
"p",
"=",
"make",
"(",
"map",
"[",
"string",
"]",
"interface",
"{",
"}",
")",
"\n",
"return",
"p",
"\n",
"}"
] |
// You should always use this function to get a new ListRemoteAccessVpnsParams instance,
// as then you are sure you have configured all required params
|
[
"You",
"should",
"always",
"use",
"this",
"function",
"to",
"get",
"a",
"new",
"ListRemoteAccessVpnsParams",
"instance",
"as",
"then",
"you",
"are",
"sure",
"you",
"have",
"configured",
"all",
"required",
"params"
] |
b6f53ed3282d22b6446422879587b0a78e1b0f11
|
https://github.com/xanzy/go-cloudstack/blob/b6f53ed3282d22b6446422879587b0a78e1b0f11/cloudstack/VPNService.go#L1166-L1170
|
145,335 |
xanzy/go-cloudstack
|
cloudstack/VPNService.go
|
ListRemoteAccessVpns
|
func (s *VPNService) ListRemoteAccessVpns(p *ListRemoteAccessVpnsParams) (*ListRemoteAccessVpnsResponse, error) {
resp, err := s.cs.newRequest("listRemoteAccessVpns", p.toURLValues())
if err != nil {
return nil, err
}
var r ListRemoteAccessVpnsResponse
if err := json.Unmarshal(resp, &r); err != nil {
return nil, err
}
return &r, nil
}
|
go
|
func (s *VPNService) ListRemoteAccessVpns(p *ListRemoteAccessVpnsParams) (*ListRemoteAccessVpnsResponse, error) {
resp, err := s.cs.newRequest("listRemoteAccessVpns", p.toURLValues())
if err != nil {
return nil, err
}
var r ListRemoteAccessVpnsResponse
if err := json.Unmarshal(resp, &r); err != nil {
return nil, err
}
return &r, nil
}
|
[
"func",
"(",
"s",
"*",
"VPNService",
")",
"ListRemoteAccessVpns",
"(",
"p",
"*",
"ListRemoteAccessVpnsParams",
")",
"(",
"*",
"ListRemoteAccessVpnsResponse",
",",
"error",
")",
"{",
"resp",
",",
"err",
":=",
"s",
".",
"cs",
".",
"newRequest",
"(",
"\"",
"\"",
",",
"p",
".",
"toURLValues",
"(",
")",
")",
"\n",
"if",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"var",
"r",
"ListRemoteAccessVpnsResponse",
"\n",
"if",
"err",
":=",
"json",
".",
"Unmarshal",
"(",
"resp",
",",
"&",
"r",
")",
";",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"return",
"&",
"r",
",",
"nil",
"\n",
"}"
] |
// Lists remote access vpns
|
[
"Lists",
"remote",
"access",
"vpns"
] |
b6f53ed3282d22b6446422879587b0a78e1b0f11
|
https://github.com/xanzy/go-cloudstack/blob/b6f53ed3282d22b6446422879587b0a78e1b0f11/cloudstack/VPNService.go#L1206-L1218
|
145,336 |
xanzy/go-cloudstack
|
cloudstack/VPNService.go
|
NewListVpnConnectionsParams
|
func (s *VPNService) NewListVpnConnectionsParams() *ListVpnConnectionsParams {
p := &ListVpnConnectionsParams{}
p.p = make(map[string]interface{})
return p
}
|
go
|
func (s *VPNService) NewListVpnConnectionsParams() *ListVpnConnectionsParams {
p := &ListVpnConnectionsParams{}
p.p = make(map[string]interface{})
return p
}
|
[
"func",
"(",
"s",
"*",
"VPNService",
")",
"NewListVpnConnectionsParams",
"(",
")",
"*",
"ListVpnConnectionsParams",
"{",
"p",
":=",
"&",
"ListVpnConnectionsParams",
"{",
"}",
"\n",
"p",
".",
"p",
"=",
"make",
"(",
"map",
"[",
"string",
"]",
"interface",
"{",
"}",
")",
"\n",
"return",
"p",
"\n",
"}"
] |
// You should always use this function to get a new ListVpnConnectionsParams instance,
// as then you are sure you have configured all required params
|
[
"You",
"should",
"always",
"use",
"this",
"function",
"to",
"get",
"a",
"new",
"ListVpnConnectionsParams",
"instance",
"as",
"then",
"you",
"are",
"sure",
"you",
"have",
"configured",
"all",
"required",
"params"
] |
b6f53ed3282d22b6446422879587b0a78e1b0f11
|
https://github.com/xanzy/go-cloudstack/blob/b6f53ed3282d22b6446422879587b0a78e1b0f11/cloudstack/VPNService.go#L1380-L1384
|
145,337 |
xanzy/go-cloudstack
|
cloudstack/VPNService.go
|
ListVpnConnections
|
func (s *VPNService) ListVpnConnections(p *ListVpnConnectionsParams) (*ListVpnConnectionsResponse, error) {
resp, err := s.cs.newRequest("listVpnConnections", p.toURLValues())
if err != nil {
return nil, err
}
var r ListVpnConnectionsResponse
if err := json.Unmarshal(resp, &r); err != nil {
return nil, err
}
return &r, nil
}
|
go
|
func (s *VPNService) ListVpnConnections(p *ListVpnConnectionsParams) (*ListVpnConnectionsResponse, error) {
resp, err := s.cs.newRequest("listVpnConnections", p.toURLValues())
if err != nil {
return nil, err
}
var r ListVpnConnectionsResponse
if err := json.Unmarshal(resp, &r); err != nil {
return nil, err
}
return &r, nil
}
|
[
"func",
"(",
"s",
"*",
"VPNService",
")",
"ListVpnConnections",
"(",
"p",
"*",
"ListVpnConnectionsParams",
")",
"(",
"*",
"ListVpnConnectionsResponse",
",",
"error",
")",
"{",
"resp",
",",
"err",
":=",
"s",
".",
"cs",
".",
"newRequest",
"(",
"\"",
"\"",
",",
"p",
".",
"toURLValues",
"(",
")",
")",
"\n",
"if",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"var",
"r",
"ListVpnConnectionsResponse",
"\n",
"if",
"err",
":=",
"json",
".",
"Unmarshal",
"(",
"resp",
",",
"&",
"r",
")",
";",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"return",
"&",
"r",
",",
"nil",
"\n",
"}"
] |
// Lists site to site vpn connection gateways
|
[
"Lists",
"site",
"to",
"site",
"vpn",
"connection",
"gateways"
] |
b6f53ed3282d22b6446422879587b0a78e1b0f11
|
https://github.com/xanzy/go-cloudstack/blob/b6f53ed3282d22b6446422879587b0a78e1b0f11/cloudstack/VPNService.go#L1420-L1432
|
145,338 |
xanzy/go-cloudstack
|
cloudstack/VPNService.go
|
NewListVpnCustomerGatewaysParams
|
func (s *VPNService) NewListVpnCustomerGatewaysParams() *ListVpnCustomerGatewaysParams {
p := &ListVpnCustomerGatewaysParams{}
p.p = make(map[string]interface{})
return p
}
|
go
|
func (s *VPNService) NewListVpnCustomerGatewaysParams() *ListVpnCustomerGatewaysParams {
p := &ListVpnCustomerGatewaysParams{}
p.p = make(map[string]interface{})
return p
}
|
[
"func",
"(",
"s",
"*",
"VPNService",
")",
"NewListVpnCustomerGatewaysParams",
"(",
")",
"*",
"ListVpnCustomerGatewaysParams",
"{",
"p",
":=",
"&",
"ListVpnCustomerGatewaysParams",
"{",
"}",
"\n",
"p",
".",
"p",
"=",
"make",
"(",
"map",
"[",
"string",
"]",
"interface",
"{",
"}",
")",
"\n",
"return",
"p",
"\n",
"}"
] |
// You should always use this function to get a new ListVpnCustomerGatewaysParams instance,
// as then you are sure you have configured all required params
|
[
"You",
"should",
"always",
"use",
"this",
"function",
"to",
"get",
"a",
"new",
"ListVpnCustomerGatewaysParams",
"instance",
"as",
"then",
"you",
"are",
"sure",
"you",
"have",
"configured",
"all",
"required",
"params"
] |
b6f53ed3282d22b6446422879587b0a78e1b0f11
|
https://github.com/xanzy/go-cloudstack/blob/b6f53ed3282d22b6446422879587b0a78e1b0f11/cloudstack/VPNService.go#L1582-L1586
|
145,339 |
xanzy/go-cloudstack
|
cloudstack/VPNService.go
|
ListVpnCustomerGateways
|
func (s *VPNService) ListVpnCustomerGateways(p *ListVpnCustomerGatewaysParams) (*ListVpnCustomerGatewaysResponse, error) {
resp, err := s.cs.newRequest("listVpnCustomerGateways", p.toURLValues())
if err != nil {
return nil, err
}
var r ListVpnCustomerGatewaysResponse
if err := json.Unmarshal(resp, &r); err != nil {
return nil, err
}
return &r, nil
}
|
go
|
func (s *VPNService) ListVpnCustomerGateways(p *ListVpnCustomerGatewaysParams) (*ListVpnCustomerGatewaysResponse, error) {
resp, err := s.cs.newRequest("listVpnCustomerGateways", p.toURLValues())
if err != nil {
return nil, err
}
var r ListVpnCustomerGatewaysResponse
if err := json.Unmarshal(resp, &r); err != nil {
return nil, err
}
return &r, nil
}
|
[
"func",
"(",
"s",
"*",
"VPNService",
")",
"ListVpnCustomerGateways",
"(",
"p",
"*",
"ListVpnCustomerGatewaysParams",
")",
"(",
"*",
"ListVpnCustomerGatewaysResponse",
",",
"error",
")",
"{",
"resp",
",",
"err",
":=",
"s",
".",
"cs",
".",
"newRequest",
"(",
"\"",
"\"",
",",
"p",
".",
"toURLValues",
"(",
")",
")",
"\n",
"if",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"var",
"r",
"ListVpnCustomerGatewaysResponse",
"\n",
"if",
"err",
":=",
"json",
".",
"Unmarshal",
"(",
"resp",
",",
"&",
"r",
")",
";",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"return",
"&",
"r",
",",
"nil",
"\n",
"}"
] |
// Lists site to site vpn customer gateways
|
[
"Lists",
"site",
"to",
"site",
"vpn",
"customer",
"gateways"
] |
b6f53ed3282d22b6446422879587b0a78e1b0f11
|
https://github.com/xanzy/go-cloudstack/blob/b6f53ed3282d22b6446422879587b0a78e1b0f11/cloudstack/VPNService.go#L1672-L1684
|
145,340 |
xanzy/go-cloudstack
|
cloudstack/VPNService.go
|
NewListVpnGatewaysParams
|
func (s *VPNService) NewListVpnGatewaysParams() *ListVpnGatewaysParams {
p := &ListVpnGatewaysParams{}
p.p = make(map[string]interface{})
return p
}
|
go
|
func (s *VPNService) NewListVpnGatewaysParams() *ListVpnGatewaysParams {
p := &ListVpnGatewaysParams{}
p.p = make(map[string]interface{})
return p
}
|
[
"func",
"(",
"s",
"*",
"VPNService",
")",
"NewListVpnGatewaysParams",
"(",
")",
"*",
"ListVpnGatewaysParams",
"{",
"p",
":=",
"&",
"ListVpnGatewaysParams",
"{",
"}",
"\n",
"p",
".",
"p",
"=",
"make",
"(",
"map",
"[",
"string",
"]",
"interface",
"{",
"}",
")",
"\n",
"return",
"p",
"\n",
"}"
] |
// You should always use this function to get a new ListVpnGatewaysParams instance,
// as then you are sure you have configured all required params
|
[
"You",
"should",
"always",
"use",
"this",
"function",
"to",
"get",
"a",
"new",
"ListVpnGatewaysParams",
"instance",
"as",
"then",
"you",
"are",
"sure",
"you",
"have",
"configured",
"all",
"required",
"params"
] |
b6f53ed3282d22b6446422879587b0a78e1b0f11
|
https://github.com/xanzy/go-cloudstack/blob/b6f53ed3282d22b6446422879587b0a78e1b0f11/cloudstack/VPNService.go#L1852-L1856
|
145,341 |
xanzy/go-cloudstack
|
cloudstack/VPNService.go
|
ListVpnGateways
|
func (s *VPNService) ListVpnGateways(p *ListVpnGatewaysParams) (*ListVpnGatewaysResponse, error) {
resp, err := s.cs.newRequest("listVpnGateways", p.toURLValues())
if err != nil {
return nil, err
}
var r ListVpnGatewaysResponse
if err := json.Unmarshal(resp, &r); err != nil {
return nil, err
}
return &r, nil
}
|
go
|
func (s *VPNService) ListVpnGateways(p *ListVpnGatewaysParams) (*ListVpnGatewaysResponse, error) {
resp, err := s.cs.newRequest("listVpnGateways", p.toURLValues())
if err != nil {
return nil, err
}
var r ListVpnGatewaysResponse
if err := json.Unmarshal(resp, &r); err != nil {
return nil, err
}
return &r, nil
}
|
[
"func",
"(",
"s",
"*",
"VPNService",
")",
"ListVpnGateways",
"(",
"p",
"*",
"ListVpnGatewaysParams",
")",
"(",
"*",
"ListVpnGatewaysResponse",
",",
"error",
")",
"{",
"resp",
",",
"err",
":=",
"s",
".",
"cs",
".",
"newRequest",
"(",
"\"",
"\"",
",",
"p",
".",
"toURLValues",
"(",
")",
")",
"\n",
"if",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"var",
"r",
"ListVpnGatewaysResponse",
"\n",
"if",
"err",
":=",
"json",
".",
"Unmarshal",
"(",
"resp",
",",
"&",
"r",
")",
";",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"return",
"&",
"r",
",",
"nil",
"\n",
"}"
] |
// Lists site 2 site vpn gateways
|
[
"Lists",
"site",
"2",
"site",
"vpn",
"gateways"
] |
b6f53ed3282d22b6446422879587b0a78e1b0f11
|
https://github.com/xanzy/go-cloudstack/blob/b6f53ed3282d22b6446422879587b0a78e1b0f11/cloudstack/VPNService.go#L1892-L1904
|
145,342 |
xanzy/go-cloudstack
|
cloudstack/VPNService.go
|
NewListVpnUsersParams
|
func (s *VPNService) NewListVpnUsersParams() *ListVpnUsersParams {
p := &ListVpnUsersParams{}
p.p = make(map[string]interface{})
return p
}
|
go
|
func (s *VPNService) NewListVpnUsersParams() *ListVpnUsersParams {
p := &ListVpnUsersParams{}
p.p = make(map[string]interface{})
return p
}
|
[
"func",
"(",
"s",
"*",
"VPNService",
")",
"NewListVpnUsersParams",
"(",
")",
"*",
"ListVpnUsersParams",
"{",
"p",
":=",
"&",
"ListVpnUsersParams",
"{",
"}",
"\n",
"p",
".",
"p",
"=",
"make",
"(",
"map",
"[",
"string",
"]",
"interface",
"{",
"}",
")",
"\n",
"return",
"p",
"\n",
"}"
] |
// You should always use this function to get a new ListVpnUsersParams instance,
// as then you are sure you have configured all required params
|
[
"You",
"should",
"always",
"use",
"this",
"function",
"to",
"get",
"a",
"new",
"ListVpnUsersParams",
"instance",
"as",
"then",
"you",
"are",
"sure",
"you",
"have",
"configured",
"all",
"required",
"params"
] |
b6f53ed3282d22b6446422879587b0a78e1b0f11
|
https://github.com/xanzy/go-cloudstack/blob/b6f53ed3282d22b6446422879587b0a78e1b0f11/cloudstack/VPNService.go#L2052-L2056
|
145,343 |
xanzy/go-cloudstack
|
cloudstack/VPNService.go
|
ListVpnUsers
|
func (s *VPNService) ListVpnUsers(p *ListVpnUsersParams) (*ListVpnUsersResponse, error) {
resp, err := s.cs.newRequest("listVpnUsers", p.toURLValues())
if err != nil {
return nil, err
}
var r ListVpnUsersResponse
if err := json.Unmarshal(resp, &r); err != nil {
return nil, err
}
return &r, nil
}
|
go
|
func (s *VPNService) ListVpnUsers(p *ListVpnUsersParams) (*ListVpnUsersResponse, error) {
resp, err := s.cs.newRequest("listVpnUsers", p.toURLValues())
if err != nil {
return nil, err
}
var r ListVpnUsersResponse
if err := json.Unmarshal(resp, &r); err != nil {
return nil, err
}
return &r, nil
}
|
[
"func",
"(",
"s",
"*",
"VPNService",
")",
"ListVpnUsers",
"(",
"p",
"*",
"ListVpnUsersParams",
")",
"(",
"*",
"ListVpnUsersResponse",
",",
"error",
")",
"{",
"resp",
",",
"err",
":=",
"s",
".",
"cs",
".",
"newRequest",
"(",
"\"",
"\"",
",",
"p",
".",
"toURLValues",
"(",
")",
")",
"\n",
"if",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"var",
"r",
"ListVpnUsersResponse",
"\n",
"if",
"err",
":=",
"json",
".",
"Unmarshal",
"(",
"resp",
",",
"&",
"r",
")",
";",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"return",
"&",
"r",
",",
"nil",
"\n",
"}"
] |
// Lists vpn users
|
[
"Lists",
"vpn",
"users"
] |
b6f53ed3282d22b6446422879587b0a78e1b0f11
|
https://github.com/xanzy/go-cloudstack/blob/b6f53ed3282d22b6446422879587b0a78e1b0f11/cloudstack/VPNService.go#L2092-L2104
|
145,344 |
xanzy/go-cloudstack
|
cloudstack/VPNService.go
|
NewRemoveVpnUserParams
|
func (s *VPNService) NewRemoveVpnUserParams(username string) *RemoveVpnUserParams {
p := &RemoveVpnUserParams{}
p.p = make(map[string]interface{})
p.p["username"] = username
return p
}
|
go
|
func (s *VPNService) NewRemoveVpnUserParams(username string) *RemoveVpnUserParams {
p := &RemoveVpnUserParams{}
p.p = make(map[string]interface{})
p.p["username"] = username
return p
}
|
[
"func",
"(",
"s",
"*",
"VPNService",
")",
"NewRemoveVpnUserParams",
"(",
"username",
"string",
")",
"*",
"RemoveVpnUserParams",
"{",
"p",
":=",
"&",
"RemoveVpnUserParams",
"{",
"}",
"\n",
"p",
".",
"p",
"=",
"make",
"(",
"map",
"[",
"string",
"]",
"interface",
"{",
"}",
")",
"\n",
"p",
".",
"p",
"[",
"\"",
"\"",
"]",
"=",
"username",
"\n",
"return",
"p",
"\n",
"}"
] |
// You should always use this function to get a new RemoveVpnUserParams instance,
// as then you are sure you have configured all required params
|
[
"You",
"should",
"always",
"use",
"this",
"function",
"to",
"get",
"a",
"new",
"RemoveVpnUserParams",
"instance",
"as",
"then",
"you",
"are",
"sure",
"you",
"have",
"configured",
"all",
"required",
"params"
] |
b6f53ed3282d22b6446422879587b0a78e1b0f11
|
https://github.com/xanzy/go-cloudstack/blob/b6f53ed3282d22b6446422879587b0a78e1b0f11/cloudstack/VPNService.go#L2180-L2185
|
145,345 |
xanzy/go-cloudstack
|
cloudstack/VPNService.go
|
RemoveVpnUser
|
func (s *VPNService) RemoveVpnUser(p *RemoveVpnUserParams) (*RemoveVpnUserResponse, error) {
resp, err := s.cs.newRequest("removeVpnUser", p.toURLValues())
if err != nil {
return nil, err
}
var r RemoveVpnUserResponse
if err := json.Unmarshal(resp, &r); err != nil {
return nil, err
}
// If we have a async client, we need to wait for the async result
if s.cs.async {
b, err := s.cs.GetAsyncJobResult(r.JobID, s.cs.timeout)
if err != nil {
if err == AsyncTimeoutErr {
return &r, err
}
return nil, err
}
if err := json.Unmarshal(b, &r); err != nil {
return nil, err
}
}
return &r, nil
}
|
go
|
func (s *VPNService) RemoveVpnUser(p *RemoveVpnUserParams) (*RemoveVpnUserResponse, error) {
resp, err := s.cs.newRequest("removeVpnUser", p.toURLValues())
if err != nil {
return nil, err
}
var r RemoveVpnUserResponse
if err := json.Unmarshal(resp, &r); err != nil {
return nil, err
}
// If we have a async client, we need to wait for the async result
if s.cs.async {
b, err := s.cs.GetAsyncJobResult(r.JobID, s.cs.timeout)
if err != nil {
if err == AsyncTimeoutErr {
return &r, err
}
return nil, err
}
if err := json.Unmarshal(b, &r); err != nil {
return nil, err
}
}
return &r, nil
}
|
[
"func",
"(",
"s",
"*",
"VPNService",
")",
"RemoveVpnUser",
"(",
"p",
"*",
"RemoveVpnUserParams",
")",
"(",
"*",
"RemoveVpnUserResponse",
",",
"error",
")",
"{",
"resp",
",",
"err",
":=",
"s",
".",
"cs",
".",
"newRequest",
"(",
"\"",
"\"",
",",
"p",
".",
"toURLValues",
"(",
")",
")",
"\n",
"if",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"var",
"r",
"RemoveVpnUserResponse",
"\n",
"if",
"err",
":=",
"json",
".",
"Unmarshal",
"(",
"resp",
",",
"&",
"r",
")",
";",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"// If we have a async client, we need to wait for the async result",
"if",
"s",
".",
"cs",
".",
"async",
"{",
"b",
",",
"err",
":=",
"s",
".",
"cs",
".",
"GetAsyncJobResult",
"(",
"r",
".",
"JobID",
",",
"s",
".",
"cs",
".",
"timeout",
")",
"\n",
"if",
"err",
"!=",
"nil",
"{",
"if",
"err",
"==",
"AsyncTimeoutErr",
"{",
"return",
"&",
"r",
",",
"err",
"\n",
"}",
"\n",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"if",
"err",
":=",
"json",
".",
"Unmarshal",
"(",
"b",
",",
"&",
"r",
")",
";",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n",
"}",
"\n\n",
"return",
"&",
"r",
",",
"nil",
"\n",
"}"
] |
// Removes vpn user
|
[
"Removes",
"vpn",
"user"
] |
b6f53ed3282d22b6446422879587b0a78e1b0f11
|
https://github.com/xanzy/go-cloudstack/blob/b6f53ed3282d22b6446422879587b0a78e1b0f11/cloudstack/VPNService.go#L2188-L2215
|
145,346 |
xanzy/go-cloudstack
|
cloudstack/VPNService.go
|
NewResetVpnConnectionParams
|
func (s *VPNService) NewResetVpnConnectionParams(id string) *ResetVpnConnectionParams {
p := &ResetVpnConnectionParams{}
p.p = make(map[string]interface{})
p.p["id"] = id
return p
}
|
go
|
func (s *VPNService) NewResetVpnConnectionParams(id string) *ResetVpnConnectionParams {
p := &ResetVpnConnectionParams{}
p.p = make(map[string]interface{})
p.p["id"] = id
return p
}
|
[
"func",
"(",
"s",
"*",
"VPNService",
")",
"NewResetVpnConnectionParams",
"(",
"id",
"string",
")",
"*",
"ResetVpnConnectionParams",
"{",
"p",
":=",
"&",
"ResetVpnConnectionParams",
"{",
"}",
"\n",
"p",
".",
"p",
"=",
"make",
"(",
"map",
"[",
"string",
"]",
"interface",
"{",
"}",
")",
"\n",
"p",
".",
"p",
"[",
"\"",
"\"",
"]",
"=",
"id",
"\n",
"return",
"p",
"\n",
"}"
] |
// You should always use this function to get a new ResetVpnConnectionParams instance,
// as then you are sure you have configured all required params
|
[
"You",
"should",
"always",
"use",
"this",
"function",
"to",
"get",
"a",
"new",
"ResetVpnConnectionParams",
"instance",
"as",
"then",
"you",
"are",
"sure",
"you",
"have",
"configured",
"all",
"required",
"params"
] |
b6f53ed3282d22b6446422879587b0a78e1b0f11
|
https://github.com/xanzy/go-cloudstack/blob/b6f53ed3282d22b6446422879587b0a78e1b0f11/cloudstack/VPNService.go#L2270-L2275
|
145,347 |
xanzy/go-cloudstack
|
cloudstack/VPNService.go
|
ResetVpnConnection
|
func (s *VPNService) ResetVpnConnection(p *ResetVpnConnectionParams) (*ResetVpnConnectionResponse, error) {
resp, err := s.cs.newRequest("resetVpnConnection", p.toURLValues())
if err != nil {
return nil, err
}
var r ResetVpnConnectionResponse
if err := json.Unmarshal(resp, &r); err != nil {
return nil, err
}
// If we have a async client, we need to wait for the async result
if s.cs.async {
b, err := s.cs.GetAsyncJobResult(r.JobID, s.cs.timeout)
if err != nil {
if err == AsyncTimeoutErr {
return &r, err
}
return nil, err
}
b, err = getRawValue(b)
if err != nil {
return nil, err
}
if err := json.Unmarshal(b, &r); err != nil {
return nil, err
}
}
return &r, nil
}
|
go
|
func (s *VPNService) ResetVpnConnection(p *ResetVpnConnectionParams) (*ResetVpnConnectionResponse, error) {
resp, err := s.cs.newRequest("resetVpnConnection", p.toURLValues())
if err != nil {
return nil, err
}
var r ResetVpnConnectionResponse
if err := json.Unmarshal(resp, &r); err != nil {
return nil, err
}
// If we have a async client, we need to wait for the async result
if s.cs.async {
b, err := s.cs.GetAsyncJobResult(r.JobID, s.cs.timeout)
if err != nil {
if err == AsyncTimeoutErr {
return &r, err
}
return nil, err
}
b, err = getRawValue(b)
if err != nil {
return nil, err
}
if err := json.Unmarshal(b, &r); err != nil {
return nil, err
}
}
return &r, nil
}
|
[
"func",
"(",
"s",
"*",
"VPNService",
")",
"ResetVpnConnection",
"(",
"p",
"*",
"ResetVpnConnectionParams",
")",
"(",
"*",
"ResetVpnConnectionResponse",
",",
"error",
")",
"{",
"resp",
",",
"err",
":=",
"s",
".",
"cs",
".",
"newRequest",
"(",
"\"",
"\"",
",",
"p",
".",
"toURLValues",
"(",
")",
")",
"\n",
"if",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"var",
"r",
"ResetVpnConnectionResponse",
"\n",
"if",
"err",
":=",
"json",
".",
"Unmarshal",
"(",
"resp",
",",
"&",
"r",
")",
";",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"// If we have a async client, we need to wait for the async result",
"if",
"s",
".",
"cs",
".",
"async",
"{",
"b",
",",
"err",
":=",
"s",
".",
"cs",
".",
"GetAsyncJobResult",
"(",
"r",
".",
"JobID",
",",
"s",
".",
"cs",
".",
"timeout",
")",
"\n",
"if",
"err",
"!=",
"nil",
"{",
"if",
"err",
"==",
"AsyncTimeoutErr",
"{",
"return",
"&",
"r",
",",
"err",
"\n",
"}",
"\n",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"b",
",",
"err",
"=",
"getRawValue",
"(",
"b",
")",
"\n",
"if",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"if",
"err",
":=",
"json",
".",
"Unmarshal",
"(",
"b",
",",
"&",
"r",
")",
";",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n",
"}",
"\n\n",
"return",
"&",
"r",
",",
"nil",
"\n",
"}"
] |
// Reset site to site vpn connection
|
[
"Reset",
"site",
"to",
"site",
"vpn",
"connection"
] |
b6f53ed3282d22b6446422879587b0a78e1b0f11
|
https://github.com/xanzy/go-cloudstack/blob/b6f53ed3282d22b6446422879587b0a78e1b0f11/cloudstack/VPNService.go#L2278-L2310
|
145,348 |
xanzy/go-cloudstack
|
cloudstack/VPNService.go
|
NewUpdateRemoteAccessVpnParams
|
func (s *VPNService) NewUpdateRemoteAccessVpnParams(id string) *UpdateRemoteAccessVpnParams {
p := &UpdateRemoteAccessVpnParams{}
p.p = make(map[string]interface{})
p.p["id"] = id
return p
}
|
go
|
func (s *VPNService) NewUpdateRemoteAccessVpnParams(id string) *UpdateRemoteAccessVpnParams {
p := &UpdateRemoteAccessVpnParams{}
p.p = make(map[string]interface{})
p.p["id"] = id
return p
}
|
[
"func",
"(",
"s",
"*",
"VPNService",
")",
"NewUpdateRemoteAccessVpnParams",
"(",
"id",
"string",
")",
"*",
"UpdateRemoteAccessVpnParams",
"{",
"p",
":=",
"&",
"UpdateRemoteAccessVpnParams",
"{",
"}",
"\n",
"p",
".",
"p",
"=",
"make",
"(",
"map",
"[",
"string",
"]",
"interface",
"{",
"}",
")",
"\n",
"p",
".",
"p",
"[",
"\"",
"\"",
"]",
"=",
"id",
"\n",
"return",
"p",
"\n",
"}"
] |
// You should always use this function to get a new UpdateRemoteAccessVpnParams instance,
// as then you are sure you have configured all required params
|
[
"You",
"should",
"always",
"use",
"this",
"function",
"to",
"get",
"a",
"new",
"UpdateRemoteAccessVpnParams",
"instance",
"as",
"then",
"you",
"are",
"sure",
"you",
"have",
"configured",
"all",
"required",
"params"
] |
b6f53ed3282d22b6446422879587b0a78e1b0f11
|
https://github.com/xanzy/go-cloudstack/blob/b6f53ed3282d22b6446422879587b0a78e1b0f11/cloudstack/VPNService.go#L2387-L2392
|
145,349 |
xanzy/go-cloudstack
|
cloudstack/VPNService.go
|
UpdateRemoteAccessVpn
|
func (s *VPNService) UpdateRemoteAccessVpn(p *UpdateRemoteAccessVpnParams) (*UpdateRemoteAccessVpnResponse, error) {
resp, err := s.cs.newRequest("updateRemoteAccessVpn", p.toURLValues())
if err != nil {
return nil, err
}
var r UpdateRemoteAccessVpnResponse
if err := json.Unmarshal(resp, &r); err != nil {
return nil, err
}
// If we have a async client, we need to wait for the async result
if s.cs.async {
b, err := s.cs.GetAsyncJobResult(r.JobID, s.cs.timeout)
if err != nil {
if err == AsyncTimeoutErr {
return &r, err
}
return nil, err
}
b, err = getRawValue(b)
if err != nil {
return nil, err
}
if err := json.Unmarshal(b, &r); err != nil {
return nil, err
}
}
return &r, nil
}
|
go
|
func (s *VPNService) UpdateRemoteAccessVpn(p *UpdateRemoteAccessVpnParams) (*UpdateRemoteAccessVpnResponse, error) {
resp, err := s.cs.newRequest("updateRemoteAccessVpn", p.toURLValues())
if err != nil {
return nil, err
}
var r UpdateRemoteAccessVpnResponse
if err := json.Unmarshal(resp, &r); err != nil {
return nil, err
}
// If we have a async client, we need to wait for the async result
if s.cs.async {
b, err := s.cs.GetAsyncJobResult(r.JobID, s.cs.timeout)
if err != nil {
if err == AsyncTimeoutErr {
return &r, err
}
return nil, err
}
b, err = getRawValue(b)
if err != nil {
return nil, err
}
if err := json.Unmarshal(b, &r); err != nil {
return nil, err
}
}
return &r, nil
}
|
[
"func",
"(",
"s",
"*",
"VPNService",
")",
"UpdateRemoteAccessVpn",
"(",
"p",
"*",
"UpdateRemoteAccessVpnParams",
")",
"(",
"*",
"UpdateRemoteAccessVpnResponse",
",",
"error",
")",
"{",
"resp",
",",
"err",
":=",
"s",
".",
"cs",
".",
"newRequest",
"(",
"\"",
"\"",
",",
"p",
".",
"toURLValues",
"(",
")",
")",
"\n",
"if",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"var",
"r",
"UpdateRemoteAccessVpnResponse",
"\n",
"if",
"err",
":=",
"json",
".",
"Unmarshal",
"(",
"resp",
",",
"&",
"r",
")",
";",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"// If we have a async client, we need to wait for the async result",
"if",
"s",
".",
"cs",
".",
"async",
"{",
"b",
",",
"err",
":=",
"s",
".",
"cs",
".",
"GetAsyncJobResult",
"(",
"r",
".",
"JobID",
",",
"s",
".",
"cs",
".",
"timeout",
")",
"\n",
"if",
"err",
"!=",
"nil",
"{",
"if",
"err",
"==",
"AsyncTimeoutErr",
"{",
"return",
"&",
"r",
",",
"err",
"\n",
"}",
"\n",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"b",
",",
"err",
"=",
"getRawValue",
"(",
"b",
")",
"\n",
"if",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"if",
"err",
":=",
"json",
".",
"Unmarshal",
"(",
"b",
",",
"&",
"r",
")",
";",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n",
"}",
"\n\n",
"return",
"&",
"r",
",",
"nil",
"\n",
"}"
] |
// Updates remote access vpn
|
[
"Updates",
"remote",
"access",
"vpn"
] |
b6f53ed3282d22b6446422879587b0a78e1b0f11
|
https://github.com/xanzy/go-cloudstack/blob/b6f53ed3282d22b6446422879587b0a78e1b0f11/cloudstack/VPNService.go#L2395-L2427
|
145,350 |
xanzy/go-cloudstack
|
cloudstack/VPNService.go
|
NewUpdateVpnConnectionParams
|
func (s *VPNService) NewUpdateVpnConnectionParams(id string) *UpdateVpnConnectionParams {
p := &UpdateVpnConnectionParams{}
p.p = make(map[string]interface{})
p.p["id"] = id
return p
}
|
go
|
func (s *VPNService) NewUpdateVpnConnectionParams(id string) *UpdateVpnConnectionParams {
p := &UpdateVpnConnectionParams{}
p.p = make(map[string]interface{})
p.p["id"] = id
return p
}
|
[
"func",
"(",
"s",
"*",
"VPNService",
")",
"NewUpdateVpnConnectionParams",
"(",
"id",
"string",
")",
"*",
"UpdateVpnConnectionParams",
"{",
"p",
":=",
"&",
"UpdateVpnConnectionParams",
"{",
"}",
"\n",
"p",
".",
"p",
"=",
"make",
"(",
"map",
"[",
"string",
"]",
"interface",
"{",
"}",
")",
"\n",
"p",
".",
"p",
"[",
"\"",
"\"",
"]",
"=",
"id",
"\n",
"return",
"p",
"\n",
"}"
] |
// You should always use this function to get a new UpdateVpnConnectionParams instance,
// as then you are sure you have configured all required params
|
[
"You",
"should",
"always",
"use",
"this",
"function",
"to",
"get",
"a",
"new",
"UpdateVpnConnectionParams",
"instance",
"as",
"then",
"you",
"are",
"sure",
"you",
"have",
"configured",
"all",
"required",
"params"
] |
b6f53ed3282d22b6446422879587b0a78e1b0f11
|
https://github.com/xanzy/go-cloudstack/blob/b6f53ed3282d22b6446422879587b0a78e1b0f11/cloudstack/VPNService.go#L2493-L2498
|
145,351 |
xanzy/go-cloudstack
|
cloudstack/VPNService.go
|
UpdateVpnConnection
|
func (s *VPNService) UpdateVpnConnection(p *UpdateVpnConnectionParams) (*UpdateVpnConnectionResponse, error) {
resp, err := s.cs.newRequest("updateVpnConnection", p.toURLValues())
if err != nil {
return nil, err
}
var r UpdateVpnConnectionResponse
if err := json.Unmarshal(resp, &r); err != nil {
return nil, err
}
// If we have a async client, we need to wait for the async result
if s.cs.async {
b, err := s.cs.GetAsyncJobResult(r.JobID, s.cs.timeout)
if err != nil {
if err == AsyncTimeoutErr {
return &r, err
}
return nil, err
}
b, err = getRawValue(b)
if err != nil {
return nil, err
}
if err := json.Unmarshal(b, &r); err != nil {
return nil, err
}
}
return &r, nil
}
|
go
|
func (s *VPNService) UpdateVpnConnection(p *UpdateVpnConnectionParams) (*UpdateVpnConnectionResponse, error) {
resp, err := s.cs.newRequest("updateVpnConnection", p.toURLValues())
if err != nil {
return nil, err
}
var r UpdateVpnConnectionResponse
if err := json.Unmarshal(resp, &r); err != nil {
return nil, err
}
// If we have a async client, we need to wait for the async result
if s.cs.async {
b, err := s.cs.GetAsyncJobResult(r.JobID, s.cs.timeout)
if err != nil {
if err == AsyncTimeoutErr {
return &r, err
}
return nil, err
}
b, err = getRawValue(b)
if err != nil {
return nil, err
}
if err := json.Unmarshal(b, &r); err != nil {
return nil, err
}
}
return &r, nil
}
|
[
"func",
"(",
"s",
"*",
"VPNService",
")",
"UpdateVpnConnection",
"(",
"p",
"*",
"UpdateVpnConnectionParams",
")",
"(",
"*",
"UpdateVpnConnectionResponse",
",",
"error",
")",
"{",
"resp",
",",
"err",
":=",
"s",
".",
"cs",
".",
"newRequest",
"(",
"\"",
"\"",
",",
"p",
".",
"toURLValues",
"(",
")",
")",
"\n",
"if",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"var",
"r",
"UpdateVpnConnectionResponse",
"\n",
"if",
"err",
":=",
"json",
".",
"Unmarshal",
"(",
"resp",
",",
"&",
"r",
")",
";",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"// If we have a async client, we need to wait for the async result",
"if",
"s",
".",
"cs",
".",
"async",
"{",
"b",
",",
"err",
":=",
"s",
".",
"cs",
".",
"GetAsyncJobResult",
"(",
"r",
".",
"JobID",
",",
"s",
".",
"cs",
".",
"timeout",
")",
"\n",
"if",
"err",
"!=",
"nil",
"{",
"if",
"err",
"==",
"AsyncTimeoutErr",
"{",
"return",
"&",
"r",
",",
"err",
"\n",
"}",
"\n",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"b",
",",
"err",
"=",
"getRawValue",
"(",
"b",
")",
"\n",
"if",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"if",
"err",
":=",
"json",
".",
"Unmarshal",
"(",
"b",
",",
"&",
"r",
")",
";",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n",
"}",
"\n\n",
"return",
"&",
"r",
",",
"nil",
"\n",
"}"
] |
// Updates site to site vpn connection
|
[
"Updates",
"site",
"to",
"site",
"vpn",
"connection"
] |
b6f53ed3282d22b6446422879587b0a78e1b0f11
|
https://github.com/xanzy/go-cloudstack/blob/b6f53ed3282d22b6446422879587b0a78e1b0f11/cloudstack/VPNService.go#L2501-L2533
|
145,352 |
xanzy/go-cloudstack
|
cloudstack/VPNService.go
|
NewUpdateVpnCustomerGatewayParams
|
func (s *VPNService) NewUpdateVpnCustomerGatewayParams(cidrlist string, esppolicy string, gateway string, id string, ikepolicy string, ipsecpsk string) *UpdateVpnCustomerGatewayParams {
p := &UpdateVpnCustomerGatewayParams{}
p.p = make(map[string]interface{})
p.p["cidrlist"] = cidrlist
p.p["esppolicy"] = esppolicy
p.p["gateway"] = gateway
p.p["id"] = id
p.p["ikepolicy"] = ikepolicy
p.p["ipsecpsk"] = ipsecpsk
return p
}
|
go
|
func (s *VPNService) NewUpdateVpnCustomerGatewayParams(cidrlist string, esppolicy string, gateway string, id string, ikepolicy string, ipsecpsk string) *UpdateVpnCustomerGatewayParams {
p := &UpdateVpnCustomerGatewayParams{}
p.p = make(map[string]interface{})
p.p["cidrlist"] = cidrlist
p.p["esppolicy"] = esppolicy
p.p["gateway"] = gateway
p.p["id"] = id
p.p["ikepolicy"] = ikepolicy
p.p["ipsecpsk"] = ipsecpsk
return p
}
|
[
"func",
"(",
"s",
"*",
"VPNService",
")",
"NewUpdateVpnCustomerGatewayParams",
"(",
"cidrlist",
"string",
",",
"esppolicy",
"string",
",",
"gateway",
"string",
",",
"id",
"string",
",",
"ikepolicy",
"string",
",",
"ipsecpsk",
"string",
")",
"*",
"UpdateVpnCustomerGatewayParams",
"{",
"p",
":=",
"&",
"UpdateVpnCustomerGatewayParams",
"{",
"}",
"\n",
"p",
".",
"p",
"=",
"make",
"(",
"map",
"[",
"string",
"]",
"interface",
"{",
"}",
")",
"\n",
"p",
".",
"p",
"[",
"\"",
"\"",
"]",
"=",
"cidrlist",
"\n",
"p",
".",
"p",
"[",
"\"",
"\"",
"]",
"=",
"esppolicy",
"\n",
"p",
".",
"p",
"[",
"\"",
"\"",
"]",
"=",
"gateway",
"\n",
"p",
".",
"p",
"[",
"\"",
"\"",
"]",
"=",
"id",
"\n",
"p",
".",
"p",
"[",
"\"",
"\"",
"]",
"=",
"ikepolicy",
"\n",
"p",
".",
"p",
"[",
"\"",
"\"",
"]",
"=",
"ipsecpsk",
"\n",
"return",
"p",
"\n",
"}"
] |
// You should always use this function to get a new UpdateVpnCustomerGatewayParams instance,
// as then you are sure you have configured all required params
|
[
"You",
"should",
"always",
"use",
"this",
"function",
"to",
"get",
"a",
"new",
"UpdateVpnCustomerGatewayParams",
"instance",
"as",
"then",
"you",
"are",
"sure",
"you",
"have",
"configured",
"all",
"required",
"params"
] |
b6f53ed3282d22b6446422879587b0a78e1b0f11
|
https://github.com/xanzy/go-cloudstack/blob/b6f53ed3282d22b6446422879587b0a78e1b0f11/cloudstack/VPNService.go#L2723-L2733
|
145,353 |
xanzy/go-cloudstack
|
cloudstack/VPNService.go
|
UpdateVpnCustomerGateway
|
func (s *VPNService) UpdateVpnCustomerGateway(p *UpdateVpnCustomerGatewayParams) (*UpdateVpnCustomerGatewayResponse, error) {
resp, err := s.cs.newRequest("updateVpnCustomerGateway", p.toURLValues())
if err != nil {
return nil, err
}
var r UpdateVpnCustomerGatewayResponse
if err := json.Unmarshal(resp, &r); err != nil {
return nil, err
}
// If we have a async client, we need to wait for the async result
if s.cs.async {
b, err := s.cs.GetAsyncJobResult(r.JobID, s.cs.timeout)
if err != nil {
if err == AsyncTimeoutErr {
return &r, err
}
return nil, err
}
b, err = getRawValue(b)
if err != nil {
return nil, err
}
if err := json.Unmarshal(b, &r); err != nil {
return nil, err
}
}
return &r, nil
}
|
go
|
func (s *VPNService) UpdateVpnCustomerGateway(p *UpdateVpnCustomerGatewayParams) (*UpdateVpnCustomerGatewayResponse, error) {
resp, err := s.cs.newRequest("updateVpnCustomerGateway", p.toURLValues())
if err != nil {
return nil, err
}
var r UpdateVpnCustomerGatewayResponse
if err := json.Unmarshal(resp, &r); err != nil {
return nil, err
}
// If we have a async client, we need to wait for the async result
if s.cs.async {
b, err := s.cs.GetAsyncJobResult(r.JobID, s.cs.timeout)
if err != nil {
if err == AsyncTimeoutErr {
return &r, err
}
return nil, err
}
b, err = getRawValue(b)
if err != nil {
return nil, err
}
if err := json.Unmarshal(b, &r); err != nil {
return nil, err
}
}
return &r, nil
}
|
[
"func",
"(",
"s",
"*",
"VPNService",
")",
"UpdateVpnCustomerGateway",
"(",
"p",
"*",
"UpdateVpnCustomerGatewayParams",
")",
"(",
"*",
"UpdateVpnCustomerGatewayResponse",
",",
"error",
")",
"{",
"resp",
",",
"err",
":=",
"s",
".",
"cs",
".",
"newRequest",
"(",
"\"",
"\"",
",",
"p",
".",
"toURLValues",
"(",
")",
")",
"\n",
"if",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"var",
"r",
"UpdateVpnCustomerGatewayResponse",
"\n",
"if",
"err",
":=",
"json",
".",
"Unmarshal",
"(",
"resp",
",",
"&",
"r",
")",
";",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"// If we have a async client, we need to wait for the async result",
"if",
"s",
".",
"cs",
".",
"async",
"{",
"b",
",",
"err",
":=",
"s",
".",
"cs",
".",
"GetAsyncJobResult",
"(",
"r",
".",
"JobID",
",",
"s",
".",
"cs",
".",
"timeout",
")",
"\n",
"if",
"err",
"!=",
"nil",
"{",
"if",
"err",
"==",
"AsyncTimeoutErr",
"{",
"return",
"&",
"r",
",",
"err",
"\n",
"}",
"\n",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"b",
",",
"err",
"=",
"getRawValue",
"(",
"b",
")",
"\n",
"if",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"if",
"err",
":=",
"json",
".",
"Unmarshal",
"(",
"b",
",",
"&",
"r",
")",
";",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n",
"}",
"\n\n",
"return",
"&",
"r",
",",
"nil",
"\n",
"}"
] |
// Update site to site vpn customer gateway
|
[
"Update",
"site",
"to",
"site",
"vpn",
"customer",
"gateway"
] |
b6f53ed3282d22b6446422879587b0a78e1b0f11
|
https://github.com/xanzy/go-cloudstack/blob/b6f53ed3282d22b6446422879587b0a78e1b0f11/cloudstack/VPNService.go#L2736-L2768
|
145,354 |
xanzy/go-cloudstack
|
cloudstack/VPNService.go
|
NewUpdateVpnGatewayParams
|
func (s *VPNService) NewUpdateVpnGatewayParams(id string) *UpdateVpnGatewayParams {
p := &UpdateVpnGatewayParams{}
p.p = make(map[string]interface{})
p.p["id"] = id
return p
}
|
go
|
func (s *VPNService) NewUpdateVpnGatewayParams(id string) *UpdateVpnGatewayParams {
p := &UpdateVpnGatewayParams{}
p.p = make(map[string]interface{})
p.p["id"] = id
return p
}
|
[
"func",
"(",
"s",
"*",
"VPNService",
")",
"NewUpdateVpnGatewayParams",
"(",
"id",
"string",
")",
"*",
"UpdateVpnGatewayParams",
"{",
"p",
":=",
"&",
"UpdateVpnGatewayParams",
"{",
"}",
"\n",
"p",
".",
"p",
"=",
"make",
"(",
"map",
"[",
"string",
"]",
"interface",
"{",
"}",
")",
"\n",
"p",
".",
"p",
"[",
"\"",
"\"",
"]",
"=",
"id",
"\n",
"return",
"p",
"\n",
"}"
] |
// You should always use this function to get a new UpdateVpnGatewayParams instance,
// as then you are sure you have configured all required params
|
[
"You",
"should",
"always",
"use",
"this",
"function",
"to",
"get",
"a",
"new",
"UpdateVpnGatewayParams",
"instance",
"as",
"then",
"you",
"are",
"sure",
"you",
"have",
"configured",
"all",
"required",
"params"
] |
b6f53ed3282d22b6446422879587b0a78e1b0f11
|
https://github.com/xanzy/go-cloudstack/blob/b6f53ed3282d22b6446422879587b0a78e1b0f11/cloudstack/VPNService.go#L2840-L2845
|
145,355 |
xanzy/go-cloudstack
|
cloudstack/VPNService.go
|
UpdateVpnGateway
|
func (s *VPNService) UpdateVpnGateway(p *UpdateVpnGatewayParams) (*UpdateVpnGatewayResponse, error) {
resp, err := s.cs.newRequest("updateVpnGateway", p.toURLValues())
if err != nil {
return nil, err
}
var r UpdateVpnGatewayResponse
if err := json.Unmarshal(resp, &r); err != nil {
return nil, err
}
// If we have a async client, we need to wait for the async result
if s.cs.async {
b, err := s.cs.GetAsyncJobResult(r.JobID, s.cs.timeout)
if err != nil {
if err == AsyncTimeoutErr {
return &r, err
}
return nil, err
}
b, err = getRawValue(b)
if err != nil {
return nil, err
}
if err := json.Unmarshal(b, &r); err != nil {
return nil, err
}
}
return &r, nil
}
|
go
|
func (s *VPNService) UpdateVpnGateway(p *UpdateVpnGatewayParams) (*UpdateVpnGatewayResponse, error) {
resp, err := s.cs.newRequest("updateVpnGateway", p.toURLValues())
if err != nil {
return nil, err
}
var r UpdateVpnGatewayResponse
if err := json.Unmarshal(resp, &r); err != nil {
return nil, err
}
// If we have a async client, we need to wait for the async result
if s.cs.async {
b, err := s.cs.GetAsyncJobResult(r.JobID, s.cs.timeout)
if err != nil {
if err == AsyncTimeoutErr {
return &r, err
}
return nil, err
}
b, err = getRawValue(b)
if err != nil {
return nil, err
}
if err := json.Unmarshal(b, &r); err != nil {
return nil, err
}
}
return &r, nil
}
|
[
"func",
"(",
"s",
"*",
"VPNService",
")",
"UpdateVpnGateway",
"(",
"p",
"*",
"UpdateVpnGatewayParams",
")",
"(",
"*",
"UpdateVpnGatewayResponse",
",",
"error",
")",
"{",
"resp",
",",
"err",
":=",
"s",
".",
"cs",
".",
"newRequest",
"(",
"\"",
"\"",
",",
"p",
".",
"toURLValues",
"(",
")",
")",
"\n",
"if",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"var",
"r",
"UpdateVpnGatewayResponse",
"\n",
"if",
"err",
":=",
"json",
".",
"Unmarshal",
"(",
"resp",
",",
"&",
"r",
")",
";",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"// If we have a async client, we need to wait for the async result",
"if",
"s",
".",
"cs",
".",
"async",
"{",
"b",
",",
"err",
":=",
"s",
".",
"cs",
".",
"GetAsyncJobResult",
"(",
"r",
".",
"JobID",
",",
"s",
".",
"cs",
".",
"timeout",
")",
"\n",
"if",
"err",
"!=",
"nil",
"{",
"if",
"err",
"==",
"AsyncTimeoutErr",
"{",
"return",
"&",
"r",
",",
"err",
"\n",
"}",
"\n",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"b",
",",
"err",
"=",
"getRawValue",
"(",
"b",
")",
"\n",
"if",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"if",
"err",
":=",
"json",
".",
"Unmarshal",
"(",
"b",
",",
"&",
"r",
")",
";",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n",
"}",
"\n\n",
"return",
"&",
"r",
",",
"nil",
"\n",
"}"
] |
// Updates site to site vpn local gateway
|
[
"Updates",
"site",
"to",
"site",
"vpn",
"local",
"gateway"
] |
b6f53ed3282d22b6446422879587b0a78e1b0f11
|
https://github.com/xanzy/go-cloudstack/blob/b6f53ed3282d22b6446422879587b0a78e1b0f11/cloudstack/VPNService.go#L2848-L2880
|
145,356 |
xanzy/go-cloudstack
|
cloudstack/PodService.go
|
NewCreatePodParams
|
func (s *PodService) NewCreatePodParams(gateway string, name string, netmask string, startip string, zoneid string) *CreatePodParams {
p := &CreatePodParams{}
p.p = make(map[string]interface{})
p.p["gateway"] = gateway
p.p["name"] = name
p.p["netmask"] = netmask
p.p["startip"] = startip
p.p["zoneid"] = zoneid
return p
}
|
go
|
func (s *PodService) NewCreatePodParams(gateway string, name string, netmask string, startip string, zoneid string) *CreatePodParams {
p := &CreatePodParams{}
p.p = make(map[string]interface{})
p.p["gateway"] = gateway
p.p["name"] = name
p.p["netmask"] = netmask
p.p["startip"] = startip
p.p["zoneid"] = zoneid
return p
}
|
[
"func",
"(",
"s",
"*",
"PodService",
")",
"NewCreatePodParams",
"(",
"gateway",
"string",
",",
"name",
"string",
",",
"netmask",
"string",
",",
"startip",
"string",
",",
"zoneid",
"string",
")",
"*",
"CreatePodParams",
"{",
"p",
":=",
"&",
"CreatePodParams",
"{",
"}",
"\n",
"p",
".",
"p",
"=",
"make",
"(",
"map",
"[",
"string",
"]",
"interface",
"{",
"}",
")",
"\n",
"p",
".",
"p",
"[",
"\"",
"\"",
"]",
"=",
"gateway",
"\n",
"p",
".",
"p",
"[",
"\"",
"\"",
"]",
"=",
"name",
"\n",
"p",
".",
"p",
"[",
"\"",
"\"",
"]",
"=",
"netmask",
"\n",
"p",
".",
"p",
"[",
"\"",
"\"",
"]",
"=",
"startip",
"\n",
"p",
".",
"p",
"[",
"\"",
"\"",
"]",
"=",
"zoneid",
"\n",
"return",
"p",
"\n",
"}"
] |
// You should always use this function to get a new CreatePodParams instance,
// as then you are sure you have configured all required params
|
[
"You",
"should",
"always",
"use",
"this",
"function",
"to",
"get",
"a",
"new",
"CreatePodParams",
"instance",
"as",
"then",
"you",
"are",
"sure",
"you",
"have",
"configured",
"all",
"required",
"params"
] |
b6f53ed3282d22b6446422879587b0a78e1b0f11
|
https://github.com/xanzy/go-cloudstack/blob/b6f53ed3282d22b6446422879587b0a78e1b0f11/cloudstack/PodService.go#L118-L127
|
145,357 |
xanzy/go-cloudstack
|
cloudstack/PodService.go
|
NewDedicatePodParams
|
func (s *PodService) NewDedicatePodParams(domainid string, podid string) *DedicatePodParams {
p := &DedicatePodParams{}
p.p = make(map[string]interface{})
p.p["domainid"] = domainid
p.p["podid"] = podid
return p
}
|
go
|
func (s *PodService) NewDedicatePodParams(domainid string, podid string) *DedicatePodParams {
p := &DedicatePodParams{}
p.p = make(map[string]interface{})
p.p["domainid"] = domainid
p.p["podid"] = podid
return p
}
|
[
"func",
"(",
"s",
"*",
"PodService",
")",
"NewDedicatePodParams",
"(",
"domainid",
"string",
",",
"podid",
"string",
")",
"*",
"DedicatePodParams",
"{",
"p",
":=",
"&",
"DedicatePodParams",
"{",
"}",
"\n",
"p",
".",
"p",
"=",
"make",
"(",
"map",
"[",
"string",
"]",
"interface",
"{",
"}",
")",
"\n",
"p",
".",
"p",
"[",
"\"",
"\"",
"]",
"=",
"domainid",
"\n",
"p",
".",
"p",
"[",
"\"",
"\"",
"]",
"=",
"podid",
"\n",
"return",
"p",
"\n",
"}"
] |
// You should always use this function to get a new DedicatePodParams instance,
// as then you are sure you have configured all required params
|
[
"You",
"should",
"always",
"use",
"this",
"function",
"to",
"get",
"a",
"new",
"DedicatePodParams",
"instance",
"as",
"then",
"you",
"are",
"sure",
"you",
"have",
"configured",
"all",
"required",
"params"
] |
b6f53ed3282d22b6446422879587b0a78e1b0f11
|
https://github.com/xanzy/go-cloudstack/blob/b6f53ed3282d22b6446422879587b0a78e1b0f11/cloudstack/PodService.go#L221-L227
|
145,358 |
xanzy/go-cloudstack
|
cloudstack/PodService.go
|
NewDeletePodParams
|
func (s *PodService) NewDeletePodParams(id string) *DeletePodParams {
p := &DeletePodParams{}
p.p = make(map[string]interface{})
p.p["id"] = id
return p
}
|
go
|
func (s *PodService) NewDeletePodParams(id string) *DeletePodParams {
p := &DeletePodParams{}
p.p = make(map[string]interface{})
p.p["id"] = id
return p
}
|
[
"func",
"(",
"s",
"*",
"PodService",
")",
"NewDeletePodParams",
"(",
"id",
"string",
")",
"*",
"DeletePodParams",
"{",
"p",
":=",
"&",
"DeletePodParams",
"{",
"}",
"\n",
"p",
".",
"p",
"=",
"make",
"(",
"map",
"[",
"string",
"]",
"interface",
"{",
"}",
")",
"\n",
"p",
".",
"p",
"[",
"\"",
"\"",
"]",
"=",
"id",
"\n",
"return",
"p",
"\n",
"}"
] |
// You should always use this function to get a new DeletePodParams instance,
// as then you are sure you have configured all required params
|
[
"You",
"should",
"always",
"use",
"this",
"function",
"to",
"get",
"a",
"new",
"DeletePodParams",
"instance",
"as",
"then",
"you",
"are",
"sure",
"you",
"have",
"configured",
"all",
"required",
"params"
] |
b6f53ed3282d22b6446422879587b0a78e1b0f11
|
https://github.com/xanzy/go-cloudstack/blob/b6f53ed3282d22b6446422879587b0a78e1b0f11/cloudstack/PodService.go#L299-L304
|
145,359 |
xanzy/go-cloudstack
|
cloudstack/PodService.go
|
NewListDedicatedPodsParams
|
func (s *PodService) NewListDedicatedPodsParams() *ListDedicatedPodsParams {
p := &ListDedicatedPodsParams{}
p.p = make(map[string]interface{})
return p
}
|
go
|
func (s *PodService) NewListDedicatedPodsParams() *ListDedicatedPodsParams {
p := &ListDedicatedPodsParams{}
p.p = make(map[string]interface{})
return p
}
|
[
"func",
"(",
"s",
"*",
"PodService",
")",
"NewListDedicatedPodsParams",
"(",
")",
"*",
"ListDedicatedPodsParams",
"{",
"p",
":=",
"&",
"ListDedicatedPodsParams",
"{",
"}",
"\n",
"p",
".",
"p",
"=",
"make",
"(",
"map",
"[",
"string",
"]",
"interface",
"{",
"}",
")",
"\n",
"return",
"p",
"\n",
"}"
] |
// You should always use this function to get a new ListDedicatedPodsParams instance,
// as then you are sure you have configured all required params
|
[
"You",
"should",
"always",
"use",
"this",
"function",
"to",
"get",
"a",
"new",
"ListDedicatedPodsParams",
"instance",
"as",
"then",
"you",
"are",
"sure",
"you",
"have",
"configured",
"all",
"required",
"params"
] |
b6f53ed3282d22b6446422879587b0a78e1b0f11
|
https://github.com/xanzy/go-cloudstack/blob/b6f53ed3282d22b6446422879587b0a78e1b0f11/cloudstack/PodService.go#L438-L442
|
145,360 |
xanzy/go-cloudstack
|
cloudstack/PodService.go
|
NewListPodsParams
|
func (s *PodService) NewListPodsParams() *ListPodsParams {
p := &ListPodsParams{}
p.p = make(map[string]interface{})
return p
}
|
go
|
func (s *PodService) NewListPodsParams() *ListPodsParams {
p := &ListPodsParams{}
p.p = make(map[string]interface{})
return p
}
|
[
"func",
"(",
"s",
"*",
"PodService",
")",
"NewListPodsParams",
"(",
")",
"*",
"ListPodsParams",
"{",
"p",
":=",
"&",
"ListPodsParams",
"{",
"}",
"\n",
"p",
".",
"p",
"=",
"make",
"(",
"map",
"[",
"string",
"]",
"interface",
"{",
"}",
")",
"\n",
"return",
"p",
"\n",
"}"
] |
// You should always use this function to get a new ListPodsParams instance,
// as then you are sure you have configured all required params
|
[
"You",
"should",
"always",
"use",
"this",
"function",
"to",
"get",
"a",
"new",
"ListPodsParams",
"instance",
"as",
"then",
"you",
"are",
"sure",
"you",
"have",
"configured",
"all",
"required",
"params"
] |
b6f53ed3282d22b6446422879587b0a78e1b0f11
|
https://github.com/xanzy/go-cloudstack/blob/b6f53ed3282d22b6446422879587b0a78e1b0f11/cloudstack/PodService.go#L578-L582
|
145,361 |
xanzy/go-cloudstack
|
cloudstack/PodService.go
|
NewReleaseDedicatedPodParams
|
func (s *PodService) NewReleaseDedicatedPodParams(podid string) *ReleaseDedicatedPodParams {
p := &ReleaseDedicatedPodParams{}
p.p = make(map[string]interface{})
p.p["podid"] = podid
return p
}
|
go
|
func (s *PodService) NewReleaseDedicatedPodParams(podid string) *ReleaseDedicatedPodParams {
p := &ReleaseDedicatedPodParams{}
p.p = make(map[string]interface{})
p.p["podid"] = podid
return p
}
|
[
"func",
"(",
"s",
"*",
"PodService",
")",
"NewReleaseDedicatedPodParams",
"(",
"podid",
"string",
")",
"*",
"ReleaseDedicatedPodParams",
"{",
"p",
":=",
"&",
"ReleaseDedicatedPodParams",
"{",
"}",
"\n",
"p",
".",
"p",
"=",
"make",
"(",
"map",
"[",
"string",
"]",
"interface",
"{",
"}",
")",
"\n",
"p",
".",
"p",
"[",
"\"",
"\"",
"]",
"=",
"podid",
"\n",
"return",
"p",
"\n",
"}"
] |
// You should always use this function to get a new ReleaseDedicatedPodParams instance,
// as then you are sure you have configured all required params
|
[
"You",
"should",
"always",
"use",
"this",
"function",
"to",
"get",
"a",
"new",
"ReleaseDedicatedPodParams",
"instance",
"as",
"then",
"you",
"are",
"sure",
"you",
"have",
"configured",
"all",
"required",
"params"
] |
b6f53ed3282d22b6446422879587b0a78e1b0f11
|
https://github.com/xanzy/go-cloudstack/blob/b6f53ed3282d22b6446422879587b0a78e1b0f11/cloudstack/PodService.go#L742-L747
|
145,362 |
xanzy/go-cloudstack
|
cloudstack/PodService.go
|
NewUpdatePodParams
|
func (s *PodService) NewUpdatePodParams(id string) *UpdatePodParams {
p := &UpdatePodParams{}
p.p = make(map[string]interface{})
p.p["id"] = id
return p
}
|
go
|
func (s *PodService) NewUpdatePodParams(id string) *UpdatePodParams {
p := &UpdatePodParams{}
p.p = make(map[string]interface{})
p.p["id"] = id
return p
}
|
[
"func",
"(",
"s",
"*",
"PodService",
")",
"NewUpdatePodParams",
"(",
"id",
"string",
")",
"*",
"UpdatePodParams",
"{",
"p",
":=",
"&",
"UpdatePodParams",
"{",
"}",
"\n",
"p",
".",
"p",
"=",
"make",
"(",
"map",
"[",
"string",
"]",
"interface",
"{",
"}",
")",
"\n",
"p",
".",
"p",
"[",
"\"",
"\"",
"]",
"=",
"id",
"\n",
"return",
"p",
"\n",
"}"
] |
// You should always use this function to get a new UpdatePodParams instance,
// as then you are sure you have configured all required params
|
[
"You",
"should",
"always",
"use",
"this",
"function",
"to",
"get",
"a",
"new",
"UpdatePodParams",
"instance",
"as",
"then",
"you",
"are",
"sure",
"you",
"have",
"configured",
"all",
"required",
"params"
] |
b6f53ed3282d22b6446422879587b0a78e1b0f11
|
https://github.com/xanzy/go-cloudstack/blob/b6f53ed3282d22b6446422879587b0a78e1b0f11/cloudstack/PodService.go#L876-L881
|
145,363 |
xanzy/go-cloudstack
|
cloudstack/QuotaService.go
|
NewQuotaIsEnabledParams
|
func (s *QuotaService) NewQuotaIsEnabledParams() *QuotaIsEnabledParams {
p := &QuotaIsEnabledParams{}
p.p = make(map[string]interface{})
return p
}
|
go
|
func (s *QuotaService) NewQuotaIsEnabledParams() *QuotaIsEnabledParams {
p := &QuotaIsEnabledParams{}
p.p = make(map[string]interface{})
return p
}
|
[
"func",
"(",
"s",
"*",
"QuotaService",
")",
"NewQuotaIsEnabledParams",
"(",
")",
"*",
"QuotaIsEnabledParams",
"{",
"p",
":=",
"&",
"QuotaIsEnabledParams",
"{",
"}",
"\n",
"p",
".",
"p",
"=",
"make",
"(",
"map",
"[",
"string",
"]",
"interface",
"{",
"}",
")",
"\n",
"return",
"p",
"\n",
"}"
] |
// You should always use this function to get a new QuotaIsEnabledParams instance,
// as then you are sure you have configured all required params
|
[
"You",
"should",
"always",
"use",
"this",
"function",
"to",
"get",
"a",
"new",
"QuotaIsEnabledParams",
"instance",
"as",
"then",
"you",
"are",
"sure",
"you",
"have",
"configured",
"all",
"required",
"params"
] |
b6f53ed3282d22b6446422879587b0a78e1b0f11
|
https://github.com/xanzy/go-cloudstack/blob/b6f53ed3282d22b6446422879587b0a78e1b0f11/cloudstack/QuotaService.go#L38-L42
|
145,364 |
xanzy/go-cloudstack
|
cloudstack/QuotaService.go
|
QuotaIsEnabled
|
func (s *QuotaService) QuotaIsEnabled(p *QuotaIsEnabledParams) (*QuotaIsEnabledResponse, error) {
resp, err := s.cs.newRequest("quotaIsEnabled", p.toURLValues())
if err != nil {
return nil, err
}
var r QuotaIsEnabledResponse
if err := json.Unmarshal(resp, &r); err != nil {
return nil, err
}
return &r, nil
}
|
go
|
func (s *QuotaService) QuotaIsEnabled(p *QuotaIsEnabledParams) (*QuotaIsEnabledResponse, error) {
resp, err := s.cs.newRequest("quotaIsEnabled", p.toURLValues())
if err != nil {
return nil, err
}
var r QuotaIsEnabledResponse
if err := json.Unmarshal(resp, &r); err != nil {
return nil, err
}
return &r, nil
}
|
[
"func",
"(",
"s",
"*",
"QuotaService",
")",
"QuotaIsEnabled",
"(",
"p",
"*",
"QuotaIsEnabledParams",
")",
"(",
"*",
"QuotaIsEnabledResponse",
",",
"error",
")",
"{",
"resp",
",",
"err",
":=",
"s",
".",
"cs",
".",
"newRequest",
"(",
"\"",
"\"",
",",
"p",
".",
"toURLValues",
"(",
")",
")",
"\n",
"if",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"var",
"r",
"QuotaIsEnabledResponse",
"\n",
"if",
"err",
":=",
"json",
".",
"Unmarshal",
"(",
"resp",
",",
"&",
"r",
")",
";",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"return",
"&",
"r",
",",
"nil",
"\n",
"}"
] |
// Return true if the plugin is enabled
|
[
"Return",
"true",
"if",
"the",
"plugin",
"is",
"enabled"
] |
b6f53ed3282d22b6446422879587b0a78e1b0f11
|
https://github.com/xanzy/go-cloudstack/blob/b6f53ed3282d22b6446422879587b0a78e1b0f11/cloudstack/QuotaService.go#L45-L57
|
145,365 |
xanzy/go-cloudstack
|
cloudstack/AccountService.go
|
NewAddAccountToProjectParams
|
func (s *AccountService) NewAddAccountToProjectParams(projectid string) *AddAccountToProjectParams {
p := &AddAccountToProjectParams{}
p.p = make(map[string]interface{})
p.p["projectid"] = projectid
return p
}
|
go
|
func (s *AccountService) NewAddAccountToProjectParams(projectid string) *AddAccountToProjectParams {
p := &AddAccountToProjectParams{}
p.p = make(map[string]interface{})
p.p["projectid"] = projectid
return p
}
|
[
"func",
"(",
"s",
"*",
"AccountService",
")",
"NewAddAccountToProjectParams",
"(",
"projectid",
"string",
")",
"*",
"AddAccountToProjectParams",
"{",
"p",
":=",
"&",
"AddAccountToProjectParams",
"{",
"}",
"\n",
"p",
".",
"p",
"=",
"make",
"(",
"map",
"[",
"string",
"]",
"interface",
"{",
"}",
")",
"\n",
"p",
".",
"p",
"[",
"\"",
"\"",
"]",
"=",
"projectid",
"\n",
"return",
"p",
"\n",
"}"
] |
// You should always use this function to get a new AddAccountToProjectParams instance,
// as then you are sure you have configured all required params
|
[
"You",
"should",
"always",
"use",
"this",
"function",
"to",
"get",
"a",
"new",
"AddAccountToProjectParams",
"instance",
"as",
"then",
"you",
"are",
"sure",
"you",
"have",
"configured",
"all",
"required",
"params"
] |
b6f53ed3282d22b6446422879587b0a78e1b0f11
|
https://github.com/xanzy/go-cloudstack/blob/b6f53ed3282d22b6446422879587b0a78e1b0f11/cloudstack/AccountService.go#L74-L79
|
145,366 |
xanzy/go-cloudstack
|
cloudstack/AccountService.go
|
AddAccountToProject
|
func (s *AccountService) AddAccountToProject(p *AddAccountToProjectParams) (*AddAccountToProjectResponse, error) {
resp, err := s.cs.newRequest("addAccountToProject", p.toURLValues())
if err != nil {
return nil, err
}
var r AddAccountToProjectResponse
if err := json.Unmarshal(resp, &r); err != nil {
return nil, err
}
// If we have a async client, we need to wait for the async result
if s.cs.async {
b, err := s.cs.GetAsyncJobResult(r.JobID, s.cs.timeout)
if err != nil {
if err == AsyncTimeoutErr {
return &r, err
}
return nil, err
}
if err := json.Unmarshal(b, &r); err != nil {
return nil, err
}
}
return &r, nil
}
|
go
|
func (s *AccountService) AddAccountToProject(p *AddAccountToProjectParams) (*AddAccountToProjectResponse, error) {
resp, err := s.cs.newRequest("addAccountToProject", p.toURLValues())
if err != nil {
return nil, err
}
var r AddAccountToProjectResponse
if err := json.Unmarshal(resp, &r); err != nil {
return nil, err
}
// If we have a async client, we need to wait for the async result
if s.cs.async {
b, err := s.cs.GetAsyncJobResult(r.JobID, s.cs.timeout)
if err != nil {
if err == AsyncTimeoutErr {
return &r, err
}
return nil, err
}
if err := json.Unmarshal(b, &r); err != nil {
return nil, err
}
}
return &r, nil
}
|
[
"func",
"(",
"s",
"*",
"AccountService",
")",
"AddAccountToProject",
"(",
"p",
"*",
"AddAccountToProjectParams",
")",
"(",
"*",
"AddAccountToProjectResponse",
",",
"error",
")",
"{",
"resp",
",",
"err",
":=",
"s",
".",
"cs",
".",
"newRequest",
"(",
"\"",
"\"",
",",
"p",
".",
"toURLValues",
"(",
")",
")",
"\n",
"if",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"var",
"r",
"AddAccountToProjectResponse",
"\n",
"if",
"err",
":=",
"json",
".",
"Unmarshal",
"(",
"resp",
",",
"&",
"r",
")",
";",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"// If we have a async client, we need to wait for the async result",
"if",
"s",
".",
"cs",
".",
"async",
"{",
"b",
",",
"err",
":=",
"s",
".",
"cs",
".",
"GetAsyncJobResult",
"(",
"r",
".",
"JobID",
",",
"s",
".",
"cs",
".",
"timeout",
")",
"\n",
"if",
"err",
"!=",
"nil",
"{",
"if",
"err",
"==",
"AsyncTimeoutErr",
"{",
"return",
"&",
"r",
",",
"err",
"\n",
"}",
"\n",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"if",
"err",
":=",
"json",
".",
"Unmarshal",
"(",
"b",
",",
"&",
"r",
")",
";",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n",
"}",
"\n\n",
"return",
"&",
"r",
",",
"nil",
"\n",
"}"
] |
// Adds account to a project
|
[
"Adds",
"account",
"to",
"a",
"project"
] |
b6f53ed3282d22b6446422879587b0a78e1b0f11
|
https://github.com/xanzy/go-cloudstack/blob/b6f53ed3282d22b6446422879587b0a78e1b0f11/cloudstack/AccountService.go#L82-L109
|
145,367 |
xanzy/go-cloudstack
|
cloudstack/AccountService.go
|
NewCreateAccountParams
|
func (s *AccountService) NewCreateAccountParams(email string, firstname string, lastname string, password string, username string) *CreateAccountParams {
p := &CreateAccountParams{}
p.p = make(map[string]interface{})
p.p["email"] = email
p.p["firstname"] = firstname
p.p["lastname"] = lastname
p.p["password"] = password
p.p["username"] = username
return p
}
|
go
|
func (s *AccountService) NewCreateAccountParams(email string, firstname string, lastname string, password string, username string) *CreateAccountParams {
p := &CreateAccountParams{}
p.p = make(map[string]interface{})
p.p["email"] = email
p.p["firstname"] = firstname
p.p["lastname"] = lastname
p.p["password"] = password
p.p["username"] = username
return p
}
|
[
"func",
"(",
"s",
"*",
"AccountService",
")",
"NewCreateAccountParams",
"(",
"email",
"string",
",",
"firstname",
"string",
",",
"lastname",
"string",
",",
"password",
"string",
",",
"username",
"string",
")",
"*",
"CreateAccountParams",
"{",
"p",
":=",
"&",
"CreateAccountParams",
"{",
"}",
"\n",
"p",
".",
"p",
"=",
"make",
"(",
"map",
"[",
"string",
"]",
"interface",
"{",
"}",
")",
"\n",
"p",
".",
"p",
"[",
"\"",
"\"",
"]",
"=",
"email",
"\n",
"p",
".",
"p",
"[",
"\"",
"\"",
"]",
"=",
"firstname",
"\n",
"p",
".",
"p",
"[",
"\"",
"\"",
"]",
"=",
"lastname",
"\n",
"p",
".",
"p",
"[",
"\"",
"\"",
"]",
"=",
"password",
"\n",
"p",
".",
"p",
"[",
"\"",
"\"",
"]",
"=",
"username",
"\n",
"return",
"p",
"\n",
"}"
] |
// You should always use this function to get a new CreateAccountParams instance,
// as then you are sure you have configured all required params
|
[
"You",
"should",
"always",
"use",
"this",
"function",
"to",
"get",
"a",
"new",
"CreateAccountParams",
"instance",
"as",
"then",
"you",
"are",
"sure",
"you",
"have",
"configured",
"all",
"required",
"params"
] |
b6f53ed3282d22b6446422879587b0a78e1b0f11
|
https://github.com/xanzy/go-cloudstack/blob/b6f53ed3282d22b6446422879587b0a78e1b0f11/cloudstack/AccountService.go#L291-L300
|
145,368 |
xanzy/go-cloudstack
|
cloudstack/AccountService.go
|
NewDeleteAccountParams
|
func (s *AccountService) NewDeleteAccountParams(id string) *DeleteAccountParams {
p := &DeleteAccountParams{}
p.p = make(map[string]interface{})
p.p["id"] = id
return p
}
|
go
|
func (s *AccountService) NewDeleteAccountParams(id string) *DeleteAccountParams {
p := &DeleteAccountParams{}
p.p = make(map[string]interface{})
p.p["id"] = id
return p
}
|
[
"func",
"(",
"s",
"*",
"AccountService",
")",
"NewDeleteAccountParams",
"(",
"id",
"string",
")",
"*",
"DeleteAccountParams",
"{",
"p",
":=",
"&",
"DeleteAccountParams",
"{",
"}",
"\n",
"p",
".",
"p",
"=",
"make",
"(",
"map",
"[",
"string",
"]",
"interface",
"{",
"}",
")",
"\n",
"p",
".",
"p",
"[",
"\"",
"\"",
"]",
"=",
"id",
"\n",
"return",
"p",
"\n",
"}"
] |
// You should always use this function to get a new DeleteAccountParams instance,
// as then you are sure you have configured all required params
|
[
"You",
"should",
"always",
"use",
"this",
"function",
"to",
"get",
"a",
"new",
"DeleteAccountParams",
"instance",
"as",
"then",
"you",
"are",
"sure",
"you",
"have",
"configured",
"all",
"required",
"params"
] |
b6f53ed3282d22b6446422879587b0a78e1b0f11
|
https://github.com/xanzy/go-cloudstack/blob/b6f53ed3282d22b6446422879587b0a78e1b0f11/cloudstack/AccountService.go#L429-L434
|
145,369 |
xanzy/go-cloudstack
|
cloudstack/AccountService.go
|
NewDeleteAccountFromProjectParams
|
func (s *AccountService) NewDeleteAccountFromProjectParams(account string, projectid string) *DeleteAccountFromProjectParams {
p := &DeleteAccountFromProjectParams{}
p.p = make(map[string]interface{})
p.p["account"] = account
p.p["projectid"] = projectid
return p
}
|
go
|
func (s *AccountService) NewDeleteAccountFromProjectParams(account string, projectid string) *DeleteAccountFromProjectParams {
p := &DeleteAccountFromProjectParams{}
p.p = make(map[string]interface{})
p.p["account"] = account
p.p["projectid"] = projectid
return p
}
|
[
"func",
"(",
"s",
"*",
"AccountService",
")",
"NewDeleteAccountFromProjectParams",
"(",
"account",
"string",
",",
"projectid",
"string",
")",
"*",
"DeleteAccountFromProjectParams",
"{",
"p",
":=",
"&",
"DeleteAccountFromProjectParams",
"{",
"}",
"\n",
"p",
".",
"p",
"=",
"make",
"(",
"map",
"[",
"string",
"]",
"interface",
"{",
"}",
")",
"\n",
"p",
".",
"p",
"[",
"\"",
"\"",
"]",
"=",
"account",
"\n",
"p",
".",
"p",
"[",
"\"",
"\"",
"]",
"=",
"projectid",
"\n",
"return",
"p",
"\n",
"}"
] |
// You should always use this function to get a new DeleteAccountFromProjectParams instance,
// as then you are sure you have configured all required params
|
[
"You",
"should",
"always",
"use",
"this",
"function",
"to",
"get",
"a",
"new",
"DeleteAccountFromProjectParams",
"instance",
"as",
"then",
"you",
"are",
"sure",
"you",
"have",
"configured",
"all",
"required",
"params"
] |
b6f53ed3282d22b6446422879587b0a78e1b0f11
|
https://github.com/xanzy/go-cloudstack/blob/b6f53ed3282d22b6446422879587b0a78e1b0f11/cloudstack/AccountService.go#L508-L514
|
145,370 |
xanzy/go-cloudstack
|
cloudstack/AccountService.go
|
NewDisableAccountParams
|
func (s *AccountService) NewDisableAccountParams(lock bool) *DisableAccountParams {
p := &DisableAccountParams{}
p.p = make(map[string]interface{})
p.p["lock"] = lock
return p
}
|
go
|
func (s *AccountService) NewDisableAccountParams(lock bool) *DisableAccountParams {
p := &DisableAccountParams{}
p.p = make(map[string]interface{})
p.p["lock"] = lock
return p
}
|
[
"func",
"(",
"s",
"*",
"AccountService",
")",
"NewDisableAccountParams",
"(",
"lock",
"bool",
")",
"*",
"DisableAccountParams",
"{",
"p",
":=",
"&",
"DisableAccountParams",
"{",
"}",
"\n",
"p",
".",
"p",
"=",
"make",
"(",
"map",
"[",
"string",
"]",
"interface",
"{",
"}",
")",
"\n",
"p",
".",
"p",
"[",
"\"",
"\"",
"]",
"=",
"lock",
"\n",
"return",
"p",
"\n",
"}"
] |
// You should always use this function to get a new DisableAccountParams instance,
// as then you are sure you have configured all required params
|
[
"You",
"should",
"always",
"use",
"this",
"function",
"to",
"get",
"a",
"new",
"DisableAccountParams",
"instance",
"as",
"then",
"you",
"are",
"sure",
"you",
"have",
"configured",
"all",
"required",
"params"
] |
b6f53ed3282d22b6446422879587b0a78e1b0f11
|
https://github.com/xanzy/go-cloudstack/blob/b6f53ed3282d22b6446422879587b0a78e1b0f11/cloudstack/AccountService.go#L611-L616
|
145,371 |
xanzy/go-cloudstack
|
cloudstack/AccountService.go
|
NewEnableAccountParams
|
func (s *AccountService) NewEnableAccountParams() *EnableAccountParams {
p := &EnableAccountParams{}
p.p = make(map[string]interface{})
return p
}
|
go
|
func (s *AccountService) NewEnableAccountParams() *EnableAccountParams {
p := &EnableAccountParams{}
p.p = make(map[string]interface{})
return p
}
|
[
"func",
"(",
"s",
"*",
"AccountService",
")",
"NewEnableAccountParams",
"(",
")",
"*",
"EnableAccountParams",
"{",
"p",
":=",
"&",
"EnableAccountParams",
"{",
"}",
"\n",
"p",
".",
"p",
"=",
"make",
"(",
"map",
"[",
"string",
"]",
"interface",
"{",
"}",
")",
"\n",
"return",
"p",
"\n",
"}"
] |
// You should always use this function to get a new EnableAccountParams instance,
// as then you are sure you have configured all required params
|
[
"You",
"should",
"always",
"use",
"this",
"function",
"to",
"get",
"a",
"new",
"EnableAccountParams",
"instance",
"as",
"then",
"you",
"are",
"sure",
"you",
"have",
"configured",
"all",
"required",
"params"
] |
b6f53ed3282d22b6446422879587b0a78e1b0f11
|
https://github.com/xanzy/go-cloudstack/blob/b6f53ed3282d22b6446422879587b0a78e1b0f11/cloudstack/AccountService.go#L784-L788
|
145,372 |
xanzy/go-cloudstack
|
cloudstack/AccountService.go
|
NewGetSolidFireAccountIdParams
|
func (s *AccountService) NewGetSolidFireAccountIdParams(accountid string, storageid string) *GetSolidFireAccountIdParams {
p := &GetSolidFireAccountIdParams{}
p.p = make(map[string]interface{})
p.p["accountid"] = accountid
p.p["storageid"] = storageid
return p
}
|
go
|
func (s *AccountService) NewGetSolidFireAccountIdParams(accountid string, storageid string) *GetSolidFireAccountIdParams {
p := &GetSolidFireAccountIdParams{}
p.p = make(map[string]interface{})
p.p["accountid"] = accountid
p.p["storageid"] = storageid
return p
}
|
[
"func",
"(",
"s",
"*",
"AccountService",
")",
"NewGetSolidFireAccountIdParams",
"(",
"accountid",
"string",
",",
"storageid",
"string",
")",
"*",
"GetSolidFireAccountIdParams",
"{",
"p",
":=",
"&",
"GetSolidFireAccountIdParams",
"{",
"}",
"\n",
"p",
".",
"p",
"=",
"make",
"(",
"map",
"[",
"string",
"]",
"interface",
"{",
"}",
")",
"\n",
"p",
".",
"p",
"[",
"\"",
"\"",
"]",
"=",
"accountid",
"\n",
"p",
".",
"p",
"[",
"\"",
"\"",
"]",
"=",
"storageid",
"\n",
"return",
"p",
"\n",
"}"
] |
// You should always use this function to get a new GetSolidFireAccountIdParams instance,
// as then you are sure you have configured all required params
|
[
"You",
"should",
"always",
"use",
"this",
"function",
"to",
"get",
"a",
"new",
"GetSolidFireAccountIdParams",
"instance",
"as",
"then",
"you",
"are",
"sure",
"you",
"have",
"configured",
"all",
"required",
"params"
] |
b6f53ed3282d22b6446422879587b0a78e1b0f11
|
https://github.com/xanzy/go-cloudstack/blob/b6f53ed3282d22b6446422879587b0a78e1b0f11/cloudstack/AccountService.go#L924-L930
|
145,373 |
xanzy/go-cloudstack
|
cloudstack/AccountService.go
|
GetSolidFireAccountId
|
func (s *AccountService) GetSolidFireAccountId(p *GetSolidFireAccountIdParams) (*GetSolidFireAccountIdResponse, error) {
resp, err := s.cs.newRequest("getSolidFireAccountId", p.toURLValues())
if err != nil {
return nil, err
}
var r GetSolidFireAccountIdResponse
if err := json.Unmarshal(resp, &r); err != nil {
return nil, err
}
return &r, nil
}
|
go
|
func (s *AccountService) GetSolidFireAccountId(p *GetSolidFireAccountIdParams) (*GetSolidFireAccountIdResponse, error) {
resp, err := s.cs.newRequest("getSolidFireAccountId", p.toURLValues())
if err != nil {
return nil, err
}
var r GetSolidFireAccountIdResponse
if err := json.Unmarshal(resp, &r); err != nil {
return nil, err
}
return &r, nil
}
|
[
"func",
"(",
"s",
"*",
"AccountService",
")",
"GetSolidFireAccountId",
"(",
"p",
"*",
"GetSolidFireAccountIdParams",
")",
"(",
"*",
"GetSolidFireAccountIdResponse",
",",
"error",
")",
"{",
"resp",
",",
"err",
":=",
"s",
".",
"cs",
".",
"newRequest",
"(",
"\"",
"\"",
",",
"p",
".",
"toURLValues",
"(",
")",
")",
"\n",
"if",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"var",
"r",
"GetSolidFireAccountIdResponse",
"\n",
"if",
"err",
":=",
"json",
".",
"Unmarshal",
"(",
"resp",
",",
"&",
"r",
")",
";",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"return",
"&",
"r",
",",
"nil",
"\n",
"}"
] |
// Get SolidFire Account ID
|
[
"Get",
"SolidFire",
"Account",
"ID"
] |
b6f53ed3282d22b6446422879587b0a78e1b0f11
|
https://github.com/xanzy/go-cloudstack/blob/b6f53ed3282d22b6446422879587b0a78e1b0f11/cloudstack/AccountService.go#L933-L945
|
145,374 |
xanzy/go-cloudstack
|
cloudstack/AccountService.go
|
NewListAccountsParams
|
func (s *AccountService) NewListAccountsParams() *ListAccountsParams {
p := &ListAccountsParams{}
p.p = make(map[string]interface{})
return p
}
|
go
|
func (s *AccountService) NewListAccountsParams() *ListAccountsParams {
p := &ListAccountsParams{}
p.p = make(map[string]interface{})
return p
}
|
[
"func",
"(",
"s",
"*",
"AccountService",
")",
"NewListAccountsParams",
"(",
")",
"*",
"ListAccountsParams",
"{",
"p",
":=",
"&",
"ListAccountsParams",
"{",
"}",
"\n",
"p",
".",
"p",
"=",
"make",
"(",
"map",
"[",
"string",
"]",
"interface",
"{",
"}",
")",
"\n",
"return",
"p",
"\n",
"}"
] |
// You should always use this function to get a new ListAccountsParams instance,
// as then you are sure you have configured all required params
|
[
"You",
"should",
"always",
"use",
"this",
"function",
"to",
"get",
"a",
"new",
"ListAccountsParams",
"instance",
"as",
"then",
"you",
"are",
"sure",
"you",
"have",
"configured",
"all",
"required",
"params"
] |
b6f53ed3282d22b6446422879587b0a78e1b0f11
|
https://github.com/xanzy/go-cloudstack/blob/b6f53ed3282d22b6446422879587b0a78e1b0f11/cloudstack/AccountService.go#L1092-L1096
|
145,375 |
xanzy/go-cloudstack
|
cloudstack/AccountService.go
|
NewListProjectAccountsParams
|
func (s *AccountService) NewListProjectAccountsParams(projectid string) *ListProjectAccountsParams {
p := &ListProjectAccountsParams{}
p.p = make(map[string]interface{})
p.p["projectid"] = projectid
return p
}
|
go
|
func (s *AccountService) NewListProjectAccountsParams(projectid string) *ListProjectAccountsParams {
p := &ListProjectAccountsParams{}
p.p = make(map[string]interface{})
p.p["projectid"] = projectid
return p
}
|
[
"func",
"(",
"s",
"*",
"AccountService",
")",
"NewListProjectAccountsParams",
"(",
"projectid",
"string",
")",
"*",
"ListProjectAccountsParams",
"{",
"p",
":=",
"&",
"ListProjectAccountsParams",
"{",
"}",
"\n",
"p",
".",
"p",
"=",
"make",
"(",
"map",
"[",
"string",
"]",
"interface",
"{",
"}",
")",
"\n",
"p",
".",
"p",
"[",
"\"",
"\"",
"]",
"=",
"projectid",
"\n",
"return",
"p",
"\n",
"}"
] |
// You should always use this function to get a new ListProjectAccountsParams instance,
// as then you are sure you have configured all required params
|
[
"You",
"should",
"always",
"use",
"this",
"function",
"to",
"get",
"a",
"new",
"ListProjectAccountsParams",
"instance",
"as",
"then",
"you",
"are",
"sure",
"you",
"have",
"configured",
"all",
"required",
"params"
] |
b6f53ed3282d22b6446422879587b0a78e1b0f11
|
https://github.com/xanzy/go-cloudstack/blob/b6f53ed3282d22b6446422879587b0a78e1b0f11/cloudstack/AccountService.go#L1366-L1371
|
145,376 |
xanzy/go-cloudstack
|
cloudstack/AccountService.go
|
NewLockAccountParams
|
func (s *AccountService) NewLockAccountParams(account string, domainid string) *LockAccountParams {
p := &LockAccountParams{}
p.p = make(map[string]interface{})
p.p["account"] = account
p.p["domainid"] = domainid
return p
}
|
go
|
func (s *AccountService) NewLockAccountParams(account string, domainid string) *LockAccountParams {
p := &LockAccountParams{}
p.p = make(map[string]interface{})
p.p["account"] = account
p.p["domainid"] = domainid
return p
}
|
[
"func",
"(",
"s",
"*",
"AccountService",
")",
"NewLockAccountParams",
"(",
"account",
"string",
",",
"domainid",
"string",
")",
"*",
"LockAccountParams",
"{",
"p",
":=",
"&",
"LockAccountParams",
"{",
"}",
"\n",
"p",
".",
"p",
"=",
"make",
"(",
"map",
"[",
"string",
"]",
"interface",
"{",
"}",
")",
"\n",
"p",
".",
"p",
"[",
"\"",
"\"",
"]",
"=",
"account",
"\n",
"p",
".",
"p",
"[",
"\"",
"\"",
"]",
"=",
"domainid",
"\n",
"return",
"p",
"\n",
"}"
] |
// You should always use this function to get a new LockAccountParams instance,
// as then you are sure you have configured all required params
|
[
"You",
"should",
"always",
"use",
"this",
"function",
"to",
"get",
"a",
"new",
"LockAccountParams",
"instance",
"as",
"then",
"you",
"are",
"sure",
"you",
"have",
"configured",
"all",
"required",
"params"
] |
b6f53ed3282d22b6446422879587b0a78e1b0f11
|
https://github.com/xanzy/go-cloudstack/blob/b6f53ed3282d22b6446422879587b0a78e1b0f11/cloudstack/AccountService.go#L1526-L1532
|
145,377 |
xanzy/go-cloudstack
|
cloudstack/AccountService.go
|
LockAccount
|
func (s *AccountService) LockAccount(p *LockAccountParams) (*LockAccountResponse, error) {
resp, err := s.cs.newRequest("lockAccount", p.toURLValues())
if err != nil {
return nil, err
}
var r LockAccountResponse
if err := json.Unmarshal(resp, &r); err != nil {
return nil, err
}
return &r, nil
}
|
go
|
func (s *AccountService) LockAccount(p *LockAccountParams) (*LockAccountResponse, error) {
resp, err := s.cs.newRequest("lockAccount", p.toURLValues())
if err != nil {
return nil, err
}
var r LockAccountResponse
if err := json.Unmarshal(resp, &r); err != nil {
return nil, err
}
return &r, nil
}
|
[
"func",
"(",
"s",
"*",
"AccountService",
")",
"LockAccount",
"(",
"p",
"*",
"LockAccountParams",
")",
"(",
"*",
"LockAccountResponse",
",",
"error",
")",
"{",
"resp",
",",
"err",
":=",
"s",
".",
"cs",
".",
"newRequest",
"(",
"\"",
"\"",
",",
"p",
".",
"toURLValues",
"(",
")",
")",
"\n",
"if",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"var",
"r",
"LockAccountResponse",
"\n",
"if",
"err",
":=",
"json",
".",
"Unmarshal",
"(",
"resp",
",",
"&",
"r",
")",
";",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"return",
"&",
"r",
",",
"nil",
"\n",
"}"
] |
// This deprecated function used to locks an account. Look for the API DisableAccount instead
|
[
"This",
"deprecated",
"function",
"used",
"to",
"locks",
"an",
"account",
".",
"Look",
"for",
"the",
"API",
"DisableAccount",
"instead"
] |
b6f53ed3282d22b6446422879587b0a78e1b0f11
|
https://github.com/xanzy/go-cloudstack/blob/b6f53ed3282d22b6446422879587b0a78e1b0f11/cloudstack/AccountService.go#L1535-L1547
|
145,378 |
xanzy/go-cloudstack
|
cloudstack/AccountService.go
|
NewMarkDefaultZoneForAccountParams
|
func (s *AccountService) NewMarkDefaultZoneForAccountParams(account string, domainid string, zoneid string) *MarkDefaultZoneForAccountParams {
p := &MarkDefaultZoneForAccountParams{}
p.p = make(map[string]interface{})
p.p["account"] = account
p.p["domainid"] = domainid
p.p["zoneid"] = zoneid
return p
}
|
go
|
func (s *AccountService) NewMarkDefaultZoneForAccountParams(account string, domainid string, zoneid string) *MarkDefaultZoneForAccountParams {
p := &MarkDefaultZoneForAccountParams{}
p.p = make(map[string]interface{})
p.p["account"] = account
p.p["domainid"] = domainid
p.p["zoneid"] = zoneid
return p
}
|
[
"func",
"(",
"s",
"*",
"AccountService",
")",
"NewMarkDefaultZoneForAccountParams",
"(",
"account",
"string",
",",
"domainid",
"string",
",",
"zoneid",
"string",
")",
"*",
"MarkDefaultZoneForAccountParams",
"{",
"p",
":=",
"&",
"MarkDefaultZoneForAccountParams",
"{",
"}",
"\n",
"p",
".",
"p",
"=",
"make",
"(",
"map",
"[",
"string",
"]",
"interface",
"{",
"}",
")",
"\n",
"p",
".",
"p",
"[",
"\"",
"\"",
"]",
"=",
"account",
"\n",
"p",
".",
"p",
"[",
"\"",
"\"",
"]",
"=",
"domainid",
"\n",
"p",
".",
"p",
"[",
"\"",
"\"",
"]",
"=",
"zoneid",
"\n",
"return",
"p",
"\n",
"}"
] |
// You should always use this function to get a new MarkDefaultZoneForAccountParams instance,
// as then you are sure you have configured all required params
|
[
"You",
"should",
"always",
"use",
"this",
"function",
"to",
"get",
"a",
"new",
"MarkDefaultZoneForAccountParams",
"instance",
"as",
"then",
"you",
"are",
"sure",
"you",
"have",
"configured",
"all",
"required",
"params"
] |
b6f53ed3282d22b6446422879587b0a78e1b0f11
|
https://github.com/xanzy/go-cloudstack/blob/b6f53ed3282d22b6446422879587b0a78e1b0f11/cloudstack/AccountService.go#L1679-L1686
|
145,379 |
xanzy/go-cloudstack
|
cloudstack/AccountService.go
|
NewUpdateAccountParams
|
func (s *AccountService) NewUpdateAccountParams(newname string) *UpdateAccountParams {
p := &UpdateAccountParams{}
p.p = make(map[string]interface{})
p.p["newname"] = newname
return p
}
|
go
|
func (s *AccountService) NewUpdateAccountParams(newname string) *UpdateAccountParams {
p := &UpdateAccountParams{}
p.p = make(map[string]interface{})
p.p["newname"] = newname
return p
}
|
[
"func",
"(",
"s",
"*",
"AccountService",
")",
"NewUpdateAccountParams",
"(",
"newname",
"string",
")",
"*",
"UpdateAccountParams",
"{",
"p",
":=",
"&",
"UpdateAccountParams",
"{",
"}",
"\n",
"p",
".",
"p",
"=",
"make",
"(",
"map",
"[",
"string",
"]",
"interface",
"{",
"}",
")",
"\n",
"p",
".",
"p",
"[",
"\"",
"\"",
"]",
"=",
"newname",
"\n",
"return",
"p",
"\n",
"}"
] |
// You should always use this function to get a new UpdateAccountParams instance,
// as then you are sure you have configured all required params
|
[
"You",
"should",
"always",
"use",
"this",
"function",
"to",
"get",
"a",
"new",
"UpdateAccountParams",
"instance",
"as",
"then",
"you",
"are",
"sure",
"you",
"have",
"configured",
"all",
"required",
"params"
] |
b6f53ed3282d22b6446422879587b0a78e1b0f11
|
https://github.com/xanzy/go-cloudstack/blob/b6f53ed3282d22b6446422879587b0a78e1b0f11/cloudstack/AccountService.go#L1892-L1897
|
145,380 |
xanzy/go-cloudstack
|
cloudstack/OutofbandManagementService.go
|
NewChangeOutOfBandManagementPasswordParams
|
func (s *OutofbandManagementService) NewChangeOutOfBandManagementPasswordParams(hostid string) *ChangeOutOfBandManagementPasswordParams {
p := &ChangeOutOfBandManagementPasswordParams{}
p.p = make(map[string]interface{})
p.p["hostid"] = hostid
return p
}
|
go
|
func (s *OutofbandManagementService) NewChangeOutOfBandManagementPasswordParams(hostid string) *ChangeOutOfBandManagementPasswordParams {
p := &ChangeOutOfBandManagementPasswordParams{}
p.p = make(map[string]interface{})
p.p["hostid"] = hostid
return p
}
|
[
"func",
"(",
"s",
"*",
"OutofbandManagementService",
")",
"NewChangeOutOfBandManagementPasswordParams",
"(",
"hostid",
"string",
")",
"*",
"ChangeOutOfBandManagementPasswordParams",
"{",
"p",
":=",
"&",
"ChangeOutOfBandManagementPasswordParams",
"{",
"}",
"\n",
"p",
".",
"p",
"=",
"make",
"(",
"map",
"[",
"string",
"]",
"interface",
"{",
"}",
")",
"\n",
"p",
".",
"p",
"[",
"\"",
"\"",
"]",
"=",
"hostid",
"\n",
"return",
"p",
"\n",
"}"
] |
// You should always use this function to get a new ChangeOutOfBandManagementPasswordParams instance,
// as then you are sure you have configured all required params
|
[
"You",
"should",
"always",
"use",
"this",
"function",
"to",
"get",
"a",
"new",
"ChangeOutOfBandManagementPasswordParams",
"instance",
"as",
"then",
"you",
"are",
"sure",
"you",
"have",
"configured",
"all",
"required",
"params"
] |
b6f53ed3282d22b6446422879587b0a78e1b0f11
|
https://github.com/xanzy/go-cloudstack/blob/b6f53ed3282d22b6446422879587b0a78e1b0f11/cloudstack/OutofbandManagementService.go#L61-L66
|
145,381 |
xanzy/go-cloudstack
|
cloudstack/OutofbandManagementService.go
|
ChangeOutOfBandManagementPassword
|
func (s *OutofbandManagementService) ChangeOutOfBandManagementPassword(p *ChangeOutOfBandManagementPasswordParams) (*ChangeOutOfBandManagementPasswordResponse, error) {
resp, err := s.cs.newRequest("changeOutOfBandManagementPassword", p.toURLValues())
if err != nil {
return nil, err
}
var r ChangeOutOfBandManagementPasswordResponse
if err := json.Unmarshal(resp, &r); err != nil {
return nil, err
}
// If we have a async client, we need to wait for the async result
if s.cs.async {
b, err := s.cs.GetAsyncJobResult(r.JobID, s.cs.timeout)
if err != nil {
if err == AsyncTimeoutErr {
return &r, err
}
return nil, err
}
b, err = getRawValue(b)
if err != nil {
return nil, err
}
if err := json.Unmarshal(b, &r); err != nil {
return nil, err
}
}
return &r, nil
}
|
go
|
func (s *OutofbandManagementService) ChangeOutOfBandManagementPassword(p *ChangeOutOfBandManagementPasswordParams) (*ChangeOutOfBandManagementPasswordResponse, error) {
resp, err := s.cs.newRequest("changeOutOfBandManagementPassword", p.toURLValues())
if err != nil {
return nil, err
}
var r ChangeOutOfBandManagementPasswordResponse
if err := json.Unmarshal(resp, &r); err != nil {
return nil, err
}
// If we have a async client, we need to wait for the async result
if s.cs.async {
b, err := s.cs.GetAsyncJobResult(r.JobID, s.cs.timeout)
if err != nil {
if err == AsyncTimeoutErr {
return &r, err
}
return nil, err
}
b, err = getRawValue(b)
if err != nil {
return nil, err
}
if err := json.Unmarshal(b, &r); err != nil {
return nil, err
}
}
return &r, nil
}
|
[
"func",
"(",
"s",
"*",
"OutofbandManagementService",
")",
"ChangeOutOfBandManagementPassword",
"(",
"p",
"*",
"ChangeOutOfBandManagementPasswordParams",
")",
"(",
"*",
"ChangeOutOfBandManagementPasswordResponse",
",",
"error",
")",
"{",
"resp",
",",
"err",
":=",
"s",
".",
"cs",
".",
"newRequest",
"(",
"\"",
"\"",
",",
"p",
".",
"toURLValues",
"(",
")",
")",
"\n",
"if",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"var",
"r",
"ChangeOutOfBandManagementPasswordResponse",
"\n",
"if",
"err",
":=",
"json",
".",
"Unmarshal",
"(",
"resp",
",",
"&",
"r",
")",
";",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"// If we have a async client, we need to wait for the async result",
"if",
"s",
".",
"cs",
".",
"async",
"{",
"b",
",",
"err",
":=",
"s",
".",
"cs",
".",
"GetAsyncJobResult",
"(",
"r",
".",
"JobID",
",",
"s",
".",
"cs",
".",
"timeout",
")",
"\n",
"if",
"err",
"!=",
"nil",
"{",
"if",
"err",
"==",
"AsyncTimeoutErr",
"{",
"return",
"&",
"r",
",",
"err",
"\n",
"}",
"\n",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"b",
",",
"err",
"=",
"getRawValue",
"(",
"b",
")",
"\n",
"if",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"if",
"err",
":=",
"json",
".",
"Unmarshal",
"(",
"b",
",",
"&",
"r",
")",
";",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n",
"}",
"\n\n",
"return",
"&",
"r",
",",
"nil",
"\n",
"}"
] |
// Changes out-of-band management interface password on the host and updates the interface configuration in CloudStack if the operation succeeds, else reverts the old password
|
[
"Changes",
"out",
"-",
"of",
"-",
"band",
"management",
"interface",
"password",
"on",
"the",
"host",
"and",
"updates",
"the",
"interface",
"configuration",
"in",
"CloudStack",
"if",
"the",
"operation",
"succeeds",
"else",
"reverts",
"the",
"old",
"password"
] |
b6f53ed3282d22b6446422879587b0a78e1b0f11
|
https://github.com/xanzy/go-cloudstack/blob/b6f53ed3282d22b6446422879587b0a78e1b0f11/cloudstack/OutofbandManagementService.go#L69-L101
|
145,382 |
xanzy/go-cloudstack
|
cloudstack/OutofbandManagementService.go
|
NewConfigureOutOfBandManagementParams
|
func (s *OutofbandManagementService) NewConfigureOutOfBandManagementParams(address string, driver string, hostid string, password string, port string, username string) *ConfigureOutOfBandManagementParams {
p := &ConfigureOutOfBandManagementParams{}
p.p = make(map[string]interface{})
p.p["address"] = address
p.p["driver"] = driver
p.p["hostid"] = hostid
p.p["password"] = password
p.p["port"] = port
p.p["username"] = username
return p
}
|
go
|
func (s *OutofbandManagementService) NewConfigureOutOfBandManagementParams(address string, driver string, hostid string, password string, port string, username string) *ConfigureOutOfBandManagementParams {
p := &ConfigureOutOfBandManagementParams{}
p.p = make(map[string]interface{})
p.p["address"] = address
p.p["driver"] = driver
p.p["hostid"] = hostid
p.p["password"] = password
p.p["port"] = port
p.p["username"] = username
return p
}
|
[
"func",
"(",
"s",
"*",
"OutofbandManagementService",
")",
"NewConfigureOutOfBandManagementParams",
"(",
"address",
"string",
",",
"driver",
"string",
",",
"hostid",
"string",
",",
"password",
"string",
",",
"port",
"string",
",",
"username",
"string",
")",
"*",
"ConfigureOutOfBandManagementParams",
"{",
"p",
":=",
"&",
"ConfigureOutOfBandManagementParams",
"{",
"}",
"\n",
"p",
".",
"p",
"=",
"make",
"(",
"map",
"[",
"string",
"]",
"interface",
"{",
"}",
")",
"\n",
"p",
".",
"p",
"[",
"\"",
"\"",
"]",
"=",
"address",
"\n",
"p",
".",
"p",
"[",
"\"",
"\"",
"]",
"=",
"driver",
"\n",
"p",
".",
"p",
"[",
"\"",
"\"",
"]",
"=",
"hostid",
"\n",
"p",
".",
"p",
"[",
"\"",
"\"",
"]",
"=",
"password",
"\n",
"p",
".",
"p",
"[",
"\"",
"\"",
"]",
"=",
"port",
"\n",
"p",
".",
"p",
"[",
"\"",
"\"",
"]",
"=",
"username",
"\n",
"return",
"p",
"\n",
"}"
] |
// You should always use this function to get a new ConfigureOutOfBandManagementParams instance,
// as then you are sure you have configured all required params
|
[
"You",
"should",
"always",
"use",
"this",
"function",
"to",
"get",
"a",
"new",
"ConfigureOutOfBandManagementParams",
"instance",
"as",
"then",
"you",
"are",
"sure",
"you",
"have",
"configured",
"all",
"required",
"params"
] |
b6f53ed3282d22b6446422879587b0a78e1b0f11
|
https://github.com/xanzy/go-cloudstack/blob/b6f53ed3282d22b6446422879587b0a78e1b0f11/cloudstack/OutofbandManagementService.go#L198-L208
|
145,383 |
xanzy/go-cloudstack
|
cloudstack/OutofbandManagementService.go
|
ConfigureOutOfBandManagement
|
func (s *OutofbandManagementService) ConfigureOutOfBandManagement(p *ConfigureOutOfBandManagementParams) (*OutOfBandManagementResponse, error) {
resp, err := s.cs.newRequest("configureOutOfBandManagement", p.toURLValues())
if err != nil {
return nil, err
}
var r OutOfBandManagementResponse
if err := json.Unmarshal(resp, &r); err != nil {
return nil, err
}
return &r, nil
}
|
go
|
func (s *OutofbandManagementService) ConfigureOutOfBandManagement(p *ConfigureOutOfBandManagementParams) (*OutOfBandManagementResponse, error) {
resp, err := s.cs.newRequest("configureOutOfBandManagement", p.toURLValues())
if err != nil {
return nil, err
}
var r OutOfBandManagementResponse
if err := json.Unmarshal(resp, &r); err != nil {
return nil, err
}
return &r, nil
}
|
[
"func",
"(",
"s",
"*",
"OutofbandManagementService",
")",
"ConfigureOutOfBandManagement",
"(",
"p",
"*",
"ConfigureOutOfBandManagementParams",
")",
"(",
"*",
"OutOfBandManagementResponse",
",",
"error",
")",
"{",
"resp",
",",
"err",
":=",
"s",
".",
"cs",
".",
"newRequest",
"(",
"\"",
"\"",
",",
"p",
".",
"toURLValues",
"(",
")",
")",
"\n",
"if",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"var",
"r",
"OutOfBandManagementResponse",
"\n",
"if",
"err",
":=",
"json",
".",
"Unmarshal",
"(",
"resp",
",",
"&",
"r",
")",
";",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"return",
"&",
"r",
",",
"nil",
"\n",
"}"
] |
// Configures a host's out-of-band management interface
|
[
"Configures",
"a",
"host",
"s",
"out",
"-",
"of",
"-",
"band",
"management",
"interface"
] |
b6f53ed3282d22b6446422879587b0a78e1b0f11
|
https://github.com/xanzy/go-cloudstack/blob/b6f53ed3282d22b6446422879587b0a78e1b0f11/cloudstack/OutofbandManagementService.go#L211-L223
|
145,384 |
xanzy/go-cloudstack
|
cloudstack/OutofbandManagementService.go
|
NewIssueOutOfBandManagementPowerActionParams
|
func (s *OutofbandManagementService) NewIssueOutOfBandManagementPowerActionParams(action string, hostid string) *IssueOutOfBandManagementPowerActionParams {
p := &IssueOutOfBandManagementPowerActionParams{}
p.p = make(map[string]interface{})
p.p["action"] = action
p.p["hostid"] = hostid
return p
}
|
go
|
func (s *OutofbandManagementService) NewIssueOutOfBandManagementPowerActionParams(action string, hostid string) *IssueOutOfBandManagementPowerActionParams {
p := &IssueOutOfBandManagementPowerActionParams{}
p.p = make(map[string]interface{})
p.p["action"] = action
p.p["hostid"] = hostid
return p
}
|
[
"func",
"(",
"s",
"*",
"OutofbandManagementService",
")",
"NewIssueOutOfBandManagementPowerActionParams",
"(",
"action",
"string",
",",
"hostid",
"string",
")",
"*",
"IssueOutOfBandManagementPowerActionParams",
"{",
"p",
":=",
"&",
"IssueOutOfBandManagementPowerActionParams",
"{",
"}",
"\n",
"p",
".",
"p",
"=",
"make",
"(",
"map",
"[",
"string",
"]",
"interface",
"{",
"}",
")",
"\n",
"p",
".",
"p",
"[",
"\"",
"\"",
"]",
"=",
"action",
"\n",
"p",
".",
"p",
"[",
"\"",
"\"",
"]",
"=",
"hostid",
"\n",
"return",
"p",
"\n",
"}"
] |
// You should always use this function to get a new IssueOutOfBandManagementPowerActionParams instance,
// as then you are sure you have configured all required params
|
[
"You",
"should",
"always",
"use",
"this",
"function",
"to",
"get",
"a",
"new",
"IssueOutOfBandManagementPowerActionParams",
"instance",
"as",
"then",
"you",
"are",
"sure",
"you",
"have",
"configured",
"all",
"required",
"params"
] |
b6f53ed3282d22b6446422879587b0a78e1b0f11
|
https://github.com/xanzy/go-cloudstack/blob/b6f53ed3282d22b6446422879587b0a78e1b0f11/cloudstack/OutofbandManagementService.go#L287-L293
|
145,385 |
xanzy/go-cloudstack
|
cloudstack/OutofbandManagementService.go
|
IssueOutOfBandManagementPowerAction
|
func (s *OutofbandManagementService) IssueOutOfBandManagementPowerAction(p *IssueOutOfBandManagementPowerActionParams) (*IssueOutOfBandManagementPowerActionResponse, error) {
resp, err := s.cs.newRequest("issueOutOfBandManagementPowerAction", p.toURLValues())
if err != nil {
return nil, err
}
var r IssueOutOfBandManagementPowerActionResponse
if err := json.Unmarshal(resp, &r); err != nil {
return nil, err
}
// If we have a async client, we need to wait for the async result
if s.cs.async {
b, err := s.cs.GetAsyncJobResult(r.JobID, s.cs.timeout)
if err != nil {
if err == AsyncTimeoutErr {
return &r, err
}
return nil, err
}
b, err = getRawValue(b)
if err != nil {
return nil, err
}
if err := json.Unmarshal(b, &r); err != nil {
return nil, err
}
}
return &r, nil
}
|
go
|
func (s *OutofbandManagementService) IssueOutOfBandManagementPowerAction(p *IssueOutOfBandManagementPowerActionParams) (*IssueOutOfBandManagementPowerActionResponse, error) {
resp, err := s.cs.newRequest("issueOutOfBandManagementPowerAction", p.toURLValues())
if err != nil {
return nil, err
}
var r IssueOutOfBandManagementPowerActionResponse
if err := json.Unmarshal(resp, &r); err != nil {
return nil, err
}
// If we have a async client, we need to wait for the async result
if s.cs.async {
b, err := s.cs.GetAsyncJobResult(r.JobID, s.cs.timeout)
if err != nil {
if err == AsyncTimeoutErr {
return &r, err
}
return nil, err
}
b, err = getRawValue(b)
if err != nil {
return nil, err
}
if err := json.Unmarshal(b, &r); err != nil {
return nil, err
}
}
return &r, nil
}
|
[
"func",
"(",
"s",
"*",
"OutofbandManagementService",
")",
"IssueOutOfBandManagementPowerAction",
"(",
"p",
"*",
"IssueOutOfBandManagementPowerActionParams",
")",
"(",
"*",
"IssueOutOfBandManagementPowerActionResponse",
",",
"error",
")",
"{",
"resp",
",",
"err",
":=",
"s",
".",
"cs",
".",
"newRequest",
"(",
"\"",
"\"",
",",
"p",
".",
"toURLValues",
"(",
")",
")",
"\n",
"if",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"var",
"r",
"IssueOutOfBandManagementPowerActionResponse",
"\n",
"if",
"err",
":=",
"json",
".",
"Unmarshal",
"(",
"resp",
",",
"&",
"r",
")",
";",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"// If we have a async client, we need to wait for the async result",
"if",
"s",
".",
"cs",
".",
"async",
"{",
"b",
",",
"err",
":=",
"s",
".",
"cs",
".",
"GetAsyncJobResult",
"(",
"r",
".",
"JobID",
",",
"s",
".",
"cs",
".",
"timeout",
")",
"\n",
"if",
"err",
"!=",
"nil",
"{",
"if",
"err",
"==",
"AsyncTimeoutErr",
"{",
"return",
"&",
"r",
",",
"err",
"\n",
"}",
"\n",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"b",
",",
"err",
"=",
"getRawValue",
"(",
"b",
")",
"\n",
"if",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"if",
"err",
":=",
"json",
".",
"Unmarshal",
"(",
"b",
",",
"&",
"r",
")",
";",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n",
"}",
"\n\n",
"return",
"&",
"r",
",",
"nil",
"\n",
"}"
] |
// Initiates the specified power action to the host's out-of-band management interface
|
[
"Initiates",
"the",
"specified",
"power",
"action",
"to",
"the",
"host",
"s",
"out",
"-",
"of",
"-",
"band",
"management",
"interface"
] |
b6f53ed3282d22b6446422879587b0a78e1b0f11
|
https://github.com/xanzy/go-cloudstack/blob/b6f53ed3282d22b6446422879587b0a78e1b0f11/cloudstack/OutofbandManagementService.go#L296-L328
|
145,386 |
xanzy/go-cloudstack
|
cloudstack/LimitService.go
|
NewGetApiLimitParams
|
func (s *LimitService) NewGetApiLimitParams() *GetApiLimitParams {
p := &GetApiLimitParams{}
p.p = make(map[string]interface{})
return p
}
|
go
|
func (s *LimitService) NewGetApiLimitParams() *GetApiLimitParams {
p := &GetApiLimitParams{}
p.p = make(map[string]interface{})
return p
}
|
[
"func",
"(",
"s",
"*",
"LimitService",
")",
"NewGetApiLimitParams",
"(",
")",
"*",
"GetApiLimitParams",
"{",
"p",
":=",
"&",
"GetApiLimitParams",
"{",
"}",
"\n",
"p",
".",
"p",
"=",
"make",
"(",
"map",
"[",
"string",
"]",
"interface",
"{",
"}",
")",
"\n",
"return",
"p",
"\n",
"}"
] |
// You should always use this function to get a new GetApiLimitParams instance,
// as then you are sure you have configured all required params
|
[
"You",
"should",
"always",
"use",
"this",
"function",
"to",
"get",
"a",
"new",
"GetApiLimitParams",
"instance",
"as",
"then",
"you",
"are",
"sure",
"you",
"have",
"configured",
"all",
"required",
"params"
] |
b6f53ed3282d22b6446422879587b0a78e1b0f11
|
https://github.com/xanzy/go-cloudstack/blob/b6f53ed3282d22b6446422879587b0a78e1b0f11/cloudstack/LimitService.go#L39-L43
|
145,387 |
xanzy/go-cloudstack
|
cloudstack/LimitService.go
|
GetApiLimit
|
func (s *LimitService) GetApiLimit(p *GetApiLimitParams) (*GetApiLimitResponse, error) {
resp, err := s.cs.newRequest("getApiLimit", p.toURLValues())
if err != nil {
return nil, err
}
var r GetApiLimitResponse
if err := json.Unmarshal(resp, &r); err != nil {
return nil, err
}
return &r, nil
}
|
go
|
func (s *LimitService) GetApiLimit(p *GetApiLimitParams) (*GetApiLimitResponse, error) {
resp, err := s.cs.newRequest("getApiLimit", p.toURLValues())
if err != nil {
return nil, err
}
var r GetApiLimitResponse
if err := json.Unmarshal(resp, &r); err != nil {
return nil, err
}
return &r, nil
}
|
[
"func",
"(",
"s",
"*",
"LimitService",
")",
"GetApiLimit",
"(",
"p",
"*",
"GetApiLimitParams",
")",
"(",
"*",
"GetApiLimitResponse",
",",
"error",
")",
"{",
"resp",
",",
"err",
":=",
"s",
".",
"cs",
".",
"newRequest",
"(",
"\"",
"\"",
",",
"p",
".",
"toURLValues",
"(",
")",
")",
"\n",
"if",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"var",
"r",
"GetApiLimitResponse",
"\n",
"if",
"err",
":=",
"json",
".",
"Unmarshal",
"(",
"resp",
",",
"&",
"r",
")",
";",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"return",
"&",
"r",
",",
"nil",
"\n",
"}"
] |
// Get API limit count for the caller
|
[
"Get",
"API",
"limit",
"count",
"for",
"the",
"caller"
] |
b6f53ed3282d22b6446422879587b0a78e1b0f11
|
https://github.com/xanzy/go-cloudstack/blob/b6f53ed3282d22b6446422879587b0a78e1b0f11/cloudstack/LimitService.go#L46-L58
|
145,388 |
xanzy/go-cloudstack
|
cloudstack/LimitService.go
|
NewListResourceLimitsParams
|
func (s *LimitService) NewListResourceLimitsParams() *ListResourceLimitsParams {
p := &ListResourceLimitsParams{}
p.p = make(map[string]interface{})
return p
}
|
go
|
func (s *LimitService) NewListResourceLimitsParams() *ListResourceLimitsParams {
p := &ListResourceLimitsParams{}
p.p = make(map[string]interface{})
return p
}
|
[
"func",
"(",
"s",
"*",
"LimitService",
")",
"NewListResourceLimitsParams",
"(",
")",
"*",
"ListResourceLimitsParams",
"{",
"p",
":=",
"&",
"ListResourceLimitsParams",
"{",
"}",
"\n",
"p",
".",
"p",
"=",
"make",
"(",
"map",
"[",
"string",
"]",
"interface",
"{",
"}",
")",
"\n",
"return",
"p",
"\n",
"}"
] |
// You should always use this function to get a new ListResourceLimitsParams instance,
// as then you are sure you have configured all required params
|
[
"You",
"should",
"always",
"use",
"this",
"function",
"to",
"get",
"a",
"new",
"ListResourceLimitsParams",
"instance",
"as",
"then",
"you",
"are",
"sure",
"you",
"have",
"configured",
"all",
"required",
"params"
] |
b6f53ed3282d22b6446422879587b0a78e1b0f11
|
https://github.com/xanzy/go-cloudstack/blob/b6f53ed3282d22b6446422879587b0a78e1b0f11/cloudstack/LimitService.go#L209-L213
|
145,389 |
xanzy/go-cloudstack
|
cloudstack/LimitService.go
|
ListResourceLimits
|
func (s *LimitService) ListResourceLimits(p *ListResourceLimitsParams) (*ListResourceLimitsResponse, error) {
resp, err := s.cs.newRequest("listResourceLimits", p.toURLValues())
if err != nil {
return nil, err
}
var r ListResourceLimitsResponse
if err := json.Unmarshal(resp, &r); err != nil {
return nil, err
}
return &r, nil
}
|
go
|
func (s *LimitService) ListResourceLimits(p *ListResourceLimitsParams) (*ListResourceLimitsResponse, error) {
resp, err := s.cs.newRequest("listResourceLimits", p.toURLValues())
if err != nil {
return nil, err
}
var r ListResourceLimitsResponse
if err := json.Unmarshal(resp, &r); err != nil {
return nil, err
}
return &r, nil
}
|
[
"func",
"(",
"s",
"*",
"LimitService",
")",
"ListResourceLimits",
"(",
"p",
"*",
"ListResourceLimitsParams",
")",
"(",
"*",
"ListResourceLimitsResponse",
",",
"error",
")",
"{",
"resp",
",",
"err",
":=",
"s",
".",
"cs",
".",
"newRequest",
"(",
"\"",
"\"",
",",
"p",
".",
"toURLValues",
"(",
")",
")",
"\n",
"if",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"var",
"r",
"ListResourceLimitsResponse",
"\n",
"if",
"err",
":=",
"json",
".",
"Unmarshal",
"(",
"resp",
",",
"&",
"r",
")",
";",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"return",
"&",
"r",
",",
"nil",
"\n",
"}"
] |
// Lists resource limits.
|
[
"Lists",
"resource",
"limits",
"."
] |
b6f53ed3282d22b6446422879587b0a78e1b0f11
|
https://github.com/xanzy/go-cloudstack/blob/b6f53ed3282d22b6446422879587b0a78e1b0f11/cloudstack/LimitService.go#L216-L228
|
145,390 |
xanzy/go-cloudstack
|
cloudstack/LimitService.go
|
NewResetApiLimitParams
|
func (s *LimitService) NewResetApiLimitParams() *ResetApiLimitParams {
p := &ResetApiLimitParams{}
p.p = make(map[string]interface{})
return p
}
|
go
|
func (s *LimitService) NewResetApiLimitParams() *ResetApiLimitParams {
p := &ResetApiLimitParams{}
p.p = make(map[string]interface{})
return p
}
|
[
"func",
"(",
"s",
"*",
"LimitService",
")",
"NewResetApiLimitParams",
"(",
")",
"*",
"ResetApiLimitParams",
"{",
"p",
":=",
"&",
"ResetApiLimitParams",
"{",
"}",
"\n",
"p",
".",
"p",
"=",
"make",
"(",
"map",
"[",
"string",
"]",
"interface",
"{",
"}",
")",
"\n",
"return",
"p",
"\n",
"}"
] |
// You should always use this function to get a new ResetApiLimitParams instance,
// as then you are sure you have configured all required params
|
[
"You",
"should",
"always",
"use",
"this",
"function",
"to",
"get",
"a",
"new",
"ResetApiLimitParams",
"instance",
"as",
"then",
"you",
"are",
"sure",
"you",
"have",
"configured",
"all",
"required",
"params"
] |
b6f53ed3282d22b6446422879587b0a78e1b0f11
|
https://github.com/xanzy/go-cloudstack/blob/b6f53ed3282d22b6446422879587b0a78e1b0f11/cloudstack/LimitService.go#L271-L275
|
145,391 |
xanzy/go-cloudstack
|
cloudstack/LimitService.go
|
ResetApiLimit
|
func (s *LimitService) ResetApiLimit(p *ResetApiLimitParams) (*ResetApiLimitResponse, error) {
resp, err := s.cs.newRequest("resetApiLimit", p.toURLValues())
if err != nil {
return nil, err
}
var r ResetApiLimitResponse
if err := json.Unmarshal(resp, &r); err != nil {
return nil, err
}
return &r, nil
}
|
go
|
func (s *LimitService) ResetApiLimit(p *ResetApiLimitParams) (*ResetApiLimitResponse, error) {
resp, err := s.cs.newRequest("resetApiLimit", p.toURLValues())
if err != nil {
return nil, err
}
var r ResetApiLimitResponse
if err := json.Unmarshal(resp, &r); err != nil {
return nil, err
}
return &r, nil
}
|
[
"func",
"(",
"s",
"*",
"LimitService",
")",
"ResetApiLimit",
"(",
"p",
"*",
"ResetApiLimitParams",
")",
"(",
"*",
"ResetApiLimitResponse",
",",
"error",
")",
"{",
"resp",
",",
"err",
":=",
"s",
".",
"cs",
".",
"newRequest",
"(",
"\"",
"\"",
",",
"p",
".",
"toURLValues",
"(",
")",
")",
"\n",
"if",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"var",
"r",
"ResetApiLimitResponse",
"\n",
"if",
"err",
":=",
"json",
".",
"Unmarshal",
"(",
"resp",
",",
"&",
"r",
")",
";",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"return",
"&",
"r",
",",
"nil",
"\n",
"}"
] |
// Reset api count
|
[
"Reset",
"api",
"count"
] |
b6f53ed3282d22b6446422879587b0a78e1b0f11
|
https://github.com/xanzy/go-cloudstack/blob/b6f53ed3282d22b6446422879587b0a78e1b0f11/cloudstack/LimitService.go#L278-L290
|
145,392 |
xanzy/go-cloudstack
|
cloudstack/LimitService.go
|
NewUpdateResourceCountParams
|
func (s *LimitService) NewUpdateResourceCountParams(domainid string) *UpdateResourceCountParams {
p := &UpdateResourceCountParams{}
p.p = make(map[string]interface{})
p.p["domainid"] = domainid
return p
}
|
go
|
func (s *LimitService) NewUpdateResourceCountParams(domainid string) *UpdateResourceCountParams {
p := &UpdateResourceCountParams{}
p.p = make(map[string]interface{})
p.p["domainid"] = domainid
return p
}
|
[
"func",
"(",
"s",
"*",
"LimitService",
")",
"NewUpdateResourceCountParams",
"(",
"domainid",
"string",
")",
"*",
"UpdateResourceCountParams",
"{",
"p",
":=",
"&",
"UpdateResourceCountParams",
"{",
"}",
"\n",
"p",
".",
"p",
"=",
"make",
"(",
"map",
"[",
"string",
"]",
"interface",
"{",
"}",
")",
"\n",
"p",
".",
"p",
"[",
"\"",
"\"",
"]",
"=",
"domainid",
"\n",
"return",
"p",
"\n",
"}"
] |
// You should always use this function to get a new UpdateResourceCountParams instance,
// as then you are sure you have configured all required params
|
[
"You",
"should",
"always",
"use",
"this",
"function",
"to",
"get",
"a",
"new",
"UpdateResourceCountParams",
"instance",
"as",
"then",
"you",
"are",
"sure",
"you",
"have",
"configured",
"all",
"required",
"params"
] |
b6f53ed3282d22b6446422879587b0a78e1b0f11
|
https://github.com/xanzy/go-cloudstack/blob/b6f53ed3282d22b6446422879587b0a78e1b0f11/cloudstack/LimitService.go#L359-L364
|
145,393 |
xanzy/go-cloudstack
|
cloudstack/LimitService.go
|
UpdateResourceCount
|
func (s *LimitService) UpdateResourceCount(p *UpdateResourceCountParams) (*UpdateResourceCountResponse, error) {
resp, err := s.cs.newRequest("updateResourceCount", p.toURLValues())
if err != nil {
return nil, err
}
var r UpdateResourceCountResponse
if err := json.Unmarshal(resp, &r); err != nil {
return nil, err
}
return &r, nil
}
|
go
|
func (s *LimitService) UpdateResourceCount(p *UpdateResourceCountParams) (*UpdateResourceCountResponse, error) {
resp, err := s.cs.newRequest("updateResourceCount", p.toURLValues())
if err != nil {
return nil, err
}
var r UpdateResourceCountResponse
if err := json.Unmarshal(resp, &r); err != nil {
return nil, err
}
return &r, nil
}
|
[
"func",
"(",
"s",
"*",
"LimitService",
")",
"UpdateResourceCount",
"(",
"p",
"*",
"UpdateResourceCountParams",
")",
"(",
"*",
"UpdateResourceCountResponse",
",",
"error",
")",
"{",
"resp",
",",
"err",
":=",
"s",
".",
"cs",
".",
"newRequest",
"(",
"\"",
"\"",
",",
"p",
".",
"toURLValues",
"(",
")",
")",
"\n",
"if",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"var",
"r",
"UpdateResourceCountResponse",
"\n",
"if",
"err",
":=",
"json",
".",
"Unmarshal",
"(",
"resp",
",",
"&",
"r",
")",
";",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"return",
"&",
"r",
",",
"nil",
"\n",
"}"
] |
// Recalculate and update resource count for an account or domain.
|
[
"Recalculate",
"and",
"update",
"resource",
"count",
"for",
"an",
"account",
"or",
"domain",
"."
] |
b6f53ed3282d22b6446422879587b0a78e1b0f11
|
https://github.com/xanzy/go-cloudstack/blob/b6f53ed3282d22b6446422879587b0a78e1b0f11/cloudstack/LimitService.go#L367-L379
|
145,394 |
xanzy/go-cloudstack
|
cloudstack/LimitService.go
|
NewUpdateResourceLimitParams
|
func (s *LimitService) NewUpdateResourceLimitParams(resourcetype int) *UpdateResourceLimitParams {
p := &UpdateResourceLimitParams{}
p.p = make(map[string]interface{})
p.p["resourcetype"] = resourcetype
return p
}
|
go
|
func (s *LimitService) NewUpdateResourceLimitParams(resourcetype int) *UpdateResourceLimitParams {
p := &UpdateResourceLimitParams{}
p.p = make(map[string]interface{})
p.p["resourcetype"] = resourcetype
return p
}
|
[
"func",
"(",
"s",
"*",
"LimitService",
")",
"NewUpdateResourceLimitParams",
"(",
"resourcetype",
"int",
")",
"*",
"UpdateResourceLimitParams",
"{",
"p",
":=",
"&",
"UpdateResourceLimitParams",
"{",
"}",
"\n",
"p",
".",
"p",
"=",
"make",
"(",
"map",
"[",
"string",
"]",
"interface",
"{",
"}",
")",
"\n",
"p",
".",
"p",
"[",
"\"",
"\"",
"]",
"=",
"resourcetype",
"\n",
"return",
"p",
"\n",
"}"
] |
// You should always use this function to get a new UpdateResourceLimitParams instance,
// as then you are sure you have configured all required params
|
[
"You",
"should",
"always",
"use",
"this",
"function",
"to",
"get",
"a",
"new",
"UpdateResourceLimitParams",
"instance",
"as",
"then",
"you",
"are",
"sure",
"you",
"have",
"configured",
"all",
"required",
"params"
] |
b6f53ed3282d22b6446422879587b0a78e1b0f11
|
https://github.com/xanzy/go-cloudstack/blob/b6f53ed3282d22b6446422879587b0a78e1b0f11/cloudstack/LimitService.go#L463-L468
|
145,395 |
xanzy/go-cloudstack
|
cloudstack/LimitService.go
|
UpdateResourceLimit
|
func (s *LimitService) UpdateResourceLimit(p *UpdateResourceLimitParams) (*UpdateResourceLimitResponse, error) {
resp, err := s.cs.newRequest("updateResourceLimit", p.toURLValues())
if err != nil {
return nil, err
}
var r UpdateResourceLimitResponse
if err := json.Unmarshal(resp, &r); err != nil {
return nil, err
}
return &r, nil
}
|
go
|
func (s *LimitService) UpdateResourceLimit(p *UpdateResourceLimitParams) (*UpdateResourceLimitResponse, error) {
resp, err := s.cs.newRequest("updateResourceLimit", p.toURLValues())
if err != nil {
return nil, err
}
var r UpdateResourceLimitResponse
if err := json.Unmarshal(resp, &r); err != nil {
return nil, err
}
return &r, nil
}
|
[
"func",
"(",
"s",
"*",
"LimitService",
")",
"UpdateResourceLimit",
"(",
"p",
"*",
"UpdateResourceLimitParams",
")",
"(",
"*",
"UpdateResourceLimitResponse",
",",
"error",
")",
"{",
"resp",
",",
"err",
":=",
"s",
".",
"cs",
".",
"newRequest",
"(",
"\"",
"\"",
",",
"p",
".",
"toURLValues",
"(",
")",
")",
"\n",
"if",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"var",
"r",
"UpdateResourceLimitResponse",
"\n",
"if",
"err",
":=",
"json",
".",
"Unmarshal",
"(",
"resp",
",",
"&",
"r",
")",
";",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"return",
"&",
"r",
",",
"nil",
"\n",
"}"
] |
// Updates resource limits for an account or domain.
|
[
"Updates",
"resource",
"limits",
"for",
"an",
"account",
"or",
"domain",
"."
] |
b6f53ed3282d22b6446422879587b0a78e1b0f11
|
https://github.com/xanzy/go-cloudstack/blob/b6f53ed3282d22b6446422879587b0a78e1b0f11/cloudstack/LimitService.go#L471-L483
|
145,396 |
xanzy/go-cloudstack
|
cloudstack/EventService.go
|
NewArchiveEventsParams
|
func (s *EventService) NewArchiveEventsParams() *ArchiveEventsParams {
p := &ArchiveEventsParams{}
p.p = make(map[string]interface{})
return p
}
|
go
|
func (s *EventService) NewArchiveEventsParams() *ArchiveEventsParams {
p := &ArchiveEventsParams{}
p.p = make(map[string]interface{})
return p
}
|
[
"func",
"(",
"s",
"*",
"EventService",
")",
"NewArchiveEventsParams",
"(",
")",
"*",
"ArchiveEventsParams",
"{",
"p",
":=",
"&",
"ArchiveEventsParams",
"{",
"}",
"\n",
"p",
".",
"p",
"=",
"make",
"(",
"map",
"[",
"string",
"]",
"interface",
"{",
"}",
")",
"\n",
"return",
"p",
"\n",
"}"
] |
// You should always use this function to get a new ArchiveEventsParams instance,
// as then you are sure you have configured all required params
|
[
"You",
"should",
"always",
"use",
"this",
"function",
"to",
"get",
"a",
"new",
"ArchiveEventsParams",
"instance",
"as",
"then",
"you",
"are",
"sure",
"you",
"have",
"configured",
"all",
"required",
"params"
] |
b6f53ed3282d22b6446422879587b0a78e1b0f11
|
https://github.com/xanzy/go-cloudstack/blob/b6f53ed3282d22b6446422879587b0a78e1b0f11/cloudstack/EventService.go#L86-L90
|
145,397 |
xanzy/go-cloudstack
|
cloudstack/EventService.go
|
ArchiveEvents
|
func (s *EventService) ArchiveEvents(p *ArchiveEventsParams) (*ArchiveEventsResponse, error) {
resp, err := s.cs.newRequest("archiveEvents", p.toURLValues())
if err != nil {
return nil, err
}
var r ArchiveEventsResponse
if err := json.Unmarshal(resp, &r); err != nil {
return nil, err
}
return &r, nil
}
|
go
|
func (s *EventService) ArchiveEvents(p *ArchiveEventsParams) (*ArchiveEventsResponse, error) {
resp, err := s.cs.newRequest("archiveEvents", p.toURLValues())
if err != nil {
return nil, err
}
var r ArchiveEventsResponse
if err := json.Unmarshal(resp, &r); err != nil {
return nil, err
}
return &r, nil
}
|
[
"func",
"(",
"s",
"*",
"EventService",
")",
"ArchiveEvents",
"(",
"p",
"*",
"ArchiveEventsParams",
")",
"(",
"*",
"ArchiveEventsResponse",
",",
"error",
")",
"{",
"resp",
",",
"err",
":=",
"s",
".",
"cs",
".",
"newRequest",
"(",
"\"",
"\"",
",",
"p",
".",
"toURLValues",
"(",
")",
")",
"\n",
"if",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"var",
"r",
"ArchiveEventsResponse",
"\n",
"if",
"err",
":=",
"json",
".",
"Unmarshal",
"(",
"resp",
",",
"&",
"r",
")",
";",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"return",
"&",
"r",
",",
"nil",
"\n",
"}"
] |
// Archive one or more events.
|
[
"Archive",
"one",
"or",
"more",
"events",
"."
] |
b6f53ed3282d22b6446422879587b0a78e1b0f11
|
https://github.com/xanzy/go-cloudstack/blob/b6f53ed3282d22b6446422879587b0a78e1b0f11/cloudstack/EventService.go#L93-L105
|
145,398 |
xanzy/go-cloudstack
|
cloudstack/EventService.go
|
NewDeleteEventsParams
|
func (s *EventService) NewDeleteEventsParams() *DeleteEventsParams {
p := &DeleteEventsParams{}
p.p = make(map[string]interface{})
return p
}
|
go
|
func (s *EventService) NewDeleteEventsParams() *DeleteEventsParams {
p := &DeleteEventsParams{}
p.p = make(map[string]interface{})
return p
}
|
[
"func",
"(",
"s",
"*",
"EventService",
")",
"NewDeleteEventsParams",
"(",
")",
"*",
"DeleteEventsParams",
"{",
"p",
":=",
"&",
"DeleteEventsParams",
"{",
"}",
"\n",
"p",
".",
"p",
"=",
"make",
"(",
"map",
"[",
"string",
"]",
"interface",
"{",
"}",
")",
"\n",
"return",
"p",
"\n",
"}"
] |
// You should always use this function to get a new DeleteEventsParams instance,
// as then you are sure you have configured all required params
|
[
"You",
"should",
"always",
"use",
"this",
"function",
"to",
"get",
"a",
"new",
"DeleteEventsParams",
"instance",
"as",
"then",
"you",
"are",
"sure",
"you",
"have",
"configured",
"all",
"required",
"params"
] |
b6f53ed3282d22b6446422879587b0a78e1b0f11
|
https://github.com/xanzy/go-cloudstack/blob/b6f53ed3282d22b6446422879587b0a78e1b0f11/cloudstack/EventService.go#L190-L194
|
145,399 |
xanzy/go-cloudstack
|
cloudstack/EventService.go
|
DeleteEvents
|
func (s *EventService) DeleteEvents(p *DeleteEventsParams) (*DeleteEventsResponse, error) {
resp, err := s.cs.newRequest("deleteEvents", p.toURLValues())
if err != nil {
return nil, err
}
var r DeleteEventsResponse
if err := json.Unmarshal(resp, &r); err != nil {
return nil, err
}
return &r, nil
}
|
go
|
func (s *EventService) DeleteEvents(p *DeleteEventsParams) (*DeleteEventsResponse, error) {
resp, err := s.cs.newRequest("deleteEvents", p.toURLValues())
if err != nil {
return nil, err
}
var r DeleteEventsResponse
if err := json.Unmarshal(resp, &r); err != nil {
return nil, err
}
return &r, nil
}
|
[
"func",
"(",
"s",
"*",
"EventService",
")",
"DeleteEvents",
"(",
"p",
"*",
"DeleteEventsParams",
")",
"(",
"*",
"DeleteEventsResponse",
",",
"error",
")",
"{",
"resp",
",",
"err",
":=",
"s",
".",
"cs",
".",
"newRequest",
"(",
"\"",
"\"",
",",
"p",
".",
"toURLValues",
"(",
")",
")",
"\n",
"if",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"var",
"r",
"DeleteEventsResponse",
"\n",
"if",
"err",
":=",
"json",
".",
"Unmarshal",
"(",
"resp",
",",
"&",
"r",
")",
";",
"err",
"!=",
"nil",
"{",
"return",
"nil",
",",
"err",
"\n",
"}",
"\n\n",
"return",
"&",
"r",
",",
"nil",
"\n",
"}"
] |
// Delete one or more events.
|
[
"Delete",
"one",
"or",
"more",
"events",
"."
] |
b6f53ed3282d22b6446422879587b0a78e1b0f11
|
https://github.com/xanzy/go-cloudstack/blob/b6f53ed3282d22b6446422879587b0a78e1b0f11/cloudstack/EventService.go#L197-L209
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.