package
0.20240715.1103416
Repository: https://github.com/hashicorp/go-azure-sdk.git
Documentation: pkg.go.dev
# README
github.com/hashicorp/go-azure-sdk/resource-manager/datamigration/2021-06-30/patch
Documentation
The patch
SDK allows for interaction with the Azure Resource Manager Service datamigration
(API Version 2021-06-30
).
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/datamigration/2021-06-30/patch"
Client Initialization
client := patch.NewPATCHClientWithBaseURI("https://management.azure.com")
client.Client.Authorizer = authorizer
Example Usage: PATCHClient.FilesUpdate
ctx := context.TODO()
id := patch.NewFileID("12345678-1234-9876-4563-123456789012", "resourceGroupValue", "serviceValue", "projectValue", "fileValue")
payload := patch.ProjectFile{
// ...
}
read, err := client.FilesUpdate(ctx, id, payload)
if err != nil {
// handle the error
}
if model := read.Model; model != nil {
// do something with the model/response object
}
Example Usage: PATCHClient.ProjectsUpdate
ctx := context.TODO()
id := patch.NewProjectID("12345678-1234-9876-4563-123456789012", "resourceGroupValue", "serviceValue", "projectValue")
payload := patch.Project{
// ...
}
read, err := client.ProjectsUpdate(ctx, id, payload)
if err != nil {
// handle the error
}
if model := read.Model; model != nil {
// do something with the model/response object
}
Example Usage: PATCHClient.ServiceTasksUpdate
ctx := context.TODO()
id := patch.NewServiceTaskID("12345678-1234-9876-4563-123456789012", "resourceGroupValue", "serviceValue", "serviceTaskValue")
payload := patch.ProjectTask{
// ...
}
read, err := client.ServiceTasksUpdate(ctx, id, payload)
if err != nil {
// handle the error
}
if model := read.Model; model != nil {
// do something with the model/response object
}
Example Usage: PATCHClient.ServicesUpdate
ctx := context.TODO()
id := patch.NewServiceID("12345678-1234-9876-4563-123456789012", "resourceGroupValue", "serviceValue")
payload := patch.DataMigrationService{
// ...
}
if err := client.ServicesUpdateThenPoll(ctx, id, payload); err != nil {
// handle the error
}
Example Usage: PATCHClient.TasksUpdate
ctx := context.TODO()
id := patch.NewTaskID("12345678-1234-9876-4563-123456789012", "resourceGroupValue", "serviceValue", "projectValue", "taskValue")
payload := patch.ProjectTask{
// ...
}
read, err := client.TasksUpdate(ctx, id, payload)
if err != nil {
// handle the error
}
if model := read.Model; model != nil {
// do something with the model/response object
}