README ¶
github.com/hashicorp/go-azure-sdk/resource-manager/machinelearningservices/2022-05-01/modelcontainer
Documentation
The modelcontainer
SDK allows for interaction with the Azure Resource Manager Service machinelearningservices
(API Version 2022-05-01
).
This readme covers example usages, but further information on using this SDK can be found in the project root.
Import Path
import "github.com/hashicorp/go-azure-sdk/resource-manager/machinelearningservices/2022-05-01/modelcontainer"
Client Initialization
client := modelcontainer.NewModelContainerClientWithBaseURI("https://management.azure.com")
client.Client.Authorizer = authorizer
Example Usage: ModelContainerClient.CreateOrUpdate
ctx := context.TODO()
id := modelcontainer.NewModelID("12345678-1234-9876-4563-123456789012", "example-resource-group", "workspaceValue", "modelValue")
payload := modelcontainer.ModelContainerResource{
// ...
}
read, err := client.CreateOrUpdate(ctx, id, payload)
if err != nil {
// handle the error
}
if model := read.Model; model != nil {
// do something with the model/response object
}
Example Usage: ModelContainerClient.Delete
ctx := context.TODO()
id := modelcontainer.NewModelID("12345678-1234-9876-4563-123456789012", "example-resource-group", "workspaceValue", "modelValue")
read, err := client.Delete(ctx, id)
if err != nil {
// handle the error
}
if model := read.Model; model != nil {
// do something with the model/response object
}
Example Usage: ModelContainerClient.Get
ctx := context.TODO()
id := modelcontainer.NewModelID("12345678-1234-9876-4563-123456789012", "example-resource-group", "workspaceValue", "modelValue")
read, err := client.Get(ctx, id)
if err != nil {
// handle the error
}
if model := read.Model; model != nil {
// do something with the model/response object
}
Example Usage: ModelContainerClient.List
ctx := context.TODO()
id := modelcontainer.NewWorkspaceID("12345678-1234-9876-4563-123456789012", "example-resource-group", "workspaceValue")
// alternatively `client.List(ctx, id, modelcontainer.DefaultListOperationOptions())` can be used to do batched pagination
items, err := client.ListComplete(ctx, id, modelcontainer.DefaultListOperationOptions())
if err != nil {
// handle the error
}
for _, item := range items {
// do something
}
Documentation ¶
Index ¶
- func PossibleValuesForListViewType() []string
- func ValidateModelID(input interface{}, key string) (warnings []string, errors []error)
- func ValidateWorkspaceID(input interface{}, key string) (warnings []string, errors []error)
- type AssetContainer
- type CreateOrUpdateOperationResponse
- type DeleteOperationResponse
- type GetOperationResponse
- type ListCompleteResult
- type ListOperationOptions
- type ListOperationResponse
- type ListViewType
- type ModelContainerClient
- func (c ModelContainerClient) CreateOrUpdate(ctx context.Context, id ModelId, input ModelContainerResource) (result CreateOrUpdateOperationResponse, err error)
- func (c ModelContainerClient) Delete(ctx context.Context, id ModelId) (result DeleteOperationResponse, err error)
- func (c ModelContainerClient) Get(ctx context.Context, id ModelId) (result GetOperationResponse, err error)
- func (c ModelContainerClient) List(ctx context.Context, id WorkspaceId, options ListOperationOptions) (resp ListOperationResponse, err error)
- func (c ModelContainerClient) ListComplete(ctx context.Context, id WorkspaceId, options ListOperationOptions) (ListCompleteResult, error)
- func (c ModelContainerClient) ListCompleteMatchingPredicate(ctx context.Context, id WorkspaceId, options ListOperationOptions, ...) (resp ListCompleteResult, err error)
- type ModelContainerResource
- type ModelContainerResourceOperationPredicate
- type ModelId
- type WorkspaceId
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func PossibleValuesForListViewType ¶
func PossibleValuesForListViewType() []string
func ValidateModelID ¶
ValidateModelID checks that 'input' can be parsed as a Model ID
func ValidateWorkspaceID ¶
ValidateWorkspaceID checks that 'input' can be parsed as a Workspace ID
Types ¶
type AssetContainer ¶
type AssetContainer struct { Description *string `json:"description,omitempty"` IsArchived *bool `json:"isArchived,omitempty"` LatestVersion *string `json:"latestVersion,omitempty"` NextVersion *string `json:"nextVersion,omitempty"` Properties *map[string]string `json:"properties,omitempty"` Tags *map[string]string `json:"tags,omitempty"` }
type CreateOrUpdateOperationResponse ¶
type CreateOrUpdateOperationResponse struct { HttpResponse *http.Response Model *ModelContainerResource }
type DeleteOperationResponse ¶
type GetOperationResponse ¶
type GetOperationResponse struct { HttpResponse *http.Response Model *ModelContainerResource }
type ListCompleteResult ¶
type ListCompleteResult struct {
Items []ModelContainerResource
}
type ListOperationOptions ¶
type ListOperationOptions struct { Count *int64 ListViewType *ListViewType Skip *string }
func DefaultListOperationOptions ¶
func DefaultListOperationOptions() ListOperationOptions
type ListOperationResponse ¶
type ListOperationResponse struct { HttpResponse *http.Response Model *[]ModelContainerResource // contains filtered or unexported fields }
func (ListOperationResponse) HasMore ¶
func (r ListOperationResponse) HasMore() bool
func (ListOperationResponse) LoadMore ¶
func (r ListOperationResponse) LoadMore(ctx context.Context) (resp ListOperationResponse, err error)
type ListViewType ¶
type ListViewType string
const ( ListViewTypeActiveOnly ListViewType = "ActiveOnly" ListViewTypeAll ListViewType = "All" ListViewTypeArchivedOnly ListViewType = "ArchivedOnly" )
type ModelContainerClient ¶
type ModelContainerClient struct { Client autorest.Client // contains filtered or unexported fields }
func NewModelContainerClientWithBaseURI ¶
func NewModelContainerClientWithBaseURI(endpoint string) ModelContainerClient
func (ModelContainerClient) CreateOrUpdate ¶
func (c ModelContainerClient) CreateOrUpdate(ctx context.Context, id ModelId, input ModelContainerResource) (result CreateOrUpdateOperationResponse, err error)
CreateOrUpdate ...
func (ModelContainerClient) Delete ¶
func (c ModelContainerClient) Delete(ctx context.Context, id ModelId) (result DeleteOperationResponse, err error)
Delete ...
func (ModelContainerClient) Get ¶
func (c ModelContainerClient) Get(ctx context.Context, id ModelId) (result GetOperationResponse, err error)
Get ...
func (ModelContainerClient) List ¶
func (c ModelContainerClient) List(ctx context.Context, id WorkspaceId, options ListOperationOptions) (resp ListOperationResponse, err error)
List ...
func (ModelContainerClient) ListComplete ¶
func (c ModelContainerClient) ListComplete(ctx context.Context, id WorkspaceId, options ListOperationOptions) (ListCompleteResult, error)
ListComplete retrieves all of the results into a single object
func (ModelContainerClient) ListCompleteMatchingPredicate ¶
func (c ModelContainerClient) ListCompleteMatchingPredicate(ctx context.Context, id WorkspaceId, options ListOperationOptions, predicate ModelContainerResourceOperationPredicate) (resp ListCompleteResult, err error)
ListCompleteMatchingPredicate retrieves all of the results and then applied the predicate
type ModelContainerResource ¶
type ModelContainerResource struct { Id *string `json:"id,omitempty"` Name *string `json:"name,omitempty"` Properties AssetContainer `json:"properties"` SystemData *systemdata.SystemData `json:"systemData,omitempty"` Type *string `json:"type,omitempty"` }
type ModelContainerResourceOperationPredicate ¶
func (ModelContainerResourceOperationPredicate) Matches ¶
func (p ModelContainerResourceOperationPredicate) Matches(input ModelContainerResource) bool
type ModelId ¶
type ModelId struct { SubscriptionId string ResourceGroupName string WorkspaceName string ModelName string }
ModelId is a struct representing the Resource ID for a Model
func NewModelID ¶
func NewModelID(subscriptionId string, resourceGroupName string, workspaceName string, modelName string) ModelId
NewModelID returns a new ModelId struct
func ParseModelID ¶
ParseModelID parses 'input' into a ModelId
func ParseModelIDInsensitively ¶
ParseModelIDInsensitively parses 'input' case-insensitively into a ModelId note: this method should only be used for API response data and not user input
func (ModelId) Segments ¶
func (id ModelId) Segments() []resourceids.Segment
Segments returns a slice of Resource ID Segments which comprise this Model ID
type WorkspaceId ¶
WorkspaceId is a struct representing the Resource ID for a Workspace
func NewWorkspaceID ¶
func NewWorkspaceID(subscriptionId string, resourceGroupName string, workspaceName string) WorkspaceId
NewWorkspaceID returns a new WorkspaceId struct
func ParseWorkspaceID ¶
func ParseWorkspaceID(input string) (*WorkspaceId, error)
ParseWorkspaceID parses 'input' into a WorkspaceId
func ParseWorkspaceIDInsensitively ¶
func ParseWorkspaceIDInsensitively(input string) (*WorkspaceId, error)
ParseWorkspaceIDInsensitively parses 'input' case-insensitively into a WorkspaceId note: this method should only be used for API response data and not user input
func (WorkspaceId) Segments ¶
func (id WorkspaceId) Segments() []resourceids.Segment
Segments returns a slice of Resource ID Segments which comprise this Workspace ID
func (WorkspaceId) String ¶
func (id WorkspaceId) String() string
String returns a human-readable description of this Workspace ID