groupuser

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: 10 Imported by: 0

README

github.com/hashicorp/go-azure-sdk/resource-manager/apimanagement/2021-08-01/groupuser Documentation

The groupuser SDK allows for interaction with the Azure Resource Manager Service apimanagement (API Version 2021-08-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/apimanagement/2021-08-01/groupuser"

Client Initialization

client := groupuser.NewGroupUserClientWithBaseURI("https://management.azure.com")
client.Client.Authorizer = authorizer

Example Usage: GroupUserClient.CheckEntityExists

ctx := context.TODO()
id := groupuser.NewGroupUserID("12345678-1234-9876-4563-123456789012", "example-resource-group", "serviceValue", "groupIdValue", "userIdValue")

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

Example Usage: GroupUserClient.Create

ctx := context.TODO()
id := groupuser.NewGroupUserID("12345678-1234-9876-4563-123456789012", "example-resource-group", "serviceValue", "groupIdValue", "userIdValue")

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

Example Usage: GroupUserClient.Delete

ctx := context.TODO()
id := groupuser.NewGroupUserID("12345678-1234-9876-4563-123456789012", "example-resource-group", "serviceValue", "groupIdValue", "userIdValue")

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

ctx := context.TODO()
id := groupuser.NewGroupID("12345678-1234-9876-4563-123456789012", "example-resource-group", "serviceValue", "groupIdValue")

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

func PossibleValuesForGroupType() []string

func PossibleValuesForUserState

func PossibleValuesForUserState() []string

func ValidateGroupID

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

ValidateGroupID checks that 'input' can be parsed as a Group ID

func ValidateGroupUserID

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

ValidateGroupUserID checks that 'input' can be parsed as a Group User ID

Types

type CheckEntityExistsOperationResponse

type CheckEntityExistsOperationResponse struct {
	HttpResponse *http.Response
}

type CreateOperationResponse

type CreateOperationResponse struct {
	HttpResponse *http.Response
	Model        *UserContract
}

type DeleteOperationResponse

type DeleteOperationResponse struct {
	HttpResponse *http.Response
}

type GroupContractProperties

type GroupContractProperties struct {
	BuiltIn     *bool      `json:"builtIn,omitempty"`
	Description *string    `json:"description,omitempty"`
	DisplayName string     `json:"displayName"`
	ExternalId  *string    `json:"externalId,omitempty"`
	Type        *GroupType `json:"type,omitempty"`
}

type GroupId

type GroupId struct {
	SubscriptionId    string
	ResourceGroupName string
	ServiceName       string
	GroupId           string
}

GroupId is a struct representing the Resource ID for a Group

func NewGroupID

func NewGroupID(subscriptionId string, resourceGroupName string, serviceName string, groupId string) GroupId

NewGroupID returns a new GroupId struct

func ParseGroupID

func ParseGroupID(input string) (*GroupId, error)

ParseGroupID parses 'input' into a GroupId

func ParseGroupIDInsensitively

func ParseGroupIDInsensitively(input string) (*GroupId, error)

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

func (GroupId) ID

func (id GroupId) ID() string

ID returns the formatted Group ID

func (GroupId) Segments

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

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

func (GroupId) String

func (id GroupId) String() string

String returns a human-readable description of this Group ID

type GroupType

type GroupType string
const (
	GroupTypeCustom   GroupType = "custom"
	GroupTypeExternal GroupType = "external"
	GroupTypeSystem   GroupType = "system"
)

type GroupUserClient

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

func NewGroupUserClientWithBaseURI

func NewGroupUserClientWithBaseURI(endpoint string) GroupUserClient

func (GroupUserClient) CheckEntityExists

func (c GroupUserClient) CheckEntityExists(ctx context.Context, id GroupUserId) (result CheckEntityExistsOperationResponse, err error)

CheckEntityExists ...

func (GroupUserClient) Create

func (c GroupUserClient) Create(ctx context.Context, id GroupUserId) (result CreateOperationResponse, err error)

Create ...

func (GroupUserClient) Delete

func (c GroupUserClient) Delete(ctx context.Context, id GroupUserId) (result DeleteOperationResponse, err error)

Delete ...

func (GroupUserClient) List

List ...

func (GroupUserClient) ListComplete

ListComplete retrieves all of the results into a single object

func (GroupUserClient) ListCompleteMatchingPredicate

func (c GroupUserClient) ListCompleteMatchingPredicate(ctx context.Context, id GroupId, options ListOperationOptions, predicate UserContractOperationPredicate) (resp ListCompleteResult, err error)

ListCompleteMatchingPredicate retrieves all of the results and then applied the predicate

type GroupUserId

type GroupUserId struct {
	SubscriptionId    string
	ResourceGroupName string
	ServiceName       string
	GroupId           string
	UserId            string
}

GroupUserId is a struct representing the Resource ID for a Group User

func NewGroupUserID

func NewGroupUserID(subscriptionId string, resourceGroupName string, serviceName string, groupId string, userId string) GroupUserId

NewGroupUserID returns a new GroupUserId struct

func ParseGroupUserID

func ParseGroupUserID(input string) (*GroupUserId, error)

ParseGroupUserID parses 'input' into a GroupUserId

func ParseGroupUserIDInsensitively

func ParseGroupUserIDInsensitively(input string) (*GroupUserId, error)

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

func (GroupUserId) ID

func (id GroupUserId) ID() string

ID returns the formatted Group User ID

func (GroupUserId) Segments

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

Segments returns a slice of Resource ID Segments which comprise this Group User ID

func (GroupUserId) String

func (id GroupUserId) String() string

String returns a human-readable description of this Group User ID

type ListCompleteResult

type ListCompleteResult struct {
	Items []UserContract
}

type ListOperationOptions

type ListOperationOptions struct {
	Filter *string
	Skip   *int64
	Top    *int64
}

func DefaultListOperationOptions

func DefaultListOperationOptions() ListOperationOptions

type ListOperationResponse

type ListOperationResponse struct {
	HttpResponse *http.Response
	Model        *[]UserContract
	// 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 UserContract

type UserContract struct {
	Id         *string                 `json:"id,omitempty"`
	Name       *string                 `json:"name,omitempty"`
	Properties *UserContractProperties `json:"properties,omitempty"`
	Type       *string                 `json:"type,omitempty"`
}

type UserContractOperationPredicate

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

func (UserContractOperationPredicate) Matches

type UserContractProperties

type UserContractProperties struct {
	Email            *string                    `json:"email,omitempty"`
	FirstName        *string                    `json:"firstName,omitempty"`
	Groups           *[]GroupContractProperties `json:"groups,omitempty"`
	Identities       *[]UserIdentityContract    `json:"identities,omitempty"`
	LastName         *string                    `json:"lastName,omitempty"`
	Note             *string                    `json:"note,omitempty"`
	RegistrationDate *string                    `json:"registrationDate,omitempty"`
	State            *UserState                 `json:"state,omitempty"`
}

func (*UserContractProperties) GetRegistrationDateAsTime

func (o *UserContractProperties) GetRegistrationDateAsTime() (*time.Time, error)

func (*UserContractProperties) SetRegistrationDateAsTime

func (o *UserContractProperties) SetRegistrationDateAsTime(input time.Time)

type UserIdentityContract

type UserIdentityContract struct {
	Id       *string `json:"id,omitempty"`
	Provider *string `json:"provider,omitempty"`
}

type UserState

type UserState string
const (
	UserStateActive  UserState = "active"
	UserStateBlocked UserState = "blocked"
	UserStateDeleted UserState = "deleted"
	UserStatePending UserState = "pending"
)

Jump to

Keyboard shortcuts

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