computepolicies

package
v0.20220817.1110045 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Aug 17, 2022 License: MPL-2.0 Imports: 8 Imported by: 1

README

github.com/hashicorp/go-azure-sdk/resource-manager/datalakeanalytics/2016-11-01/computepolicies Documentation

The computepolicies SDK allows for interaction with the Azure Resource Manager Service datalakeanalytics (API Version 2016-11-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/datalakeanalytics/2016-11-01/computepolicies"

Client Initialization

client := computepolicies.NewComputePoliciesClientWithBaseURI("https://management.azure.com")
client.Client.Authorizer = authorizer

Example Usage: ComputePoliciesClient.CreateOrUpdate

ctx := context.TODO()
id := computepolicies.NewComputePoliciesID("12345678-1234-9876-4563-123456789012", "example-resource-group", "accountValue", "computePolicyValue")

payload := computepolicies.CreateOrUpdateComputePolicyParameters{
	// ...
}


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: ComputePoliciesClient.Delete

ctx := context.TODO()
id := computepolicies.NewComputePoliciesID("12345678-1234-9876-4563-123456789012", "example-resource-group", "accountValue", "computePolicyValue")

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: ComputePoliciesClient.Get

ctx := context.TODO()
id := computepolicies.NewComputePoliciesID("12345678-1234-9876-4563-123456789012", "example-resource-group", "accountValue", "computePolicyValue")

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: ComputePoliciesClient.ListByAccount

ctx := context.TODO()
id := computepolicies.NewAccountID("12345678-1234-9876-4563-123456789012", "example-resource-group", "accountValue")

// alternatively `client.ListByAccount(ctx, id)` can be used to do batched pagination
items, err := client.ListByAccountComplete(ctx, id)
if err != nil {
	// handle the error
}
for _, item := range items {
	// do something
}

Example Usage: ComputePoliciesClient.Update

ctx := context.TODO()
id := computepolicies.NewComputePoliciesID("12345678-1234-9876-4563-123456789012", "example-resource-group", "accountValue", "computePolicyValue")

payload := computepolicies.UpdateComputePolicyParameters{
	// ...
}


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

Constants

This section is empty.

Variables

This section is empty.

Functions

func PossibleValuesForAADObjectType

func PossibleValuesForAADObjectType() []string

func ValidateAccountID

func ValidateAccountID(input interface{}, key string) (warnings []string, errors []error)

ValidateAccountID checks that 'input' can be parsed as a Account ID

func ValidateComputePoliciesID

func ValidateComputePoliciesID(input interface{}, key string) (warnings []string, errors []error)

ValidateComputePoliciesID checks that 'input' can be parsed as a Compute Policies ID

Types

type AADObjectType

type AADObjectType string
const (
	AADObjectTypeGroup            AADObjectType = "Group"
	AADObjectTypeServicePrincipal AADObjectType = "ServicePrincipal"
	AADObjectTypeUser             AADObjectType = "User"
)

type AccountId

type AccountId struct {
	SubscriptionId    string
	ResourceGroupName string
	AccountName       string
}

AccountId is a struct representing the Resource ID for a Account

func NewAccountID

func NewAccountID(subscriptionId string, resourceGroupName string, accountName string) AccountId

NewAccountID returns a new AccountId struct

func ParseAccountID

func ParseAccountID(input string) (*AccountId, error)

ParseAccountID parses 'input' into a AccountId

func ParseAccountIDInsensitively

func ParseAccountIDInsensitively(input string) (*AccountId, error)

ParseAccountIDInsensitively parses 'input' case-insensitively into a AccountId note: this method should only be used for API response data and not user input

func (AccountId) ID

func (id AccountId) ID() string

ID returns the formatted Account ID

func (AccountId) Segments

func (id AccountId) Segments() []resourceids.Segment

Segments returns a slice of Resource ID Segments which comprise this Account ID

func (AccountId) String

func (id AccountId) String() string

String returns a human-readable description of this Account ID

type ComputePoliciesClient

type ComputePoliciesClient struct {
	Client autorest.Client
	// contains filtered or unexported fields
}

func NewComputePoliciesClientWithBaseURI

func NewComputePoliciesClientWithBaseURI(endpoint string) ComputePoliciesClient

func (ComputePoliciesClient) CreateOrUpdate

CreateOrUpdate ...

func (ComputePoliciesClient) Delete

Delete ...

func (ComputePoliciesClient) Get

Get ...

func (ComputePoliciesClient) ListByAccount

ListByAccount ...

func (ComputePoliciesClient) ListByAccountComplete

ListByAccountComplete retrieves all of the results into a single object

func (ComputePoliciesClient) ListByAccountCompleteMatchingPredicate

func (c ComputePoliciesClient) ListByAccountCompleteMatchingPredicate(ctx context.Context, id AccountId, predicate ComputePolicyOperationPredicate) (resp ListByAccountCompleteResult, err error)

ListByAccountCompleteMatchingPredicate retrieves all of the results and then applied the predicate

func (ComputePoliciesClient) Update

Update ...

type ComputePoliciesId

type ComputePoliciesId struct {
	SubscriptionId    string
	ResourceGroupName string
	AccountName       string
	ComputePolicyName string
}

ComputePoliciesId is a struct representing the Resource ID for a Compute Policies

func NewComputePoliciesID

func NewComputePoliciesID(subscriptionId string, resourceGroupName string, accountName string, computePolicyName string) ComputePoliciesId

NewComputePoliciesID returns a new ComputePoliciesId struct

func ParseComputePoliciesID

func ParseComputePoliciesID(input string) (*ComputePoliciesId, error)

ParseComputePoliciesID parses 'input' into a ComputePoliciesId

func ParseComputePoliciesIDInsensitively

func ParseComputePoliciesIDInsensitively(input string) (*ComputePoliciesId, error)

ParseComputePoliciesIDInsensitively parses 'input' case-insensitively into a ComputePoliciesId note: this method should only be used for API response data and not user input

func (ComputePoliciesId) ID

func (id ComputePoliciesId) ID() string

ID returns the formatted Compute Policies ID

func (ComputePoliciesId) Segments

func (id ComputePoliciesId) Segments() []resourceids.Segment

Segments returns a slice of Resource ID Segments which comprise this Compute Policies ID

func (ComputePoliciesId) String

func (id ComputePoliciesId) String() string

String returns a human-readable description of this Compute Policies ID

type ComputePolicy

type ComputePolicy struct {
	Id         *string                  `json:"id,omitempty"`
	Name       *string                  `json:"name,omitempty"`
	Properties *ComputePolicyProperties `json:"properties,omitempty"`
	Type       *string                  `json:"type,omitempty"`
}

type ComputePolicyOperationPredicate

type ComputePolicyOperationPredicate struct {
	Id   *string
	Name *string
	Type *string
}

func (ComputePolicyOperationPredicate) Matches

type ComputePolicyProperties

type ComputePolicyProperties struct {
	MaxDegreeOfParallelismPerJob *int64         `json:"maxDegreeOfParallelismPerJob,omitempty"`
	MinPriorityPerJob            *int64         `json:"minPriorityPerJob,omitempty"`
	ObjectId                     *string        `json:"objectId,omitempty"`
	ObjectType                   *AADObjectType `json:"objectType,omitempty"`
}

type CreateOrUpdateComputePolicyParameters

type CreateOrUpdateComputePolicyParameters struct {
	Properties CreateOrUpdateComputePolicyProperties `json:"properties"`
}

type CreateOrUpdateComputePolicyProperties

type CreateOrUpdateComputePolicyProperties struct {
	MaxDegreeOfParallelismPerJob *int64        `json:"maxDegreeOfParallelismPerJob,omitempty"`
	MinPriorityPerJob            *int64        `json:"minPriorityPerJob,omitempty"`
	ObjectId                     string        `json:"objectId"`
	ObjectType                   AADObjectType `json:"objectType"`
}

type CreateOrUpdateOperationResponse

type CreateOrUpdateOperationResponse struct {
	HttpResponse *http.Response
	Model        *ComputePolicy
}

type DeleteOperationResponse

type DeleteOperationResponse struct {
	HttpResponse *http.Response
}

type GetOperationResponse

type GetOperationResponse struct {
	HttpResponse *http.Response
	Model        *ComputePolicy
}

type ListByAccountCompleteResult

type ListByAccountCompleteResult struct {
	Items []ComputePolicy
}

type ListByAccountOperationResponse

type ListByAccountOperationResponse struct {
	HttpResponse *http.Response
	Model        *[]ComputePolicy
	// contains filtered or unexported fields
}

func (ListByAccountOperationResponse) HasMore

func (ListByAccountOperationResponse) LoadMore

type UpdateComputePolicyParameters

type UpdateComputePolicyParameters struct {
	Properties *UpdateComputePolicyProperties `json:"properties,omitempty"`
}

type UpdateComputePolicyProperties

type UpdateComputePolicyProperties struct {
	MaxDegreeOfParallelismPerJob *int64         `json:"maxDegreeOfParallelismPerJob,omitempty"`
	MinPriorityPerJob            *int64         `json:"minPriorityPerJob,omitempty"`
	ObjectId                     *string        `json:"objectId,omitempty"`
	ObjectType                   *AADObjectType `json:"objectType,omitempty"`
}

type UpdateOperationResponse

type UpdateOperationResponse struct {
	HttpResponse *http.Response
	Model        *ComputePolicy
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL