policysets

package
v0.20230530.1154251 Latest Latest
Warning

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

Go to latest
Published: May 30, 2023 License: MPL-2.0 Imports: 7 Imported by: 1

README

github.com/hashicorp/go-azure-sdk/resource-manager/devtestlab/2018-09-15/policysets Documentation

The policysets SDK allows for interaction with the Azure Resource Manager Service devtestlab (API Version 2018-09-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/devtestlab/2018-09-15/policysets"

Client Initialization

client := policysets.NewPolicySetsClientWithBaseURI("https://management.azure.com")
client.Client.Authorizer = authorizer

Example Usage: PolicySetsClient.EvaluatePolicies

ctx := context.TODO()
id := policysets.NewPolicySetID("12345678-1234-9876-4563-123456789012", "example-resource-group", "labValue", "policySetValue")

payload := policysets.EvaluatePoliciesRequest{
	// ...
}


read, err := client.EvaluatePolicies(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 ValidatePolicySetID

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

ValidatePolicySetID checks that 'input' can be parsed as a Policy Set ID

Types

type EvaluatePoliciesOperationResponse

type EvaluatePoliciesOperationResponse struct {
	HttpResponse *http.Response
	Model        *EvaluatePoliciesResponse
}

type EvaluatePoliciesProperties

type EvaluatePoliciesProperties struct {
	FactData     *string `json:"factData,omitempty"`
	FactName     *string `json:"factName,omitempty"`
	UserObjectId *string `json:"userObjectId,omitempty"`
	ValueOffset  *string `json:"valueOffset,omitempty"`
}

type EvaluatePoliciesRequest

type EvaluatePoliciesRequest struct {
	Policies *[]EvaluatePoliciesProperties `json:"policies,omitempty"`
}

type EvaluatePoliciesResponse

type EvaluatePoliciesResponse struct {
	Results *[]PolicySetResult `json:"results,omitempty"`
}

type PolicySetId

type PolicySetId struct {
	SubscriptionId    string
	ResourceGroupName string
	LabName           string
	PolicySetName     string
}

PolicySetId is a struct representing the Resource ID for a Policy Set

func NewPolicySetID

func NewPolicySetID(subscriptionId string, resourceGroupName string, labName string, policySetName string) PolicySetId

NewPolicySetID returns a new PolicySetId struct

func ParsePolicySetID

func ParsePolicySetID(input string) (*PolicySetId, error)

ParsePolicySetID parses 'input' into a PolicySetId

func ParsePolicySetIDInsensitively

func ParsePolicySetIDInsensitively(input string) (*PolicySetId, error)

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

func (PolicySetId) ID

func (id PolicySetId) ID() string

ID returns the formatted Policy Set ID

func (PolicySetId) Segments

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

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

func (PolicySetId) String

func (id PolicySetId) String() string

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

type PolicySetResult

type PolicySetResult struct {
	HasError         *bool              `json:"hasError,omitempty"`
	PolicyViolations *[]PolicyViolation `json:"policyViolations,omitempty"`
}

type PolicySetsClient

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

func NewPolicySetsClientWithBaseURI

func NewPolicySetsClientWithBaseURI(endpoint string) PolicySetsClient

func (PolicySetsClient) EvaluatePolicies

EvaluatePolicies ...

type PolicyViolation

type PolicyViolation struct {
	Code    *string `json:"code,omitempty"`
	Message *string `json:"message,omitempty"`
}

Jump to

Keyboard shortcuts

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