compliancepolicy

package
v0.20241126.2320 Latest Latest
Warning

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

Go to latest
Published: Nov 26, 2024 License: MPL-2.0 Imports: 8 Imported by: 0

README

github.com/hashicorp/go-azure-sdk/microsoft-graph/devicemanagement/beta/compliancepolicy Documentation

The compliancepolicy SDK allows for interaction with Microsoft Graph devicemanagement (API Version beta).

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/microsoft-graph/devicemanagement/beta/compliancepolicy"

Client Initialization

client := compliancepolicy.NewCompliancePolicyClientWithBaseURI("https://graph.microsoft.com")
client.Client.Authorizer = authorizer

Example Usage: CompliancePolicyClient.AssignCompliancePolicies

ctx := context.TODO()
id := compliancepolicy.NewDeviceManagementCompliancePolicyID("deviceManagementCompliancePolicyId")

payload := compliancepolicy.AssignCompliancePoliciesRequest{
	// ...
}


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

Example Usage: CompliancePolicyClient.CreateCompliancePolicy

ctx := context.TODO()

payload := compliancepolicy.DeviceManagementCompliancePolicy{
	// ...
}


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

Example Usage: CompliancePolicyClient.DeleteCompliancePolicy

ctx := context.TODO()
id := compliancepolicy.NewDeviceManagementCompliancePolicyID("deviceManagementCompliancePolicyId")

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

Example Usage: CompliancePolicyClient.GetCompliancePoliciesCount

ctx := context.TODO()


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

Example Usage: CompliancePolicyClient.GetCompliancePolicy

ctx := context.TODO()
id := compliancepolicy.NewDeviceManagementCompliancePolicyID("deviceManagementCompliancePolicyId")

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

Example Usage: CompliancePolicyClient.ListCompliancePolicies

ctx := context.TODO()


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

Example Usage: CompliancePolicyClient.SetCompliancePolicyScheduledActions

ctx := context.TODO()
id := compliancepolicy.NewDeviceManagementCompliancePolicyID("deviceManagementCompliancePolicyId")

payload := compliancepolicy.SetCompliancePolicyScheduledActionsRequest{
	// ...
}


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

Example Usage: CompliancePolicyClient.UpdateCompliancePolicy

ctx := context.TODO()
id := compliancepolicy.NewDeviceManagementCompliancePolicyID("deviceManagementCompliancePolicyId")

payload := compliancepolicy.DeviceManagementCompliancePolicy{
	// ...
}


read, err := client.UpdateCompliancePolicy(ctx, id, payload, compliancepolicy.DefaultUpdateCompliancePolicyOperationOptions())
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

This section is empty.

Types

type AssignCompliancePoliciesCompleteResult

type AssignCompliancePoliciesCompleteResult struct {
	LatestHttpResponse *http.Response
	Items              []beta.DeviceManagementConfigurationPolicyAssignment
}

type AssignCompliancePoliciesCustomPager

type AssignCompliancePoliciesCustomPager struct {
	NextLink *odata.Link `json:"@odata.nextLink"`
}
func (p *AssignCompliancePoliciesCustomPager) NextPageLink() *odata.Link

type AssignCompliancePoliciesOperationOptions

type AssignCompliancePoliciesOperationOptions struct {
	Metadata  *odata.Metadata
	RetryFunc client.RequestRetryFunc
	Skip      *int64
	Top       *int64
}

func DefaultAssignCompliancePoliciesOperationOptions

func DefaultAssignCompliancePoliciesOperationOptions() AssignCompliancePoliciesOperationOptions

func (AssignCompliancePoliciesOperationOptions) ToHeaders

func (AssignCompliancePoliciesOperationOptions) ToOData

func (AssignCompliancePoliciesOperationOptions) ToQuery

type AssignCompliancePoliciesOperationResponse

type AssignCompliancePoliciesOperationResponse struct {
	HttpResponse *http.Response
	OData        *odata.OData
	Model        *[]beta.DeviceManagementConfigurationPolicyAssignment
}

type AssignCompliancePoliciesRequest

type AssignCompliancePoliciesRequest struct {
	Assignments *[]beta.DeviceManagementConfigurationPolicyAssignment `json:"assignments,omitempty"`
}

type CompliancePolicyClient

type CompliancePolicyClient struct {
	Client *msgraph.Client
}

func NewCompliancePolicyClientWithBaseURI

func NewCompliancePolicyClientWithBaseURI(sdkApi sdkEnv.Api) (*CompliancePolicyClient, error)

func (CompliancePolicyClient) AssignCompliancePolicies

AssignCompliancePolicies - Invoke action assign

func (CompliancePolicyClient) AssignCompliancePoliciesComplete

AssignCompliancePoliciesComplete retrieves all the results into a single object

func (CompliancePolicyClient) AssignCompliancePoliciesCompleteMatchingPredicate

AssignCompliancePoliciesCompleteMatchingPredicate retrieves all the results and then applies the predicate

func (CompliancePolicyClient) CreateCompliancePolicy

CreateCompliancePolicy - Create new navigation property to compliancePolicies for deviceManagement

func (CompliancePolicyClient) DeleteCompliancePolicy

DeleteCompliancePolicy - Delete navigation property compliancePolicies for deviceManagement

func (CompliancePolicyClient) GetCompliancePoliciesCount

GetCompliancePoliciesCount - Get the number of the resource

func (CompliancePolicyClient) GetCompliancePolicy

GetCompliancePolicy - Get compliancePolicies from deviceManagement. List of all compliance policies

func (CompliancePolicyClient) ListCompliancePolicies

ListCompliancePolicies - Get compliancePolicies from deviceManagement. List of all compliance policies

func (CompliancePolicyClient) ListCompliancePoliciesComplete

ListCompliancePoliciesComplete retrieves all the results into a single object

func (CompliancePolicyClient) ListCompliancePoliciesCompleteMatchingPredicate

ListCompliancePoliciesCompleteMatchingPredicate retrieves all the results and then applies the predicate

func (CompliancePolicyClient) SetCompliancePolicyScheduledActions

SetCompliancePolicyScheduledActions - Invoke action setScheduledActions

func (CompliancePolicyClient) SetCompliancePolicyScheduledActionsComplete

SetCompliancePolicyScheduledActionsComplete retrieves all the results into a single object

func (CompliancePolicyClient) SetCompliancePolicyScheduledActionsCompleteMatchingPredicate

SetCompliancePolicyScheduledActionsCompleteMatchingPredicate retrieves all the results and then applies the predicate

func (CompliancePolicyClient) UpdateCompliancePolicy

UpdateCompliancePolicy - Update the navigation property compliancePolicies in deviceManagement

type CreateCompliancePolicyOperationOptions

type CreateCompliancePolicyOperationOptions struct {
	Metadata  *odata.Metadata
	RetryFunc client.RequestRetryFunc
}

func DefaultCreateCompliancePolicyOperationOptions

func DefaultCreateCompliancePolicyOperationOptions() CreateCompliancePolicyOperationOptions

func (CreateCompliancePolicyOperationOptions) ToHeaders

func (CreateCompliancePolicyOperationOptions) ToOData

func (CreateCompliancePolicyOperationOptions) ToQuery

type CreateCompliancePolicyOperationResponse

type CreateCompliancePolicyOperationResponse struct {
	HttpResponse *http.Response
	OData        *odata.OData
	Model        *beta.DeviceManagementCompliancePolicy
}

type DeleteCompliancePolicyOperationOptions

type DeleteCompliancePolicyOperationOptions struct {
	IfMatch   *string
	Metadata  *odata.Metadata
	RetryFunc client.RequestRetryFunc
}

func DefaultDeleteCompliancePolicyOperationOptions

func DefaultDeleteCompliancePolicyOperationOptions() DeleteCompliancePolicyOperationOptions

func (DeleteCompliancePolicyOperationOptions) ToHeaders

func (DeleteCompliancePolicyOperationOptions) ToOData

func (DeleteCompliancePolicyOperationOptions) ToQuery

type DeleteCompliancePolicyOperationResponse

type DeleteCompliancePolicyOperationResponse struct {
	HttpResponse *http.Response
	OData        *odata.OData
}

type DeviceManagementCompliancePolicyOperationPredicate

type DeviceManagementCompliancePolicyOperationPredicate struct {
}

func (DeviceManagementCompliancePolicyOperationPredicate) Matches

type DeviceManagementComplianceScheduledActionForRuleOperationPredicate

type DeviceManagementComplianceScheduledActionForRuleOperationPredicate struct {
}

func (DeviceManagementComplianceScheduledActionForRuleOperationPredicate) Matches

type DeviceManagementConfigurationPolicyAssignmentOperationPredicate

type DeviceManagementConfigurationPolicyAssignmentOperationPredicate struct {
}

func (DeviceManagementConfigurationPolicyAssignmentOperationPredicate) Matches

type GetCompliancePoliciesCountOperationOptions

type GetCompliancePoliciesCountOperationOptions struct {
	Filter    *string
	Metadata  *odata.Metadata
	RetryFunc client.RequestRetryFunc
	Search    *string
}

func DefaultGetCompliancePoliciesCountOperationOptions

func DefaultGetCompliancePoliciesCountOperationOptions() GetCompliancePoliciesCountOperationOptions

func (GetCompliancePoliciesCountOperationOptions) ToHeaders

func (GetCompliancePoliciesCountOperationOptions) ToOData

func (GetCompliancePoliciesCountOperationOptions) ToQuery

type GetCompliancePoliciesCountOperationResponse

type GetCompliancePoliciesCountOperationResponse struct {
	HttpResponse *http.Response
	OData        *odata.OData
	Model        *[]byte
}

type GetCompliancePolicyOperationOptions

type GetCompliancePolicyOperationOptions struct {
	Expand    *odata.Expand
	Metadata  *odata.Metadata
	RetryFunc client.RequestRetryFunc
	Select    *[]string
}

func DefaultGetCompliancePolicyOperationOptions

func DefaultGetCompliancePolicyOperationOptions() GetCompliancePolicyOperationOptions

func (GetCompliancePolicyOperationOptions) ToHeaders

func (GetCompliancePolicyOperationOptions) ToOData

func (GetCompliancePolicyOperationOptions) ToQuery

type GetCompliancePolicyOperationResponse

type GetCompliancePolicyOperationResponse struct {
	HttpResponse *http.Response
	OData        *odata.OData
	Model        *beta.DeviceManagementCompliancePolicy
}

type ListCompliancePoliciesCompleteResult

type ListCompliancePoliciesCompleteResult struct {
	LatestHttpResponse *http.Response
	Items              []beta.DeviceManagementCompliancePolicy
}

type ListCompliancePoliciesCustomPager

type ListCompliancePoliciesCustomPager struct {
	NextLink *odata.Link `json:"@odata.nextLink"`
}
func (p *ListCompliancePoliciesCustomPager) NextPageLink() *odata.Link

type ListCompliancePoliciesOperationOptions

type ListCompliancePoliciesOperationOptions struct {
	Count     *bool
	Expand    *odata.Expand
	Filter    *string
	Metadata  *odata.Metadata
	OrderBy   *odata.OrderBy
	RetryFunc client.RequestRetryFunc
	Search    *string
	Select    *[]string
	Skip      *int64
	Top       *int64
}

func DefaultListCompliancePoliciesOperationOptions

func DefaultListCompliancePoliciesOperationOptions() ListCompliancePoliciesOperationOptions

func (ListCompliancePoliciesOperationOptions) ToHeaders

func (ListCompliancePoliciesOperationOptions) ToOData

func (ListCompliancePoliciesOperationOptions) ToQuery

type ListCompliancePoliciesOperationResponse

type ListCompliancePoliciesOperationResponse struct {
	HttpResponse *http.Response
	OData        *odata.OData
	Model        *[]beta.DeviceManagementCompliancePolicy
}

type SetCompliancePolicyScheduledActionsCompleteResult

type SetCompliancePolicyScheduledActionsCompleteResult struct {
	LatestHttpResponse *http.Response
	Items              []beta.DeviceManagementComplianceScheduledActionForRule
}

type SetCompliancePolicyScheduledActionsCustomPager

type SetCompliancePolicyScheduledActionsCustomPager struct {
	NextLink *odata.Link `json:"@odata.nextLink"`
}

type SetCompliancePolicyScheduledActionsOperationOptions

type SetCompliancePolicyScheduledActionsOperationOptions struct {
	Metadata  *odata.Metadata
	RetryFunc client.RequestRetryFunc
	Skip      *int64
	Top       *int64
}

func DefaultSetCompliancePolicyScheduledActionsOperationOptions

func DefaultSetCompliancePolicyScheduledActionsOperationOptions() SetCompliancePolicyScheduledActionsOperationOptions

func (SetCompliancePolicyScheduledActionsOperationOptions) ToHeaders

func (SetCompliancePolicyScheduledActionsOperationOptions) ToOData

func (SetCompliancePolicyScheduledActionsOperationOptions) ToQuery

type SetCompliancePolicyScheduledActionsOperationResponse

type SetCompliancePolicyScheduledActionsOperationResponse struct {
	HttpResponse *http.Response
	OData        *odata.OData
	Model        *[]beta.DeviceManagementComplianceScheduledActionForRule
}

type SetCompliancePolicyScheduledActionsRequest

type SetCompliancePolicyScheduledActionsRequest struct {
	ScheduledActions *[]beta.DeviceManagementComplianceScheduledActionForRule `json:"scheduledActions,omitempty"`
}

type UpdateCompliancePolicyOperationOptions

type UpdateCompliancePolicyOperationOptions struct {
	Metadata  *odata.Metadata
	RetryFunc client.RequestRetryFunc
}

func DefaultUpdateCompliancePolicyOperationOptions

func DefaultUpdateCompliancePolicyOperationOptions() UpdateCompliancePolicyOperationOptions

func (UpdateCompliancePolicyOperationOptions) ToHeaders

func (UpdateCompliancePolicyOperationOptions) ToOData

func (UpdateCompliancePolicyOperationOptions) ToQuery

type UpdateCompliancePolicyOperationResponse

type UpdateCompliancePolicyOperationResponse struct {
	HttpResponse *http.Response
	OData        *odata.OData
}

Jump to

Keyboard shortcuts

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