accesspolicies

package
v0.20230726.1135558 Latest Latest
Warning

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

Go to latest
Published: Jul 26, 2023 License: MPL-2.0 Imports: 7 Imported by: 0

README

github.com/hashicorp/go-azure-sdk/resource-manager/timeseriesinsights/2020-05-15/accesspolicies Documentation

The accesspolicies SDK allows for interaction with the Azure Resource Manager Service timeseriesinsights (API Version 2020-05-15).

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/timeseriesinsights/2020-05-15/accesspolicies"

Client Initialization

client := accesspolicies.NewAccessPoliciesClientWithBaseURI("https://management.azure.com")
client.Client.Authorizer = authorizer

Example Usage: AccessPoliciesClient.CreateOrUpdate

ctx := context.TODO()
id := accesspolicies.NewAccessPolicyID("12345678-1234-9876-4563-123456789012", "example-resource-group", "environmentValue", "accessPolicyValue")

payload := accesspolicies.AccessPolicyCreateOrUpdateParameters{
	// ...
}


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

ctx := context.TODO()
id := accesspolicies.NewAccessPolicyID("12345678-1234-9876-4563-123456789012", "example-resource-group", "environmentValue", "accessPolicyValue")

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

ctx := context.TODO()
id := accesspolicies.NewAccessPolicyID("12345678-1234-9876-4563-123456789012", "example-resource-group", "environmentValue", "accessPolicyValue")

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: AccessPoliciesClient.ListByEnvironment

ctx := context.TODO()
id := accesspolicies.NewEnvironmentID("12345678-1234-9876-4563-123456789012", "example-resource-group", "environmentValue")

read, err := client.ListByEnvironment(ctx, id)
if err != nil {
	// handle the error
}
if model := read.Model; model != nil {
	// do something with the model/response object
}

Example Usage: AccessPoliciesClient.Update

ctx := context.TODO()
id := accesspolicies.NewAccessPolicyID("12345678-1234-9876-4563-123456789012", "example-resource-group", "environmentValue", "accessPolicyValue")

payload := accesspolicies.AccessPolicyUpdateParameters{
	// ...
}


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 PossibleValuesForAccessPolicyRole

func PossibleValuesForAccessPolicyRole() []string

func ValidateAccessPolicyID

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

ValidateAccessPolicyID checks that 'input' can be parsed as a Access Policy ID

func ValidateEnvironmentID

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

ValidateEnvironmentID checks that 'input' can be parsed as a Environment ID

Types

type AccessPoliciesClient

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

func NewAccessPoliciesClientWithBaseURI

func NewAccessPoliciesClientWithBaseURI(endpoint string) AccessPoliciesClient

func (AccessPoliciesClient) CreateOrUpdate

CreateOrUpdate ...

func (AccessPoliciesClient) Delete

Delete ...

func (AccessPoliciesClient) Get

Get ...

func (AccessPoliciesClient) ListByEnvironment

ListByEnvironment ...

func (AccessPoliciesClient) Update

Update ...

type AccessPolicyCreateOrUpdateParameters

type AccessPolicyCreateOrUpdateParameters struct {
	Properties AccessPolicyResourceProperties `json:"properties"`
}

type AccessPolicyId

type AccessPolicyId struct {
	SubscriptionId    string
	ResourceGroupName string
	EnvironmentName   string
	AccessPolicyName  string
}

AccessPolicyId is a struct representing the Resource ID for a Access Policy

func NewAccessPolicyID

func NewAccessPolicyID(subscriptionId string, resourceGroupName string, environmentName string, accessPolicyName string) AccessPolicyId

NewAccessPolicyID returns a new AccessPolicyId struct

func ParseAccessPolicyID

func ParseAccessPolicyID(input string) (*AccessPolicyId, error)

ParseAccessPolicyID parses 'input' into a AccessPolicyId

func ParseAccessPolicyIDInsensitively

func ParseAccessPolicyIDInsensitively(input string) (*AccessPolicyId, error)

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

func (AccessPolicyId) ID

func (id AccessPolicyId) ID() string

ID returns the formatted Access Policy ID

func (AccessPolicyId) Segments

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

Segments returns a slice of Resource ID Segments which comprise this Access Policy ID

func (AccessPolicyId) String

func (id AccessPolicyId) String() string

String returns a human-readable description of this Access Policy ID

type AccessPolicyListResponse

type AccessPolicyListResponse struct {
	Value *[]AccessPolicyResource `json:"value,omitempty"`
}

type AccessPolicyMutableProperties

type AccessPolicyMutableProperties struct {
	Description *string             `json:"description,omitempty"`
	Roles       *[]AccessPolicyRole `json:"roles,omitempty"`
}

type AccessPolicyResource

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

type AccessPolicyResourceProperties

type AccessPolicyResourceProperties struct {
	Description       *string             `json:"description,omitempty"`
	PrincipalObjectId *string             `json:"principalObjectId,omitempty"`
	Roles             *[]AccessPolicyRole `json:"roles,omitempty"`
}

type AccessPolicyRole

type AccessPolicyRole string
const (
	AccessPolicyRoleContributor AccessPolicyRole = "Contributor"
	AccessPolicyRoleReader      AccessPolicyRole = "Reader"
)

type AccessPolicyUpdateParameters

type AccessPolicyUpdateParameters struct {
	Properties *AccessPolicyMutableProperties `json:"properties,omitempty"`
}

type CreateOrUpdateOperationResponse

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

type DeleteOperationResponse

type DeleteOperationResponse struct {
	HttpResponse *http.Response
}

type EnvironmentId

type EnvironmentId struct {
	SubscriptionId    string
	ResourceGroupName string
	EnvironmentName   string
}

EnvironmentId is a struct representing the Resource ID for a Environment

func NewEnvironmentID

func NewEnvironmentID(subscriptionId string, resourceGroupName string, environmentName string) EnvironmentId

NewEnvironmentID returns a new EnvironmentId struct

func ParseEnvironmentID

func ParseEnvironmentID(input string) (*EnvironmentId, error)

ParseEnvironmentID parses 'input' into a EnvironmentId

func ParseEnvironmentIDInsensitively

func ParseEnvironmentIDInsensitively(input string) (*EnvironmentId, error)

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

func (EnvironmentId) ID

func (id EnvironmentId) ID() string

ID returns the formatted Environment ID

func (EnvironmentId) Segments

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

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

func (EnvironmentId) String

func (id EnvironmentId) String() string

String returns a human-readable description of this Environment ID

type GetOperationResponse

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

type ListByEnvironmentOperationResponse

type ListByEnvironmentOperationResponse struct {
	HttpResponse *http.Response
	Model        *AccessPolicyListResponse
}

type UpdateOperationResponse

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

Jump to

Keyboard shortcuts

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