policyrules

package
v0.1.1 Latest Latest
Warning

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

Go to latest
Published: Jan 18, 2022 License: Apache-2.0 Imports: 6 Imported by: 1

Documentation

Overview

Package policyrules contains methods related to PolicyRules

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type PolicyRulesV1

type PolicyRulesV1 struct {
	// contains filtered or unexported fields
}

PolicyRulesV1 represents a custom type struct

func (*PolicyRulesV1) CreatePolicyRule

func (p *PolicyRulesV1) CreatePolicyRule(
	body *models.CreatePolicyRuleV1Request) (
	*models.CreateRuleResponse, *apiutils.APIError)

CreatePolicyRule Creates a new policy rule. Policy rules determine how a policy should be assigned to assets.

func (*PolicyRulesV1) DeletePolicyRule

func (p *PolicyRulesV1) DeletePolicyRule(
	ruleId string) (
	*models.DeleteRuleResponse, *apiutils.APIError)

DeletePolicyRule Deletes the specified policy rule.

func (*PolicyRulesV1) ListPolicyRules

func (p *PolicyRulesV1) ListPolicyRules(
	limit *int64,
	start *string,
	organizationalUnitId *string,
	sort *string,
	filter *string) (
	*models.ListRulesResponse, *apiutils.APIError)

ListPolicyRules Returns a list of policy rules.

func (*PolicyRulesV1) ReadPolicyRule

func (p *PolicyRulesV1) ReadPolicyRule(
	ruleId string) (
	*models.ReadRuleResponse, *apiutils.APIError)

ReadPolicyRule Returns a representation of the specified policy rule.

func (*PolicyRulesV1) UpdatePolicyRule

func (p *PolicyRulesV1) UpdatePolicyRule(
	ruleId string,
	body *models.UpdatePolicyRuleV1Request) (
	*models.UpdateRuleResponse, *apiutils.APIError)

UpdatePolicyRule Updates an existing policy rule.

type PolicyRulesV1Client

type PolicyRulesV1Client interface {
	//  Returns a list of policy rules.
	ListPolicyRules(
		limit *int64,
		start *string,
		organizationalUnitId *string,
		sort *string,
		filter *string) (
		*models.ListRulesResponse, *apiutils.APIError)

	//  Creates a new policy rule. Policy rules determine how a policy should be assigned to assets.
	CreatePolicyRule(
		body *models.CreatePolicyRuleV1Request) (
		*models.CreateRuleResponse, *apiutils.APIError)

	//  Returns a representation of the specified policy rule.
	ReadPolicyRule(
		ruleId string) (
		*models.ReadRuleResponse, *apiutils.APIError)

	//  Updates an existing policy rule.
	UpdatePolicyRule(
		ruleId string,
		body *models.UpdatePolicyRuleV1Request) (
		*models.UpdateRuleResponse, *apiutils.APIError)

	//  Deletes the specified policy rule.
	DeletePolicyRule(
		ruleId string) (
		*models.DeleteRuleResponse, *apiutils.APIError)
}

PolicyRulesV1Client represents a custom type interface

func NewPolicyRulesV1

func NewPolicyRulesV1(config config.Config) PolicyRulesV1Client

NewPolicyRulesV1 returns PolicyRulesV1Client

Jump to

Keyboard shortcuts

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