README ¶
github.com/hashicorp/go-azure-sdk/resource-manager/portal/2019-01-01-preview/dashboard
Documentation
The dashboard
SDK allows for interaction with the Azure Resource Manager Service portal
(API Version 2019-01-01-preview
).
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/portal/2019-01-01-preview/dashboard"
Client Initialization
client := dashboard.NewDashboardClientWithBaseURI("https://management.azure.com")
client.Client.Authorizer = authorizer
Example Usage: DashboardClient.CreateOrUpdate
ctx := context.TODO()
id := dashboard.NewDashboardID("12345678-1234-9876-4563-123456789012", "example-resource-group", "dashboardValue")
payload := dashboard.Dashboard{
// ...
}
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: DashboardClient.Delete
ctx := context.TODO()
id := dashboard.NewDashboardID("12345678-1234-9876-4563-123456789012", "example-resource-group", "dashboardValue")
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: DashboardClient.Get
ctx := context.TODO()
id := dashboard.NewDashboardID("12345678-1234-9876-4563-123456789012", "example-resource-group", "dashboardValue")
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: DashboardClient.ListByResourceGroup
ctx := context.TODO()
id := dashboard.NewResourceGroupID("12345678-1234-9876-4563-123456789012", "example-resource-group")
// alternatively `client.ListByResourceGroup(ctx, id)` can be used to do batched pagination
items, err := client.ListByResourceGroupComplete(ctx, id)
if err != nil {
// handle the error
}
for _, item := range items {
// do something
}
Example Usage: DashboardClient.ListBySubscription
ctx := context.TODO()
id := dashboard.NewSubscriptionID("12345678-1234-9876-4563-123456789012")
// alternatively `client.ListBySubscription(ctx, id)` can be used to do batched pagination
items, err := client.ListBySubscriptionComplete(ctx, id)
if err != nil {
// handle the error
}
for _, item := range items {
// do something
}
Example Usage: DashboardClient.Update
ctx := context.TODO()
id := dashboard.NewDashboardID("12345678-1234-9876-4563-123456789012", "example-resource-group", "dashboardValue")
payload := dashboard.PatchableDashboard{
// ...
}
read, err := client.Update(ctx, id, payload)
if err != nil {
// handle the error
}
if model := read.Model; model != nil {
// do something with the model/response object
}
Documentation ¶
Index ¶
- func ValidateDashboardID(input interface{}, key string) (warnings []string, errors []error)
- type CreateOrUpdateOperationResponse
- type Dashboard
- type DashboardClient
- func (c DashboardClient) CreateOrUpdate(ctx context.Context, id DashboardId, input Dashboard) (result CreateOrUpdateOperationResponse, err error)
- func (c DashboardClient) Delete(ctx context.Context, id DashboardId) (result DeleteOperationResponse, err error)
- func (c DashboardClient) Get(ctx context.Context, id DashboardId) (result GetOperationResponse, err error)
- func (c DashboardClient) ListByResourceGroup(ctx context.Context, id commonids.ResourceGroupId) (resp ListByResourceGroupOperationResponse, err error)
- func (c DashboardClient) ListByResourceGroupComplete(ctx context.Context, id commonids.ResourceGroupId) (ListByResourceGroupCompleteResult, error)
- func (c DashboardClient) ListByResourceGroupCompleteMatchingPredicate(ctx context.Context, id commonids.ResourceGroupId, ...) (resp ListByResourceGroupCompleteResult, err error)
- func (c DashboardClient) ListBySubscription(ctx context.Context, id commonids.SubscriptionId) (resp ListBySubscriptionOperationResponse, err error)
- func (c DashboardClient) ListBySubscriptionComplete(ctx context.Context, id commonids.SubscriptionId) (ListBySubscriptionCompleteResult, error)
- func (c DashboardClient) ListBySubscriptionCompleteMatchingPredicate(ctx context.Context, id commonids.SubscriptionId, ...) (resp ListBySubscriptionCompleteResult, err error)
- func (c DashboardClient) Update(ctx context.Context, id DashboardId, input PatchableDashboard) (result UpdateOperationResponse, err error)
- type DashboardId
- type DashboardLens
- type DashboardOperationPredicate
- type DashboardParts
- type DashboardPartsPosition
- type DashboardProperties
- type DeleteOperationResponse
- type GetOperationResponse
- type ListByResourceGroupCompleteResult
- type ListByResourceGroupOperationResponse
- type ListBySubscriptionCompleteResult
- type ListBySubscriptionOperationResponse
- type PatchableDashboard
- type UpdateOperationResponse
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ValidateDashboardID ¶
ValidateDashboardID checks that 'input' can be parsed as a Dashboard ID
Types ¶
type DashboardClient ¶
func NewDashboardClientWithBaseURI ¶
func NewDashboardClientWithBaseURI(endpoint string) DashboardClient
func (DashboardClient) CreateOrUpdate ¶
func (c DashboardClient) CreateOrUpdate(ctx context.Context, id DashboardId, input Dashboard) (result CreateOrUpdateOperationResponse, err error)
CreateOrUpdate ...
func (DashboardClient) Delete ¶
func (c DashboardClient) Delete(ctx context.Context, id DashboardId) (result DeleteOperationResponse, err error)
Delete ...
func (DashboardClient) Get ¶
func (c DashboardClient) Get(ctx context.Context, id DashboardId) (result GetOperationResponse, err error)
Get ...
func (DashboardClient) ListByResourceGroup ¶
func (c DashboardClient) ListByResourceGroup(ctx context.Context, id commonids.ResourceGroupId) (resp ListByResourceGroupOperationResponse, err error)
ListByResourceGroup ...
func (DashboardClient) ListByResourceGroupComplete ¶
func (c DashboardClient) ListByResourceGroupComplete(ctx context.Context, id commonids.ResourceGroupId) (ListByResourceGroupCompleteResult, error)
ListByResourceGroupComplete retrieves all of the results into a single object
func (DashboardClient) ListByResourceGroupCompleteMatchingPredicate ¶
func (c DashboardClient) ListByResourceGroupCompleteMatchingPredicate(ctx context.Context, id commonids.ResourceGroupId, predicate DashboardOperationPredicate) (resp ListByResourceGroupCompleteResult, err error)
ListByResourceGroupCompleteMatchingPredicate retrieves all of the results and then applied the predicate
func (DashboardClient) ListBySubscription ¶
func (c DashboardClient) ListBySubscription(ctx context.Context, id commonids.SubscriptionId) (resp ListBySubscriptionOperationResponse, err error)
ListBySubscription ...
func (DashboardClient) ListBySubscriptionComplete ¶
func (c DashboardClient) ListBySubscriptionComplete(ctx context.Context, id commonids.SubscriptionId) (ListBySubscriptionCompleteResult, error)
ListBySubscriptionComplete retrieves all of the results into a single object
func (DashboardClient) ListBySubscriptionCompleteMatchingPredicate ¶
func (c DashboardClient) ListBySubscriptionCompleteMatchingPredicate(ctx context.Context, id commonids.SubscriptionId, predicate DashboardOperationPredicate) (resp ListBySubscriptionCompleteResult, err error)
ListBySubscriptionCompleteMatchingPredicate retrieves all of the results and then applied the predicate
func (DashboardClient) Update ¶
func (c DashboardClient) Update(ctx context.Context, id DashboardId, input PatchableDashboard) (result UpdateOperationResponse, err error)
Update ...
type DashboardId ¶
DashboardId is a struct representing the Resource ID for a Dashboard
func NewDashboardID ¶
func NewDashboardID(subscriptionId string, resourceGroupName string, dashboardName string) DashboardId
NewDashboardID returns a new DashboardId struct
func ParseDashboardID ¶
func ParseDashboardID(input string) (*DashboardId, error)
ParseDashboardID parses 'input' into a DashboardId
func ParseDashboardIDInsensitively ¶
func ParseDashboardIDInsensitively(input string) (*DashboardId, error)
ParseDashboardIDInsensitively parses 'input' case-insensitively into a DashboardId note: this method should only be used for API response data and not user input
func (DashboardId) Segments ¶
func (id DashboardId) Segments() []resourceids.Segment
Segments returns a slice of Resource ID Segments which comprise this Dashboard ID
func (DashboardId) String ¶
func (id DashboardId) String() string
String returns a human-readable description of this Dashboard ID
type DashboardLens ¶
type DashboardLens struct { Metadata *map[string]interface{} `json:"metadata,omitempty"` Order int64 `json:"order"` Parts map[string]DashboardParts `json:"parts"` }
type DashboardOperationPredicate ¶
func (DashboardOperationPredicate) Matches ¶
func (p DashboardOperationPredicate) Matches(input Dashboard) bool
type DashboardParts ¶
type DashboardParts struct { Metadata *interface{} `json:"metadata,omitempty"` Position DashboardPartsPosition `json:"position"` }
type DashboardPartsPosition ¶
type DashboardProperties ¶
type DashboardProperties struct { Lenses *map[string]DashboardLens `json:"lenses,omitempty"` Metadata *map[string]interface{} `json:"metadata,omitempty"` }
type DeleteOperationResponse ¶
type GetOperationResponse ¶
type ListByResourceGroupCompleteResult ¶
type ListByResourceGroupCompleteResult struct {
Items []Dashboard
}
type ListByResourceGroupOperationResponse ¶
type ListByResourceGroupOperationResponse struct { HttpResponse *http.Response Model *[]Dashboard // contains filtered or unexported fields }
func (ListByResourceGroupOperationResponse) HasMore ¶
func (r ListByResourceGroupOperationResponse) HasMore() bool
func (ListByResourceGroupOperationResponse) LoadMore ¶
func (r ListByResourceGroupOperationResponse) LoadMore(ctx context.Context) (resp ListByResourceGroupOperationResponse, err error)
type ListBySubscriptionCompleteResult ¶
type ListBySubscriptionCompleteResult struct {
Items []Dashboard
}
type ListBySubscriptionOperationResponse ¶
type ListBySubscriptionOperationResponse struct { HttpResponse *http.Response Model *[]Dashboard // contains filtered or unexported fields }
func (ListBySubscriptionOperationResponse) HasMore ¶
func (r ListBySubscriptionOperationResponse) HasMore() bool
func (ListBySubscriptionOperationResponse) LoadMore ¶
func (r ListBySubscriptionOperationResponse) LoadMore(ctx context.Context) (resp ListBySubscriptionOperationResponse, err error)
type PatchableDashboard ¶
type PatchableDashboard struct { Properties *DashboardProperties `json:"properties,omitempty"` Tags *map[string]string `json:"tags,omitempty"` }
type UpdateOperationResponse ¶
Source Files ¶
- client.go
- id_dashboard.go
- method_createorupdate_autorest.go
- method_delete_autorest.go
- method_get_autorest.go
- method_listbyresourcegroup_autorest.go
- method_listbysubscription_autorest.go
- method_update_autorest.go
- model_dashboard.go
- model_dashboardlens.go
- model_dashboardparts.go
- model_dashboardpartsposition.go
- model_dashboardproperties.go
- model_patchabledashboard.go
- predicates.go
- version.go