adminrulecollections

package
v0.20240425.1225320 Latest Latest
Warning

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

Go to latest
Published: Apr 25, 2024 License: MPL-2.0 Imports: 13 Imported by: 0

README

github.com/hashicorp/go-azure-sdk/resource-manager/network/2023-04-01/adminrulecollections Documentation

The adminrulecollections SDK allows for interaction with the Azure Resource Manager Service network (API Version 2023-04-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/network/2023-04-01/adminrulecollections"

Client Initialization

client := adminrulecollections.NewAdminRuleCollectionsClientWithBaseURI("https://management.azure.com")
client.Client.Authorizer = authorizer

Example Usage: AdminRuleCollectionsClient.CreateOrUpdate

ctx := context.TODO()
id := adminrulecollections.NewRuleCollectionID("12345678-1234-9876-4563-123456789012", "example-resource-group", "networkManagerValue", "securityAdminConfigurationValue", "ruleCollectionValue")

payload := adminrulecollections.AdminRuleCollection{
	// ...
}


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

ctx := context.TODO()
id := adminrulecollections.NewRuleCollectionID("12345678-1234-9876-4563-123456789012", "example-resource-group", "networkManagerValue", "securityAdminConfigurationValue", "ruleCollectionValue")

if err := client.DeleteThenPoll(ctx, id, adminrulecollections.DefaultDeleteOperationOptions()); err != nil {
	// handle the error
}

Example Usage: AdminRuleCollectionsClient.Get

ctx := context.TODO()
id := adminrulecollections.NewRuleCollectionID("12345678-1234-9876-4563-123456789012", "example-resource-group", "networkManagerValue", "securityAdminConfigurationValue", "ruleCollectionValue")

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

ctx := context.TODO()
id := adminrulecollections.NewSecurityAdminConfigurationID("12345678-1234-9876-4563-123456789012", "example-resource-group", "networkManagerValue", "securityAdminConfigurationValue")

// alternatively `client.List(ctx, id, adminrulecollections.DefaultListOperationOptions())` can be used to do batched pagination
items, err := client.ListComplete(ctx, id, adminrulecollections.DefaultListOperationOptions())
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 ValidateRuleCollectionID

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

ValidateRuleCollectionID checks that 'input' can be parsed as a Rule Collection ID

func ValidateSecurityAdminConfigurationID

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

ValidateSecurityAdminConfigurationID checks that 'input' can be parsed as a Security Admin Configuration ID

Types

type AdminRuleCollection

type AdminRuleCollection struct {
	Etag       *string                              `json:"etag,omitempty"`
	Id         *string                              `json:"id,omitempty"`
	Name       *string                              `json:"name,omitempty"`
	Properties *AdminRuleCollectionPropertiesFormat `json:"properties,omitempty"`
	SystemData *systemdata.SystemData               `json:"systemData,omitempty"`
	Type       *string                              `json:"type,omitempty"`
}

type AdminRuleCollectionOperationPredicate

type AdminRuleCollectionOperationPredicate struct {
	Etag *string
	Id   *string
	Name *string
	Type *string
}

func (AdminRuleCollectionOperationPredicate) Matches

type AdminRuleCollectionPropertiesFormat

type AdminRuleCollectionPropertiesFormat struct {
	AppliesToGroups   []NetworkManagerSecurityGroupItem `json:"appliesToGroups"`
	Description       *string                           `json:"description,omitempty"`
	ProvisioningState *ProvisioningState                `json:"provisioningState,omitempty"`
	ResourceGuid      *string                           `json:"resourceGuid,omitempty"`
}

type AdminRuleCollectionsClient

type AdminRuleCollectionsClient struct {
	Client *resourcemanager.Client
}

func NewAdminRuleCollectionsClientWithBaseURI

func NewAdminRuleCollectionsClientWithBaseURI(sdkApi sdkEnv.Api) (*AdminRuleCollectionsClient, error)

func (AdminRuleCollectionsClient) CreateOrUpdate

CreateOrUpdate ...

func (AdminRuleCollectionsClient) Delete

Delete ...

func (AdminRuleCollectionsClient) DeleteThenPoll

DeleteThenPoll performs Delete then polls until it's completed

func (AdminRuleCollectionsClient) Get

Get ...

func (AdminRuleCollectionsClient) List

List ...

func (AdminRuleCollectionsClient) ListComplete

ListComplete retrieves all the results into a single object

func (AdminRuleCollectionsClient) ListCompleteMatchingPredicate

ListCompleteMatchingPredicate retrieves all the results and then applies the predicate

type CreateOrUpdateOperationResponse

type CreateOrUpdateOperationResponse struct {
	HttpResponse *http.Response
	OData        *odata.OData
	Model        *AdminRuleCollection
}

type DeleteOperationOptions

type DeleteOperationOptions struct {
	Force *bool
}

func DefaultDeleteOperationOptions

func DefaultDeleteOperationOptions() DeleteOperationOptions

func (DeleteOperationOptions) ToHeaders

func (o DeleteOperationOptions) ToHeaders() *client.Headers

func (DeleteOperationOptions) ToOData

func (o DeleteOperationOptions) ToOData() *odata.Query

func (DeleteOperationOptions) ToQuery

type DeleteOperationResponse

type DeleteOperationResponse struct {
	Poller       pollers.Poller
	HttpResponse *http.Response
	OData        *odata.OData
}

type GetOperationResponse

type GetOperationResponse struct {
	HttpResponse *http.Response
	OData        *odata.OData
	Model        *AdminRuleCollection
}

type ListCompleteResult

type ListCompleteResult struct {
	LatestHttpResponse *http.Response
	Items              []AdminRuleCollection
}

type ListOperationOptions

type ListOperationOptions struct {
	Top *int64
}

func DefaultListOperationOptions

func DefaultListOperationOptions() ListOperationOptions

func (ListOperationOptions) ToHeaders

func (o ListOperationOptions) ToHeaders() *client.Headers

func (ListOperationOptions) ToOData

func (o ListOperationOptions) ToOData() *odata.Query

func (ListOperationOptions) ToQuery

type ListOperationResponse

type ListOperationResponse struct {
	HttpResponse *http.Response
	OData        *odata.OData
	Model        *[]AdminRuleCollection
}

type NetworkManagerSecurityGroupItem

type NetworkManagerSecurityGroupItem struct {
	NetworkGroupId string `json:"networkGroupId"`
}

type ProvisioningState

type ProvisioningState string
const (
	ProvisioningStateDeleting  ProvisioningState = "Deleting"
	ProvisioningStateFailed    ProvisioningState = "Failed"
	ProvisioningStateSucceeded ProvisioningState = "Succeeded"
	ProvisioningStateUpdating  ProvisioningState = "Updating"
)

func (*ProvisioningState) UnmarshalJSON

func (s *ProvisioningState) UnmarshalJSON(bytes []byte) error

type RuleCollectionId

type RuleCollectionId struct {
	SubscriptionId                 string
	ResourceGroupName              string
	NetworkManagerName             string
	SecurityAdminConfigurationName string
	RuleCollectionName             string
}

RuleCollectionId is a struct representing the Resource ID for a Rule Collection

func NewRuleCollectionID

func NewRuleCollectionID(subscriptionId string, resourceGroupName string, networkManagerName string, securityAdminConfigurationName string, ruleCollectionName string) RuleCollectionId

NewRuleCollectionID returns a new RuleCollectionId struct

func ParseRuleCollectionID

func ParseRuleCollectionID(input string) (*RuleCollectionId, error)

ParseRuleCollectionID parses 'input' into a RuleCollectionId

func ParseRuleCollectionIDInsensitively

func ParseRuleCollectionIDInsensitively(input string) (*RuleCollectionId, error)

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

func (*RuleCollectionId) FromParseResult

func (id *RuleCollectionId) FromParseResult(input resourceids.ParseResult) error

func (RuleCollectionId) ID

func (id RuleCollectionId) ID() string

ID returns the formatted Rule Collection ID

func (RuleCollectionId) Segments

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

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

func (RuleCollectionId) String

func (id RuleCollectionId) String() string

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

type SecurityAdminConfigurationId

type SecurityAdminConfigurationId struct {
	SubscriptionId                 string
	ResourceGroupName              string
	NetworkManagerName             string
	SecurityAdminConfigurationName string
}

SecurityAdminConfigurationId is a struct representing the Resource ID for a Security Admin Configuration

func NewSecurityAdminConfigurationID

func NewSecurityAdminConfigurationID(subscriptionId string, resourceGroupName string, networkManagerName string, securityAdminConfigurationName string) SecurityAdminConfigurationId

NewSecurityAdminConfigurationID returns a new SecurityAdminConfigurationId struct

func ParseSecurityAdminConfigurationID

func ParseSecurityAdminConfigurationID(input string) (*SecurityAdminConfigurationId, error)

ParseSecurityAdminConfigurationID parses 'input' into a SecurityAdminConfigurationId

func ParseSecurityAdminConfigurationIDInsensitively

func ParseSecurityAdminConfigurationIDInsensitively(input string) (*SecurityAdminConfigurationId, error)

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

func (*SecurityAdminConfigurationId) FromParseResult

func (id *SecurityAdminConfigurationId) FromParseResult(input resourceids.ParseResult) error

func (SecurityAdminConfigurationId) ID

ID returns the formatted Security Admin Configuration ID

func (SecurityAdminConfigurationId) Segments

Segments returns a slice of Resource ID Segments which comprise this Security Admin Configuration ID

func (SecurityAdminConfigurationId) String

String returns a human-readable description of this Security Admin Configuration ID

Jump to

Keyboard shortcuts

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