Skip to content

Commit

Permalink
chore(sdk): generate go extend sdk (2024-04-15T20:00:02+00:00)
Browse files Browse the repository at this point in the history
generated from openapi spec commit: 31b2a02460dc3130d5ace93b6a1614e73ab1d969
  • Loading branch information
Ubuntu authored and elmernocon committed Apr 16, 2024
1 parent 33da858 commit adbced0
Show file tree
Hide file tree
Showing 177 changed files with 14,868 additions and 6,940 deletions.
16 changes: 16 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,19 @@
<a name="v0.68.0"></a>
## [v0.68.0]
### feat
- **api:** add sessionhistory service
### test
- **:** make compatible with docker desktop
### fix
- **:** add error checking to the found.Location parsed url
- **:** linter issue
### chore
- **:** go mod tidy
- **:** go mod tidy
- **:** gofmt auth
- **:** revert gomod and gosumg


<a name="v0.67.0"></a>
## [v0.67.0]
### test
Expand Down
8 changes: 6 additions & 2 deletions ams-sdk/pkg/amsclient/development/development_client.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
Expand Up @@ -16,13 +16,19 @@ import (
"github.com/go-openapi/runtime"
cr "github.com/go-openapi/runtime/client"
"github.com/go-openapi/strfmt"
"github.com/go-openapi/swag"
)

// NewDevelopmentServerConfigurationListParams creates a new DevelopmentServerConfigurationListParams object
// with the default values initialized.
func NewDevelopmentServerConfigurationListParams() *DevelopmentServerConfigurationListParams {
var ()
var (
countDefault = int64(100)
offsetDefault = int64(0)
)
return &DevelopmentServerConfigurationListParams{
Count: &countDefault,
Offset: &offsetDefault,

timeout: cr.DefaultTimeout,
}
Expand All @@ -31,8 +37,13 @@ func NewDevelopmentServerConfigurationListParams() *DevelopmentServerConfigurati
// NewDevelopmentServerConfigurationListParamsWithTimeout creates a new DevelopmentServerConfigurationListParams object
// with the default values initialized, and the ability to set a timeout on a request
func NewDevelopmentServerConfigurationListParamsWithTimeout(timeout time.Duration) *DevelopmentServerConfigurationListParams {
var ()
var (
countDefault = int64(100)
offsetDefault = int64(0)
)
return &DevelopmentServerConfigurationListParams{
Count: &countDefault,
Offset: &offsetDefault,

timeout: timeout,
}
Expand All @@ -41,8 +52,13 @@ func NewDevelopmentServerConfigurationListParamsWithTimeout(timeout time.Duratio
// NewDevelopmentServerConfigurationListParamsWithContext creates a new DevelopmentServerConfigurationListParams object
// with the default values initialized, and the ability to set a context for a request
func NewDevelopmentServerConfigurationListParamsWithContext(ctx context.Context) *DevelopmentServerConfigurationListParams {
var ()
var (
countDefault = int64(100)
offsetDefault = int64(0)
)
return &DevelopmentServerConfigurationListParams{
Count: &countDefault,
Offset: &offsetDefault,

Context: ctx,
}
Expand All @@ -51,8 +67,13 @@ func NewDevelopmentServerConfigurationListParamsWithContext(ctx context.Context)
// NewDevelopmentServerConfigurationListParamsWithHTTPClient creates a new DevelopmentServerConfigurationListParams object
// with the default values initialized, and the ability to set a custom HTTPClient for a request
func NewDevelopmentServerConfigurationListParamsWithHTTPClient(client *http.Client) *DevelopmentServerConfigurationListParams {
var ()
var (
countDefault = int64(100)
offsetDefault = int64(0)
)
return &DevelopmentServerConfigurationListParams{
Count: &countDefault,
Offset: &offsetDefault,
HTTPClient: client,
}
}
Expand All @@ -69,6 +90,16 @@ type DevelopmentServerConfigurationListParams struct {
*/
Namespace string
/*Count
defines the maximum number of records returned in one page.
*/
Count *int64
/*Offset
specifies the start index for the records returned.
*/
Offset *int64

timeout time.Duration
AuthInfoWriter runtime.ClientAuthInfoWriter
Expand Down Expand Up @@ -146,6 +177,28 @@ func (o *DevelopmentServerConfigurationListParams) SetNamespace(namespace string
o.Namespace = namespace
}

// WithCount adds the count to the development server configuration list params
func (o *DevelopmentServerConfigurationListParams) WithCount(count *int64) *DevelopmentServerConfigurationListParams {
o.SetCount(count)
return o
}

// SetCount adds the count to the development server configuration list params
func (o *DevelopmentServerConfigurationListParams) SetCount(count *int64) {
o.Count = count
}

// WithOffset adds the offset to the development server configuration list params
func (o *DevelopmentServerConfigurationListParams) WithOffset(offset *int64) *DevelopmentServerConfigurationListParams {
o.SetOffset(offset)
return o
}

// SetOffset adds the offset to the development server configuration list params
func (o *DevelopmentServerConfigurationListParams) SetOffset(offset *int64) {
o.Offset = offset
}

// WriteToRequest writes these params to a swagger request
func (o *DevelopmentServerConfigurationListParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error {

Expand All @@ -159,6 +212,38 @@ func (o *DevelopmentServerConfigurationListParams) WriteToRequest(r runtime.Clie
return err
}

if o.Count != nil {

// query param count
var qrCount int64
if o.Count != nil {
qrCount = *o.Count
}
qCount := swag.FormatInt64(qrCount)
if qCount != "" {
if err := r.SetQueryParam("count", qCount); err != nil {
return err
}
}

}

if o.Offset != nil {

// query param offset
var qrOffset int64
if o.Offset != nil {
qrOffset = *o.Offset
}
qOffset := swag.FormatInt64(qrOffset)
if qOffset != "" {
if err := r.SetQueryParam("offset", qOffset); err != nil {
return err
}
}

}

// setting the default header value
if err := r.SetHeaderParam("User-Agent", utils.UserAgentGen()); err != nil {
return err
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ func NewDevelopmentServerConfigurationListOK() *DevelopmentServerConfigurationLi
development server configurations
*/
type DevelopmentServerConfigurationListOK struct {
Payload []*amsclientmodels.APIDevelopmentServerConfigurationGetResponse
Payload *amsclientmodels.APIDevelopmentServerConfigurationListResponse
}

func (o *DevelopmentServerConfigurationListOK) Error() string {
Expand All @@ -94,7 +94,7 @@ func (o *DevelopmentServerConfigurationListOK) ToJSONString() string {
return fmt.Sprintf("%+v", string(b))
}

func (o *DevelopmentServerConfigurationListOK) GetPayload() []*amsclientmodels.APIDevelopmentServerConfigurationGetResponse {
func (o *DevelopmentServerConfigurationListOK) GetPayload() *amsclientmodels.APIDevelopmentServerConfigurationListResponse {
return o.Payload
}

Expand All @@ -105,8 +105,10 @@ func (o *DevelopmentServerConfigurationListOK) readResponse(response runtime.Cli
consumer = runtime.ByteStreamConsumer()
}

o.Payload = new(amsclientmodels.APIDevelopmentServerConfigurationListResponse)

// response payload
if err := consumer.Consume(response.Body(), &o.Payload); err != nil && err != io.EOF {
if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF {
return err
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,9 +18,9 @@ import (
// swagger:model Api development server configuration create request.
type APIDevelopmentServerConfigurationCreateRequest struct {

// commandline
// commandlinearguments
// Required: true
CommandLine *string `json:"commandLine"`
CommandLineArguments *string `json:"commandLineArguments"`

// imageid
// Required: true
Expand All @@ -35,7 +35,7 @@ type APIDevelopmentServerConfigurationCreateRequest struct {
func (m *APIDevelopmentServerConfigurationCreateRequest) Validate(formats strfmt.Registry) error {
var res []error

if err := m.validateCommandLine(formats); err != nil {
if err := m.validateCommandLineArguments(formats); err != nil {
res = append(res, err)
}
if err := m.validateImageID(formats); err != nil {
Expand All @@ -51,9 +51,9 @@ func (m *APIDevelopmentServerConfigurationCreateRequest) Validate(formats strfmt
return nil
}

func (m *APIDevelopmentServerConfigurationCreateRequest) validateCommandLine(formats strfmt.Registry) error {
func (m *APIDevelopmentServerConfigurationCreateRequest) validateCommandLineArguments(formats strfmt.Registry) error {

if err := validate.Required("commandLine", "body", m.CommandLine); err != nil {
if err := validate.Required("commandLineArguments", "body", m.CommandLineArguments); err != nil {
return err
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,9 +18,9 @@ import (
// swagger:model Api development server configuration get response.
type APIDevelopmentServerConfigurationGetResponse struct {

// commandline
// commandlinearguments
// Required: true
CommandLine *string `json:"commandLine"`
CommandLineArguments *string `json:"commandLineArguments"`

// imageid
// Required: true
Expand All @@ -35,7 +35,7 @@ type APIDevelopmentServerConfigurationGetResponse struct {
func (m *APIDevelopmentServerConfigurationGetResponse) Validate(formats strfmt.Registry) error {
var res []error

if err := m.validateCommandLine(formats); err != nil {
if err := m.validateCommandLineArguments(formats); err != nil {
res = append(res, err)
}
if err := m.validateImageID(formats); err != nil {
Expand All @@ -51,9 +51,9 @@ func (m *APIDevelopmentServerConfigurationGetResponse) Validate(formats strfmt.R
return nil
}

func (m *APIDevelopmentServerConfigurationGetResponse) validateCommandLine(formats strfmt.Registry) error {
func (m *APIDevelopmentServerConfigurationGetResponse) validateCommandLineArguments(formats strfmt.Registry) error {

if err := validate.Required("commandLine", "body", m.CommandLine); err != nil {
if err := validate.Required("commandLineArguments", "body", m.CommandLineArguments); err != nil {
return err
}

Expand Down
Loading

0 comments on commit adbced0

Please sign in to comment.