driverootpermission

package
v0.20241021.1074254 Latest Latest
Warning

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

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

README

github.com/hashicorp/go-azure-sdk/microsoft-graph/me/beta/driverootpermission Documentation

The driverootpermission SDK allows for interaction with Microsoft Graph me (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/me/beta/driverootpermission"

Client Initialization

client := driverootpermission.NewDriveRootPermissionClientWithBaseURI("https://graph.microsoft.com")
client.Client.Authorizer = authorizer

Example Usage: DriveRootPermissionClient.CreateDriveRootPermission

ctx := context.TODO()
id := driverootpermission.NewMeDriveID("driveId")

payload := driverootpermission.Permission{
	// ...
}


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

Example Usage: DriveRootPermissionClient.DeleteDriveRootPermission

ctx := context.TODO()
id := driverootpermission.NewMeDriveIdRootPermissionID("driveId", "permissionId")

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

Example Usage: DriveRootPermissionClient.GetDriveRootPermission

ctx := context.TODO()
id := driverootpermission.NewMeDriveIdRootPermissionID("driveId", "permissionId")

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

Example Usage: DriveRootPermissionClient.GetDriveRootPermissionsCount

ctx := context.TODO()
id := driverootpermission.NewMeDriveID("driveId")

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

Example Usage: DriveRootPermissionClient.ListDriveRootPermissionGrants

ctx := context.TODO()
id := driverootpermission.NewMeDriveIdRootPermissionID("driveId", "permissionId")

payload := driverootpermission.ListDriveRootPermissionGrantsRequest{
	// ...
}


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

Example Usage: DriveRootPermissionClient.ListDriveRootPermissions

ctx := context.TODO()
id := driverootpermission.NewMeDriveID("driveId")

// alternatively `client.ListDriveRootPermissions(ctx, id, driverootpermission.DefaultListDriveRootPermissionsOperationOptions())` can be used to do batched pagination
items, err := client.ListDriveRootPermissionsComplete(ctx, id, driverootpermission.DefaultListDriveRootPermissionsOperationOptions())
if err != nil {
	// handle the error
}
for _, item := range items {
	// do something
}

Example Usage: DriveRootPermissionClient.RevokeDriveRootPermissionGrants

ctx := context.TODO()
id := driverootpermission.NewMeDriveIdRootPermissionID("driveId", "permissionId")

payload := driverootpermission.RevokeDriveRootPermissionGrantsRequest{
	// ...
}


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

Example Usage: DriveRootPermissionClient.UpdateDriveRootPermission

ctx := context.TODO()
id := driverootpermission.NewMeDriveIdRootPermissionID("driveId", "permissionId")

payload := driverootpermission.Permission{
	// ...
}


read, err := client.UpdateDriveRootPermission(ctx, id, payload, driverootpermission.DefaultUpdateDriveRootPermissionOperationOptions())
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 CreateDriveRootPermissionOperationOptions

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

func DefaultCreateDriveRootPermissionOperationOptions

func DefaultCreateDriveRootPermissionOperationOptions() CreateDriveRootPermissionOperationOptions

func (CreateDriveRootPermissionOperationOptions) ToHeaders

func (CreateDriveRootPermissionOperationOptions) ToOData

func (CreateDriveRootPermissionOperationOptions) ToQuery

type CreateDriveRootPermissionOperationResponse

type CreateDriveRootPermissionOperationResponse struct {
	HttpResponse *http.Response
	OData        *odata.OData
	Model        *beta.Permission
}

type DeleteDriveRootPermissionOperationOptions

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

func DefaultDeleteDriveRootPermissionOperationOptions

func DefaultDeleteDriveRootPermissionOperationOptions() DeleteDriveRootPermissionOperationOptions

func (DeleteDriveRootPermissionOperationOptions) ToHeaders

func (DeleteDriveRootPermissionOperationOptions) ToOData

func (DeleteDriveRootPermissionOperationOptions) ToQuery

type DeleteDriveRootPermissionOperationResponse

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

type DriveRootPermissionClient

type DriveRootPermissionClient struct {
	Client *msgraph.Client
}

func NewDriveRootPermissionClientWithBaseURI

func NewDriveRootPermissionClientWithBaseURI(sdkApi sdkEnv.Api) (*DriveRootPermissionClient, error)

func (DriveRootPermissionClient) CreateDriveRootPermission

CreateDriveRootPermission - Create new navigation property to permissions for me

func (DriveRootPermissionClient) DeleteDriveRootPermission

DeleteDriveRootPermission - Delete navigation property permissions for me

func (DriveRootPermissionClient) GetDriveRootPermission

GetDriveRootPermission - Get permissions from me. The set of permissions for the item. Read-only. Nullable.

func (DriveRootPermissionClient) GetDriveRootPermissionsCount

GetDriveRootPermissionsCount - Get the number of the resource

func (DriveRootPermissionClient) ListDriveRootPermissionGrants

ListDriveRootPermissionGrants - Invoke action grant. Grant users access to a link represented by a permission.

func (DriveRootPermissionClient) ListDriveRootPermissionGrantsComplete

ListDriveRootPermissionGrantsComplete retrieves all the results into a single object

func (DriveRootPermissionClient) ListDriveRootPermissionGrantsCompleteMatchingPredicate

ListDriveRootPermissionGrantsCompleteMatchingPredicate retrieves all the results and then applies the predicate

func (DriveRootPermissionClient) ListDriveRootPermissions

ListDriveRootPermissions - Get permissions from me. The set of permissions for the item. Read-only. Nullable.

func (DriveRootPermissionClient) ListDriveRootPermissionsComplete

ListDriveRootPermissionsComplete retrieves all the results into a single object

func (DriveRootPermissionClient) ListDriveRootPermissionsCompleteMatchingPredicate

func (c DriveRootPermissionClient) ListDriveRootPermissionsCompleteMatchingPredicate(ctx context.Context, id beta.MeDriveId, options ListDriveRootPermissionsOperationOptions, predicate PermissionOperationPredicate) (result ListDriveRootPermissionsCompleteResult, err error)

ListDriveRootPermissionsCompleteMatchingPredicate retrieves all the results and then applies the predicate

func (DriveRootPermissionClient) RevokeDriveRootPermissionGrants

RevokeDriveRootPermissionGrants - Invoke action revokeGrants. Revoke access to a listItem or driveItem granted via a sharing link by removing the specified recipient from the link.

func (DriveRootPermissionClient) UpdateDriveRootPermission

UpdateDriveRootPermission - Update the navigation property permissions in me

type GetDriveRootPermissionOperationOptions

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

func DefaultGetDriveRootPermissionOperationOptions

func DefaultGetDriveRootPermissionOperationOptions() GetDriveRootPermissionOperationOptions

func (GetDriveRootPermissionOperationOptions) ToHeaders

func (GetDriveRootPermissionOperationOptions) ToOData

func (GetDriveRootPermissionOperationOptions) ToQuery

type GetDriveRootPermissionOperationResponse

type GetDriveRootPermissionOperationResponse struct {
	HttpResponse *http.Response
	OData        *odata.OData
	Model        *beta.Permission
}

type GetDriveRootPermissionsCountOperationOptions

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

func DefaultGetDriveRootPermissionsCountOperationOptions

func DefaultGetDriveRootPermissionsCountOperationOptions() GetDriveRootPermissionsCountOperationOptions

func (GetDriveRootPermissionsCountOperationOptions) ToHeaders

func (GetDriveRootPermissionsCountOperationOptions) ToOData

func (GetDriveRootPermissionsCountOperationOptions) ToQuery

type GetDriveRootPermissionsCountOperationResponse

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

type ListDriveRootPermissionGrantsCompleteResult

type ListDriveRootPermissionGrantsCompleteResult struct {
	LatestHttpResponse *http.Response
	Items              []beta.Permission
}

type ListDriveRootPermissionGrantsCustomPager

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

type ListDriveRootPermissionGrantsOperationOptions

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

func DefaultListDriveRootPermissionGrantsOperationOptions

func DefaultListDriveRootPermissionGrantsOperationOptions() ListDriveRootPermissionGrantsOperationOptions

func (ListDriveRootPermissionGrantsOperationOptions) ToHeaders

func (ListDriveRootPermissionGrantsOperationOptions) ToOData

func (ListDriveRootPermissionGrantsOperationOptions) ToQuery

type ListDriveRootPermissionGrantsOperationResponse

type ListDriveRootPermissionGrantsOperationResponse struct {
	HttpResponse *http.Response
	OData        *odata.OData
	Model        *[]beta.Permission
}

type ListDriveRootPermissionGrantsRequest

type ListDriveRootPermissionGrantsRequest struct {
	Recipients *[]beta.DriveRecipient `json:"recipients,omitempty"`
	Roles      *[]string              `json:"roles,omitempty"`
}

type ListDriveRootPermissionsCompleteResult

type ListDriveRootPermissionsCompleteResult struct {
	LatestHttpResponse *http.Response
	Items              []beta.Permission
}

type ListDriveRootPermissionsCustomPager

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

type ListDriveRootPermissionsOperationOptions

type ListDriveRootPermissionsOperationOptions 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 DefaultListDriveRootPermissionsOperationOptions

func DefaultListDriveRootPermissionsOperationOptions() ListDriveRootPermissionsOperationOptions

func (ListDriveRootPermissionsOperationOptions) ToHeaders

func (ListDriveRootPermissionsOperationOptions) ToOData

func (ListDriveRootPermissionsOperationOptions) ToQuery

type ListDriveRootPermissionsOperationResponse

type ListDriveRootPermissionsOperationResponse struct {
	HttpResponse *http.Response
	OData        *odata.OData
	Model        *[]beta.Permission
}

type PermissionOperationPredicate

type PermissionOperationPredicate struct {
}

func (PermissionOperationPredicate) Matches

type RevokeDriveRootPermissionGrantsOperationOptions

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

func DefaultRevokeDriveRootPermissionGrantsOperationOptions

func DefaultRevokeDriveRootPermissionGrantsOperationOptions() RevokeDriveRootPermissionGrantsOperationOptions

func (RevokeDriveRootPermissionGrantsOperationOptions) ToHeaders

func (RevokeDriveRootPermissionGrantsOperationOptions) ToOData

func (RevokeDriveRootPermissionGrantsOperationOptions) ToQuery

type RevokeDriveRootPermissionGrantsOperationResponse

type RevokeDriveRootPermissionGrantsOperationResponse struct {
	HttpResponse *http.Response
	OData        *odata.OData
	Model        *beta.Permission
}

type RevokeDriveRootPermissionGrantsRequest

type RevokeDriveRootPermissionGrantsRequest struct {
	Grantees *[]beta.DriveRecipient `json:"grantees,omitempty"`
}

type UpdateDriveRootPermissionOperationOptions

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

func DefaultUpdateDriveRootPermissionOperationOptions

func DefaultUpdateDriveRootPermissionOperationOptions() UpdateDriveRootPermissionOperationOptions

func (UpdateDriveRootPermissionOperationOptions) ToHeaders

func (UpdateDriveRootPermissionOperationOptions) ToOData

func (UpdateDriveRootPermissionOperationOptions) ToQuery

type UpdateDriveRootPermissionOperationResponse

type UpdateDriveRootPermissionOperationResponse 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