README ¶
github.com/hashicorp/go-azure-sdk/resource-manager/migrate/2020-01-01/jobs
Documentation
The jobs
SDK allows for interaction with the Azure Resource Manager Service migrate
(API Version 2020-01-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/migrate/2020-01-01/jobs"
Client Initialization
client := jobs.NewJobsClientWithBaseURI("https://management.azure.com")
client.Client.Authorizer = authorizer
Example Usage: JobsClient.GetAllJobsInSite
ctx := context.TODO()
id := jobs.NewVMwareSiteID("12345678-1234-9876-4563-123456789012", "example-resource-group", "vmwareSiteValue")
// alternatively `client.GetAllJobsInSite(ctx, id)` can be used to do batched pagination
items, err := client.GetAllJobsInSiteComplete(ctx, id)
if err != nil {
// handle the error
}
for _, item := range items {
// do something
}
Example Usage: JobsClient.GetJob
ctx := context.TODO()
id := jobs.NewVMwareSiteJobID("12345678-1234-9876-4563-123456789012", "example-resource-group", "vmwareSiteValue", "jobValue")
read, err := client.GetJob(ctx, id)
if err != nil {
// handle the error
}
if model := read.Model; model != nil {
// do something with the model/response object
}
Documentation ¶
Index ¶
- func ValidateVMwareSiteID(input interface{}, key string) (warnings []string, errors []error)
- type ErrorDetails
- type GetAllJobsInSiteCompleteResult
- type GetAllJobsInSiteOperationResponse
- type GetJobOperationResponse
- type JobProperties
- type JobsClient
- func (c JobsClient) GetAllJobsInSite(ctx context.Context, id VMwareSiteId) (resp GetAllJobsInSiteOperationResponse, err error)
- func (c JobsClient) GetAllJobsInSiteComplete(ctx context.Context, id VMwareSiteId) (GetAllJobsInSiteCompleteResult, error)
- func (c JobsClient) GetAllJobsInSiteCompleteMatchingPredicate(ctx context.Context, id VMwareSiteId, predicate VMwareJobOperationPredicate) (resp GetAllJobsInSiteCompleteResult, err error)
- func (c JobsClient) GetJob(ctx context.Context, id commonids.VMwareSiteJobId) (result GetJobOperationResponse, err error)
- type VMwareJob
- type VMwareJobOperationPredicate
- type VMwareSiteId
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ValidateVMwareSiteID ¶
ValidateVMwareSiteID checks that 'input' can be parsed as a V Mware Site ID
Types ¶
type ErrorDetails ¶
type ErrorDetails struct { AgentErrorCode *string `json:"agentErrorCode,omitempty"` AgentErrorMessage *string `json:"agentErrorMessage,omitempty"` AgentErrorPossibleCauses *string `json:"agentErrorPossibleCauses,omitempty"` AgentErrorRecommendedAction *string `json:"agentErrorRecommendedAction,omitempty"` Code *string `json:"code,omitempty"` IsAgentReportedError *bool `json:"isAgentReportedError,omitempty"` Message *string `json:"message,omitempty"` PossibleCauses *string `json:"possibleCauses,omitempty"` RecommendedAction *string `json:"recommendedAction,omitempty"` Severity *string `json:"severity,omitempty"` }
type GetAllJobsInSiteCompleteResult ¶
type GetAllJobsInSiteCompleteResult struct {
Items []VMwareJob
}
type GetAllJobsInSiteOperationResponse ¶
type GetAllJobsInSiteOperationResponse struct { HttpResponse *http.Response Model *[]VMwareJob // contains filtered or unexported fields }
func (GetAllJobsInSiteOperationResponse) HasMore ¶
func (r GetAllJobsInSiteOperationResponse) HasMore() bool
func (GetAllJobsInSiteOperationResponse) LoadMore ¶
func (r GetAllJobsInSiteOperationResponse) LoadMore(ctx context.Context) (resp GetAllJobsInSiteOperationResponse, err error)
type GetJobOperationResponse ¶
type JobProperties ¶
type JobProperties struct { ActivityId *string `json:"activityId,omitempty"` ClientRequestId *string `json:"clientRequestId,omitempty"` DisplayName *string `json:"displayName,omitempty"` EndTime *string `json:"endTime,omitempty"` Errors *[]ErrorDetails `json:"errors,omitempty"` StartTime *string `json:"startTime,omitempty"` Status *string `json:"status,omitempty"` }
type JobsClient ¶
func NewJobsClientWithBaseURI ¶
func NewJobsClientWithBaseURI(endpoint string) JobsClient
func (JobsClient) GetAllJobsInSite ¶
func (c JobsClient) GetAllJobsInSite(ctx context.Context, id VMwareSiteId) (resp GetAllJobsInSiteOperationResponse, err error)
GetAllJobsInSite ...
func (JobsClient) GetAllJobsInSiteComplete ¶
func (c JobsClient) GetAllJobsInSiteComplete(ctx context.Context, id VMwareSiteId) (GetAllJobsInSiteCompleteResult, error)
GetAllJobsInSiteComplete retrieves all of the results into a single object
func (JobsClient) GetAllJobsInSiteCompleteMatchingPredicate ¶
func (c JobsClient) GetAllJobsInSiteCompleteMatchingPredicate(ctx context.Context, id VMwareSiteId, predicate VMwareJobOperationPredicate) (resp GetAllJobsInSiteCompleteResult, err error)
GetAllJobsInSiteCompleteMatchingPredicate retrieves all of the results and then applied the predicate
func (JobsClient) GetJob ¶
func (c JobsClient) GetJob(ctx context.Context, id commonids.VMwareSiteJobId) (result GetJobOperationResponse, err error)
GetJob ...
type VMwareJob ¶
type VMwareJob struct { Id *string `json:"id,omitempty"` Name *string `json:"name,omitempty"` Properties *JobProperties `json:"properties,omitempty"` Type *string `json:"type,omitempty"` }
type VMwareJobOperationPredicate ¶
func (VMwareJobOperationPredicate) Matches ¶
func (p VMwareJobOperationPredicate) Matches(input VMwareJob) bool
type VMwareSiteId ¶
VMwareSiteId is a struct representing the Resource ID for a V Mware Site
func NewVMwareSiteID ¶
func NewVMwareSiteID(subscriptionId string, resourceGroupName string, vmwareSiteName string) VMwareSiteId
NewVMwareSiteID returns a new VMwareSiteId struct
func ParseVMwareSiteID ¶
func ParseVMwareSiteID(input string) (*VMwareSiteId, error)
ParseVMwareSiteID parses 'input' into a VMwareSiteId
func ParseVMwareSiteIDInsensitively ¶
func ParseVMwareSiteIDInsensitively(input string) (*VMwareSiteId, error)
ParseVMwareSiteIDInsensitively parses 'input' case-insensitively into a VMwareSiteId note: this method should only be used for API response data and not user input
func (VMwareSiteId) ID ¶
func (id VMwareSiteId) ID() string
ID returns the formatted V Mware Site ID
func (VMwareSiteId) Segments ¶
func (id VMwareSiteId) Segments() []resourceids.Segment
Segments returns a slice of Resource ID Segments which comprise this V Mware Site ID
func (VMwareSiteId) String ¶
func (id VMwareSiteId) String() string
String returns a human-readable description of this V Mware Site ID