tagrules

package
v0.0.0-...-a81a29a Latest Latest
Warning

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

Go to latest
Published: Jun 15, 2023 License: MPL-2.0 Imports: 9 Imported by: 0

README

github.com/hashicorp/go-azure-sdk/resource-manager/logz/2020-10-01/tagrules Documentation

The tagrules SDK allows for interaction with the Azure Resource Manager Service logz (API Version 2020-10-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/logz/2020-10-01/tagrules"

Client Initialization

client := tagrules.NewTagRulesClientWithBaseURI("https://management.azure.com")
client.Client.Authorizer = authorizer

Example Usage: TagRulesClient.CreateOrUpdate

ctx := context.TODO()
id := tagrules.NewTagRuleID("12345678-1234-9876-4563-123456789012", "example-resource-group", "monitorValue", "tagRuleValue")

payload := tagrules.MonitoringTagRules{
	// ...
}


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

ctx := context.TODO()
id := tagrules.NewTagRuleID("12345678-1234-9876-4563-123456789012", "example-resource-group", "monitorValue", "tagRuleValue")

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

ctx := context.TODO()
id := tagrules.NewTagRuleID("12345678-1234-9876-4563-123456789012", "example-resource-group", "monitorValue", "tagRuleValue")

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: TagRulesClient.List

ctx := context.TODO()
id := tagrules.NewMonitorID("12345678-1234-9876-4563-123456789012", "example-resource-group", "monitorValue")

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

Example Usage: TagRulesClient.SubAccountTagRulesCreateOrUpdate

ctx := context.TODO()
id := tagrules.NewAccountTagRuleID("12345678-1234-9876-4563-123456789012", "example-resource-group", "monitorValue", "accountValue", "tagRuleValue")

payload := tagrules.MonitoringTagRules{
	// ...
}


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

Example Usage: TagRulesClient.SubAccountTagRulesDelete

ctx := context.TODO()
id := tagrules.NewAccountTagRuleID("12345678-1234-9876-4563-123456789012", "example-resource-group", "monitorValue", "accountValue", "tagRuleValue")

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

Example Usage: TagRulesClient.SubAccountTagRulesGet

ctx := context.TODO()
id := tagrules.NewAccountTagRuleID("12345678-1234-9876-4563-123456789012", "example-resource-group", "monitorValue", "accountValue", "tagRuleValue")

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

Example Usage: TagRulesClient.SubAccountTagRulesList

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

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

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func PossibleValuesForProvisioningState

func PossibleValuesForProvisioningState() []string

func PossibleValuesForTagAction

func PossibleValuesForTagAction() []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 ValidateAccountTagRuleID

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

ValidateAccountTagRuleID checks that 'input' can be parsed as a Account Tag Rule ID

func ValidateMonitorID

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

ValidateMonitorID checks that 'input' can be parsed as a Monitor ID

func ValidateTagRuleID

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

ValidateTagRuleID checks that 'input' can be parsed as a Tag Rule ID

Types

type AccountId

type AccountId struct {
	SubscriptionId    string
	ResourceGroupName string
	MonitorName       string
	AccountName       string
}

AccountId is a struct representing the Resource ID for a Account

func NewAccountID

func NewAccountID(subscriptionId string, resourceGroupName string, monitorName 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 AccountTagRuleId

type AccountTagRuleId struct {
	SubscriptionId    string
	ResourceGroupName string
	MonitorName       string
	AccountName       string
	TagRuleName       string
}

AccountTagRuleId is a struct representing the Resource ID for a Account Tag Rule

func NewAccountTagRuleID

func NewAccountTagRuleID(subscriptionId string, resourceGroupName string, monitorName string, accountName string, tagRuleName string) AccountTagRuleId

NewAccountTagRuleID returns a new AccountTagRuleId struct

func ParseAccountTagRuleID

func ParseAccountTagRuleID(input string) (*AccountTagRuleId, error)

ParseAccountTagRuleID parses 'input' into a AccountTagRuleId

func ParseAccountTagRuleIDInsensitively

func ParseAccountTagRuleIDInsensitively(input string) (*AccountTagRuleId, error)

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

func (AccountTagRuleId) ID

func (id AccountTagRuleId) ID() string

ID returns the formatted Account Tag Rule ID

func (AccountTagRuleId) Segments

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

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

func (AccountTagRuleId) String

func (id AccountTagRuleId) String() string

String returns a human-readable description of this Account Tag Rule ID

type CreateOrUpdateOperationResponse

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

type DeleteOperationResponse

type DeleteOperationResponse struct {
	HttpResponse *http.Response
}

type FilteringTag

type FilteringTag struct {
	Action *TagAction `json:"action,omitempty"`
	Name   *string    `json:"name,omitempty"`
	Value  *string    `json:"value,omitempty"`
}

type GetOperationResponse

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

type ListCompleteResult

type ListCompleteResult struct {
	Items []MonitoringTagRules
}

type ListOperationResponse

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

func (ListOperationResponse) HasMore

func (r ListOperationResponse) HasMore() bool

func (ListOperationResponse) LoadMore

func (r ListOperationResponse) LoadMore(ctx context.Context) (resp ListOperationResponse, err error)

type LogRules

type LogRules struct {
	FilteringTags        *[]FilteringTag `json:"filteringTags,omitempty"`
	SendAadLogs          *bool           `json:"sendAadLogs,omitempty"`
	SendActivityLogs     *bool           `json:"sendActivityLogs,omitempty"`
	SendSubscriptionLogs *bool           `json:"sendSubscriptionLogs,omitempty"`
}

type MonitorId

type MonitorId struct {
	SubscriptionId    string
	ResourceGroupName string
	MonitorName       string
}

MonitorId is a struct representing the Resource ID for a Monitor

func NewMonitorID

func NewMonitorID(subscriptionId string, resourceGroupName string, monitorName string) MonitorId

NewMonitorID returns a new MonitorId struct

func ParseMonitorID

func ParseMonitorID(input string) (*MonitorId, error)

ParseMonitorID parses 'input' into a MonitorId

func ParseMonitorIDInsensitively

func ParseMonitorIDInsensitively(input string) (*MonitorId, error)

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

func (MonitorId) ID

func (id MonitorId) ID() string

ID returns the formatted Monitor ID

func (MonitorId) Segments

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

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

func (MonitorId) String

func (id MonitorId) String() string

String returns a human-readable description of this Monitor ID

type MonitoringTagRules

type MonitoringTagRules struct {
	Id         *string                       `json:"id,omitempty"`
	Name       *string                       `json:"name,omitempty"`
	Properties *MonitoringTagRulesProperties `json:"properties,omitempty"`
	SystemData *systemdata.SystemData        `json:"systemData,omitempty"`
	Type       *string                       `json:"type,omitempty"`
}

type MonitoringTagRulesOperationPredicate

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

func (MonitoringTagRulesOperationPredicate) Matches

type MonitoringTagRulesProperties

type MonitoringTagRulesProperties struct {
	LogRules          *LogRules              `json:"logRules,omitempty"`
	ProvisioningState *ProvisioningState     `json:"provisioningState,omitempty"`
	SystemData        *systemdata.SystemData `json:"systemData,omitempty"`
}

type ProvisioningState

type ProvisioningState string
const (
	ProvisioningStateAccepted     ProvisioningState = "Accepted"
	ProvisioningStateCanceled     ProvisioningState = "Canceled"
	ProvisioningStateCreating     ProvisioningState = "Creating"
	ProvisioningStateDeleted      ProvisioningState = "Deleted"
	ProvisioningStateDeleting     ProvisioningState = "Deleting"
	ProvisioningStateFailed       ProvisioningState = "Failed"
	ProvisioningStateNotSpecified ProvisioningState = "NotSpecified"
	ProvisioningStateSucceeded    ProvisioningState = "Succeeded"
	ProvisioningStateUpdating     ProvisioningState = "Updating"
)

type SubAccountTagRulesCreateOrUpdateOperationResponse

type SubAccountTagRulesCreateOrUpdateOperationResponse struct {
	HttpResponse *http.Response
	Model        *MonitoringTagRules
}

type SubAccountTagRulesDeleteOperationResponse

type SubAccountTagRulesDeleteOperationResponse struct {
	HttpResponse *http.Response
}

type SubAccountTagRulesGetOperationResponse

type SubAccountTagRulesGetOperationResponse struct {
	HttpResponse *http.Response
	Model        *MonitoringTagRules
}

type SubAccountTagRulesListCompleteResult

type SubAccountTagRulesListCompleteResult struct {
	Items []MonitoringTagRules
}

type SubAccountTagRulesListOperationResponse

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

func (SubAccountTagRulesListOperationResponse) HasMore

func (SubAccountTagRulesListOperationResponse) LoadMore

type TagAction

type TagAction string
const (
	TagActionExclude TagAction = "Exclude"
	TagActionInclude TagAction = "Include"
)

type TagRuleId

type TagRuleId struct {
	SubscriptionId    string
	ResourceGroupName string
	MonitorName       string
	TagRuleName       string
}

TagRuleId is a struct representing the Resource ID for a Tag Rule

func NewTagRuleID

func NewTagRuleID(subscriptionId string, resourceGroupName string, monitorName string, tagRuleName string) TagRuleId

NewTagRuleID returns a new TagRuleId struct

func ParseTagRuleID

func ParseTagRuleID(input string) (*TagRuleId, error)

ParseTagRuleID parses 'input' into a TagRuleId

func ParseTagRuleIDInsensitively

func ParseTagRuleIDInsensitively(input string) (*TagRuleId, error)

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

func (TagRuleId) ID

func (id TagRuleId) ID() string

ID returns the formatted Tag Rule ID

func (TagRuleId) Segments

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

Segments returns a slice of Resource ID Segments which comprise this Tag Rule ID

func (TagRuleId) String

func (id TagRuleId) String() string

String returns a human-readable description of this Tag Rule ID

type TagRulesClient

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

func NewTagRulesClientWithBaseURI

func NewTagRulesClientWithBaseURI(endpoint string) TagRulesClient

func (TagRulesClient) CreateOrUpdate

func (c TagRulesClient) CreateOrUpdate(ctx context.Context, id TagRuleId, input MonitoringTagRules) (result CreateOrUpdateOperationResponse, err error)

CreateOrUpdate ...

func (TagRulesClient) Delete

func (c TagRulesClient) Delete(ctx context.Context, id TagRuleId) (result DeleteOperationResponse, err error)

Delete ...

func (TagRulesClient) Get

func (c TagRulesClient) Get(ctx context.Context, id TagRuleId) (result GetOperationResponse, err error)

Get ...

func (TagRulesClient) List

func (c TagRulesClient) List(ctx context.Context, id MonitorId) (resp ListOperationResponse, err error)

List ...

func (TagRulesClient) ListComplete

func (c TagRulesClient) ListComplete(ctx context.Context, id MonitorId) (ListCompleteResult, error)

ListComplete retrieves all of the results into a single object

func (TagRulesClient) ListCompleteMatchingPredicate

func (c TagRulesClient) ListCompleteMatchingPredicate(ctx context.Context, id MonitorId, predicate MonitoringTagRulesOperationPredicate) (resp ListCompleteResult, err error)

ListCompleteMatchingPredicate retrieves all of the results and then applied the predicate

func (TagRulesClient) SubAccountTagRulesCreateOrUpdate

func (c TagRulesClient) SubAccountTagRulesCreateOrUpdate(ctx context.Context, id AccountTagRuleId, input MonitoringTagRules) (result SubAccountTagRulesCreateOrUpdateOperationResponse, err error)

SubAccountTagRulesCreateOrUpdate ...

func (TagRulesClient) SubAccountTagRulesDelete

func (c TagRulesClient) SubAccountTagRulesDelete(ctx context.Context, id AccountTagRuleId) (result SubAccountTagRulesDeleteOperationResponse, err error)

SubAccountTagRulesDelete ...

func (TagRulesClient) SubAccountTagRulesGet

func (c TagRulesClient) SubAccountTagRulesGet(ctx context.Context, id AccountTagRuleId) (result SubAccountTagRulesGetOperationResponse, err error)

SubAccountTagRulesGet ...

func (TagRulesClient) SubAccountTagRulesList

func (c TagRulesClient) SubAccountTagRulesList(ctx context.Context, id AccountId) (resp SubAccountTagRulesListOperationResponse, err error)

SubAccountTagRulesList ...

func (TagRulesClient) SubAccountTagRulesListComplete

func (c TagRulesClient) SubAccountTagRulesListComplete(ctx context.Context, id AccountId) (SubAccountTagRulesListCompleteResult, error)

SubAccountTagRulesListComplete retrieves all of the results into a single object

func (TagRulesClient) SubAccountTagRulesListCompleteMatchingPredicate

func (c TagRulesClient) SubAccountTagRulesListCompleteMatchingPredicate(ctx context.Context, id AccountId, predicate MonitoringTagRulesOperationPredicate) (resp SubAccountTagRulesListCompleteResult, err error)

SubAccountTagRulesListCompleteMatchingPredicate retrieves all of the results and then applied the predicate

Jump to

Keyboard shortcuts

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