Skip to content

Commit d1c564d

Browse files
stackit-pipelineHenrique Santos
andauthored
Generator: update SDK /services (#218)
* Generate services * Add removed methods * Reword deprecation message * Reword * Simplify implementation --------- Co-authored-by: Henrique Santos <henrique.santos@freiheit.com>
1 parent 9ebfbb1 commit d1c564d

File tree

3 files changed

+242
-193
lines changed

3 files changed

+242
-193
lines changed

services/mongodbflex/api_default.go

Lines changed: 138 additions & 138 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
Lines changed: 49 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,49 @@
1+
// Will be deleted next time SDK generation happens
2+
3+
package mongodbflex
4+
5+
import (
6+
"context"
7+
)
8+
9+
// Deprecated: this struct will be removed in the next minor update, use ApiListStoragesRequest instead
10+
type ApiGetStorageRequest struct {
11+
ctx context.Context
12+
apiService *DefaultApiService
13+
projectId string
14+
flavor string
15+
}
16+
17+
func (r ApiGetStorageRequest) Execute() (*ListStoragesResponse, error) {
18+
return ApiListStoragesRequest(r).Execute()
19+
}
20+
21+
/*
22+
GetStorage Get storage
23+
returns the storage for a certain flavor
24+
25+
@param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background().
26+
@param projectId project id
27+
@param flavor flavor id
28+
@return ApiGetStorageRequest
29+
*/
30+
// Deprecated: this method will be removed in the next minor update, use ListStorage instead
31+
func (a *APIClient) GetStorage(ctx context.Context, projectId, flavor string) ApiGetStorageRequest {
32+
return ApiGetStorageRequest{
33+
apiService: a.defaultApi,
34+
ctx: ctx,
35+
projectId: projectId,
36+
flavor: flavor,
37+
}
38+
}
39+
40+
// Deprecated: this method will be removed in the next minor update, use ListStorageExecute instead
41+
func (a *APIClient) GetStorageExecute(ctx context.Context, projectId, flavor string) (*ListStoragesResponse, error) {
42+
r := ApiGetStorageRequest{
43+
apiService: a.defaultApi,
44+
ctx: ctx,
45+
projectId: projectId,
46+
flavor: flavor,
47+
}
48+
return r.Execute()
49+
}

0 commit comments

Comments
 (0)