Non-Page files removed.
This commit is contained in:
parent
9dc487b39f
commit
8f22c4f776
@ -1,79 +1,85 @@
|
||||
package sites
|
||||
|
||||
import (
|
||||
"context"
|
||||
i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f "github.com/microsoft/kiota-abstractions-go"
|
||||
i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models/odataerrors"
|
||||
"context"
|
||||
|
||||
i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models/odataerrors"
|
||||
i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f "github.com/microsoft/kiota-abstractions-go"
|
||||
msgraphsdk "github.com/microsoftgraph/msgraph-sdk-go"
|
||||
)
|
||||
|
||||
// AddRequestBuilder provides operations to call the add method.
|
||||
type AddRequestBuilder struct {
|
||||
// Path parameters for the request
|
||||
pathParameters map[string]string
|
||||
// The request adapter to use to execute the requests.
|
||||
requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter
|
||||
// Url template to use to build the URL for the current request builder
|
||||
urlTemplate string
|
||||
// Path parameters for the request
|
||||
pathParameters map[string]string
|
||||
// The request adapter to use to execute the requests.
|
||||
requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter
|
||||
// Url template to use to build the URL for the current request builder
|
||||
urlTemplate string
|
||||
}
|
||||
|
||||
// AddRequestBuilderPostRequestConfiguration configuration for the request such as headers, query parameters, and middleware options.
|
||||
type AddRequestBuilderPostRequestConfiguration struct {
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
}
|
||||
|
||||
// NewAddRequestBuilderInternal instantiates a new AddRequestBuilder and sets the default values.
|
||||
func NewAddRequestBuilderInternal(pathParameters map[string]string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*AddRequestBuilder) {
|
||||
m := &AddRequestBuilder{
|
||||
}
|
||||
m.urlTemplate = "{+baseurl}/sites/microsoft.graph.add";
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
m.pathParameters = urlTplParams;
|
||||
m.requestAdapter = requestAdapter;
|
||||
return m
|
||||
func NewAddRequestBuilderInternal(pathParameters map[string]string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter) *AddRequestBuilder {
|
||||
m := &AddRequestBuilder{}
|
||||
m.urlTemplate = "{+baseurl}/sites/microsoft.graph.add"
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
m.pathParameters = urlTplParams
|
||||
m.requestAdapter = requestAdapter
|
||||
return m
|
||||
}
|
||||
|
||||
// NewAddRequestBuilder instantiates a new AddRequestBuilder and sets the default values.
|
||||
func NewAddRequestBuilder(rawUrl string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*AddRequestBuilder) {
|
||||
urlParams := make(map[string]string)
|
||||
urlParams["request-raw-url"] = rawUrl
|
||||
return NewAddRequestBuilderInternal(urlParams, requestAdapter)
|
||||
func NewAddRequestBuilder(rawUrl string, requestAdapter *msgraphsdk.GraphRequestAdapter) *AddRequestBuilder {
|
||||
urlParams := make(map[string]string)
|
||||
urlParams["request-raw-url"] = rawUrl
|
||||
return NewAddRequestBuilderInternal(urlParams, requestAdapter)
|
||||
}
|
||||
|
||||
// CreatePostRequestInformation follow a user's site or multiple sites.
|
||||
func (m *AddRequestBuilder) CreatePostRequestInformation(ctx context.Context, body AddPostRequestBodyable, requestConfiguration *AddRequestBuilderPostRequestConfiguration)(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.POST
|
||||
requestInfo.Headers.Add("Accept", "application/json")
|
||||
requestInfo.SetContentFromParsable(ctx, m.requestAdapter, "application/json", body)
|
||||
if requestConfiguration != nil {
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
func (m *AddRequestBuilder) CreatePostRequestInformation(ctx context.Context, body AddPostRequestBodyable, requestConfiguration *AddRequestBuilderPostRequestConfiguration) (*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.POST
|
||||
requestInfo.Headers.Add("Accept", "application/json")
|
||||
requestInfo.SetContentFromParsable(ctx, m.requestAdapter, "application/json", body)
|
||||
if requestConfiguration != nil {
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
}
|
||||
|
||||
// Post follow a user's site or multiple sites.
|
||||
// [Find more info here]
|
||||
//
|
||||
//
|
||||
// [Find more info here]: https://docs.microsoft.com/graph/api/site-follow?view=graph-rest-1.0
|
||||
func (m *AddRequestBuilder) Post(ctx context.Context, body AddPostRequestBodyable, requestConfiguration *AddRequestBuilderPostRequestConfiguration)(AddResponseable, error) {
|
||||
requestInfo, err := m.CreatePostRequestInformation(ctx, body, requestConfiguration);
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings {
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.SendAsync(ctx, requestInfo, CreateAddResponseFromDiscriminatorValue, errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(AddResponseable), nil
|
||||
func (m *AddRequestBuilder) Post(ctx context.Context, body AddPostRequestBodyable, requestConfiguration *AddRequestBuilderPostRequestConfiguration) (AddResponseable, error) {
|
||||
requestInfo, err := m.CreatePostRequestInformation(ctx, body, requestConfiguration)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings{
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.Send(ctx, requestInfo, CreateAddResponseFromDiscriminatorValue, errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(AddResponseable), nil
|
||||
}
|
||||
|
||||
@ -1,87 +1,93 @@
|
||||
package sites
|
||||
|
||||
import (
|
||||
"context"
|
||||
i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f "github.com/microsoft/kiota-abstractions-go"
|
||||
i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models/odataerrors"
|
||||
"context"
|
||||
|
||||
i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models/odataerrors"
|
||||
i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f "github.com/microsoft/kiota-abstractions-go"
|
||||
)
|
||||
|
||||
// CountRequestBuilder provides operations to count the resources in the collection.
|
||||
type CountRequestBuilder struct {
|
||||
// Path parameters for the request
|
||||
pathParameters map[string]string
|
||||
// The request adapter to use to execute the requests.
|
||||
requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter
|
||||
// Url template to use to build the URL for the current request builder
|
||||
urlTemplate string
|
||||
// Path parameters for the request
|
||||
pathParameters map[string]string
|
||||
// The request adapter to use to execute the requests.
|
||||
requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter
|
||||
// Url template to use to build the URL for the current request builder
|
||||
urlTemplate string
|
||||
}
|
||||
|
||||
// CountRequestBuilderGetQueryParameters get the number of the resource
|
||||
type CountRequestBuilderGetQueryParameters struct {
|
||||
// Filter items by property values
|
||||
Filter *string `uriparametername:"%24filter"`
|
||||
// Search items by search phrases
|
||||
Search *string `uriparametername:"%24search"`
|
||||
// Filter items by property values
|
||||
Filter *string `uriparametername:"%24filter"`
|
||||
// Search items by search phrases
|
||||
Search *string `uriparametername:"%24search"`
|
||||
}
|
||||
|
||||
// CountRequestBuilderGetRequestConfiguration configuration for the request such as headers, query parameters, and middleware options.
|
||||
type CountRequestBuilderGetRequestConfiguration struct {
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
// Request query parameters
|
||||
QueryParameters *CountRequestBuilderGetQueryParameters
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
// Request query parameters
|
||||
QueryParameters *CountRequestBuilderGetQueryParameters
|
||||
}
|
||||
|
||||
// NewCountRequestBuilderInternal instantiates a new CountRequestBuilder and sets the default values.
|
||||
func NewCountRequestBuilderInternal(pathParameters map[string]string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*CountRequestBuilder) {
|
||||
m := &CountRequestBuilder{
|
||||
}
|
||||
m.urlTemplate = "{+baseurl}/sites/$count{?%24search,%24filter}";
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
m.pathParameters = urlTplParams;
|
||||
m.requestAdapter = requestAdapter;
|
||||
return m
|
||||
func NewCountRequestBuilderInternal(pathParameters map[string]string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter) *CountRequestBuilder {
|
||||
m := &CountRequestBuilder{}
|
||||
m.urlTemplate = "{+baseurl}/sites/$count{?%24search,%24filter}"
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
m.pathParameters = urlTplParams
|
||||
m.requestAdapter = requestAdapter
|
||||
return m
|
||||
}
|
||||
|
||||
// NewCountRequestBuilder instantiates a new CountRequestBuilder and sets the default values.
|
||||
func NewCountRequestBuilder(rawUrl string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*CountRequestBuilder) {
|
||||
urlParams := make(map[string]string)
|
||||
urlParams["request-raw-url"] = rawUrl
|
||||
return NewCountRequestBuilderInternal(urlParams, requestAdapter)
|
||||
func NewCountRequestBuilder(rawUrl string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter) *CountRequestBuilder {
|
||||
urlParams := make(map[string]string)
|
||||
urlParams["request-raw-url"] = rawUrl
|
||||
return NewCountRequestBuilderInternal(urlParams, requestAdapter)
|
||||
}
|
||||
|
||||
// CreateGetRequestInformation get the number of the resource
|
||||
func (m *CountRequestBuilder) CreateGetRequestInformation(ctx context.Context, requestConfiguration *CountRequestBuilderGetRequestConfiguration)(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.GET
|
||||
requestInfo.Headers.Add("Accept", "text/plain")
|
||||
if requestConfiguration != nil {
|
||||
if requestConfiguration.QueryParameters != nil {
|
||||
requestInfo.AddQueryParameters(*(requestConfiguration.QueryParameters))
|
||||
}
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
func (m *CountRequestBuilder) CreateGetRequestInformation(ctx context.Context, requestConfiguration *CountRequestBuilderGetRequestConfiguration) (*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.GET
|
||||
requestInfo.Headers.Add("Accept", "text/plain")
|
||||
if requestConfiguration != nil {
|
||||
if requestConfiguration.QueryParameters != nil {
|
||||
requestInfo.AddQueryParameters(*(requestConfiguration.QueryParameters))
|
||||
}
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
}
|
||||
|
||||
// Get get the number of the resource
|
||||
func (m *CountRequestBuilder) Get(ctx context.Context, requestConfiguration *CountRequestBuilderGetRequestConfiguration)(*int32, error) {
|
||||
requestInfo, err := m.CreateGetRequestInformation(ctx, requestConfiguration);
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings {
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.SendPrimitiveAsync(ctx, requestInfo, "int32", errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(*int32), nil
|
||||
func (m *CountRequestBuilder) Get(ctx context.Context, requestConfiguration *CountRequestBuilderGetRequestConfiguration) (*int32, error) {
|
||||
requestInfo, err := m.CreateGetRequestInformation(ctx, requestConfiguration)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings{
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.SendPrimitive(ctx, requestInfo, "int32", errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(*int32), nil
|
||||
}
|
||||
|
||||
@ -1,97 +1,103 @@
|
||||
package sites
|
||||
|
||||
import (
|
||||
"context"
|
||||
i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f "github.com/microsoft/kiota-abstractions-go"
|
||||
i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models/odataerrors"
|
||||
"context"
|
||||
|
||||
i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models/odataerrors"
|
||||
i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f "github.com/microsoft/kiota-abstractions-go"
|
||||
)
|
||||
|
||||
// DeltaRequestBuilder provides operations to call the delta method.
|
||||
type DeltaRequestBuilder struct {
|
||||
// Path parameters for the request
|
||||
pathParameters map[string]string
|
||||
// The request adapter to use to execute the requests.
|
||||
requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter
|
||||
// Url template to use to build the URL for the current request builder
|
||||
urlTemplate string
|
||||
// Path parameters for the request
|
||||
pathParameters map[string]string
|
||||
// The request adapter to use to execute the requests.
|
||||
requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter
|
||||
// Url template to use to build the URL for the current request builder
|
||||
urlTemplate string
|
||||
}
|
||||
|
||||
// DeltaRequestBuilderGetQueryParameters invoke function delta
|
||||
type DeltaRequestBuilderGetQueryParameters struct {
|
||||
// Include count of items
|
||||
Count *bool `uriparametername:"%24count"`
|
||||
// Filter items by property values
|
||||
Filter *string `uriparametername:"%24filter"`
|
||||
// Order items by property values
|
||||
Orderby []string `uriparametername:"%24orderby"`
|
||||
// Search items by search phrases
|
||||
Search *string `uriparametername:"%24search"`
|
||||
// Select properties to be returned
|
||||
Select []string `uriparametername:"%24select"`
|
||||
// Skip the first n items
|
||||
Skip *int32 `uriparametername:"%24skip"`
|
||||
// Show only the first n items
|
||||
Top *int32 `uriparametername:"%24top"`
|
||||
// Include count of items
|
||||
Count *bool `uriparametername:"%24count"`
|
||||
// Filter items by property values
|
||||
Filter *string `uriparametername:"%24filter"`
|
||||
// Order items by property values
|
||||
Orderby []string `uriparametername:"%24orderby"`
|
||||
// Search items by search phrases
|
||||
Search *string `uriparametername:"%24search"`
|
||||
// Select properties to be returned
|
||||
Select []string `uriparametername:"%24select"`
|
||||
// Skip the first n items
|
||||
Skip *int32 `uriparametername:"%24skip"`
|
||||
// Show only the first n items
|
||||
Top *int32 `uriparametername:"%24top"`
|
||||
}
|
||||
|
||||
// DeltaRequestBuilderGetRequestConfiguration configuration for the request such as headers, query parameters, and middleware options.
|
||||
type DeltaRequestBuilderGetRequestConfiguration struct {
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
// Request query parameters
|
||||
QueryParameters *DeltaRequestBuilderGetQueryParameters
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
// Request query parameters
|
||||
QueryParameters *DeltaRequestBuilderGetQueryParameters
|
||||
}
|
||||
|
||||
// NewDeltaRequestBuilderInternal instantiates a new DeltaRequestBuilder and sets the default values.
|
||||
func NewDeltaRequestBuilderInternal(pathParameters map[string]string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*DeltaRequestBuilder) {
|
||||
m := &DeltaRequestBuilder{
|
||||
}
|
||||
m.urlTemplate = "{+baseurl}/sites/microsoft.graph.delta(){?%24top,%24skip,%24search,%24filter,%24count,%24select,%24orderby}";
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
m.pathParameters = urlTplParams;
|
||||
m.requestAdapter = requestAdapter;
|
||||
return m
|
||||
func NewDeltaRequestBuilderInternal(pathParameters map[string]string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter) *DeltaRequestBuilder {
|
||||
m := &DeltaRequestBuilder{}
|
||||
m.urlTemplate = "{+baseurl}/sites/microsoft.graph.delta(){?%24top,%24skip,%24search,%24filter,%24count,%24select,%24orderby}"
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
m.pathParameters = urlTplParams
|
||||
m.requestAdapter = requestAdapter
|
||||
return m
|
||||
}
|
||||
|
||||
// NewDeltaRequestBuilder instantiates a new DeltaRequestBuilder and sets the default values.
|
||||
func NewDeltaRequestBuilder(rawUrl string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*DeltaRequestBuilder) {
|
||||
urlParams := make(map[string]string)
|
||||
urlParams["request-raw-url"] = rawUrl
|
||||
return NewDeltaRequestBuilderInternal(urlParams, requestAdapter)
|
||||
func NewDeltaRequestBuilder(rawUrl string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter) *DeltaRequestBuilder {
|
||||
urlParams := make(map[string]string)
|
||||
urlParams["request-raw-url"] = rawUrl
|
||||
return NewDeltaRequestBuilderInternal(urlParams, requestAdapter)
|
||||
}
|
||||
|
||||
// CreateGetRequestInformation invoke function delta
|
||||
func (m *DeltaRequestBuilder) CreateGetRequestInformation(ctx context.Context, requestConfiguration *DeltaRequestBuilderGetRequestConfiguration)(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.GET
|
||||
requestInfo.Headers.Add("Accept", "application/json")
|
||||
if requestConfiguration != nil {
|
||||
if requestConfiguration.QueryParameters != nil {
|
||||
requestInfo.AddQueryParameters(*(requestConfiguration.QueryParameters))
|
||||
}
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
func (m *DeltaRequestBuilder) CreateGetRequestInformation(ctx context.Context, requestConfiguration *DeltaRequestBuilderGetRequestConfiguration) (*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.GET
|
||||
requestInfo.Headers.Add("Accept", "application/json")
|
||||
if requestConfiguration != nil {
|
||||
if requestConfiguration.QueryParameters != nil {
|
||||
requestInfo.AddQueryParameters(*(requestConfiguration.QueryParameters))
|
||||
}
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
}
|
||||
|
||||
// Get invoke function delta
|
||||
func (m *DeltaRequestBuilder) Get(ctx context.Context, requestConfiguration *DeltaRequestBuilderGetRequestConfiguration)(DeltaResponseable, error) {
|
||||
requestInfo, err := m.CreateGetRequestInformation(ctx, requestConfiguration);
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings {
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.SendAsync(ctx, requestInfo, CreateDeltaResponseFromDiscriminatorValue, errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(DeltaResponseable), nil
|
||||
func (m *DeltaRequestBuilder) Get(ctx context.Context, requestConfiguration *DeltaRequestBuilderGetRequestConfiguration) (DeltaResponseable, error) {
|
||||
requestInfo, err := m.CreateGetRequestInformation(ctx, requestConfiguration)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings{
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.Send(ctx, requestInfo, CreateDeltaResponseFromDiscriminatorValue, errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(DeltaResponseable), nil
|
||||
}
|
||||
|
||||
@ -1,88 +0,0 @@
|
||||
package sites
|
||||
|
||||
import (
|
||||
"context"
|
||||
i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f "github.com/microsoft/kiota-abstractions-go"
|
||||
ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models"
|
||||
i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models/odataerrors"
|
||||
)
|
||||
|
||||
// ItemAnalyticsRequestBuilder provides operations to manage the analytics property of the microsoft.graph.site entity.
|
||||
type ItemAnalyticsRequestBuilder struct {
|
||||
// Path parameters for the request
|
||||
pathParameters map[string]string
|
||||
// The request adapter to use to execute the requests.
|
||||
requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter
|
||||
// Url template to use to build the URL for the current request builder
|
||||
urlTemplate string
|
||||
}
|
||||
// ItemAnalyticsRequestBuilderGetQueryParameters analytics about the view activities that took place in this site.
|
||||
type ItemAnalyticsRequestBuilderGetQueryParameters struct {
|
||||
// Expand related entities
|
||||
Expand []string `uriparametername:"%24expand"`
|
||||
// Select properties to be returned
|
||||
Select []string `uriparametername:"%24select"`
|
||||
}
|
||||
// ItemAnalyticsRequestBuilderGetRequestConfiguration configuration for the request such as headers, query parameters, and middleware options.
|
||||
type ItemAnalyticsRequestBuilderGetRequestConfiguration struct {
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
// Request query parameters
|
||||
QueryParameters *ItemAnalyticsRequestBuilderGetQueryParameters
|
||||
}
|
||||
// NewItemAnalyticsRequestBuilderInternal instantiates a new AnalyticsRequestBuilder and sets the default values.
|
||||
func NewItemAnalyticsRequestBuilderInternal(pathParameters map[string]string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemAnalyticsRequestBuilder) {
|
||||
m := &ItemAnalyticsRequestBuilder{
|
||||
}
|
||||
m.urlTemplate = "{+baseurl}/sites/{site%2Did}/analytics{?%24select,%24expand}";
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
m.pathParameters = urlTplParams;
|
||||
m.requestAdapter = requestAdapter;
|
||||
return m
|
||||
}
|
||||
// NewItemAnalyticsRequestBuilder instantiates a new AnalyticsRequestBuilder and sets the default values.
|
||||
func NewItemAnalyticsRequestBuilder(rawUrl string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemAnalyticsRequestBuilder) {
|
||||
urlParams := make(map[string]string)
|
||||
urlParams["request-raw-url"] = rawUrl
|
||||
return NewItemAnalyticsRequestBuilderInternal(urlParams, requestAdapter)
|
||||
}
|
||||
// CreateGetRequestInformation analytics about the view activities that took place in this site.
|
||||
func (m *ItemAnalyticsRequestBuilder) CreateGetRequestInformation(ctx context.Context, requestConfiguration *ItemAnalyticsRequestBuilderGetRequestConfiguration)(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.GET
|
||||
requestInfo.Headers.Add("Accept", "application/json")
|
||||
if requestConfiguration != nil {
|
||||
if requestConfiguration.QueryParameters != nil {
|
||||
requestInfo.AddQueryParameters(*(requestConfiguration.QueryParameters))
|
||||
}
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
}
|
||||
// Get analytics about the view activities that took place in this site.
|
||||
func (m *ItemAnalyticsRequestBuilder) Get(ctx context.Context, requestConfiguration *ItemAnalyticsRequestBuilderGetRequestConfiguration)(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ItemAnalyticsable, error) {
|
||||
requestInfo, err := m.CreateGetRequestInformation(ctx, requestConfiguration);
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings {
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.SendAsync(ctx, requestInfo, ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CreateItemAnalyticsFromDiscriminatorValue, errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ItemAnalyticsable), nil
|
||||
}
|
||||
@ -1,167 +1,180 @@
|
||||
package sites
|
||||
|
||||
import (
|
||||
"context"
|
||||
i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f "github.com/microsoft/kiota-abstractions-go"
|
||||
ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models"
|
||||
i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models/odataerrors"
|
||||
"context"
|
||||
|
||||
ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models"
|
||||
i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models/odataerrors"
|
||||
i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f "github.com/microsoft/kiota-abstractions-go"
|
||||
)
|
||||
|
||||
// ItemColumnsColumnDefinitionItemRequestBuilder provides operations to manage the columns property of the microsoft.graph.site entity.
|
||||
type ItemColumnsColumnDefinitionItemRequestBuilder struct {
|
||||
// Path parameters for the request
|
||||
pathParameters map[string]string
|
||||
// The request adapter to use to execute the requests.
|
||||
requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter
|
||||
// Url template to use to build the URL for the current request builder
|
||||
urlTemplate string
|
||||
// Path parameters for the request
|
||||
pathParameters map[string]string
|
||||
// The request adapter to use to execute the requests.
|
||||
requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter
|
||||
// Url template to use to build the URL for the current request builder
|
||||
urlTemplate string
|
||||
}
|
||||
|
||||
// ItemColumnsColumnDefinitionItemRequestBuilderDeleteRequestConfiguration configuration for the request such as headers, query parameters, and middleware options.
|
||||
type ItemColumnsColumnDefinitionItemRequestBuilderDeleteRequestConfiguration struct {
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
}
|
||||
|
||||
// ItemColumnsColumnDefinitionItemRequestBuilderGetQueryParameters the collection of column definitions reusable across lists under this site.
|
||||
type ItemColumnsColumnDefinitionItemRequestBuilderGetQueryParameters struct {
|
||||
// Expand related entities
|
||||
Expand []string `uriparametername:"%24expand"`
|
||||
// Select properties to be returned
|
||||
Select []string `uriparametername:"%24select"`
|
||||
// Expand related entities
|
||||
Expand []string `uriparametername:"%24expand"`
|
||||
// Select properties to be returned
|
||||
Select []string `uriparametername:"%24select"`
|
||||
}
|
||||
|
||||
// ItemColumnsColumnDefinitionItemRequestBuilderGetRequestConfiguration configuration for the request such as headers, query parameters, and middleware options.
|
||||
type ItemColumnsColumnDefinitionItemRequestBuilderGetRequestConfiguration struct {
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
// Request query parameters
|
||||
QueryParameters *ItemColumnsColumnDefinitionItemRequestBuilderGetQueryParameters
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
// Request query parameters
|
||||
QueryParameters *ItemColumnsColumnDefinitionItemRequestBuilderGetQueryParameters
|
||||
}
|
||||
|
||||
// ItemColumnsColumnDefinitionItemRequestBuilderPatchRequestConfiguration configuration for the request such as headers, query parameters, and middleware options.
|
||||
type ItemColumnsColumnDefinitionItemRequestBuilderPatchRequestConfiguration struct {
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
}
|
||||
|
||||
// NewItemColumnsColumnDefinitionItemRequestBuilderInternal instantiates a new ColumnDefinitionItemRequestBuilder and sets the default values.
|
||||
func NewItemColumnsColumnDefinitionItemRequestBuilderInternal(pathParameters map[string]string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemColumnsColumnDefinitionItemRequestBuilder) {
|
||||
m := &ItemColumnsColumnDefinitionItemRequestBuilder{
|
||||
}
|
||||
m.urlTemplate = "{+baseurl}/sites/{site%2Did}/columns/{columnDefinition%2Did}{?%24select,%24expand}";
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
m.pathParameters = urlTplParams;
|
||||
m.requestAdapter = requestAdapter;
|
||||
return m
|
||||
func NewItemColumnsColumnDefinitionItemRequestBuilderInternal(pathParameters map[string]string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter) *ItemColumnsColumnDefinitionItemRequestBuilder {
|
||||
m := &ItemColumnsColumnDefinitionItemRequestBuilder{}
|
||||
m.urlTemplate = "{+baseurl}/sites/{site%2Did}/columns/{columnDefinition%2Did}{?%24select,%24expand}"
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
m.pathParameters = urlTplParams
|
||||
m.requestAdapter = requestAdapter
|
||||
return m
|
||||
}
|
||||
|
||||
// NewItemColumnsColumnDefinitionItemRequestBuilder instantiates a new ColumnDefinitionItemRequestBuilder and sets the default values.
|
||||
func NewItemColumnsColumnDefinitionItemRequestBuilder(rawUrl string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemColumnsColumnDefinitionItemRequestBuilder) {
|
||||
urlParams := make(map[string]string)
|
||||
urlParams["request-raw-url"] = rawUrl
|
||||
return NewItemColumnsColumnDefinitionItemRequestBuilderInternal(urlParams, requestAdapter)
|
||||
func NewItemColumnsColumnDefinitionItemRequestBuilder(rawUrl string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter) *ItemColumnsColumnDefinitionItemRequestBuilder {
|
||||
urlParams := make(map[string]string)
|
||||
urlParams["request-raw-url"] = rawUrl
|
||||
return NewItemColumnsColumnDefinitionItemRequestBuilderInternal(urlParams, requestAdapter)
|
||||
}
|
||||
|
||||
// CreateDeleteRequestInformation delete navigation property columns for sites
|
||||
func (m *ItemColumnsColumnDefinitionItemRequestBuilder) CreateDeleteRequestInformation(ctx context.Context, requestConfiguration *ItemColumnsColumnDefinitionItemRequestBuilderDeleteRequestConfiguration)(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.DELETE
|
||||
if requestConfiguration != nil {
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
func (m *ItemColumnsColumnDefinitionItemRequestBuilder) CreateDeleteRequestInformation(ctx context.Context, requestConfiguration *ItemColumnsColumnDefinitionItemRequestBuilderDeleteRequestConfiguration) (*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.DELETE
|
||||
if requestConfiguration != nil {
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
}
|
||||
|
||||
// CreateGetRequestInformation the collection of column definitions reusable across lists under this site.
|
||||
func (m *ItemColumnsColumnDefinitionItemRequestBuilder) CreateGetRequestInformation(ctx context.Context, requestConfiguration *ItemColumnsColumnDefinitionItemRequestBuilderGetRequestConfiguration)(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.GET
|
||||
requestInfo.Headers.Add("Accept", "application/json")
|
||||
if requestConfiguration != nil {
|
||||
if requestConfiguration.QueryParameters != nil {
|
||||
requestInfo.AddQueryParameters(*(requestConfiguration.QueryParameters))
|
||||
}
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
func (m *ItemColumnsColumnDefinitionItemRequestBuilder) CreateGetRequestInformation(ctx context.Context, requestConfiguration *ItemColumnsColumnDefinitionItemRequestBuilderGetRequestConfiguration) (*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.GET
|
||||
requestInfo.Headers.Add("Accept", "application/json")
|
||||
if requestConfiguration != nil {
|
||||
if requestConfiguration.QueryParameters != nil {
|
||||
requestInfo.AddQueryParameters(*(requestConfiguration.QueryParameters))
|
||||
}
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
}
|
||||
|
||||
// CreatePatchRequestInformation update the navigation property columns in sites
|
||||
func (m *ItemColumnsColumnDefinitionItemRequestBuilder) CreatePatchRequestInformation(ctx context.Context, body ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ColumnDefinitionable, requestConfiguration *ItemColumnsColumnDefinitionItemRequestBuilderPatchRequestConfiguration)(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.PATCH
|
||||
requestInfo.Headers.Add("Accept", "application/json")
|
||||
requestInfo.SetContentFromParsable(ctx, m.requestAdapter, "application/json", body)
|
||||
if requestConfiguration != nil {
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
func (m *ItemColumnsColumnDefinitionItemRequestBuilder) CreatePatchRequestInformation(ctx context.Context, body ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ColumnDefinitionable, requestConfiguration *ItemColumnsColumnDefinitionItemRequestBuilderPatchRequestConfiguration) (*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.PATCH
|
||||
requestInfo.Headers.Add("Accept", "application/json")
|
||||
requestInfo.SetContentFromParsable(ctx, m.requestAdapter, "application/json", body)
|
||||
if requestConfiguration != nil {
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
}
|
||||
|
||||
// Delete delete navigation property columns for sites
|
||||
func (m *ItemColumnsColumnDefinitionItemRequestBuilder) Delete(ctx context.Context, requestConfiguration *ItemColumnsColumnDefinitionItemRequestBuilderDeleteRequestConfiguration)(error) {
|
||||
requestInfo, err := m.CreateDeleteRequestInformation(ctx, requestConfiguration);
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings {
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
err = m.requestAdapter.SendNoContentAsync(ctx, requestInfo, errorMapping)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
return nil
|
||||
func (m *ItemColumnsColumnDefinitionItemRequestBuilder) Delete(ctx context.Context, requestConfiguration *ItemColumnsColumnDefinitionItemRequestBuilderDeleteRequestConfiguration) error {
|
||||
requestInfo, err := m.CreateDeleteRequestInformation(ctx, requestConfiguration)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings{
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
err = m.requestAdapter.SendNoContent(ctx, requestInfo, errorMapping)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
// Get the collection of column definitions reusable across lists under this site.
|
||||
func (m *ItemColumnsColumnDefinitionItemRequestBuilder) Get(ctx context.Context, requestConfiguration *ItemColumnsColumnDefinitionItemRequestBuilderGetRequestConfiguration)(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ColumnDefinitionable, error) {
|
||||
requestInfo, err := m.CreateGetRequestInformation(ctx, requestConfiguration);
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings {
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.SendAsync(ctx, requestInfo, ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CreateColumnDefinitionFromDiscriminatorValue, errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ColumnDefinitionable), nil
|
||||
func (m *ItemColumnsColumnDefinitionItemRequestBuilder) Get(ctx context.Context, requestConfiguration *ItemColumnsColumnDefinitionItemRequestBuilderGetRequestConfiguration) (ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ColumnDefinitionable, error) {
|
||||
requestInfo, err := m.CreateGetRequestInformation(ctx, requestConfiguration)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings{
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.Send(ctx, requestInfo, ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CreateColumnDefinitionFromDiscriminatorValue, errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ColumnDefinitionable), nil
|
||||
}
|
||||
|
||||
// Patch update the navigation property columns in sites
|
||||
func (m *ItemColumnsColumnDefinitionItemRequestBuilder) Patch(ctx context.Context, body ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ColumnDefinitionable, requestConfiguration *ItemColumnsColumnDefinitionItemRequestBuilderPatchRequestConfiguration)(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ColumnDefinitionable, error) {
|
||||
requestInfo, err := m.CreatePatchRequestInformation(ctx, body, requestConfiguration);
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings {
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.SendAsync(ctx, requestInfo, ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CreateColumnDefinitionFromDiscriminatorValue, errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ColumnDefinitionable), nil
|
||||
func (m *ItemColumnsColumnDefinitionItemRequestBuilder) Patch(ctx context.Context, body ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ColumnDefinitionable, requestConfiguration *ItemColumnsColumnDefinitionItemRequestBuilderPatchRequestConfiguration) (ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ColumnDefinitionable, error) {
|
||||
requestInfo, err := m.CreatePatchRequestInformation(ctx, body, requestConfiguration)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings{
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.Send(ctx, requestInfo, ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CreateColumnDefinitionFromDiscriminatorValue, errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ColumnDefinitionable), nil
|
||||
}
|
||||
|
||||
// SourceColumn provides operations to manage the sourceColumn property of the microsoft.graph.columnDefinition entity.
|
||||
func (m *ItemColumnsColumnDefinitionItemRequestBuilder) SourceColumn()(*ItemColumnsItemSourceColumnRequestBuilder) {
|
||||
return NewItemColumnsItemSourceColumnRequestBuilderInternal(m.pathParameters, m.requestAdapter);
|
||||
func (m *ItemColumnsColumnDefinitionItemRequestBuilder) SourceColumn() *ItemColumnsItemSourceColumnRequestBuilder {
|
||||
return NewItemColumnsItemSourceColumnRequestBuilderInternal(m.pathParameters, m.requestAdapter)
|
||||
}
|
||||
|
||||
@ -1,87 +1,93 @@
|
||||
package sites
|
||||
|
||||
import (
|
||||
"context"
|
||||
i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f "github.com/microsoft/kiota-abstractions-go"
|
||||
i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models/odataerrors"
|
||||
"context"
|
||||
|
||||
i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models/odataerrors"
|
||||
i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f "github.com/microsoft/kiota-abstractions-go"
|
||||
)
|
||||
|
||||
// ItemColumnsCountRequestBuilder provides operations to count the resources in the collection.
|
||||
type ItemColumnsCountRequestBuilder struct {
|
||||
// Path parameters for the request
|
||||
pathParameters map[string]string
|
||||
// The request adapter to use to execute the requests.
|
||||
requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter
|
||||
// Url template to use to build the URL for the current request builder
|
||||
urlTemplate string
|
||||
// Path parameters for the request
|
||||
pathParameters map[string]string
|
||||
// The request adapter to use to execute the requests.
|
||||
requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter
|
||||
// Url template to use to build the URL for the current request builder
|
||||
urlTemplate string
|
||||
}
|
||||
|
||||
// ItemColumnsCountRequestBuilderGetQueryParameters get the number of the resource
|
||||
type ItemColumnsCountRequestBuilderGetQueryParameters struct {
|
||||
// Filter items by property values
|
||||
Filter *string `uriparametername:"%24filter"`
|
||||
// Search items by search phrases
|
||||
Search *string `uriparametername:"%24search"`
|
||||
// Filter items by property values
|
||||
Filter *string `uriparametername:"%24filter"`
|
||||
// Search items by search phrases
|
||||
Search *string `uriparametername:"%24search"`
|
||||
}
|
||||
|
||||
// ItemColumnsCountRequestBuilderGetRequestConfiguration configuration for the request such as headers, query parameters, and middleware options.
|
||||
type ItemColumnsCountRequestBuilderGetRequestConfiguration struct {
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
// Request query parameters
|
||||
QueryParameters *ItemColumnsCountRequestBuilderGetQueryParameters
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
// Request query parameters
|
||||
QueryParameters *ItemColumnsCountRequestBuilderGetQueryParameters
|
||||
}
|
||||
|
||||
// NewItemColumnsCountRequestBuilderInternal instantiates a new CountRequestBuilder and sets the default values.
|
||||
func NewItemColumnsCountRequestBuilderInternal(pathParameters map[string]string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemColumnsCountRequestBuilder) {
|
||||
m := &ItemColumnsCountRequestBuilder{
|
||||
}
|
||||
m.urlTemplate = "{+baseurl}/sites/{site%2Did}/columns/$count{?%24search,%24filter}";
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
m.pathParameters = urlTplParams;
|
||||
m.requestAdapter = requestAdapter;
|
||||
return m
|
||||
func NewItemColumnsCountRequestBuilderInternal(pathParameters map[string]string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter) *ItemColumnsCountRequestBuilder {
|
||||
m := &ItemColumnsCountRequestBuilder{}
|
||||
m.urlTemplate = "{+baseurl}/sites/{site%2Did}/columns/$count{?%24search,%24filter}"
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
m.pathParameters = urlTplParams
|
||||
m.requestAdapter = requestAdapter
|
||||
return m
|
||||
}
|
||||
|
||||
// NewItemColumnsCountRequestBuilder instantiates a new CountRequestBuilder and sets the default values.
|
||||
func NewItemColumnsCountRequestBuilder(rawUrl string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemColumnsCountRequestBuilder) {
|
||||
urlParams := make(map[string]string)
|
||||
urlParams["request-raw-url"] = rawUrl
|
||||
return NewItemColumnsCountRequestBuilderInternal(urlParams, requestAdapter)
|
||||
func NewItemColumnsCountRequestBuilder(rawUrl string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter) *ItemColumnsCountRequestBuilder {
|
||||
urlParams := make(map[string]string)
|
||||
urlParams["request-raw-url"] = rawUrl
|
||||
return NewItemColumnsCountRequestBuilderInternal(urlParams, requestAdapter)
|
||||
}
|
||||
|
||||
// CreateGetRequestInformation get the number of the resource
|
||||
func (m *ItemColumnsCountRequestBuilder) CreateGetRequestInformation(ctx context.Context, requestConfiguration *ItemColumnsCountRequestBuilderGetRequestConfiguration)(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.GET
|
||||
requestInfo.Headers.Add("Accept", "text/plain")
|
||||
if requestConfiguration != nil {
|
||||
if requestConfiguration.QueryParameters != nil {
|
||||
requestInfo.AddQueryParameters(*(requestConfiguration.QueryParameters))
|
||||
}
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
func (m *ItemColumnsCountRequestBuilder) CreateGetRequestInformation(ctx context.Context, requestConfiguration *ItemColumnsCountRequestBuilderGetRequestConfiguration) (*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.GET
|
||||
requestInfo.Headers.Add("Accept", "text/plain")
|
||||
if requestConfiguration != nil {
|
||||
if requestConfiguration.QueryParameters != nil {
|
||||
requestInfo.AddQueryParameters(*(requestConfiguration.QueryParameters))
|
||||
}
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
}
|
||||
|
||||
// Get get the number of the resource
|
||||
func (m *ItemColumnsCountRequestBuilder) Get(ctx context.Context, requestConfiguration *ItemColumnsCountRequestBuilderGetRequestConfiguration)(*int32, error) {
|
||||
requestInfo, err := m.CreateGetRequestInformation(ctx, requestConfiguration);
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings {
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.SendPrimitiveAsync(ctx, requestInfo, "int32", errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(*int32), nil
|
||||
func (m *ItemColumnsCountRequestBuilder) Get(ctx context.Context, requestConfiguration *ItemColumnsCountRequestBuilderGetRequestConfiguration) (*int32, error) {
|
||||
requestInfo, err := m.CreateGetRequestInformation(ctx, requestConfiguration)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings{
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.SendPrimitive(ctx, requestInfo, "int32", errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(*int32), nil
|
||||
}
|
||||
|
||||
@ -1,88 +1,94 @@
|
||||
package sites
|
||||
|
||||
import (
|
||||
"context"
|
||||
i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f "github.com/microsoft/kiota-abstractions-go"
|
||||
ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models"
|
||||
i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models/odataerrors"
|
||||
"context"
|
||||
|
||||
ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models"
|
||||
i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models/odataerrors"
|
||||
i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f "github.com/microsoft/kiota-abstractions-go"
|
||||
)
|
||||
|
||||
// ItemColumnsItemSourceColumnRequestBuilder provides operations to manage the sourceColumn property of the microsoft.graph.columnDefinition entity.
|
||||
type ItemColumnsItemSourceColumnRequestBuilder struct {
|
||||
// Path parameters for the request
|
||||
pathParameters map[string]string
|
||||
// The request adapter to use to execute the requests.
|
||||
requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter
|
||||
// Url template to use to build the URL for the current request builder
|
||||
urlTemplate string
|
||||
// Path parameters for the request
|
||||
pathParameters map[string]string
|
||||
// The request adapter to use to execute the requests.
|
||||
requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter
|
||||
// Url template to use to build the URL for the current request builder
|
||||
urlTemplate string
|
||||
}
|
||||
|
||||
// ItemColumnsItemSourceColumnRequestBuilderGetQueryParameters the source column for content type column.
|
||||
type ItemColumnsItemSourceColumnRequestBuilderGetQueryParameters struct {
|
||||
// Expand related entities
|
||||
Expand []string `uriparametername:"%24expand"`
|
||||
// Select properties to be returned
|
||||
Select []string `uriparametername:"%24select"`
|
||||
// Expand related entities
|
||||
Expand []string `uriparametername:"%24expand"`
|
||||
// Select properties to be returned
|
||||
Select []string `uriparametername:"%24select"`
|
||||
}
|
||||
|
||||
// ItemColumnsItemSourceColumnRequestBuilderGetRequestConfiguration configuration for the request such as headers, query parameters, and middleware options.
|
||||
type ItemColumnsItemSourceColumnRequestBuilderGetRequestConfiguration struct {
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
// Request query parameters
|
||||
QueryParameters *ItemColumnsItemSourceColumnRequestBuilderGetQueryParameters
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
// Request query parameters
|
||||
QueryParameters *ItemColumnsItemSourceColumnRequestBuilderGetQueryParameters
|
||||
}
|
||||
|
||||
// NewItemColumnsItemSourceColumnRequestBuilderInternal instantiates a new SourceColumnRequestBuilder and sets the default values.
|
||||
func NewItemColumnsItemSourceColumnRequestBuilderInternal(pathParameters map[string]string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemColumnsItemSourceColumnRequestBuilder) {
|
||||
m := &ItemColumnsItemSourceColumnRequestBuilder{
|
||||
}
|
||||
m.urlTemplate = "{+baseurl}/sites/{site%2Did}/columns/{columnDefinition%2Did}/sourceColumn{?%24select,%24expand}";
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
m.pathParameters = urlTplParams;
|
||||
m.requestAdapter = requestAdapter;
|
||||
return m
|
||||
func NewItemColumnsItemSourceColumnRequestBuilderInternal(pathParameters map[string]string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter) *ItemColumnsItemSourceColumnRequestBuilder {
|
||||
m := &ItemColumnsItemSourceColumnRequestBuilder{}
|
||||
m.urlTemplate = "{+baseurl}/sites/{site%2Did}/columns/{columnDefinition%2Did}/sourceColumn{?%24select,%24expand}"
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
m.pathParameters = urlTplParams
|
||||
m.requestAdapter = requestAdapter
|
||||
return m
|
||||
}
|
||||
|
||||
// NewItemColumnsItemSourceColumnRequestBuilder instantiates a new SourceColumnRequestBuilder and sets the default values.
|
||||
func NewItemColumnsItemSourceColumnRequestBuilder(rawUrl string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemColumnsItemSourceColumnRequestBuilder) {
|
||||
urlParams := make(map[string]string)
|
||||
urlParams["request-raw-url"] = rawUrl
|
||||
return NewItemColumnsItemSourceColumnRequestBuilderInternal(urlParams, requestAdapter)
|
||||
func NewItemColumnsItemSourceColumnRequestBuilder(rawUrl string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter) *ItemColumnsItemSourceColumnRequestBuilder {
|
||||
urlParams := make(map[string]string)
|
||||
urlParams["request-raw-url"] = rawUrl
|
||||
return NewItemColumnsItemSourceColumnRequestBuilderInternal(urlParams, requestAdapter)
|
||||
}
|
||||
|
||||
// CreateGetRequestInformation the source column for content type column.
|
||||
func (m *ItemColumnsItemSourceColumnRequestBuilder) CreateGetRequestInformation(ctx context.Context, requestConfiguration *ItemColumnsItemSourceColumnRequestBuilderGetRequestConfiguration)(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.GET
|
||||
requestInfo.Headers.Add("Accept", "application/json")
|
||||
if requestConfiguration != nil {
|
||||
if requestConfiguration.QueryParameters != nil {
|
||||
requestInfo.AddQueryParameters(*(requestConfiguration.QueryParameters))
|
||||
}
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
func (m *ItemColumnsItemSourceColumnRequestBuilder) CreateGetRequestInformation(ctx context.Context, requestConfiguration *ItemColumnsItemSourceColumnRequestBuilderGetRequestConfiguration) (*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.GET
|
||||
requestInfo.Headers.Add("Accept", "application/json")
|
||||
if requestConfiguration != nil {
|
||||
if requestConfiguration.QueryParameters != nil {
|
||||
requestInfo.AddQueryParameters(*(requestConfiguration.QueryParameters))
|
||||
}
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
}
|
||||
|
||||
// Get the source column for content type column.
|
||||
func (m *ItemColumnsItemSourceColumnRequestBuilder) Get(ctx context.Context, requestConfiguration *ItemColumnsItemSourceColumnRequestBuilderGetRequestConfiguration)(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ColumnDefinitionable, error) {
|
||||
requestInfo, err := m.CreateGetRequestInformation(ctx, requestConfiguration);
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings {
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.SendAsync(ctx, requestInfo, ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CreateColumnDefinitionFromDiscriminatorValue, errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ColumnDefinitionable), nil
|
||||
func (m *ItemColumnsItemSourceColumnRequestBuilder) Get(ctx context.Context, requestConfiguration *ItemColumnsItemSourceColumnRequestBuilderGetRequestConfiguration) (ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ColumnDefinitionable, error) {
|
||||
requestInfo, err := m.CreateGetRequestInformation(ctx, requestConfiguration)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings{
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.Send(ctx, requestInfo, ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CreateColumnDefinitionFromDiscriminatorValue, errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ColumnDefinitionable), nil
|
||||
}
|
||||
|
||||
@ -1,150 +1,160 @@
|
||||
package sites
|
||||
|
||||
import (
|
||||
"context"
|
||||
i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f "github.com/microsoft/kiota-abstractions-go"
|
||||
ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models"
|
||||
i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models/odataerrors"
|
||||
"context"
|
||||
|
||||
ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models"
|
||||
i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models/odataerrors"
|
||||
i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f "github.com/microsoft/kiota-abstractions-go"
|
||||
)
|
||||
|
||||
// ItemColumnsRequestBuilder provides operations to manage the columns property of the microsoft.graph.site entity.
|
||||
type ItemColumnsRequestBuilder struct {
|
||||
// Path parameters for the request
|
||||
pathParameters map[string]string
|
||||
// The request adapter to use to execute the requests.
|
||||
requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter
|
||||
// Url template to use to build the URL for the current request builder
|
||||
urlTemplate string
|
||||
// Path parameters for the request
|
||||
pathParameters map[string]string
|
||||
// The request adapter to use to execute the requests.
|
||||
requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter
|
||||
// Url template to use to build the URL for the current request builder
|
||||
urlTemplate string
|
||||
}
|
||||
|
||||
// ItemColumnsRequestBuilderGetQueryParameters get the collection of columns, represented as [columnDefinition][columnDefinition] resources, in a [site][site].
|
||||
type ItemColumnsRequestBuilderGetQueryParameters struct {
|
||||
// Include count of items
|
||||
Count *bool `uriparametername:"%24count"`
|
||||
// Expand related entities
|
||||
Expand []string `uriparametername:"%24expand"`
|
||||
// Filter items by property values
|
||||
Filter *string `uriparametername:"%24filter"`
|
||||
// Order items by property values
|
||||
Orderby []string `uriparametername:"%24orderby"`
|
||||
// Search items by search phrases
|
||||
Search *string `uriparametername:"%24search"`
|
||||
// Select properties to be returned
|
||||
Select []string `uriparametername:"%24select"`
|
||||
// Skip the first n items
|
||||
Skip *int32 `uriparametername:"%24skip"`
|
||||
// Show only the first n items
|
||||
Top *int32 `uriparametername:"%24top"`
|
||||
// Include count of items
|
||||
Count *bool `uriparametername:"%24count"`
|
||||
// Expand related entities
|
||||
Expand []string `uriparametername:"%24expand"`
|
||||
// Filter items by property values
|
||||
Filter *string `uriparametername:"%24filter"`
|
||||
// Order items by property values
|
||||
Orderby []string `uriparametername:"%24orderby"`
|
||||
// Search items by search phrases
|
||||
Search *string `uriparametername:"%24search"`
|
||||
// Select properties to be returned
|
||||
Select []string `uriparametername:"%24select"`
|
||||
// Skip the first n items
|
||||
Skip *int32 `uriparametername:"%24skip"`
|
||||
// Show only the first n items
|
||||
Top *int32 `uriparametername:"%24top"`
|
||||
}
|
||||
|
||||
// ItemColumnsRequestBuilderGetRequestConfiguration configuration for the request such as headers, query parameters, and middleware options.
|
||||
type ItemColumnsRequestBuilderGetRequestConfiguration struct {
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
// Request query parameters
|
||||
QueryParameters *ItemColumnsRequestBuilderGetQueryParameters
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
// Request query parameters
|
||||
QueryParameters *ItemColumnsRequestBuilderGetQueryParameters
|
||||
}
|
||||
|
||||
// ItemColumnsRequestBuilderPostRequestConfiguration configuration for the request such as headers, query parameters, and middleware options.
|
||||
type ItemColumnsRequestBuilderPostRequestConfiguration struct {
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
}
|
||||
|
||||
// NewItemColumnsRequestBuilderInternal instantiates a new ColumnsRequestBuilder and sets the default values.
|
||||
func NewItemColumnsRequestBuilderInternal(pathParameters map[string]string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemColumnsRequestBuilder) {
|
||||
m := &ItemColumnsRequestBuilder{
|
||||
}
|
||||
m.urlTemplate = "{+baseurl}/sites/{site%2Did}/columns{?%24top,%24skip,%24search,%24filter,%24count,%24orderby,%24select,%24expand}";
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
m.pathParameters = urlTplParams;
|
||||
m.requestAdapter = requestAdapter;
|
||||
return m
|
||||
func NewItemColumnsRequestBuilderInternal(pathParameters map[string]string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter) *ItemColumnsRequestBuilder {
|
||||
m := &ItemColumnsRequestBuilder{}
|
||||
m.urlTemplate = "{+baseurl}/sites/{site%2Did}/columns{?%24top,%24skip,%24search,%24filter,%24count,%24orderby,%24select,%24expand}"
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
m.pathParameters = urlTplParams
|
||||
m.requestAdapter = requestAdapter
|
||||
return m
|
||||
}
|
||||
|
||||
// NewItemColumnsRequestBuilder instantiates a new ColumnsRequestBuilder and sets the default values.
|
||||
func NewItemColumnsRequestBuilder(rawUrl string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemColumnsRequestBuilder) {
|
||||
urlParams := make(map[string]string)
|
||||
urlParams["request-raw-url"] = rawUrl
|
||||
return NewItemColumnsRequestBuilderInternal(urlParams, requestAdapter)
|
||||
func NewItemColumnsRequestBuilder(rawUrl string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter) *ItemColumnsRequestBuilder {
|
||||
urlParams := make(map[string]string)
|
||||
urlParams["request-raw-url"] = rawUrl
|
||||
return NewItemColumnsRequestBuilderInternal(urlParams, requestAdapter)
|
||||
}
|
||||
|
||||
// Count provides operations to count the resources in the collection.
|
||||
func (m *ItemColumnsRequestBuilder) Count()(*ItemColumnsCountRequestBuilder) {
|
||||
return NewItemColumnsCountRequestBuilderInternal(m.pathParameters, m.requestAdapter);
|
||||
func (m *ItemColumnsRequestBuilder) Count() *ItemColumnsCountRequestBuilder {
|
||||
return NewItemColumnsCountRequestBuilderInternal(m.pathParameters, m.requestAdapter)
|
||||
}
|
||||
|
||||
// CreateGetRequestInformation get the collection of columns, represented as [columnDefinition][columnDefinition] resources, in a [site][site].
|
||||
func (m *ItemColumnsRequestBuilder) CreateGetRequestInformation(ctx context.Context, requestConfiguration *ItemColumnsRequestBuilderGetRequestConfiguration)(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.GET
|
||||
requestInfo.Headers.Add("Accept", "application/json")
|
||||
if requestConfiguration != nil {
|
||||
if requestConfiguration.QueryParameters != nil {
|
||||
requestInfo.AddQueryParameters(*(requestConfiguration.QueryParameters))
|
||||
}
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
func (m *ItemColumnsRequestBuilder) CreateGetRequestInformation(ctx context.Context, requestConfiguration *ItemColumnsRequestBuilderGetRequestConfiguration) (*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.GET
|
||||
requestInfo.Headers.Add("Accept", "application/json")
|
||||
if requestConfiguration != nil {
|
||||
if requestConfiguration.QueryParameters != nil {
|
||||
requestInfo.AddQueryParameters(*(requestConfiguration.QueryParameters))
|
||||
}
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
}
|
||||
|
||||
// CreatePostRequestInformation create a column for a [site][site] by specifying a [columnDefinition][columnDefinition].
|
||||
func (m *ItemColumnsRequestBuilder) CreatePostRequestInformation(ctx context.Context, body ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ColumnDefinitionable, requestConfiguration *ItemColumnsRequestBuilderPostRequestConfiguration)(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.POST
|
||||
requestInfo.Headers.Add("Accept", "application/json")
|
||||
requestInfo.SetContentFromParsable(ctx, m.requestAdapter, "application/json", body)
|
||||
if requestConfiguration != nil {
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
func (m *ItemColumnsRequestBuilder) CreatePostRequestInformation(ctx context.Context, body ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ColumnDefinitionable, requestConfiguration *ItemColumnsRequestBuilderPostRequestConfiguration) (*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.POST
|
||||
requestInfo.Headers.Add("Accept", "application/json")
|
||||
requestInfo.SetContentFromParsable(ctx, m.requestAdapter, "application/json", body)
|
||||
if requestConfiguration != nil {
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
}
|
||||
|
||||
// Get get the collection of columns, represented as [columnDefinition][columnDefinition] resources, in a [site][site].
|
||||
// [Find more info here]
|
||||
//
|
||||
//
|
||||
// [Find more info here]: https://docs.microsoft.com/graph/api/site-list-columns?view=graph-rest-1.0
|
||||
func (m *ItemColumnsRequestBuilder) Get(ctx context.Context, requestConfiguration *ItemColumnsRequestBuilderGetRequestConfiguration)(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ColumnDefinitionCollectionResponseable, error) {
|
||||
requestInfo, err := m.CreateGetRequestInformation(ctx, requestConfiguration);
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings {
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.SendAsync(ctx, requestInfo, ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CreateColumnDefinitionCollectionResponseFromDiscriminatorValue, errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ColumnDefinitionCollectionResponseable), nil
|
||||
func (m *ItemColumnsRequestBuilder) Get(ctx context.Context, requestConfiguration *ItemColumnsRequestBuilderGetRequestConfiguration) (ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ColumnDefinitionCollectionResponseable, error) {
|
||||
requestInfo, err := m.CreateGetRequestInformation(ctx, requestConfiguration)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings{
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.Send(ctx, requestInfo, ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CreateColumnDefinitionCollectionResponseFromDiscriminatorValue, errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ColumnDefinitionCollectionResponseable), nil
|
||||
}
|
||||
|
||||
// Post create a column for a [site][site] by specifying a [columnDefinition][columnDefinition].
|
||||
// [Find more info here]
|
||||
//
|
||||
//
|
||||
// [Find more info here]: https://docs.microsoft.com/graph/api/site-post-columns?view=graph-rest-1.0
|
||||
func (m *ItemColumnsRequestBuilder) Post(ctx context.Context, body ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ColumnDefinitionable, requestConfiguration *ItemColumnsRequestBuilderPostRequestConfiguration)(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ColumnDefinitionable, error) {
|
||||
requestInfo, err := m.CreatePostRequestInformation(ctx, body, requestConfiguration);
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings {
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.SendAsync(ctx, requestInfo, ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CreateColumnDefinitionFromDiscriminatorValue, errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ColumnDefinitionable), nil
|
||||
func (m *ItemColumnsRequestBuilder) Post(ctx context.Context, body ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ColumnDefinitionable, requestConfiguration *ItemColumnsRequestBuilderPostRequestConfiguration) (ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ColumnDefinitionable, error) {
|
||||
requestInfo, err := m.CreatePostRequestInformation(ctx, body, requestConfiguration)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings{
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.Send(ctx, requestInfo, ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CreateColumnDefinitionFromDiscriminatorValue, errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ColumnDefinitionable), nil
|
||||
}
|
||||
|
||||
@ -1,80 +1,85 @@
|
||||
package sites
|
||||
|
||||
import (
|
||||
"context"
|
||||
i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f "github.com/microsoft/kiota-abstractions-go"
|
||||
ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models"
|
||||
i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models/odataerrors"
|
||||
"context"
|
||||
|
||||
ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models"
|
||||
i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models/odataerrors"
|
||||
i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f "github.com/microsoft/kiota-abstractions-go"
|
||||
)
|
||||
|
||||
// ItemContentTypesAddCopyFromContentTypeHubRequestBuilder provides operations to call the addCopyFromContentTypeHub method.
|
||||
type ItemContentTypesAddCopyFromContentTypeHubRequestBuilder struct {
|
||||
// Path parameters for the request
|
||||
pathParameters map[string]string
|
||||
// The request adapter to use to execute the requests.
|
||||
requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter
|
||||
// Url template to use to build the URL for the current request builder
|
||||
urlTemplate string
|
||||
// Path parameters for the request
|
||||
pathParameters map[string]string
|
||||
// The request adapter to use to execute the requests.
|
||||
requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter
|
||||
// Url template to use to build the URL for the current request builder
|
||||
urlTemplate string
|
||||
}
|
||||
|
||||
// ItemContentTypesAddCopyFromContentTypeHubRequestBuilderPostRequestConfiguration configuration for the request such as headers, query parameters, and middleware options.
|
||||
type ItemContentTypesAddCopyFromContentTypeHubRequestBuilderPostRequestConfiguration struct {
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
}
|
||||
|
||||
// NewItemContentTypesAddCopyFromContentTypeHubRequestBuilderInternal instantiates a new AddCopyFromContentTypeHubRequestBuilder and sets the default values.
|
||||
func NewItemContentTypesAddCopyFromContentTypeHubRequestBuilderInternal(pathParameters map[string]string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemContentTypesAddCopyFromContentTypeHubRequestBuilder) {
|
||||
m := &ItemContentTypesAddCopyFromContentTypeHubRequestBuilder{
|
||||
}
|
||||
m.urlTemplate = "{+baseurl}/sites/{site%2Did}/contentTypes/microsoft.graph.addCopyFromContentTypeHub";
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
m.pathParameters = urlTplParams;
|
||||
m.requestAdapter = requestAdapter;
|
||||
return m
|
||||
func NewItemContentTypesAddCopyFromContentTypeHubRequestBuilderInternal(pathParameters map[string]string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter) *ItemContentTypesAddCopyFromContentTypeHubRequestBuilder {
|
||||
m := &ItemContentTypesAddCopyFromContentTypeHubRequestBuilder{}
|
||||
m.urlTemplate = "{+baseurl}/sites/{site%2Did}/contentTypes/microsoft.graph.addCopyFromContentTypeHub"
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
m.pathParameters = urlTplParams
|
||||
m.requestAdapter = requestAdapter
|
||||
return m
|
||||
}
|
||||
|
||||
// NewItemContentTypesAddCopyFromContentTypeHubRequestBuilder instantiates a new AddCopyFromContentTypeHubRequestBuilder and sets the default values.
|
||||
func NewItemContentTypesAddCopyFromContentTypeHubRequestBuilder(rawUrl string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemContentTypesAddCopyFromContentTypeHubRequestBuilder) {
|
||||
urlParams := make(map[string]string)
|
||||
urlParams["request-raw-url"] = rawUrl
|
||||
return NewItemContentTypesAddCopyFromContentTypeHubRequestBuilderInternal(urlParams, requestAdapter)
|
||||
func NewItemContentTypesAddCopyFromContentTypeHubRequestBuilder(rawUrl string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter) *ItemContentTypesAddCopyFromContentTypeHubRequestBuilder {
|
||||
urlParams := make(map[string]string)
|
||||
urlParams["request-raw-url"] = rawUrl
|
||||
return NewItemContentTypesAddCopyFromContentTypeHubRequestBuilderInternal(urlParams, requestAdapter)
|
||||
}
|
||||
|
||||
// CreatePostRequestInformation add or sync a copy of a published content type from the content type hub to a target site or a list. This method is part of the content type publishing changes to optimize the syncing of published content types to sites and lists, effectively switching from a 'push everywhere' to 'pull as needed' approach. The method allows users to pull content types directly from the content type hub to a site or list. For more information, see getCompatibleHubContentTypes and the blog post Syntex Product Updates – August 2021.
|
||||
func (m *ItemContentTypesAddCopyFromContentTypeHubRequestBuilder) CreatePostRequestInformation(ctx context.Context, body ItemContentTypesAddCopyFromContentTypeHubPostRequestBodyable, requestConfiguration *ItemContentTypesAddCopyFromContentTypeHubRequestBuilderPostRequestConfiguration)(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.POST
|
||||
requestInfo.Headers.Add("Accept", "application/json")
|
||||
requestInfo.SetContentFromParsable(ctx, m.requestAdapter, "application/json", body)
|
||||
if requestConfiguration != nil {
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
func (m *ItemContentTypesAddCopyFromContentTypeHubRequestBuilder) CreatePostRequestInformation(ctx context.Context, body ItemContentTypesAddCopyFromContentTypeHubPostRequestBodyable, requestConfiguration *ItemContentTypesAddCopyFromContentTypeHubRequestBuilderPostRequestConfiguration) (*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.POST
|
||||
requestInfo.Headers.Add("Accept", "application/json")
|
||||
requestInfo.SetContentFromParsable(ctx, m.requestAdapter, "application/json", body)
|
||||
if requestConfiguration != nil {
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
}
|
||||
|
||||
// Post add or sync a copy of a published content type from the content type hub to a target site or a list. This method is part of the content type publishing changes to optimize the syncing of published content types to sites and lists, effectively switching from a 'push everywhere' to 'pull as needed' approach. The method allows users to pull content types directly from the content type hub to a site or list. For more information, see getCompatibleHubContentTypes and the blog post Syntex Product Updates – August 2021.
|
||||
// [Find more info here]
|
||||
//
|
||||
//
|
||||
// [Find more info here]: https://docs.microsoft.com/graph/api/contenttype-addcopyfromcontenttypehub?view=graph-rest-1.0
|
||||
func (m *ItemContentTypesAddCopyFromContentTypeHubRequestBuilder) Post(ctx context.Context, body ItemContentTypesAddCopyFromContentTypeHubPostRequestBodyable, requestConfiguration *ItemContentTypesAddCopyFromContentTypeHubRequestBuilderPostRequestConfiguration)(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ContentTypeable, error) {
|
||||
requestInfo, err := m.CreatePostRequestInformation(ctx, body, requestConfiguration);
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings {
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.SendAsync(ctx, requestInfo, ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CreateContentTypeFromDiscriminatorValue, errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ContentTypeable), nil
|
||||
func (m *ItemContentTypesAddCopyFromContentTypeHubRequestBuilder) Post(ctx context.Context, body ItemContentTypesAddCopyFromContentTypeHubPostRequestBodyable, requestConfiguration *ItemContentTypesAddCopyFromContentTypeHubRequestBuilderPostRequestConfiguration) (ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ContentTypeable, error) {
|
||||
requestInfo, err := m.CreatePostRequestInformation(ctx, body, requestConfiguration)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings{
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.Send(ctx, requestInfo, ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CreateContentTypeFromDiscriminatorValue, errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ContentTypeable), nil
|
||||
}
|
||||
|
||||
@ -1,80 +1,85 @@
|
||||
package sites
|
||||
|
||||
import (
|
||||
"context"
|
||||
i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f "github.com/microsoft/kiota-abstractions-go"
|
||||
ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models"
|
||||
i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models/odataerrors"
|
||||
"context"
|
||||
|
||||
ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models"
|
||||
i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models/odataerrors"
|
||||
i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f "github.com/microsoft/kiota-abstractions-go"
|
||||
)
|
||||
|
||||
// ItemContentTypesAddCopyRequestBuilder provides operations to call the addCopy method.
|
||||
type ItemContentTypesAddCopyRequestBuilder struct {
|
||||
// Path parameters for the request
|
||||
pathParameters map[string]string
|
||||
// The request adapter to use to execute the requests.
|
||||
requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter
|
||||
// Url template to use to build the URL for the current request builder
|
||||
urlTemplate string
|
||||
// Path parameters for the request
|
||||
pathParameters map[string]string
|
||||
// The request adapter to use to execute the requests.
|
||||
requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter
|
||||
// Url template to use to build the URL for the current request builder
|
||||
urlTemplate string
|
||||
}
|
||||
|
||||
// ItemContentTypesAddCopyRequestBuilderPostRequestConfiguration configuration for the request such as headers, query parameters, and middleware options.
|
||||
type ItemContentTypesAddCopyRequestBuilderPostRequestConfiguration struct {
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
}
|
||||
|
||||
// NewItemContentTypesAddCopyRequestBuilderInternal instantiates a new AddCopyRequestBuilder and sets the default values.
|
||||
func NewItemContentTypesAddCopyRequestBuilderInternal(pathParameters map[string]string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemContentTypesAddCopyRequestBuilder) {
|
||||
m := &ItemContentTypesAddCopyRequestBuilder{
|
||||
}
|
||||
m.urlTemplate = "{+baseurl}/sites/{site%2Did}/contentTypes/microsoft.graph.addCopy";
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
m.pathParameters = urlTplParams;
|
||||
m.requestAdapter = requestAdapter;
|
||||
return m
|
||||
func NewItemContentTypesAddCopyRequestBuilderInternal(pathParameters map[string]string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter) *ItemContentTypesAddCopyRequestBuilder {
|
||||
m := &ItemContentTypesAddCopyRequestBuilder{}
|
||||
m.urlTemplate = "{+baseurl}/sites/{site%2Did}/contentTypes/microsoft.graph.addCopy"
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
m.pathParameters = urlTplParams
|
||||
m.requestAdapter = requestAdapter
|
||||
return m
|
||||
}
|
||||
|
||||
// NewItemContentTypesAddCopyRequestBuilder instantiates a new AddCopyRequestBuilder and sets the default values.
|
||||
func NewItemContentTypesAddCopyRequestBuilder(rawUrl string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemContentTypesAddCopyRequestBuilder) {
|
||||
urlParams := make(map[string]string)
|
||||
urlParams["request-raw-url"] = rawUrl
|
||||
return NewItemContentTypesAddCopyRequestBuilderInternal(urlParams, requestAdapter)
|
||||
func NewItemContentTypesAddCopyRequestBuilder(rawUrl string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter) *ItemContentTypesAddCopyRequestBuilder {
|
||||
urlParams := make(map[string]string)
|
||||
urlParams["request-raw-url"] = rawUrl
|
||||
return NewItemContentTypesAddCopyRequestBuilderInternal(urlParams, requestAdapter)
|
||||
}
|
||||
|
||||
// CreatePostRequestInformation add a copy of a [content type][contentType] from a [site][site] to a [list][list].
|
||||
func (m *ItemContentTypesAddCopyRequestBuilder) CreatePostRequestInformation(ctx context.Context, body ItemContentTypesAddCopyPostRequestBodyable, requestConfiguration *ItemContentTypesAddCopyRequestBuilderPostRequestConfiguration)(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.POST
|
||||
requestInfo.Headers.Add("Accept", "application/json")
|
||||
requestInfo.SetContentFromParsable(ctx, m.requestAdapter, "application/json", body)
|
||||
if requestConfiguration != nil {
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
func (m *ItemContentTypesAddCopyRequestBuilder) CreatePostRequestInformation(ctx context.Context, body ItemContentTypesAddCopyPostRequestBodyable, requestConfiguration *ItemContentTypesAddCopyRequestBuilderPostRequestConfiguration) (*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.POST
|
||||
requestInfo.Headers.Add("Accept", "application/json")
|
||||
requestInfo.SetContentFromParsable(ctx, m.requestAdapter, "application/json", body)
|
||||
if requestConfiguration != nil {
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
}
|
||||
|
||||
// Post add a copy of a [content type][contentType] from a [site][site] to a [list][list].
|
||||
// [Find more info here]
|
||||
//
|
||||
//
|
||||
// [Find more info here]: https://docs.microsoft.com/graph/api/contenttype-addcopy?view=graph-rest-1.0
|
||||
func (m *ItemContentTypesAddCopyRequestBuilder) Post(ctx context.Context, body ItemContentTypesAddCopyPostRequestBodyable, requestConfiguration *ItemContentTypesAddCopyRequestBuilderPostRequestConfiguration)(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ContentTypeable, error) {
|
||||
requestInfo, err := m.CreatePostRequestInformation(ctx, body, requestConfiguration);
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings {
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.SendAsync(ctx, requestInfo, ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CreateContentTypeFromDiscriminatorValue, errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ContentTypeable), nil
|
||||
func (m *ItemContentTypesAddCopyRequestBuilder) Post(ctx context.Context, body ItemContentTypesAddCopyPostRequestBodyable, requestConfiguration *ItemContentTypesAddCopyRequestBuilderPostRequestConfiguration) (ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ContentTypeable, error) {
|
||||
requestInfo, err := m.CreatePostRequestInformation(ctx, body, requestConfiguration)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings{
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.Send(ctx, requestInfo, ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CreateContentTypeFromDiscriminatorValue, errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ContentTypeable), nil
|
||||
}
|
||||
|
||||
@ -1,247 +1,273 @@
|
||||
package sites
|
||||
|
||||
import (
|
||||
"context"
|
||||
i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f "github.com/microsoft/kiota-abstractions-go"
|
||||
ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models"
|
||||
i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models/odataerrors"
|
||||
"context"
|
||||
|
||||
ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models"
|
||||
i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models/odataerrors"
|
||||
i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f "github.com/microsoft/kiota-abstractions-go"
|
||||
)
|
||||
|
||||
// ItemContentTypesContentTypeItemRequestBuilder provides operations to manage the contentTypes property of the microsoft.graph.site entity.
|
||||
type ItemContentTypesContentTypeItemRequestBuilder struct {
|
||||
// Path parameters for the request
|
||||
pathParameters map[string]string
|
||||
// The request adapter to use to execute the requests.
|
||||
requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter
|
||||
// Url template to use to build the URL for the current request builder
|
||||
urlTemplate string
|
||||
// Path parameters for the request
|
||||
pathParameters map[string]string
|
||||
// The request adapter to use to execute the requests.
|
||||
requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter
|
||||
// Url template to use to build the URL for the current request builder
|
||||
urlTemplate string
|
||||
}
|
||||
|
||||
// ItemContentTypesContentTypeItemRequestBuilderDeleteRequestConfiguration configuration for the request such as headers, query parameters, and middleware options.
|
||||
type ItemContentTypesContentTypeItemRequestBuilderDeleteRequestConfiguration struct {
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
}
|
||||
|
||||
// ItemContentTypesContentTypeItemRequestBuilderGetQueryParameters the collection of content types defined for this site.
|
||||
type ItemContentTypesContentTypeItemRequestBuilderGetQueryParameters struct {
|
||||
// Expand related entities
|
||||
Expand []string `uriparametername:"%24expand"`
|
||||
// Select properties to be returned
|
||||
Select []string `uriparametername:"%24select"`
|
||||
// Expand related entities
|
||||
Expand []string `uriparametername:"%24expand"`
|
||||
// Select properties to be returned
|
||||
Select []string `uriparametername:"%24select"`
|
||||
}
|
||||
|
||||
// ItemContentTypesContentTypeItemRequestBuilderGetRequestConfiguration configuration for the request such as headers, query parameters, and middleware options.
|
||||
type ItemContentTypesContentTypeItemRequestBuilderGetRequestConfiguration struct {
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
// Request query parameters
|
||||
QueryParameters *ItemContentTypesContentTypeItemRequestBuilderGetQueryParameters
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
// Request query parameters
|
||||
QueryParameters *ItemContentTypesContentTypeItemRequestBuilderGetQueryParameters
|
||||
}
|
||||
|
||||
// ItemContentTypesContentTypeItemRequestBuilderPatchRequestConfiguration configuration for the request such as headers, query parameters, and middleware options.
|
||||
type ItemContentTypesContentTypeItemRequestBuilderPatchRequestConfiguration struct {
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
}
|
||||
|
||||
// AssociateWithHubSites provides operations to call the associateWithHubSites method.
|
||||
func (m *ItemContentTypesContentTypeItemRequestBuilder) AssociateWithHubSites()(*ItemContentTypesItemAssociateWithHubSitesRequestBuilder) {
|
||||
return NewItemContentTypesItemAssociateWithHubSitesRequestBuilderInternal(m.pathParameters, m.requestAdapter);
|
||||
func (m *ItemContentTypesContentTypeItemRequestBuilder) AssociateWithHubSites() *ItemContentTypesItemAssociateWithHubSitesRequestBuilder {
|
||||
return NewItemContentTypesItemAssociateWithHubSitesRequestBuilderInternal(m.pathParameters, m.requestAdapter)
|
||||
}
|
||||
|
||||
// Base provides operations to manage the base property of the microsoft.graph.contentType entity.
|
||||
func (m *ItemContentTypesContentTypeItemRequestBuilder) Base()(*ItemContentTypesItemBaseRequestBuilder) {
|
||||
return NewItemContentTypesItemBaseRequestBuilderInternal(m.pathParameters, m.requestAdapter);
|
||||
func (m *ItemContentTypesContentTypeItemRequestBuilder) Base() *ItemContentTypesItemBaseRequestBuilder {
|
||||
return NewItemContentTypesItemBaseRequestBuilderInternal(m.pathParameters, m.requestAdapter)
|
||||
}
|
||||
|
||||
// BaseTypes provides operations to manage the baseTypes property of the microsoft.graph.contentType entity.
|
||||
func (m *ItemContentTypesContentTypeItemRequestBuilder) BaseTypes()(*ItemContentTypesItemBaseTypesRequestBuilder) {
|
||||
return NewItemContentTypesItemBaseTypesRequestBuilderInternal(m.pathParameters, m.requestAdapter);
|
||||
func (m *ItemContentTypesContentTypeItemRequestBuilder) BaseTypes() *ItemContentTypesItemBaseTypesRequestBuilder {
|
||||
return NewItemContentTypesItemBaseTypesRequestBuilderInternal(m.pathParameters, m.requestAdapter)
|
||||
}
|
||||
|
||||
// BaseTypesById provides operations to manage the baseTypes property of the microsoft.graph.contentType entity.
|
||||
func (m *ItemContentTypesContentTypeItemRequestBuilder) BaseTypesById(id string)(*ItemContentTypesItemBaseTypesContentTypeItemRequestBuilder) {
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range m.pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
if id != "" {
|
||||
urlTplParams["contentType%2Did1"] = id
|
||||
}
|
||||
return NewItemContentTypesItemBaseTypesContentTypeItemRequestBuilderInternal(urlTplParams, m.requestAdapter);
|
||||
func (m *ItemContentTypesContentTypeItemRequestBuilder) BaseTypesById(id string) *ItemContentTypesItemBaseTypesContentTypeItemRequestBuilder {
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range m.pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
if id != "" {
|
||||
urlTplParams["contentType%2Did1"] = id
|
||||
}
|
||||
return NewItemContentTypesItemBaseTypesContentTypeItemRequestBuilderInternal(urlTplParams, m.requestAdapter)
|
||||
}
|
||||
|
||||
// ColumnLinks provides operations to manage the columnLinks property of the microsoft.graph.contentType entity.
|
||||
func (m *ItemContentTypesContentTypeItemRequestBuilder) ColumnLinks()(*ItemContentTypesItemColumnLinksRequestBuilder) {
|
||||
return NewItemContentTypesItemColumnLinksRequestBuilderInternal(m.pathParameters, m.requestAdapter);
|
||||
func (m *ItemContentTypesContentTypeItemRequestBuilder) ColumnLinks() *ItemContentTypesItemColumnLinksRequestBuilder {
|
||||
return NewItemContentTypesItemColumnLinksRequestBuilderInternal(m.pathParameters, m.requestAdapter)
|
||||
}
|
||||
|
||||
// ColumnLinksById provides operations to manage the columnLinks property of the microsoft.graph.contentType entity.
|
||||
func (m *ItemContentTypesContentTypeItemRequestBuilder) ColumnLinksById(id string)(*ItemContentTypesItemColumnLinksColumnLinkItemRequestBuilder) {
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range m.pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
if id != "" {
|
||||
urlTplParams["columnLink%2Did"] = id
|
||||
}
|
||||
return NewItemContentTypesItemColumnLinksColumnLinkItemRequestBuilderInternal(urlTplParams, m.requestAdapter);
|
||||
func (m *ItemContentTypesContentTypeItemRequestBuilder) ColumnLinksById(id string) *ItemContentTypesItemColumnLinksColumnLinkItemRequestBuilder {
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range m.pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
if id != "" {
|
||||
urlTplParams["columnLink%2Did"] = id
|
||||
}
|
||||
return NewItemContentTypesItemColumnLinksColumnLinkItemRequestBuilderInternal(urlTplParams, m.requestAdapter)
|
||||
}
|
||||
|
||||
// ColumnPositions provides operations to manage the columnPositions property of the microsoft.graph.contentType entity.
|
||||
func (m *ItemContentTypesContentTypeItemRequestBuilder) ColumnPositions()(*ItemContentTypesItemColumnPositionsRequestBuilder) {
|
||||
return NewItemContentTypesItemColumnPositionsRequestBuilderInternal(m.pathParameters, m.requestAdapter);
|
||||
func (m *ItemContentTypesContentTypeItemRequestBuilder) ColumnPositions() *ItemContentTypesItemColumnPositionsRequestBuilder {
|
||||
return NewItemContentTypesItemColumnPositionsRequestBuilderInternal(m.pathParameters, m.requestAdapter)
|
||||
}
|
||||
|
||||
// ColumnPositionsById provides operations to manage the columnPositions property of the microsoft.graph.contentType entity.
|
||||
func (m *ItemContentTypesContentTypeItemRequestBuilder) ColumnPositionsById(id string)(*ItemContentTypesItemColumnPositionsColumnDefinitionItemRequestBuilder) {
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range m.pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
if id != "" {
|
||||
urlTplParams["columnDefinition%2Did"] = id
|
||||
}
|
||||
return NewItemContentTypesItemColumnPositionsColumnDefinitionItemRequestBuilderInternal(urlTplParams, m.requestAdapter);
|
||||
func (m *ItemContentTypesContentTypeItemRequestBuilder) ColumnPositionsById(id string) *ItemContentTypesItemColumnPositionsColumnDefinitionItemRequestBuilder {
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range m.pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
if id != "" {
|
||||
urlTplParams["columnDefinition%2Did"] = id
|
||||
}
|
||||
return NewItemContentTypesItemColumnPositionsColumnDefinitionItemRequestBuilderInternal(urlTplParams, m.requestAdapter)
|
||||
}
|
||||
|
||||
// Columns provides operations to manage the columns property of the microsoft.graph.contentType entity.
|
||||
func (m *ItemContentTypesContentTypeItemRequestBuilder) Columns()(*ItemContentTypesItemColumnsRequestBuilder) {
|
||||
return NewItemContentTypesItemColumnsRequestBuilderInternal(m.pathParameters, m.requestAdapter);
|
||||
func (m *ItemContentTypesContentTypeItemRequestBuilder) Columns() *ItemContentTypesItemColumnsRequestBuilder {
|
||||
return NewItemContentTypesItemColumnsRequestBuilderInternal(m.pathParameters, m.requestAdapter)
|
||||
}
|
||||
|
||||
// ColumnsById provides operations to manage the columns property of the microsoft.graph.contentType entity.
|
||||
func (m *ItemContentTypesContentTypeItemRequestBuilder) ColumnsById(id string)(*ItemContentTypesItemColumnsColumnDefinitionItemRequestBuilder) {
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range m.pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
if id != "" {
|
||||
urlTplParams["columnDefinition%2Did"] = id
|
||||
}
|
||||
return NewItemContentTypesItemColumnsColumnDefinitionItemRequestBuilderInternal(urlTplParams, m.requestAdapter);
|
||||
func (m *ItemContentTypesContentTypeItemRequestBuilder) ColumnsById(id string) *ItemContentTypesItemColumnsColumnDefinitionItemRequestBuilder {
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range m.pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
if id != "" {
|
||||
urlTplParams["columnDefinition%2Did"] = id
|
||||
}
|
||||
return NewItemContentTypesItemColumnsColumnDefinitionItemRequestBuilderInternal(urlTplParams, m.requestAdapter)
|
||||
}
|
||||
|
||||
// NewItemContentTypesContentTypeItemRequestBuilderInternal instantiates a new ContentTypeItemRequestBuilder and sets the default values.
|
||||
func NewItemContentTypesContentTypeItemRequestBuilderInternal(pathParameters map[string]string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemContentTypesContentTypeItemRequestBuilder) {
|
||||
m := &ItemContentTypesContentTypeItemRequestBuilder{
|
||||
}
|
||||
m.urlTemplate = "{+baseurl}/sites/{site%2Did}/contentTypes/{contentType%2Did}{?%24select,%24expand}";
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
m.pathParameters = urlTplParams;
|
||||
m.requestAdapter = requestAdapter;
|
||||
return m
|
||||
func NewItemContentTypesContentTypeItemRequestBuilderInternal(pathParameters map[string]string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter) *ItemContentTypesContentTypeItemRequestBuilder {
|
||||
m := &ItemContentTypesContentTypeItemRequestBuilder{}
|
||||
m.urlTemplate = "{+baseurl}/sites/{site%2Did}/contentTypes/{contentType%2Did}{?%24select,%24expand}"
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
m.pathParameters = urlTplParams
|
||||
m.requestAdapter = requestAdapter
|
||||
return m
|
||||
}
|
||||
|
||||
// NewItemContentTypesContentTypeItemRequestBuilder instantiates a new ContentTypeItemRequestBuilder and sets the default values.
|
||||
func NewItemContentTypesContentTypeItemRequestBuilder(rawUrl string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemContentTypesContentTypeItemRequestBuilder) {
|
||||
urlParams := make(map[string]string)
|
||||
urlParams["request-raw-url"] = rawUrl
|
||||
return NewItemContentTypesContentTypeItemRequestBuilderInternal(urlParams, requestAdapter)
|
||||
func NewItemContentTypesContentTypeItemRequestBuilder(rawUrl string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter) *ItemContentTypesContentTypeItemRequestBuilder {
|
||||
urlParams := make(map[string]string)
|
||||
urlParams["request-raw-url"] = rawUrl
|
||||
return NewItemContentTypesContentTypeItemRequestBuilderInternal(urlParams, requestAdapter)
|
||||
}
|
||||
|
||||
// CopyToDefaultContentLocation provides operations to call the copyToDefaultContentLocation method.
|
||||
func (m *ItemContentTypesContentTypeItemRequestBuilder) CopyToDefaultContentLocation()(*ItemContentTypesItemCopyToDefaultContentLocationRequestBuilder) {
|
||||
return NewItemContentTypesItemCopyToDefaultContentLocationRequestBuilderInternal(m.pathParameters, m.requestAdapter);
|
||||
func (m *ItemContentTypesContentTypeItemRequestBuilder) CopyToDefaultContentLocation() *ItemContentTypesItemCopyToDefaultContentLocationRequestBuilder {
|
||||
return NewItemContentTypesItemCopyToDefaultContentLocationRequestBuilderInternal(m.pathParameters, m.requestAdapter)
|
||||
}
|
||||
|
||||
// CreateDeleteRequestInformation delete navigation property contentTypes for sites
|
||||
func (m *ItemContentTypesContentTypeItemRequestBuilder) CreateDeleteRequestInformation(ctx context.Context, requestConfiguration *ItemContentTypesContentTypeItemRequestBuilderDeleteRequestConfiguration)(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.DELETE
|
||||
if requestConfiguration != nil {
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
func (m *ItemContentTypesContentTypeItemRequestBuilder) CreateDeleteRequestInformation(ctx context.Context, requestConfiguration *ItemContentTypesContentTypeItemRequestBuilderDeleteRequestConfiguration) (*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.DELETE
|
||||
if requestConfiguration != nil {
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
}
|
||||
|
||||
// CreateGetRequestInformation the collection of content types defined for this site.
|
||||
func (m *ItemContentTypesContentTypeItemRequestBuilder) CreateGetRequestInformation(ctx context.Context, requestConfiguration *ItemContentTypesContentTypeItemRequestBuilderGetRequestConfiguration)(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.GET
|
||||
requestInfo.Headers.Add("Accept", "application/json")
|
||||
if requestConfiguration != nil {
|
||||
if requestConfiguration.QueryParameters != nil {
|
||||
requestInfo.AddQueryParameters(*(requestConfiguration.QueryParameters))
|
||||
}
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
func (m *ItemContentTypesContentTypeItemRequestBuilder) CreateGetRequestInformation(ctx context.Context, requestConfiguration *ItemContentTypesContentTypeItemRequestBuilderGetRequestConfiguration) (*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.GET
|
||||
requestInfo.Headers.Add("Accept", "application/json")
|
||||
if requestConfiguration != nil {
|
||||
if requestConfiguration.QueryParameters != nil {
|
||||
requestInfo.AddQueryParameters(*(requestConfiguration.QueryParameters))
|
||||
}
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
}
|
||||
|
||||
// CreatePatchRequestInformation update the navigation property contentTypes in sites
|
||||
func (m *ItemContentTypesContentTypeItemRequestBuilder) CreatePatchRequestInformation(ctx context.Context, body ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ContentTypeable, requestConfiguration *ItemContentTypesContentTypeItemRequestBuilderPatchRequestConfiguration)(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.PATCH
|
||||
requestInfo.Headers.Add("Accept", "application/json")
|
||||
requestInfo.SetContentFromParsable(ctx, m.requestAdapter, "application/json", body)
|
||||
if requestConfiguration != nil {
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
func (m *ItemContentTypesContentTypeItemRequestBuilder) CreatePatchRequestInformation(ctx context.Context, body ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ContentTypeable, requestConfiguration *ItemContentTypesContentTypeItemRequestBuilderPatchRequestConfiguration) (*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.PATCH
|
||||
requestInfo.Headers.Add("Accept", "application/json")
|
||||
requestInfo.SetContentFromParsable(ctx, m.requestAdapter, "application/json", body)
|
||||
if requestConfiguration != nil {
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
}
|
||||
|
||||
// Delete delete navigation property contentTypes for sites
|
||||
func (m *ItemContentTypesContentTypeItemRequestBuilder) Delete(ctx context.Context, requestConfiguration *ItemContentTypesContentTypeItemRequestBuilderDeleteRequestConfiguration)(error) {
|
||||
requestInfo, err := m.CreateDeleteRequestInformation(ctx, requestConfiguration);
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings {
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
err = m.requestAdapter.SendNoContentAsync(ctx, requestInfo, errorMapping)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
return nil
|
||||
func (m *ItemContentTypesContentTypeItemRequestBuilder) Delete(ctx context.Context, requestConfiguration *ItemContentTypesContentTypeItemRequestBuilderDeleteRequestConfiguration) error {
|
||||
requestInfo, err := m.CreateDeleteRequestInformation(ctx, requestConfiguration)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings{
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
err = m.requestAdapter.SendNoContent(ctx, requestInfo, errorMapping)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
// Get the collection of content types defined for this site.
|
||||
func (m *ItemContentTypesContentTypeItemRequestBuilder) Get(ctx context.Context, requestConfiguration *ItemContentTypesContentTypeItemRequestBuilderGetRequestConfiguration)(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ContentTypeable, error) {
|
||||
requestInfo, err := m.CreateGetRequestInformation(ctx, requestConfiguration);
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings {
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.SendAsync(ctx, requestInfo, ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CreateContentTypeFromDiscriminatorValue, errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ContentTypeable), nil
|
||||
func (m *ItemContentTypesContentTypeItemRequestBuilder) Get(ctx context.Context, requestConfiguration *ItemContentTypesContentTypeItemRequestBuilderGetRequestConfiguration) (ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ContentTypeable, error) {
|
||||
requestInfo, err := m.CreateGetRequestInformation(ctx, requestConfiguration)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings{
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.Send(ctx, requestInfo, ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CreateContentTypeFromDiscriminatorValue, errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ContentTypeable), nil
|
||||
}
|
||||
|
||||
// IsPublished provides operations to call the isPublished method.
|
||||
func (m *ItemContentTypesContentTypeItemRequestBuilder) IsPublished()(*ItemContentTypesItemIsPublishedRequestBuilder) {
|
||||
return NewItemContentTypesItemIsPublishedRequestBuilderInternal(m.pathParameters, m.requestAdapter);
|
||||
func (m *ItemContentTypesContentTypeItemRequestBuilder) IsPublished() *ItemContentTypesItemIsPublishedRequestBuilder {
|
||||
return NewItemContentTypesItemIsPublishedRequestBuilderInternal(m.pathParameters, m.requestAdapter)
|
||||
}
|
||||
|
||||
// Patch update the navigation property contentTypes in sites
|
||||
func (m *ItemContentTypesContentTypeItemRequestBuilder) Patch(ctx context.Context, body ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ContentTypeable, requestConfiguration *ItemContentTypesContentTypeItemRequestBuilderPatchRequestConfiguration)(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ContentTypeable, error) {
|
||||
requestInfo, err := m.CreatePatchRequestInformation(ctx, body, requestConfiguration);
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings {
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.SendAsync(ctx, requestInfo, ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CreateContentTypeFromDiscriminatorValue, errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ContentTypeable), nil
|
||||
func (m *ItemContentTypesContentTypeItemRequestBuilder) Patch(ctx context.Context, body ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ContentTypeable, requestConfiguration *ItemContentTypesContentTypeItemRequestBuilderPatchRequestConfiguration) (ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ContentTypeable, error) {
|
||||
requestInfo, err := m.CreatePatchRequestInformation(ctx, body, requestConfiguration)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings{
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.Send(ctx, requestInfo, ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CreateContentTypeFromDiscriminatorValue, errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ContentTypeable), nil
|
||||
}
|
||||
|
||||
// Publish provides operations to call the publish method.
|
||||
func (m *ItemContentTypesContentTypeItemRequestBuilder) Publish()(*ItemContentTypesItemPublishRequestBuilder) {
|
||||
return NewItemContentTypesItemPublishRequestBuilderInternal(m.pathParameters, m.requestAdapter);
|
||||
func (m *ItemContentTypesContentTypeItemRequestBuilder) Publish() *ItemContentTypesItemPublishRequestBuilder {
|
||||
return NewItemContentTypesItemPublishRequestBuilderInternal(m.pathParameters, m.requestAdapter)
|
||||
}
|
||||
|
||||
// Unpublish provides operations to call the unpublish method.
|
||||
func (m *ItemContentTypesContentTypeItemRequestBuilder) Unpublish()(*ItemContentTypesItemUnpublishRequestBuilder) {
|
||||
return NewItemContentTypesItemUnpublishRequestBuilderInternal(m.pathParameters, m.requestAdapter);
|
||||
func (m *ItemContentTypesContentTypeItemRequestBuilder) Unpublish() *ItemContentTypesItemUnpublishRequestBuilder {
|
||||
return NewItemContentTypesItemUnpublishRequestBuilderInternal(m.pathParameters, m.requestAdapter)
|
||||
}
|
||||
|
||||
@ -1,87 +1,93 @@
|
||||
package sites
|
||||
|
||||
import (
|
||||
"context"
|
||||
i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f "github.com/microsoft/kiota-abstractions-go"
|
||||
i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models/odataerrors"
|
||||
"context"
|
||||
|
||||
i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models/odataerrors"
|
||||
i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f "github.com/microsoft/kiota-abstractions-go"
|
||||
)
|
||||
|
||||
// ItemContentTypesCountRequestBuilder provides operations to count the resources in the collection.
|
||||
type ItemContentTypesCountRequestBuilder struct {
|
||||
// Path parameters for the request
|
||||
pathParameters map[string]string
|
||||
// The request adapter to use to execute the requests.
|
||||
requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter
|
||||
// Url template to use to build the URL for the current request builder
|
||||
urlTemplate string
|
||||
// Path parameters for the request
|
||||
pathParameters map[string]string
|
||||
// The request adapter to use to execute the requests.
|
||||
requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter
|
||||
// Url template to use to build the URL for the current request builder
|
||||
urlTemplate string
|
||||
}
|
||||
|
||||
// ItemContentTypesCountRequestBuilderGetQueryParameters get the number of the resource
|
||||
type ItemContentTypesCountRequestBuilderGetQueryParameters struct {
|
||||
// Filter items by property values
|
||||
Filter *string `uriparametername:"%24filter"`
|
||||
// Search items by search phrases
|
||||
Search *string `uriparametername:"%24search"`
|
||||
// Filter items by property values
|
||||
Filter *string `uriparametername:"%24filter"`
|
||||
// Search items by search phrases
|
||||
Search *string `uriparametername:"%24search"`
|
||||
}
|
||||
|
||||
// ItemContentTypesCountRequestBuilderGetRequestConfiguration configuration for the request such as headers, query parameters, and middleware options.
|
||||
type ItemContentTypesCountRequestBuilderGetRequestConfiguration struct {
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
// Request query parameters
|
||||
QueryParameters *ItemContentTypesCountRequestBuilderGetQueryParameters
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
// Request query parameters
|
||||
QueryParameters *ItemContentTypesCountRequestBuilderGetQueryParameters
|
||||
}
|
||||
|
||||
// NewItemContentTypesCountRequestBuilderInternal instantiates a new CountRequestBuilder and sets the default values.
|
||||
func NewItemContentTypesCountRequestBuilderInternal(pathParameters map[string]string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemContentTypesCountRequestBuilder) {
|
||||
m := &ItemContentTypesCountRequestBuilder{
|
||||
}
|
||||
m.urlTemplate = "{+baseurl}/sites/{site%2Did}/contentTypes/$count{?%24search,%24filter}";
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
m.pathParameters = urlTplParams;
|
||||
m.requestAdapter = requestAdapter;
|
||||
return m
|
||||
func NewItemContentTypesCountRequestBuilderInternal(pathParameters map[string]string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter) *ItemContentTypesCountRequestBuilder {
|
||||
m := &ItemContentTypesCountRequestBuilder{}
|
||||
m.urlTemplate = "{+baseurl}/sites/{site%2Did}/contentTypes/$count{?%24search,%24filter}"
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
m.pathParameters = urlTplParams
|
||||
m.requestAdapter = requestAdapter
|
||||
return m
|
||||
}
|
||||
|
||||
// NewItemContentTypesCountRequestBuilder instantiates a new CountRequestBuilder and sets the default values.
|
||||
func NewItemContentTypesCountRequestBuilder(rawUrl string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemContentTypesCountRequestBuilder) {
|
||||
urlParams := make(map[string]string)
|
||||
urlParams["request-raw-url"] = rawUrl
|
||||
return NewItemContentTypesCountRequestBuilderInternal(urlParams, requestAdapter)
|
||||
func NewItemContentTypesCountRequestBuilder(rawUrl string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter) *ItemContentTypesCountRequestBuilder {
|
||||
urlParams := make(map[string]string)
|
||||
urlParams["request-raw-url"] = rawUrl
|
||||
return NewItemContentTypesCountRequestBuilderInternal(urlParams, requestAdapter)
|
||||
}
|
||||
|
||||
// CreateGetRequestInformation get the number of the resource
|
||||
func (m *ItemContentTypesCountRequestBuilder) CreateGetRequestInformation(ctx context.Context, requestConfiguration *ItemContentTypesCountRequestBuilderGetRequestConfiguration)(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.GET
|
||||
requestInfo.Headers.Add("Accept", "text/plain")
|
||||
if requestConfiguration != nil {
|
||||
if requestConfiguration.QueryParameters != nil {
|
||||
requestInfo.AddQueryParameters(*(requestConfiguration.QueryParameters))
|
||||
}
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
func (m *ItemContentTypesCountRequestBuilder) CreateGetRequestInformation(ctx context.Context, requestConfiguration *ItemContentTypesCountRequestBuilderGetRequestConfiguration) (*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.GET
|
||||
requestInfo.Headers.Add("Accept", "text/plain")
|
||||
if requestConfiguration != nil {
|
||||
if requestConfiguration.QueryParameters != nil {
|
||||
requestInfo.AddQueryParameters(*(requestConfiguration.QueryParameters))
|
||||
}
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
}
|
||||
|
||||
// Get get the number of the resource
|
||||
func (m *ItemContentTypesCountRequestBuilder) Get(ctx context.Context, requestConfiguration *ItemContentTypesCountRequestBuilderGetRequestConfiguration)(*int32, error) {
|
||||
requestInfo, err := m.CreateGetRequestInformation(ctx, requestConfiguration);
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings {
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.SendPrimitiveAsync(ctx, requestInfo, "int32", errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(*int32), nil
|
||||
func (m *ItemContentTypesCountRequestBuilder) Get(ctx context.Context, requestConfiguration *ItemContentTypesCountRequestBuilderGetRequestConfiguration) (*int32, error) {
|
||||
requestInfo, err := m.CreateGetRequestInformation(ctx, requestConfiguration)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings{
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.SendPrimitive(ctx, requestInfo, "int32", errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(*int32), nil
|
||||
}
|
||||
|
||||
@ -1,97 +1,103 @@
|
||||
package sites
|
||||
|
||||
import (
|
||||
"context"
|
||||
i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f "github.com/microsoft/kiota-abstractions-go"
|
||||
i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models/odataerrors"
|
||||
"context"
|
||||
|
||||
i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models/odataerrors"
|
||||
i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f "github.com/microsoft/kiota-abstractions-go"
|
||||
)
|
||||
|
||||
// ItemContentTypesGetCompatibleHubContentTypesRequestBuilder provides operations to call the getCompatibleHubContentTypes method.
|
||||
type ItemContentTypesGetCompatibleHubContentTypesRequestBuilder struct {
|
||||
// Path parameters for the request
|
||||
pathParameters map[string]string
|
||||
// The request adapter to use to execute the requests.
|
||||
requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter
|
||||
// Url template to use to build the URL for the current request builder
|
||||
urlTemplate string
|
||||
// Path parameters for the request
|
||||
pathParameters map[string]string
|
||||
// The request adapter to use to execute the requests.
|
||||
requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter
|
||||
// Url template to use to build the URL for the current request builder
|
||||
urlTemplate string
|
||||
}
|
||||
|
||||
// ItemContentTypesGetCompatibleHubContentTypesRequestBuilderGetQueryParameters invoke function getCompatibleHubContentTypes
|
||||
type ItemContentTypesGetCompatibleHubContentTypesRequestBuilderGetQueryParameters struct {
|
||||
// Include count of items
|
||||
Count *bool `uriparametername:"%24count"`
|
||||
// Filter items by property values
|
||||
Filter *string `uriparametername:"%24filter"`
|
||||
// Order items by property values
|
||||
Orderby []string `uriparametername:"%24orderby"`
|
||||
// Search items by search phrases
|
||||
Search *string `uriparametername:"%24search"`
|
||||
// Select properties to be returned
|
||||
Select []string `uriparametername:"%24select"`
|
||||
// Skip the first n items
|
||||
Skip *int32 `uriparametername:"%24skip"`
|
||||
// Show only the first n items
|
||||
Top *int32 `uriparametername:"%24top"`
|
||||
// Include count of items
|
||||
Count *bool `uriparametername:"%24count"`
|
||||
// Filter items by property values
|
||||
Filter *string `uriparametername:"%24filter"`
|
||||
// Order items by property values
|
||||
Orderby []string `uriparametername:"%24orderby"`
|
||||
// Search items by search phrases
|
||||
Search *string `uriparametername:"%24search"`
|
||||
// Select properties to be returned
|
||||
Select []string `uriparametername:"%24select"`
|
||||
// Skip the first n items
|
||||
Skip *int32 `uriparametername:"%24skip"`
|
||||
// Show only the first n items
|
||||
Top *int32 `uriparametername:"%24top"`
|
||||
}
|
||||
|
||||
// ItemContentTypesGetCompatibleHubContentTypesRequestBuilderGetRequestConfiguration configuration for the request such as headers, query parameters, and middleware options.
|
||||
type ItemContentTypesGetCompatibleHubContentTypesRequestBuilderGetRequestConfiguration struct {
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
// Request query parameters
|
||||
QueryParameters *ItemContentTypesGetCompatibleHubContentTypesRequestBuilderGetQueryParameters
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
// Request query parameters
|
||||
QueryParameters *ItemContentTypesGetCompatibleHubContentTypesRequestBuilderGetQueryParameters
|
||||
}
|
||||
|
||||
// NewItemContentTypesGetCompatibleHubContentTypesRequestBuilderInternal instantiates a new GetCompatibleHubContentTypesRequestBuilder and sets the default values.
|
||||
func NewItemContentTypesGetCompatibleHubContentTypesRequestBuilderInternal(pathParameters map[string]string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemContentTypesGetCompatibleHubContentTypesRequestBuilder) {
|
||||
m := &ItemContentTypesGetCompatibleHubContentTypesRequestBuilder{
|
||||
}
|
||||
m.urlTemplate = "{+baseurl}/sites/{site%2Did}/contentTypes/microsoft.graph.getCompatibleHubContentTypes(){?%24top,%24skip,%24search,%24filter,%24count,%24select,%24orderby}";
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
m.pathParameters = urlTplParams;
|
||||
m.requestAdapter = requestAdapter;
|
||||
return m
|
||||
func NewItemContentTypesGetCompatibleHubContentTypesRequestBuilderInternal(pathParameters map[string]string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter) *ItemContentTypesGetCompatibleHubContentTypesRequestBuilder {
|
||||
m := &ItemContentTypesGetCompatibleHubContentTypesRequestBuilder{}
|
||||
m.urlTemplate = "{+baseurl}/sites/{site%2Did}/contentTypes/microsoft.graph.getCompatibleHubContentTypes(){?%24top,%24skip,%24search,%24filter,%24count,%24select,%24orderby}"
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
m.pathParameters = urlTplParams
|
||||
m.requestAdapter = requestAdapter
|
||||
return m
|
||||
}
|
||||
|
||||
// NewItemContentTypesGetCompatibleHubContentTypesRequestBuilder instantiates a new GetCompatibleHubContentTypesRequestBuilder and sets the default values.
|
||||
func NewItemContentTypesGetCompatibleHubContentTypesRequestBuilder(rawUrl string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemContentTypesGetCompatibleHubContentTypesRequestBuilder) {
|
||||
urlParams := make(map[string]string)
|
||||
urlParams["request-raw-url"] = rawUrl
|
||||
return NewItemContentTypesGetCompatibleHubContentTypesRequestBuilderInternal(urlParams, requestAdapter)
|
||||
func NewItemContentTypesGetCompatibleHubContentTypesRequestBuilder(rawUrl string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter) *ItemContentTypesGetCompatibleHubContentTypesRequestBuilder {
|
||||
urlParams := make(map[string]string)
|
||||
urlParams["request-raw-url"] = rawUrl
|
||||
return NewItemContentTypesGetCompatibleHubContentTypesRequestBuilderInternal(urlParams, requestAdapter)
|
||||
}
|
||||
|
||||
// CreateGetRequestInformation invoke function getCompatibleHubContentTypes
|
||||
func (m *ItemContentTypesGetCompatibleHubContentTypesRequestBuilder) CreateGetRequestInformation(ctx context.Context, requestConfiguration *ItemContentTypesGetCompatibleHubContentTypesRequestBuilderGetRequestConfiguration)(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.GET
|
||||
requestInfo.Headers.Add("Accept", "application/json")
|
||||
if requestConfiguration != nil {
|
||||
if requestConfiguration.QueryParameters != nil {
|
||||
requestInfo.AddQueryParameters(*(requestConfiguration.QueryParameters))
|
||||
}
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
func (m *ItemContentTypesGetCompatibleHubContentTypesRequestBuilder) CreateGetRequestInformation(ctx context.Context, requestConfiguration *ItemContentTypesGetCompatibleHubContentTypesRequestBuilderGetRequestConfiguration) (*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.GET
|
||||
requestInfo.Headers.Add("Accept", "application/json")
|
||||
if requestConfiguration != nil {
|
||||
if requestConfiguration.QueryParameters != nil {
|
||||
requestInfo.AddQueryParameters(*(requestConfiguration.QueryParameters))
|
||||
}
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
}
|
||||
|
||||
// Get invoke function getCompatibleHubContentTypes
|
||||
func (m *ItemContentTypesGetCompatibleHubContentTypesRequestBuilder) Get(ctx context.Context, requestConfiguration *ItemContentTypesGetCompatibleHubContentTypesRequestBuilderGetRequestConfiguration)(ItemContentTypesGetCompatibleHubContentTypesResponseable, error) {
|
||||
requestInfo, err := m.CreateGetRequestInformation(ctx, requestConfiguration);
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings {
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.SendAsync(ctx, requestInfo, CreateItemContentTypesGetCompatibleHubContentTypesResponseFromDiscriminatorValue, errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(ItemContentTypesGetCompatibleHubContentTypesResponseable), nil
|
||||
func (m *ItemContentTypesGetCompatibleHubContentTypesRequestBuilder) Get(ctx context.Context, requestConfiguration *ItemContentTypesGetCompatibleHubContentTypesRequestBuilderGetRequestConfiguration) (ItemContentTypesGetCompatibleHubContentTypesResponseable, error) {
|
||||
requestInfo, err := m.CreateGetRequestInformation(ctx, requestConfiguration)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings{
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.Send(ctx, requestInfo, CreateItemContentTypesGetCompatibleHubContentTypesResponseFromDiscriminatorValue, errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(ItemContentTypesGetCompatibleHubContentTypesResponseable), nil
|
||||
}
|
||||
|
||||
@ -1,75 +1,80 @@
|
||||
package sites
|
||||
|
||||
import (
|
||||
"context"
|
||||
i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f "github.com/microsoft/kiota-abstractions-go"
|
||||
i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models/odataerrors"
|
||||
"context"
|
||||
|
||||
i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models/odataerrors"
|
||||
i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f "github.com/microsoft/kiota-abstractions-go"
|
||||
)
|
||||
|
||||
// ItemContentTypesItemAssociateWithHubSitesRequestBuilder provides operations to call the associateWithHubSites method.
|
||||
type ItemContentTypesItemAssociateWithHubSitesRequestBuilder struct {
|
||||
// Path parameters for the request
|
||||
pathParameters map[string]string
|
||||
// The request adapter to use to execute the requests.
|
||||
requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter
|
||||
// Url template to use to build the URL for the current request builder
|
||||
urlTemplate string
|
||||
// Path parameters for the request
|
||||
pathParameters map[string]string
|
||||
// The request adapter to use to execute the requests.
|
||||
requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter
|
||||
// Url template to use to build the URL for the current request builder
|
||||
urlTemplate string
|
||||
}
|
||||
|
||||
// ItemContentTypesItemAssociateWithHubSitesRequestBuilderPostRequestConfiguration configuration for the request such as headers, query parameters, and middleware options.
|
||||
type ItemContentTypesItemAssociateWithHubSitesRequestBuilderPostRequestConfiguration struct {
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
}
|
||||
|
||||
// NewItemContentTypesItemAssociateWithHubSitesRequestBuilderInternal instantiates a new AssociateWithHubSitesRequestBuilder and sets the default values.
|
||||
func NewItemContentTypesItemAssociateWithHubSitesRequestBuilderInternal(pathParameters map[string]string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemContentTypesItemAssociateWithHubSitesRequestBuilder) {
|
||||
m := &ItemContentTypesItemAssociateWithHubSitesRequestBuilder{
|
||||
}
|
||||
m.urlTemplate = "{+baseurl}/sites/{site%2Did}/contentTypes/{contentType%2Did}/microsoft.graph.associateWithHubSites";
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
m.pathParameters = urlTplParams;
|
||||
m.requestAdapter = requestAdapter;
|
||||
return m
|
||||
func NewItemContentTypesItemAssociateWithHubSitesRequestBuilderInternal(pathParameters map[string]string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter) *ItemContentTypesItemAssociateWithHubSitesRequestBuilder {
|
||||
m := &ItemContentTypesItemAssociateWithHubSitesRequestBuilder{}
|
||||
m.urlTemplate = "{+baseurl}/sites/{site%2Did}/contentTypes/{contentType%2Did}/microsoft.graph.associateWithHubSites"
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
m.pathParameters = urlTplParams
|
||||
m.requestAdapter = requestAdapter
|
||||
return m
|
||||
}
|
||||
|
||||
// NewItemContentTypesItemAssociateWithHubSitesRequestBuilder instantiates a new AssociateWithHubSitesRequestBuilder and sets the default values.
|
||||
func NewItemContentTypesItemAssociateWithHubSitesRequestBuilder(rawUrl string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemContentTypesItemAssociateWithHubSitesRequestBuilder) {
|
||||
urlParams := make(map[string]string)
|
||||
urlParams["request-raw-url"] = rawUrl
|
||||
return NewItemContentTypesItemAssociateWithHubSitesRequestBuilderInternal(urlParams, requestAdapter)
|
||||
func NewItemContentTypesItemAssociateWithHubSitesRequestBuilder(rawUrl string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter) *ItemContentTypesItemAssociateWithHubSitesRequestBuilder {
|
||||
urlParams := make(map[string]string)
|
||||
urlParams["request-raw-url"] = rawUrl
|
||||
return NewItemContentTypesItemAssociateWithHubSitesRequestBuilderInternal(urlParams, requestAdapter)
|
||||
}
|
||||
|
||||
// CreatePostRequestInformation associate a [content type][contentType] with a list of hub sites.
|
||||
func (m *ItemContentTypesItemAssociateWithHubSitesRequestBuilder) CreatePostRequestInformation(ctx context.Context, body ItemContentTypesItemAssociateWithHubSitesPostRequestBodyable, requestConfiguration *ItemContentTypesItemAssociateWithHubSitesRequestBuilderPostRequestConfiguration)(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.POST
|
||||
requestInfo.SetContentFromParsable(ctx, m.requestAdapter, "application/json", body)
|
||||
if requestConfiguration != nil {
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
func (m *ItemContentTypesItemAssociateWithHubSitesRequestBuilder) CreatePostRequestInformation(ctx context.Context, body ItemContentTypesItemAssociateWithHubSitesPostRequestBodyable, requestConfiguration *ItemContentTypesItemAssociateWithHubSitesRequestBuilderPostRequestConfiguration) (*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.POST
|
||||
requestInfo.SetContentFromParsable(ctx, m.requestAdapter, "application/json", body)
|
||||
if requestConfiguration != nil {
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
}
|
||||
|
||||
// Post associate a [content type][contentType] with a list of hub sites.
|
||||
// [Find more info here]
|
||||
//
|
||||
//
|
||||
// [Find more info here]: https://docs.microsoft.com/graph/api/contenttype-associatewithhubsites?view=graph-rest-1.0
|
||||
func (m *ItemContentTypesItemAssociateWithHubSitesRequestBuilder) Post(ctx context.Context, body ItemContentTypesItemAssociateWithHubSitesPostRequestBodyable, requestConfiguration *ItemContentTypesItemAssociateWithHubSitesRequestBuilderPostRequestConfiguration)(error) {
|
||||
requestInfo, err := m.CreatePostRequestInformation(ctx, body, requestConfiguration);
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings {
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
err = m.requestAdapter.SendNoContentAsync(ctx, requestInfo, errorMapping)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
return nil
|
||||
func (m *ItemContentTypesItemAssociateWithHubSitesRequestBuilder) Post(ctx context.Context, body ItemContentTypesItemAssociateWithHubSitesPostRequestBodyable, requestConfiguration *ItemContentTypesItemAssociateWithHubSitesRequestBuilderPostRequestConfiguration) error {
|
||||
requestInfo, err := m.CreatePostRequestInformation(ctx, body, requestConfiguration)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings{
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
err = m.requestAdapter.SendNoContent(ctx, requestInfo, errorMapping)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
@ -1,88 +1,94 @@
|
||||
package sites
|
||||
|
||||
import (
|
||||
"context"
|
||||
i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f "github.com/microsoft/kiota-abstractions-go"
|
||||
ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models"
|
||||
i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models/odataerrors"
|
||||
"context"
|
||||
|
||||
ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models"
|
||||
i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models/odataerrors"
|
||||
i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f "github.com/microsoft/kiota-abstractions-go"
|
||||
)
|
||||
|
||||
// ItemContentTypesItemBaseRequestBuilder provides operations to manage the base property of the microsoft.graph.contentType entity.
|
||||
type ItemContentTypesItemBaseRequestBuilder struct {
|
||||
// Path parameters for the request
|
||||
pathParameters map[string]string
|
||||
// The request adapter to use to execute the requests.
|
||||
requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter
|
||||
// Url template to use to build the URL for the current request builder
|
||||
urlTemplate string
|
||||
// Path parameters for the request
|
||||
pathParameters map[string]string
|
||||
// The request adapter to use to execute the requests.
|
||||
requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter
|
||||
// Url template to use to build the URL for the current request builder
|
||||
urlTemplate string
|
||||
}
|
||||
|
||||
// ItemContentTypesItemBaseRequestBuilderGetQueryParameters parent contentType from which this content type is derived.
|
||||
type ItemContentTypesItemBaseRequestBuilderGetQueryParameters struct {
|
||||
// Expand related entities
|
||||
Expand []string `uriparametername:"%24expand"`
|
||||
// Select properties to be returned
|
||||
Select []string `uriparametername:"%24select"`
|
||||
// Expand related entities
|
||||
Expand []string `uriparametername:"%24expand"`
|
||||
// Select properties to be returned
|
||||
Select []string `uriparametername:"%24select"`
|
||||
}
|
||||
|
||||
// ItemContentTypesItemBaseRequestBuilderGetRequestConfiguration configuration for the request such as headers, query parameters, and middleware options.
|
||||
type ItemContentTypesItemBaseRequestBuilderGetRequestConfiguration struct {
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
// Request query parameters
|
||||
QueryParameters *ItemContentTypesItemBaseRequestBuilderGetQueryParameters
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
// Request query parameters
|
||||
QueryParameters *ItemContentTypesItemBaseRequestBuilderGetQueryParameters
|
||||
}
|
||||
|
||||
// NewItemContentTypesItemBaseRequestBuilderInternal instantiates a new BaseRequestBuilder and sets the default values.
|
||||
func NewItemContentTypesItemBaseRequestBuilderInternal(pathParameters map[string]string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemContentTypesItemBaseRequestBuilder) {
|
||||
m := &ItemContentTypesItemBaseRequestBuilder{
|
||||
}
|
||||
m.urlTemplate = "{+baseurl}/sites/{site%2Did}/contentTypes/{contentType%2Did}/base{?%24select,%24expand}";
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
m.pathParameters = urlTplParams;
|
||||
m.requestAdapter = requestAdapter;
|
||||
return m
|
||||
func NewItemContentTypesItemBaseRequestBuilderInternal(pathParameters map[string]string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter) *ItemContentTypesItemBaseRequestBuilder {
|
||||
m := &ItemContentTypesItemBaseRequestBuilder{}
|
||||
m.urlTemplate = "{+baseurl}/sites/{site%2Did}/contentTypes/{contentType%2Did}/base{?%24select,%24expand}"
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
m.pathParameters = urlTplParams
|
||||
m.requestAdapter = requestAdapter
|
||||
return m
|
||||
}
|
||||
|
||||
// NewItemContentTypesItemBaseRequestBuilder instantiates a new BaseRequestBuilder and sets the default values.
|
||||
func NewItemContentTypesItemBaseRequestBuilder(rawUrl string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemContentTypesItemBaseRequestBuilder) {
|
||||
urlParams := make(map[string]string)
|
||||
urlParams["request-raw-url"] = rawUrl
|
||||
return NewItemContentTypesItemBaseRequestBuilderInternal(urlParams, requestAdapter)
|
||||
func NewItemContentTypesItemBaseRequestBuilder(rawUrl string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter) *ItemContentTypesItemBaseRequestBuilder {
|
||||
urlParams := make(map[string]string)
|
||||
urlParams["request-raw-url"] = rawUrl
|
||||
return NewItemContentTypesItemBaseRequestBuilderInternal(urlParams, requestAdapter)
|
||||
}
|
||||
|
||||
// CreateGetRequestInformation parent contentType from which this content type is derived.
|
||||
func (m *ItemContentTypesItemBaseRequestBuilder) CreateGetRequestInformation(ctx context.Context, requestConfiguration *ItemContentTypesItemBaseRequestBuilderGetRequestConfiguration)(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.GET
|
||||
requestInfo.Headers.Add("Accept", "application/json")
|
||||
if requestConfiguration != nil {
|
||||
if requestConfiguration.QueryParameters != nil {
|
||||
requestInfo.AddQueryParameters(*(requestConfiguration.QueryParameters))
|
||||
}
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
func (m *ItemContentTypesItemBaseRequestBuilder) CreateGetRequestInformation(ctx context.Context, requestConfiguration *ItemContentTypesItemBaseRequestBuilderGetRequestConfiguration) (*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.GET
|
||||
requestInfo.Headers.Add("Accept", "application/json")
|
||||
if requestConfiguration != nil {
|
||||
if requestConfiguration.QueryParameters != nil {
|
||||
requestInfo.AddQueryParameters(*(requestConfiguration.QueryParameters))
|
||||
}
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
}
|
||||
|
||||
// Get parent contentType from which this content type is derived.
|
||||
func (m *ItemContentTypesItemBaseRequestBuilder) Get(ctx context.Context, requestConfiguration *ItemContentTypesItemBaseRequestBuilderGetRequestConfiguration)(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ContentTypeable, error) {
|
||||
requestInfo, err := m.CreateGetRequestInformation(ctx, requestConfiguration);
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings {
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.SendAsync(ctx, requestInfo, ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CreateContentTypeFromDiscriminatorValue, errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ContentTypeable), nil
|
||||
func (m *ItemContentTypesItemBaseRequestBuilder) Get(ctx context.Context, requestConfiguration *ItemContentTypesItemBaseRequestBuilderGetRequestConfiguration) (ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ContentTypeable, error) {
|
||||
requestInfo, err := m.CreateGetRequestInformation(ctx, requestConfiguration)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings{
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.Send(ctx, requestInfo, ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CreateContentTypeFromDiscriminatorValue, errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ContentTypeable), nil
|
||||
}
|
||||
|
||||
@ -1,88 +1,94 @@
|
||||
package sites
|
||||
|
||||
import (
|
||||
"context"
|
||||
i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f "github.com/microsoft/kiota-abstractions-go"
|
||||
ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models"
|
||||
i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models/odataerrors"
|
||||
"context"
|
||||
|
||||
ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models"
|
||||
i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models/odataerrors"
|
||||
i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f "github.com/microsoft/kiota-abstractions-go"
|
||||
)
|
||||
|
||||
// ItemContentTypesItemBaseTypesContentTypeItemRequestBuilder provides operations to manage the baseTypes property of the microsoft.graph.contentType entity.
|
||||
type ItemContentTypesItemBaseTypesContentTypeItemRequestBuilder struct {
|
||||
// Path parameters for the request
|
||||
pathParameters map[string]string
|
||||
// The request adapter to use to execute the requests.
|
||||
requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter
|
||||
// Url template to use to build the URL for the current request builder
|
||||
urlTemplate string
|
||||
// Path parameters for the request
|
||||
pathParameters map[string]string
|
||||
// The request adapter to use to execute the requests.
|
||||
requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter
|
||||
// Url template to use to build the URL for the current request builder
|
||||
urlTemplate string
|
||||
}
|
||||
|
||||
// ItemContentTypesItemBaseTypesContentTypeItemRequestBuilderGetQueryParameters the collection of content types that are ancestors of this content type.
|
||||
type ItemContentTypesItemBaseTypesContentTypeItemRequestBuilderGetQueryParameters struct {
|
||||
// Expand related entities
|
||||
Expand []string `uriparametername:"%24expand"`
|
||||
// Select properties to be returned
|
||||
Select []string `uriparametername:"%24select"`
|
||||
// Expand related entities
|
||||
Expand []string `uriparametername:"%24expand"`
|
||||
// Select properties to be returned
|
||||
Select []string `uriparametername:"%24select"`
|
||||
}
|
||||
|
||||
// ItemContentTypesItemBaseTypesContentTypeItemRequestBuilderGetRequestConfiguration configuration for the request such as headers, query parameters, and middleware options.
|
||||
type ItemContentTypesItemBaseTypesContentTypeItemRequestBuilderGetRequestConfiguration struct {
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
// Request query parameters
|
||||
QueryParameters *ItemContentTypesItemBaseTypesContentTypeItemRequestBuilderGetQueryParameters
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
// Request query parameters
|
||||
QueryParameters *ItemContentTypesItemBaseTypesContentTypeItemRequestBuilderGetQueryParameters
|
||||
}
|
||||
|
||||
// NewItemContentTypesItemBaseTypesContentTypeItemRequestBuilderInternal instantiates a new ContentTypeItemRequestBuilder and sets the default values.
|
||||
func NewItemContentTypesItemBaseTypesContentTypeItemRequestBuilderInternal(pathParameters map[string]string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemContentTypesItemBaseTypesContentTypeItemRequestBuilder) {
|
||||
m := &ItemContentTypesItemBaseTypesContentTypeItemRequestBuilder{
|
||||
}
|
||||
m.urlTemplate = "{+baseurl}/sites/{site%2Did}/contentTypes/{contentType%2Did}/baseTypes/{contentType%2Did1}{?%24select,%24expand}";
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
m.pathParameters = urlTplParams;
|
||||
m.requestAdapter = requestAdapter;
|
||||
return m
|
||||
func NewItemContentTypesItemBaseTypesContentTypeItemRequestBuilderInternal(pathParameters map[string]string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter) *ItemContentTypesItemBaseTypesContentTypeItemRequestBuilder {
|
||||
m := &ItemContentTypesItemBaseTypesContentTypeItemRequestBuilder{}
|
||||
m.urlTemplate = "{+baseurl}/sites/{site%2Did}/contentTypes/{contentType%2Did}/baseTypes/{contentType%2Did1}{?%24select,%24expand}"
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
m.pathParameters = urlTplParams
|
||||
m.requestAdapter = requestAdapter
|
||||
return m
|
||||
}
|
||||
|
||||
// NewItemContentTypesItemBaseTypesContentTypeItemRequestBuilder instantiates a new ContentTypeItemRequestBuilder and sets the default values.
|
||||
func NewItemContentTypesItemBaseTypesContentTypeItemRequestBuilder(rawUrl string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemContentTypesItemBaseTypesContentTypeItemRequestBuilder) {
|
||||
urlParams := make(map[string]string)
|
||||
urlParams["request-raw-url"] = rawUrl
|
||||
return NewItemContentTypesItemBaseTypesContentTypeItemRequestBuilderInternal(urlParams, requestAdapter)
|
||||
func NewItemContentTypesItemBaseTypesContentTypeItemRequestBuilder(rawUrl string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter) *ItemContentTypesItemBaseTypesContentTypeItemRequestBuilder {
|
||||
urlParams := make(map[string]string)
|
||||
urlParams["request-raw-url"] = rawUrl
|
||||
return NewItemContentTypesItemBaseTypesContentTypeItemRequestBuilderInternal(urlParams, requestAdapter)
|
||||
}
|
||||
|
||||
// CreateGetRequestInformation the collection of content types that are ancestors of this content type.
|
||||
func (m *ItemContentTypesItemBaseTypesContentTypeItemRequestBuilder) CreateGetRequestInformation(ctx context.Context, requestConfiguration *ItemContentTypesItemBaseTypesContentTypeItemRequestBuilderGetRequestConfiguration)(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.GET
|
||||
requestInfo.Headers.Add("Accept", "application/json")
|
||||
if requestConfiguration != nil {
|
||||
if requestConfiguration.QueryParameters != nil {
|
||||
requestInfo.AddQueryParameters(*(requestConfiguration.QueryParameters))
|
||||
}
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
func (m *ItemContentTypesItemBaseTypesContentTypeItemRequestBuilder) CreateGetRequestInformation(ctx context.Context, requestConfiguration *ItemContentTypesItemBaseTypesContentTypeItemRequestBuilderGetRequestConfiguration) (*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.GET
|
||||
requestInfo.Headers.Add("Accept", "application/json")
|
||||
if requestConfiguration != nil {
|
||||
if requestConfiguration.QueryParameters != nil {
|
||||
requestInfo.AddQueryParameters(*(requestConfiguration.QueryParameters))
|
||||
}
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
}
|
||||
|
||||
// Get the collection of content types that are ancestors of this content type.
|
||||
func (m *ItemContentTypesItemBaseTypesContentTypeItemRequestBuilder) Get(ctx context.Context, requestConfiguration *ItemContentTypesItemBaseTypesContentTypeItemRequestBuilderGetRequestConfiguration)(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ContentTypeable, error) {
|
||||
requestInfo, err := m.CreateGetRequestInformation(ctx, requestConfiguration);
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings {
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.SendAsync(ctx, requestInfo, ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CreateContentTypeFromDiscriminatorValue, errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ContentTypeable), nil
|
||||
func (m *ItemContentTypesItemBaseTypesContentTypeItemRequestBuilder) Get(ctx context.Context, requestConfiguration *ItemContentTypesItemBaseTypesContentTypeItemRequestBuilderGetRequestConfiguration) (ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ContentTypeable, error) {
|
||||
requestInfo, err := m.CreateGetRequestInformation(ctx, requestConfiguration)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings{
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.Send(ctx, requestInfo, ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CreateContentTypeFromDiscriminatorValue, errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ContentTypeable), nil
|
||||
}
|
||||
|
||||
@ -1,87 +1,93 @@
|
||||
package sites
|
||||
|
||||
import (
|
||||
"context"
|
||||
i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f "github.com/microsoft/kiota-abstractions-go"
|
||||
i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models/odataerrors"
|
||||
"context"
|
||||
|
||||
i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models/odataerrors"
|
||||
i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f "github.com/microsoft/kiota-abstractions-go"
|
||||
)
|
||||
|
||||
// ItemContentTypesItemBaseTypesCountRequestBuilder provides operations to count the resources in the collection.
|
||||
type ItemContentTypesItemBaseTypesCountRequestBuilder struct {
|
||||
// Path parameters for the request
|
||||
pathParameters map[string]string
|
||||
// The request adapter to use to execute the requests.
|
||||
requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter
|
||||
// Url template to use to build the URL for the current request builder
|
||||
urlTemplate string
|
||||
// Path parameters for the request
|
||||
pathParameters map[string]string
|
||||
// The request adapter to use to execute the requests.
|
||||
requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter
|
||||
// Url template to use to build the URL for the current request builder
|
||||
urlTemplate string
|
||||
}
|
||||
|
||||
// ItemContentTypesItemBaseTypesCountRequestBuilderGetQueryParameters get the number of the resource
|
||||
type ItemContentTypesItemBaseTypesCountRequestBuilderGetQueryParameters struct {
|
||||
// Filter items by property values
|
||||
Filter *string `uriparametername:"%24filter"`
|
||||
// Search items by search phrases
|
||||
Search *string `uriparametername:"%24search"`
|
||||
// Filter items by property values
|
||||
Filter *string `uriparametername:"%24filter"`
|
||||
// Search items by search phrases
|
||||
Search *string `uriparametername:"%24search"`
|
||||
}
|
||||
|
||||
// ItemContentTypesItemBaseTypesCountRequestBuilderGetRequestConfiguration configuration for the request such as headers, query parameters, and middleware options.
|
||||
type ItemContentTypesItemBaseTypesCountRequestBuilderGetRequestConfiguration struct {
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
// Request query parameters
|
||||
QueryParameters *ItemContentTypesItemBaseTypesCountRequestBuilderGetQueryParameters
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
// Request query parameters
|
||||
QueryParameters *ItemContentTypesItemBaseTypesCountRequestBuilderGetQueryParameters
|
||||
}
|
||||
|
||||
// NewItemContentTypesItemBaseTypesCountRequestBuilderInternal instantiates a new CountRequestBuilder and sets the default values.
|
||||
func NewItemContentTypesItemBaseTypesCountRequestBuilderInternal(pathParameters map[string]string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemContentTypesItemBaseTypesCountRequestBuilder) {
|
||||
m := &ItemContentTypesItemBaseTypesCountRequestBuilder{
|
||||
}
|
||||
m.urlTemplate = "{+baseurl}/sites/{site%2Did}/contentTypes/{contentType%2Did}/baseTypes/$count{?%24search,%24filter}";
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
m.pathParameters = urlTplParams;
|
||||
m.requestAdapter = requestAdapter;
|
||||
return m
|
||||
func NewItemContentTypesItemBaseTypesCountRequestBuilderInternal(pathParameters map[string]string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter) *ItemContentTypesItemBaseTypesCountRequestBuilder {
|
||||
m := &ItemContentTypesItemBaseTypesCountRequestBuilder{}
|
||||
m.urlTemplate = "{+baseurl}/sites/{site%2Did}/contentTypes/{contentType%2Did}/baseTypes/$count{?%24search,%24filter}"
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
m.pathParameters = urlTplParams
|
||||
m.requestAdapter = requestAdapter
|
||||
return m
|
||||
}
|
||||
|
||||
// NewItemContentTypesItemBaseTypesCountRequestBuilder instantiates a new CountRequestBuilder and sets the default values.
|
||||
func NewItemContentTypesItemBaseTypesCountRequestBuilder(rawUrl string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemContentTypesItemBaseTypesCountRequestBuilder) {
|
||||
urlParams := make(map[string]string)
|
||||
urlParams["request-raw-url"] = rawUrl
|
||||
return NewItemContentTypesItemBaseTypesCountRequestBuilderInternal(urlParams, requestAdapter)
|
||||
func NewItemContentTypesItemBaseTypesCountRequestBuilder(rawUrl string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter) *ItemContentTypesItemBaseTypesCountRequestBuilder {
|
||||
urlParams := make(map[string]string)
|
||||
urlParams["request-raw-url"] = rawUrl
|
||||
return NewItemContentTypesItemBaseTypesCountRequestBuilderInternal(urlParams, requestAdapter)
|
||||
}
|
||||
|
||||
// CreateGetRequestInformation get the number of the resource
|
||||
func (m *ItemContentTypesItemBaseTypesCountRequestBuilder) CreateGetRequestInformation(ctx context.Context, requestConfiguration *ItemContentTypesItemBaseTypesCountRequestBuilderGetRequestConfiguration)(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.GET
|
||||
requestInfo.Headers.Add("Accept", "text/plain")
|
||||
if requestConfiguration != nil {
|
||||
if requestConfiguration.QueryParameters != nil {
|
||||
requestInfo.AddQueryParameters(*(requestConfiguration.QueryParameters))
|
||||
}
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
func (m *ItemContentTypesItemBaseTypesCountRequestBuilder) CreateGetRequestInformation(ctx context.Context, requestConfiguration *ItemContentTypesItemBaseTypesCountRequestBuilderGetRequestConfiguration) (*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.GET
|
||||
requestInfo.Headers.Add("Accept", "text/plain")
|
||||
if requestConfiguration != nil {
|
||||
if requestConfiguration.QueryParameters != nil {
|
||||
requestInfo.AddQueryParameters(*(requestConfiguration.QueryParameters))
|
||||
}
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
}
|
||||
|
||||
// Get get the number of the resource
|
||||
func (m *ItemContentTypesItemBaseTypesCountRequestBuilder) Get(ctx context.Context, requestConfiguration *ItemContentTypesItemBaseTypesCountRequestBuilderGetRequestConfiguration)(*int32, error) {
|
||||
requestInfo, err := m.CreateGetRequestInformation(ctx, requestConfiguration);
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings {
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.SendPrimitiveAsync(ctx, requestInfo, "int32", errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(*int32), nil
|
||||
func (m *ItemContentTypesItemBaseTypesCountRequestBuilder) Get(ctx context.Context, requestConfiguration *ItemContentTypesItemBaseTypesCountRequestBuilderGetRequestConfiguration) (*int32, error) {
|
||||
requestInfo, err := m.CreateGetRequestInformation(ctx, requestConfiguration)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings{
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.SendPrimitive(ctx, requestInfo, "int32", errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(*int32), nil
|
||||
}
|
||||
|
||||
@ -1,104 +1,111 @@
|
||||
package sites
|
||||
|
||||
import (
|
||||
"context"
|
||||
i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f "github.com/microsoft/kiota-abstractions-go"
|
||||
ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models"
|
||||
i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models/odataerrors"
|
||||
"context"
|
||||
|
||||
ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models"
|
||||
i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models/odataerrors"
|
||||
i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f "github.com/microsoft/kiota-abstractions-go"
|
||||
)
|
||||
|
||||
// ItemContentTypesItemBaseTypesRequestBuilder provides operations to manage the baseTypes property of the microsoft.graph.contentType entity.
|
||||
type ItemContentTypesItemBaseTypesRequestBuilder struct {
|
||||
// Path parameters for the request
|
||||
pathParameters map[string]string
|
||||
// The request adapter to use to execute the requests.
|
||||
requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter
|
||||
// Url template to use to build the URL for the current request builder
|
||||
urlTemplate string
|
||||
// Path parameters for the request
|
||||
pathParameters map[string]string
|
||||
// The request adapter to use to execute the requests.
|
||||
requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter
|
||||
// Url template to use to build the URL for the current request builder
|
||||
urlTemplate string
|
||||
}
|
||||
|
||||
// ItemContentTypesItemBaseTypesRequestBuilderGetQueryParameters the collection of content types that are ancestors of this content type.
|
||||
type ItemContentTypesItemBaseTypesRequestBuilderGetQueryParameters struct {
|
||||
// Include count of items
|
||||
Count *bool `uriparametername:"%24count"`
|
||||
// Expand related entities
|
||||
Expand []string `uriparametername:"%24expand"`
|
||||
// Filter items by property values
|
||||
Filter *string `uriparametername:"%24filter"`
|
||||
// Order items by property values
|
||||
Orderby []string `uriparametername:"%24orderby"`
|
||||
// Search items by search phrases
|
||||
Search *string `uriparametername:"%24search"`
|
||||
// Select properties to be returned
|
||||
Select []string `uriparametername:"%24select"`
|
||||
// Skip the first n items
|
||||
Skip *int32 `uriparametername:"%24skip"`
|
||||
// Show only the first n items
|
||||
Top *int32 `uriparametername:"%24top"`
|
||||
// Include count of items
|
||||
Count *bool `uriparametername:"%24count"`
|
||||
// Expand related entities
|
||||
Expand []string `uriparametername:"%24expand"`
|
||||
// Filter items by property values
|
||||
Filter *string `uriparametername:"%24filter"`
|
||||
// Order items by property values
|
||||
Orderby []string `uriparametername:"%24orderby"`
|
||||
// Search items by search phrases
|
||||
Search *string `uriparametername:"%24search"`
|
||||
// Select properties to be returned
|
||||
Select []string `uriparametername:"%24select"`
|
||||
// Skip the first n items
|
||||
Skip *int32 `uriparametername:"%24skip"`
|
||||
// Show only the first n items
|
||||
Top *int32 `uriparametername:"%24top"`
|
||||
}
|
||||
|
||||
// ItemContentTypesItemBaseTypesRequestBuilderGetRequestConfiguration configuration for the request such as headers, query parameters, and middleware options.
|
||||
type ItemContentTypesItemBaseTypesRequestBuilderGetRequestConfiguration struct {
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
// Request query parameters
|
||||
QueryParameters *ItemContentTypesItemBaseTypesRequestBuilderGetQueryParameters
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
// Request query parameters
|
||||
QueryParameters *ItemContentTypesItemBaseTypesRequestBuilderGetQueryParameters
|
||||
}
|
||||
|
||||
// NewItemContentTypesItemBaseTypesRequestBuilderInternal instantiates a new BaseTypesRequestBuilder and sets the default values.
|
||||
func NewItemContentTypesItemBaseTypesRequestBuilderInternal(pathParameters map[string]string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemContentTypesItemBaseTypesRequestBuilder) {
|
||||
m := &ItemContentTypesItemBaseTypesRequestBuilder{
|
||||
}
|
||||
m.urlTemplate = "{+baseurl}/sites/{site%2Did}/contentTypes/{contentType%2Did}/baseTypes{?%24top,%24skip,%24search,%24filter,%24count,%24orderby,%24select,%24expand}";
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
m.pathParameters = urlTplParams;
|
||||
m.requestAdapter = requestAdapter;
|
||||
return m
|
||||
func NewItemContentTypesItemBaseTypesRequestBuilderInternal(pathParameters map[string]string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter) *ItemContentTypesItemBaseTypesRequestBuilder {
|
||||
m := &ItemContentTypesItemBaseTypesRequestBuilder{}
|
||||
m.urlTemplate = "{+baseurl}/sites/{site%2Did}/contentTypes/{contentType%2Did}/baseTypes{?%24top,%24skip,%24search,%24filter,%24count,%24orderby,%24select,%24expand}"
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
m.pathParameters = urlTplParams
|
||||
m.requestAdapter = requestAdapter
|
||||
return m
|
||||
}
|
||||
|
||||
// NewItemContentTypesItemBaseTypesRequestBuilder instantiates a new BaseTypesRequestBuilder and sets the default values.
|
||||
func NewItemContentTypesItemBaseTypesRequestBuilder(rawUrl string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemContentTypesItemBaseTypesRequestBuilder) {
|
||||
urlParams := make(map[string]string)
|
||||
urlParams["request-raw-url"] = rawUrl
|
||||
return NewItemContentTypesItemBaseTypesRequestBuilderInternal(urlParams, requestAdapter)
|
||||
func NewItemContentTypesItemBaseTypesRequestBuilder(rawUrl string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter) *ItemContentTypesItemBaseTypesRequestBuilder {
|
||||
urlParams := make(map[string]string)
|
||||
urlParams["request-raw-url"] = rawUrl
|
||||
return NewItemContentTypesItemBaseTypesRequestBuilderInternal(urlParams, requestAdapter)
|
||||
}
|
||||
|
||||
// Count provides operations to count the resources in the collection.
|
||||
func (m *ItemContentTypesItemBaseTypesRequestBuilder) Count()(*ItemContentTypesItemBaseTypesCountRequestBuilder) {
|
||||
return NewItemContentTypesItemBaseTypesCountRequestBuilderInternal(m.pathParameters, m.requestAdapter);
|
||||
func (m *ItemContentTypesItemBaseTypesRequestBuilder) Count() *ItemContentTypesItemBaseTypesCountRequestBuilder {
|
||||
return NewItemContentTypesItemBaseTypesCountRequestBuilderInternal(m.pathParameters, m.requestAdapter)
|
||||
}
|
||||
|
||||
// CreateGetRequestInformation the collection of content types that are ancestors of this content type.
|
||||
func (m *ItemContentTypesItemBaseTypesRequestBuilder) CreateGetRequestInformation(ctx context.Context, requestConfiguration *ItemContentTypesItemBaseTypesRequestBuilderGetRequestConfiguration)(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.GET
|
||||
requestInfo.Headers.Add("Accept", "application/json")
|
||||
if requestConfiguration != nil {
|
||||
if requestConfiguration.QueryParameters != nil {
|
||||
requestInfo.AddQueryParameters(*(requestConfiguration.QueryParameters))
|
||||
}
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
func (m *ItemContentTypesItemBaseTypesRequestBuilder) CreateGetRequestInformation(ctx context.Context, requestConfiguration *ItemContentTypesItemBaseTypesRequestBuilderGetRequestConfiguration) (*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.GET
|
||||
requestInfo.Headers.Add("Accept", "application/json")
|
||||
if requestConfiguration != nil {
|
||||
if requestConfiguration.QueryParameters != nil {
|
||||
requestInfo.AddQueryParameters(*(requestConfiguration.QueryParameters))
|
||||
}
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
}
|
||||
|
||||
// Get the collection of content types that are ancestors of this content type.
|
||||
func (m *ItemContentTypesItemBaseTypesRequestBuilder) Get(ctx context.Context, requestConfiguration *ItemContentTypesItemBaseTypesRequestBuilderGetRequestConfiguration)(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ContentTypeCollectionResponseable, error) {
|
||||
requestInfo, err := m.CreateGetRequestInformation(ctx, requestConfiguration);
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings {
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.SendAsync(ctx, requestInfo, ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CreateContentTypeCollectionResponseFromDiscriminatorValue, errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ContentTypeCollectionResponseable), nil
|
||||
func (m *ItemContentTypesItemBaseTypesRequestBuilder) Get(ctx context.Context, requestConfiguration *ItemContentTypesItemBaseTypesRequestBuilderGetRequestConfiguration) (ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ContentTypeCollectionResponseable, error) {
|
||||
requestInfo, err := m.CreateGetRequestInformation(ctx, requestConfiguration)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings{
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.Send(ctx, requestInfo, ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CreateContentTypeCollectionResponseFromDiscriminatorValue, errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ContentTypeCollectionResponseable), nil
|
||||
}
|
||||
|
||||
@ -1,163 +1,175 @@
|
||||
package sites
|
||||
|
||||
import (
|
||||
"context"
|
||||
i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f "github.com/microsoft/kiota-abstractions-go"
|
||||
ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models"
|
||||
i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models/odataerrors"
|
||||
"context"
|
||||
|
||||
ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models"
|
||||
i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models/odataerrors"
|
||||
i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f "github.com/microsoft/kiota-abstractions-go"
|
||||
)
|
||||
|
||||
// ItemContentTypesItemColumnLinksColumnLinkItemRequestBuilder provides operations to manage the columnLinks property of the microsoft.graph.contentType entity.
|
||||
type ItemContentTypesItemColumnLinksColumnLinkItemRequestBuilder struct {
|
||||
// Path parameters for the request
|
||||
pathParameters map[string]string
|
||||
// The request adapter to use to execute the requests.
|
||||
requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter
|
||||
// Url template to use to build the URL for the current request builder
|
||||
urlTemplate string
|
||||
// Path parameters for the request
|
||||
pathParameters map[string]string
|
||||
// The request adapter to use to execute the requests.
|
||||
requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter
|
||||
// Url template to use to build the URL for the current request builder
|
||||
urlTemplate string
|
||||
}
|
||||
|
||||
// ItemContentTypesItemColumnLinksColumnLinkItemRequestBuilderDeleteRequestConfiguration configuration for the request such as headers, query parameters, and middleware options.
|
||||
type ItemContentTypesItemColumnLinksColumnLinkItemRequestBuilderDeleteRequestConfiguration struct {
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
}
|
||||
|
||||
// ItemContentTypesItemColumnLinksColumnLinkItemRequestBuilderGetQueryParameters the collection of columns that are required by this content type
|
||||
type ItemContentTypesItemColumnLinksColumnLinkItemRequestBuilderGetQueryParameters struct {
|
||||
// Expand related entities
|
||||
Expand []string `uriparametername:"%24expand"`
|
||||
// Select properties to be returned
|
||||
Select []string `uriparametername:"%24select"`
|
||||
// Expand related entities
|
||||
Expand []string `uriparametername:"%24expand"`
|
||||
// Select properties to be returned
|
||||
Select []string `uriparametername:"%24select"`
|
||||
}
|
||||
|
||||
// ItemContentTypesItemColumnLinksColumnLinkItemRequestBuilderGetRequestConfiguration configuration for the request such as headers, query parameters, and middleware options.
|
||||
type ItemContentTypesItemColumnLinksColumnLinkItemRequestBuilderGetRequestConfiguration struct {
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
// Request query parameters
|
||||
QueryParameters *ItemContentTypesItemColumnLinksColumnLinkItemRequestBuilderGetQueryParameters
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
// Request query parameters
|
||||
QueryParameters *ItemContentTypesItemColumnLinksColumnLinkItemRequestBuilderGetQueryParameters
|
||||
}
|
||||
|
||||
// ItemContentTypesItemColumnLinksColumnLinkItemRequestBuilderPatchRequestConfiguration configuration for the request such as headers, query parameters, and middleware options.
|
||||
type ItemContentTypesItemColumnLinksColumnLinkItemRequestBuilderPatchRequestConfiguration struct {
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
}
|
||||
|
||||
// NewItemContentTypesItemColumnLinksColumnLinkItemRequestBuilderInternal instantiates a new ColumnLinkItemRequestBuilder and sets the default values.
|
||||
func NewItemContentTypesItemColumnLinksColumnLinkItemRequestBuilderInternal(pathParameters map[string]string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemContentTypesItemColumnLinksColumnLinkItemRequestBuilder) {
|
||||
m := &ItemContentTypesItemColumnLinksColumnLinkItemRequestBuilder{
|
||||
}
|
||||
m.urlTemplate = "{+baseurl}/sites/{site%2Did}/contentTypes/{contentType%2Did}/columnLinks/{columnLink%2Did}{?%24select,%24expand}";
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
m.pathParameters = urlTplParams;
|
||||
m.requestAdapter = requestAdapter;
|
||||
return m
|
||||
func NewItemContentTypesItemColumnLinksColumnLinkItemRequestBuilderInternal(pathParameters map[string]string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter) *ItemContentTypesItemColumnLinksColumnLinkItemRequestBuilder {
|
||||
m := &ItemContentTypesItemColumnLinksColumnLinkItemRequestBuilder{}
|
||||
m.urlTemplate = "{+baseurl}/sites/{site%2Did}/contentTypes/{contentType%2Did}/columnLinks/{columnLink%2Did}{?%24select,%24expand}"
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
m.pathParameters = urlTplParams
|
||||
m.requestAdapter = requestAdapter
|
||||
return m
|
||||
}
|
||||
|
||||
// NewItemContentTypesItemColumnLinksColumnLinkItemRequestBuilder instantiates a new ColumnLinkItemRequestBuilder and sets the default values.
|
||||
func NewItemContentTypesItemColumnLinksColumnLinkItemRequestBuilder(rawUrl string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemContentTypesItemColumnLinksColumnLinkItemRequestBuilder) {
|
||||
urlParams := make(map[string]string)
|
||||
urlParams["request-raw-url"] = rawUrl
|
||||
return NewItemContentTypesItemColumnLinksColumnLinkItemRequestBuilderInternal(urlParams, requestAdapter)
|
||||
func NewItemContentTypesItemColumnLinksColumnLinkItemRequestBuilder(rawUrl string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter) *ItemContentTypesItemColumnLinksColumnLinkItemRequestBuilder {
|
||||
urlParams := make(map[string]string)
|
||||
urlParams["request-raw-url"] = rawUrl
|
||||
return NewItemContentTypesItemColumnLinksColumnLinkItemRequestBuilderInternal(urlParams, requestAdapter)
|
||||
}
|
||||
|
||||
// CreateDeleteRequestInformation delete navigation property columnLinks for sites
|
||||
func (m *ItemContentTypesItemColumnLinksColumnLinkItemRequestBuilder) CreateDeleteRequestInformation(ctx context.Context, requestConfiguration *ItemContentTypesItemColumnLinksColumnLinkItemRequestBuilderDeleteRequestConfiguration)(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.DELETE
|
||||
if requestConfiguration != nil {
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
func (m *ItemContentTypesItemColumnLinksColumnLinkItemRequestBuilder) CreateDeleteRequestInformation(ctx context.Context, requestConfiguration *ItemContentTypesItemColumnLinksColumnLinkItemRequestBuilderDeleteRequestConfiguration) (*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.DELETE
|
||||
if requestConfiguration != nil {
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
}
|
||||
|
||||
// CreateGetRequestInformation the collection of columns that are required by this content type
|
||||
func (m *ItemContentTypesItemColumnLinksColumnLinkItemRequestBuilder) CreateGetRequestInformation(ctx context.Context, requestConfiguration *ItemContentTypesItemColumnLinksColumnLinkItemRequestBuilderGetRequestConfiguration)(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.GET
|
||||
requestInfo.Headers.Add("Accept", "application/json")
|
||||
if requestConfiguration != nil {
|
||||
if requestConfiguration.QueryParameters != nil {
|
||||
requestInfo.AddQueryParameters(*(requestConfiguration.QueryParameters))
|
||||
}
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
func (m *ItemContentTypesItemColumnLinksColumnLinkItemRequestBuilder) CreateGetRequestInformation(ctx context.Context, requestConfiguration *ItemContentTypesItemColumnLinksColumnLinkItemRequestBuilderGetRequestConfiguration) (*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.GET
|
||||
requestInfo.Headers.Add("Accept", "application/json")
|
||||
if requestConfiguration != nil {
|
||||
if requestConfiguration.QueryParameters != nil {
|
||||
requestInfo.AddQueryParameters(*(requestConfiguration.QueryParameters))
|
||||
}
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
}
|
||||
|
||||
// CreatePatchRequestInformation update the navigation property columnLinks in sites
|
||||
func (m *ItemContentTypesItemColumnLinksColumnLinkItemRequestBuilder) CreatePatchRequestInformation(ctx context.Context, body ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ColumnLinkable, requestConfiguration *ItemContentTypesItemColumnLinksColumnLinkItemRequestBuilderPatchRequestConfiguration)(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.PATCH
|
||||
requestInfo.Headers.Add("Accept", "application/json")
|
||||
requestInfo.SetContentFromParsable(ctx, m.requestAdapter, "application/json", body)
|
||||
if requestConfiguration != nil {
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
func (m *ItemContentTypesItemColumnLinksColumnLinkItemRequestBuilder) CreatePatchRequestInformation(ctx context.Context, body ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ColumnLinkable, requestConfiguration *ItemContentTypesItemColumnLinksColumnLinkItemRequestBuilderPatchRequestConfiguration) (*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.PATCH
|
||||
requestInfo.Headers.Add("Accept", "application/json")
|
||||
requestInfo.SetContentFromParsable(ctx, m.requestAdapter, "application/json", body)
|
||||
if requestConfiguration != nil {
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
}
|
||||
|
||||
// Delete delete navigation property columnLinks for sites
|
||||
func (m *ItemContentTypesItemColumnLinksColumnLinkItemRequestBuilder) Delete(ctx context.Context, requestConfiguration *ItemContentTypesItemColumnLinksColumnLinkItemRequestBuilderDeleteRequestConfiguration)(error) {
|
||||
requestInfo, err := m.CreateDeleteRequestInformation(ctx, requestConfiguration);
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings {
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
err = m.requestAdapter.SendNoContentAsync(ctx, requestInfo, errorMapping)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
return nil
|
||||
func (m *ItemContentTypesItemColumnLinksColumnLinkItemRequestBuilder) Delete(ctx context.Context, requestConfiguration *ItemContentTypesItemColumnLinksColumnLinkItemRequestBuilderDeleteRequestConfiguration) error {
|
||||
requestInfo, err := m.CreateDeleteRequestInformation(ctx, requestConfiguration)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings{
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
err = m.requestAdapter.SendNoContent(ctx, requestInfo, errorMapping)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
// Get the collection of columns that are required by this content type
|
||||
func (m *ItemContentTypesItemColumnLinksColumnLinkItemRequestBuilder) Get(ctx context.Context, requestConfiguration *ItemContentTypesItemColumnLinksColumnLinkItemRequestBuilderGetRequestConfiguration)(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ColumnLinkable, error) {
|
||||
requestInfo, err := m.CreateGetRequestInformation(ctx, requestConfiguration);
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings {
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.SendAsync(ctx, requestInfo, ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CreateColumnLinkFromDiscriminatorValue, errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ColumnLinkable), nil
|
||||
func (m *ItemContentTypesItemColumnLinksColumnLinkItemRequestBuilder) Get(ctx context.Context, requestConfiguration *ItemContentTypesItemColumnLinksColumnLinkItemRequestBuilderGetRequestConfiguration) (ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ColumnLinkable, error) {
|
||||
requestInfo, err := m.CreateGetRequestInformation(ctx, requestConfiguration)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings{
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.Send(ctx, requestInfo, ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CreateColumnLinkFromDiscriminatorValue, errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ColumnLinkable), nil
|
||||
}
|
||||
|
||||
// Patch update the navigation property columnLinks in sites
|
||||
func (m *ItemContentTypesItemColumnLinksColumnLinkItemRequestBuilder) Patch(ctx context.Context, body ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ColumnLinkable, requestConfiguration *ItemContentTypesItemColumnLinksColumnLinkItemRequestBuilderPatchRequestConfiguration)(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ColumnLinkable, error) {
|
||||
requestInfo, err := m.CreatePatchRequestInformation(ctx, body, requestConfiguration);
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings {
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.SendAsync(ctx, requestInfo, ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CreateColumnLinkFromDiscriminatorValue, errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ColumnLinkable), nil
|
||||
func (m *ItemContentTypesItemColumnLinksColumnLinkItemRequestBuilder) Patch(ctx context.Context, body ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ColumnLinkable, requestConfiguration *ItemContentTypesItemColumnLinksColumnLinkItemRequestBuilderPatchRequestConfiguration) (ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ColumnLinkable, error) {
|
||||
requestInfo, err := m.CreatePatchRequestInformation(ctx, body, requestConfiguration)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings{
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.Send(ctx, requestInfo, ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CreateColumnLinkFromDiscriminatorValue, errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ColumnLinkable), nil
|
||||
}
|
||||
|
||||
@ -1,87 +1,93 @@
|
||||
package sites
|
||||
|
||||
import (
|
||||
"context"
|
||||
i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f "github.com/microsoft/kiota-abstractions-go"
|
||||
i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models/odataerrors"
|
||||
"context"
|
||||
|
||||
i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models/odataerrors"
|
||||
i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f "github.com/microsoft/kiota-abstractions-go"
|
||||
)
|
||||
|
||||
// ItemContentTypesItemColumnLinksCountRequestBuilder provides operations to count the resources in the collection.
|
||||
type ItemContentTypesItemColumnLinksCountRequestBuilder struct {
|
||||
// Path parameters for the request
|
||||
pathParameters map[string]string
|
||||
// The request adapter to use to execute the requests.
|
||||
requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter
|
||||
// Url template to use to build the URL for the current request builder
|
||||
urlTemplate string
|
||||
// Path parameters for the request
|
||||
pathParameters map[string]string
|
||||
// The request adapter to use to execute the requests.
|
||||
requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter
|
||||
// Url template to use to build the URL for the current request builder
|
||||
urlTemplate string
|
||||
}
|
||||
|
||||
// ItemContentTypesItemColumnLinksCountRequestBuilderGetQueryParameters get the number of the resource
|
||||
type ItemContentTypesItemColumnLinksCountRequestBuilderGetQueryParameters struct {
|
||||
// Filter items by property values
|
||||
Filter *string `uriparametername:"%24filter"`
|
||||
// Search items by search phrases
|
||||
Search *string `uriparametername:"%24search"`
|
||||
// Filter items by property values
|
||||
Filter *string `uriparametername:"%24filter"`
|
||||
// Search items by search phrases
|
||||
Search *string `uriparametername:"%24search"`
|
||||
}
|
||||
|
||||
// ItemContentTypesItemColumnLinksCountRequestBuilderGetRequestConfiguration configuration for the request such as headers, query parameters, and middleware options.
|
||||
type ItemContentTypesItemColumnLinksCountRequestBuilderGetRequestConfiguration struct {
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
// Request query parameters
|
||||
QueryParameters *ItemContentTypesItemColumnLinksCountRequestBuilderGetQueryParameters
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
// Request query parameters
|
||||
QueryParameters *ItemContentTypesItemColumnLinksCountRequestBuilderGetQueryParameters
|
||||
}
|
||||
|
||||
// NewItemContentTypesItemColumnLinksCountRequestBuilderInternal instantiates a new CountRequestBuilder and sets the default values.
|
||||
func NewItemContentTypesItemColumnLinksCountRequestBuilderInternal(pathParameters map[string]string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemContentTypesItemColumnLinksCountRequestBuilder) {
|
||||
m := &ItemContentTypesItemColumnLinksCountRequestBuilder{
|
||||
}
|
||||
m.urlTemplate = "{+baseurl}/sites/{site%2Did}/contentTypes/{contentType%2Did}/columnLinks/$count{?%24search,%24filter}";
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
m.pathParameters = urlTplParams;
|
||||
m.requestAdapter = requestAdapter;
|
||||
return m
|
||||
func NewItemContentTypesItemColumnLinksCountRequestBuilderInternal(pathParameters map[string]string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter) *ItemContentTypesItemColumnLinksCountRequestBuilder {
|
||||
m := &ItemContentTypesItemColumnLinksCountRequestBuilder{}
|
||||
m.urlTemplate = "{+baseurl}/sites/{site%2Did}/contentTypes/{contentType%2Did}/columnLinks/$count{?%24search,%24filter}"
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
m.pathParameters = urlTplParams
|
||||
m.requestAdapter = requestAdapter
|
||||
return m
|
||||
}
|
||||
|
||||
// NewItemContentTypesItemColumnLinksCountRequestBuilder instantiates a new CountRequestBuilder and sets the default values.
|
||||
func NewItemContentTypesItemColumnLinksCountRequestBuilder(rawUrl string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemContentTypesItemColumnLinksCountRequestBuilder) {
|
||||
urlParams := make(map[string]string)
|
||||
urlParams["request-raw-url"] = rawUrl
|
||||
return NewItemContentTypesItemColumnLinksCountRequestBuilderInternal(urlParams, requestAdapter)
|
||||
func NewItemContentTypesItemColumnLinksCountRequestBuilder(rawUrl string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter) *ItemContentTypesItemColumnLinksCountRequestBuilder {
|
||||
urlParams := make(map[string]string)
|
||||
urlParams["request-raw-url"] = rawUrl
|
||||
return NewItemContentTypesItemColumnLinksCountRequestBuilderInternal(urlParams, requestAdapter)
|
||||
}
|
||||
|
||||
// CreateGetRequestInformation get the number of the resource
|
||||
func (m *ItemContentTypesItemColumnLinksCountRequestBuilder) CreateGetRequestInformation(ctx context.Context, requestConfiguration *ItemContentTypesItemColumnLinksCountRequestBuilderGetRequestConfiguration)(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.GET
|
||||
requestInfo.Headers.Add("Accept", "text/plain")
|
||||
if requestConfiguration != nil {
|
||||
if requestConfiguration.QueryParameters != nil {
|
||||
requestInfo.AddQueryParameters(*(requestConfiguration.QueryParameters))
|
||||
}
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
func (m *ItemContentTypesItemColumnLinksCountRequestBuilder) CreateGetRequestInformation(ctx context.Context, requestConfiguration *ItemContentTypesItemColumnLinksCountRequestBuilderGetRequestConfiguration) (*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.GET
|
||||
requestInfo.Headers.Add("Accept", "text/plain")
|
||||
if requestConfiguration != nil {
|
||||
if requestConfiguration.QueryParameters != nil {
|
||||
requestInfo.AddQueryParameters(*(requestConfiguration.QueryParameters))
|
||||
}
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
}
|
||||
|
||||
// Get get the number of the resource
|
||||
func (m *ItemContentTypesItemColumnLinksCountRequestBuilder) Get(ctx context.Context, requestConfiguration *ItemContentTypesItemColumnLinksCountRequestBuilderGetRequestConfiguration)(*int32, error) {
|
||||
requestInfo, err := m.CreateGetRequestInformation(ctx, requestConfiguration);
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings {
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.SendPrimitiveAsync(ctx, requestInfo, "int32", errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(*int32), nil
|
||||
func (m *ItemContentTypesItemColumnLinksCountRequestBuilder) Get(ctx context.Context, requestConfiguration *ItemContentTypesItemColumnLinksCountRequestBuilderGetRequestConfiguration) (*int32, error) {
|
||||
requestInfo, err := m.CreateGetRequestInformation(ctx, requestConfiguration)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings{
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.SendPrimitive(ctx, requestInfo, "int32", errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(*int32), nil
|
||||
}
|
||||
|
||||
@ -1,144 +1,154 @@
|
||||
package sites
|
||||
|
||||
import (
|
||||
"context"
|
||||
i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f "github.com/microsoft/kiota-abstractions-go"
|
||||
ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models"
|
||||
i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models/odataerrors"
|
||||
"context"
|
||||
|
||||
ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models"
|
||||
i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models/odataerrors"
|
||||
i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f "github.com/microsoft/kiota-abstractions-go"
|
||||
)
|
||||
|
||||
// ItemContentTypesItemColumnLinksRequestBuilder provides operations to manage the columnLinks property of the microsoft.graph.contentType entity.
|
||||
type ItemContentTypesItemColumnLinksRequestBuilder struct {
|
||||
// Path parameters for the request
|
||||
pathParameters map[string]string
|
||||
// The request adapter to use to execute the requests.
|
||||
requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter
|
||||
// Url template to use to build the URL for the current request builder
|
||||
urlTemplate string
|
||||
// Path parameters for the request
|
||||
pathParameters map[string]string
|
||||
// The request adapter to use to execute the requests.
|
||||
requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter
|
||||
// Url template to use to build the URL for the current request builder
|
||||
urlTemplate string
|
||||
}
|
||||
|
||||
// ItemContentTypesItemColumnLinksRequestBuilderGetQueryParameters the collection of columns that are required by this content type
|
||||
type ItemContentTypesItemColumnLinksRequestBuilderGetQueryParameters struct {
|
||||
// Include count of items
|
||||
Count *bool `uriparametername:"%24count"`
|
||||
// Expand related entities
|
||||
Expand []string `uriparametername:"%24expand"`
|
||||
// Filter items by property values
|
||||
Filter *string `uriparametername:"%24filter"`
|
||||
// Order items by property values
|
||||
Orderby []string `uriparametername:"%24orderby"`
|
||||
// Search items by search phrases
|
||||
Search *string `uriparametername:"%24search"`
|
||||
// Select properties to be returned
|
||||
Select []string `uriparametername:"%24select"`
|
||||
// Skip the first n items
|
||||
Skip *int32 `uriparametername:"%24skip"`
|
||||
// Show only the first n items
|
||||
Top *int32 `uriparametername:"%24top"`
|
||||
// Include count of items
|
||||
Count *bool `uriparametername:"%24count"`
|
||||
// Expand related entities
|
||||
Expand []string `uriparametername:"%24expand"`
|
||||
// Filter items by property values
|
||||
Filter *string `uriparametername:"%24filter"`
|
||||
// Order items by property values
|
||||
Orderby []string `uriparametername:"%24orderby"`
|
||||
// Search items by search phrases
|
||||
Search *string `uriparametername:"%24search"`
|
||||
// Select properties to be returned
|
||||
Select []string `uriparametername:"%24select"`
|
||||
// Skip the first n items
|
||||
Skip *int32 `uriparametername:"%24skip"`
|
||||
// Show only the first n items
|
||||
Top *int32 `uriparametername:"%24top"`
|
||||
}
|
||||
|
||||
// ItemContentTypesItemColumnLinksRequestBuilderGetRequestConfiguration configuration for the request such as headers, query parameters, and middleware options.
|
||||
type ItemContentTypesItemColumnLinksRequestBuilderGetRequestConfiguration struct {
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
// Request query parameters
|
||||
QueryParameters *ItemContentTypesItemColumnLinksRequestBuilderGetQueryParameters
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
// Request query parameters
|
||||
QueryParameters *ItemContentTypesItemColumnLinksRequestBuilderGetQueryParameters
|
||||
}
|
||||
|
||||
// ItemContentTypesItemColumnLinksRequestBuilderPostRequestConfiguration configuration for the request such as headers, query parameters, and middleware options.
|
||||
type ItemContentTypesItemColumnLinksRequestBuilderPostRequestConfiguration struct {
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
}
|
||||
|
||||
// NewItemContentTypesItemColumnLinksRequestBuilderInternal instantiates a new ColumnLinksRequestBuilder and sets the default values.
|
||||
func NewItemContentTypesItemColumnLinksRequestBuilderInternal(pathParameters map[string]string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemContentTypesItemColumnLinksRequestBuilder) {
|
||||
m := &ItemContentTypesItemColumnLinksRequestBuilder{
|
||||
}
|
||||
m.urlTemplate = "{+baseurl}/sites/{site%2Did}/contentTypes/{contentType%2Did}/columnLinks{?%24top,%24skip,%24search,%24filter,%24count,%24orderby,%24select,%24expand}";
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
m.pathParameters = urlTplParams;
|
||||
m.requestAdapter = requestAdapter;
|
||||
return m
|
||||
func NewItemContentTypesItemColumnLinksRequestBuilderInternal(pathParameters map[string]string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter) *ItemContentTypesItemColumnLinksRequestBuilder {
|
||||
m := &ItemContentTypesItemColumnLinksRequestBuilder{}
|
||||
m.urlTemplate = "{+baseurl}/sites/{site%2Did}/contentTypes/{contentType%2Did}/columnLinks{?%24top,%24skip,%24search,%24filter,%24count,%24orderby,%24select,%24expand}"
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
m.pathParameters = urlTplParams
|
||||
m.requestAdapter = requestAdapter
|
||||
return m
|
||||
}
|
||||
|
||||
// NewItemContentTypesItemColumnLinksRequestBuilder instantiates a new ColumnLinksRequestBuilder and sets the default values.
|
||||
func NewItemContentTypesItemColumnLinksRequestBuilder(rawUrl string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemContentTypesItemColumnLinksRequestBuilder) {
|
||||
urlParams := make(map[string]string)
|
||||
urlParams["request-raw-url"] = rawUrl
|
||||
return NewItemContentTypesItemColumnLinksRequestBuilderInternal(urlParams, requestAdapter)
|
||||
func NewItemContentTypesItemColumnLinksRequestBuilder(rawUrl string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter) *ItemContentTypesItemColumnLinksRequestBuilder {
|
||||
urlParams := make(map[string]string)
|
||||
urlParams["request-raw-url"] = rawUrl
|
||||
return NewItemContentTypesItemColumnLinksRequestBuilderInternal(urlParams, requestAdapter)
|
||||
}
|
||||
|
||||
// Count provides operations to count the resources in the collection.
|
||||
func (m *ItemContentTypesItemColumnLinksRequestBuilder) Count()(*ItemContentTypesItemColumnLinksCountRequestBuilder) {
|
||||
return NewItemContentTypesItemColumnLinksCountRequestBuilderInternal(m.pathParameters, m.requestAdapter);
|
||||
func (m *ItemContentTypesItemColumnLinksRequestBuilder) Count() *ItemContentTypesItemColumnLinksCountRequestBuilder {
|
||||
return NewItemContentTypesItemColumnLinksCountRequestBuilderInternal(m.pathParameters, m.requestAdapter)
|
||||
}
|
||||
|
||||
// CreateGetRequestInformation the collection of columns that are required by this content type
|
||||
func (m *ItemContentTypesItemColumnLinksRequestBuilder) CreateGetRequestInformation(ctx context.Context, requestConfiguration *ItemContentTypesItemColumnLinksRequestBuilderGetRequestConfiguration)(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.GET
|
||||
requestInfo.Headers.Add("Accept", "application/json")
|
||||
if requestConfiguration != nil {
|
||||
if requestConfiguration.QueryParameters != nil {
|
||||
requestInfo.AddQueryParameters(*(requestConfiguration.QueryParameters))
|
||||
}
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
func (m *ItemContentTypesItemColumnLinksRequestBuilder) CreateGetRequestInformation(ctx context.Context, requestConfiguration *ItemContentTypesItemColumnLinksRequestBuilderGetRequestConfiguration) (*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.GET
|
||||
requestInfo.Headers.Add("Accept", "application/json")
|
||||
if requestConfiguration != nil {
|
||||
if requestConfiguration.QueryParameters != nil {
|
||||
requestInfo.AddQueryParameters(*(requestConfiguration.QueryParameters))
|
||||
}
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
}
|
||||
|
||||
// CreatePostRequestInformation create new navigation property to columnLinks for sites
|
||||
func (m *ItemContentTypesItemColumnLinksRequestBuilder) CreatePostRequestInformation(ctx context.Context, body ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ColumnLinkable, requestConfiguration *ItemContentTypesItemColumnLinksRequestBuilderPostRequestConfiguration)(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.POST
|
||||
requestInfo.Headers.Add("Accept", "application/json")
|
||||
requestInfo.SetContentFromParsable(ctx, m.requestAdapter, "application/json", body)
|
||||
if requestConfiguration != nil {
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
func (m *ItemContentTypesItemColumnLinksRequestBuilder) CreatePostRequestInformation(ctx context.Context, body ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ColumnLinkable, requestConfiguration *ItemContentTypesItemColumnLinksRequestBuilderPostRequestConfiguration) (*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.POST
|
||||
requestInfo.Headers.Add("Accept", "application/json")
|
||||
requestInfo.SetContentFromParsable(ctx, m.requestAdapter, "application/json", body)
|
||||
if requestConfiguration != nil {
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
}
|
||||
|
||||
// Get the collection of columns that are required by this content type
|
||||
func (m *ItemContentTypesItemColumnLinksRequestBuilder) Get(ctx context.Context, requestConfiguration *ItemContentTypesItemColumnLinksRequestBuilderGetRequestConfiguration)(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ColumnLinkCollectionResponseable, error) {
|
||||
requestInfo, err := m.CreateGetRequestInformation(ctx, requestConfiguration);
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings {
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.SendAsync(ctx, requestInfo, ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CreateColumnLinkCollectionResponseFromDiscriminatorValue, errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ColumnLinkCollectionResponseable), nil
|
||||
func (m *ItemContentTypesItemColumnLinksRequestBuilder) Get(ctx context.Context, requestConfiguration *ItemContentTypesItemColumnLinksRequestBuilderGetRequestConfiguration) (ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ColumnLinkCollectionResponseable, error) {
|
||||
requestInfo, err := m.CreateGetRequestInformation(ctx, requestConfiguration)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings{
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.Send(ctx, requestInfo, ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CreateColumnLinkCollectionResponseFromDiscriminatorValue, errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ColumnLinkCollectionResponseable), nil
|
||||
}
|
||||
|
||||
// Post create new navigation property to columnLinks for sites
|
||||
func (m *ItemContentTypesItemColumnLinksRequestBuilder) Post(ctx context.Context, body ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ColumnLinkable, requestConfiguration *ItemContentTypesItemColumnLinksRequestBuilderPostRequestConfiguration)(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ColumnLinkable, error) {
|
||||
requestInfo, err := m.CreatePostRequestInformation(ctx, body, requestConfiguration);
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings {
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.SendAsync(ctx, requestInfo, ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CreateColumnLinkFromDiscriminatorValue, errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ColumnLinkable), nil
|
||||
func (m *ItemContentTypesItemColumnLinksRequestBuilder) Post(ctx context.Context, body ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ColumnLinkable, requestConfiguration *ItemContentTypesItemColumnLinksRequestBuilderPostRequestConfiguration) (ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ColumnLinkable, error) {
|
||||
requestInfo, err := m.CreatePostRequestInformation(ctx, body, requestConfiguration)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings{
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.Send(ctx, requestInfo, ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CreateColumnLinkFromDiscriminatorValue, errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ColumnLinkable), nil
|
||||
}
|
||||
|
||||
@ -1,88 +1,94 @@
|
||||
package sites
|
||||
|
||||
import (
|
||||
"context"
|
||||
i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f "github.com/microsoft/kiota-abstractions-go"
|
||||
ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models"
|
||||
i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models/odataerrors"
|
||||
"context"
|
||||
|
||||
ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models"
|
||||
i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models/odataerrors"
|
||||
i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f "github.com/microsoft/kiota-abstractions-go"
|
||||
)
|
||||
|
||||
// ItemContentTypesItemColumnPositionsColumnDefinitionItemRequestBuilder provides operations to manage the columnPositions property of the microsoft.graph.contentType entity.
|
||||
type ItemContentTypesItemColumnPositionsColumnDefinitionItemRequestBuilder struct {
|
||||
// Path parameters for the request
|
||||
pathParameters map[string]string
|
||||
// The request adapter to use to execute the requests.
|
||||
requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter
|
||||
// Url template to use to build the URL for the current request builder
|
||||
urlTemplate string
|
||||
// Path parameters for the request
|
||||
pathParameters map[string]string
|
||||
// The request adapter to use to execute the requests.
|
||||
requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter
|
||||
// Url template to use to build the URL for the current request builder
|
||||
urlTemplate string
|
||||
}
|
||||
|
||||
// ItemContentTypesItemColumnPositionsColumnDefinitionItemRequestBuilderGetQueryParameters column order information in a content type.
|
||||
type ItemContentTypesItemColumnPositionsColumnDefinitionItemRequestBuilderGetQueryParameters struct {
|
||||
// Expand related entities
|
||||
Expand []string `uriparametername:"%24expand"`
|
||||
// Select properties to be returned
|
||||
Select []string `uriparametername:"%24select"`
|
||||
// Expand related entities
|
||||
Expand []string `uriparametername:"%24expand"`
|
||||
// Select properties to be returned
|
||||
Select []string `uriparametername:"%24select"`
|
||||
}
|
||||
|
||||
// ItemContentTypesItemColumnPositionsColumnDefinitionItemRequestBuilderGetRequestConfiguration configuration for the request such as headers, query parameters, and middleware options.
|
||||
type ItemContentTypesItemColumnPositionsColumnDefinitionItemRequestBuilderGetRequestConfiguration struct {
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
// Request query parameters
|
||||
QueryParameters *ItemContentTypesItemColumnPositionsColumnDefinitionItemRequestBuilderGetQueryParameters
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
// Request query parameters
|
||||
QueryParameters *ItemContentTypesItemColumnPositionsColumnDefinitionItemRequestBuilderGetQueryParameters
|
||||
}
|
||||
|
||||
// NewItemContentTypesItemColumnPositionsColumnDefinitionItemRequestBuilderInternal instantiates a new ColumnDefinitionItemRequestBuilder and sets the default values.
|
||||
func NewItemContentTypesItemColumnPositionsColumnDefinitionItemRequestBuilderInternal(pathParameters map[string]string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemContentTypesItemColumnPositionsColumnDefinitionItemRequestBuilder) {
|
||||
m := &ItemContentTypesItemColumnPositionsColumnDefinitionItemRequestBuilder{
|
||||
}
|
||||
m.urlTemplate = "{+baseurl}/sites/{site%2Did}/contentTypes/{contentType%2Did}/columnPositions/{columnDefinition%2Did}{?%24select,%24expand}";
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
m.pathParameters = urlTplParams;
|
||||
m.requestAdapter = requestAdapter;
|
||||
return m
|
||||
func NewItemContentTypesItemColumnPositionsColumnDefinitionItemRequestBuilderInternal(pathParameters map[string]string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter) *ItemContentTypesItemColumnPositionsColumnDefinitionItemRequestBuilder {
|
||||
m := &ItemContentTypesItemColumnPositionsColumnDefinitionItemRequestBuilder{}
|
||||
m.urlTemplate = "{+baseurl}/sites/{site%2Did}/contentTypes/{contentType%2Did}/columnPositions/{columnDefinition%2Did}{?%24select,%24expand}"
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
m.pathParameters = urlTplParams
|
||||
m.requestAdapter = requestAdapter
|
||||
return m
|
||||
}
|
||||
|
||||
// NewItemContentTypesItemColumnPositionsColumnDefinitionItemRequestBuilder instantiates a new ColumnDefinitionItemRequestBuilder and sets the default values.
|
||||
func NewItemContentTypesItemColumnPositionsColumnDefinitionItemRequestBuilder(rawUrl string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemContentTypesItemColumnPositionsColumnDefinitionItemRequestBuilder) {
|
||||
urlParams := make(map[string]string)
|
||||
urlParams["request-raw-url"] = rawUrl
|
||||
return NewItemContentTypesItemColumnPositionsColumnDefinitionItemRequestBuilderInternal(urlParams, requestAdapter)
|
||||
func NewItemContentTypesItemColumnPositionsColumnDefinitionItemRequestBuilder(rawUrl string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter) *ItemContentTypesItemColumnPositionsColumnDefinitionItemRequestBuilder {
|
||||
urlParams := make(map[string]string)
|
||||
urlParams["request-raw-url"] = rawUrl
|
||||
return NewItemContentTypesItemColumnPositionsColumnDefinitionItemRequestBuilderInternal(urlParams, requestAdapter)
|
||||
}
|
||||
|
||||
// CreateGetRequestInformation column order information in a content type.
|
||||
func (m *ItemContentTypesItemColumnPositionsColumnDefinitionItemRequestBuilder) CreateGetRequestInformation(ctx context.Context, requestConfiguration *ItemContentTypesItemColumnPositionsColumnDefinitionItemRequestBuilderGetRequestConfiguration)(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.GET
|
||||
requestInfo.Headers.Add("Accept", "application/json")
|
||||
if requestConfiguration != nil {
|
||||
if requestConfiguration.QueryParameters != nil {
|
||||
requestInfo.AddQueryParameters(*(requestConfiguration.QueryParameters))
|
||||
}
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
func (m *ItemContentTypesItemColumnPositionsColumnDefinitionItemRequestBuilder) CreateGetRequestInformation(ctx context.Context, requestConfiguration *ItemContentTypesItemColumnPositionsColumnDefinitionItemRequestBuilderGetRequestConfiguration) (*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.GET
|
||||
requestInfo.Headers.Add("Accept", "application/json")
|
||||
if requestConfiguration != nil {
|
||||
if requestConfiguration.QueryParameters != nil {
|
||||
requestInfo.AddQueryParameters(*(requestConfiguration.QueryParameters))
|
||||
}
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
}
|
||||
|
||||
// Get column order information in a content type.
|
||||
func (m *ItemContentTypesItemColumnPositionsColumnDefinitionItemRequestBuilder) Get(ctx context.Context, requestConfiguration *ItemContentTypesItemColumnPositionsColumnDefinitionItemRequestBuilderGetRequestConfiguration)(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ColumnDefinitionable, error) {
|
||||
requestInfo, err := m.CreateGetRequestInformation(ctx, requestConfiguration);
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings {
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.SendAsync(ctx, requestInfo, ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CreateColumnDefinitionFromDiscriminatorValue, errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ColumnDefinitionable), nil
|
||||
func (m *ItemContentTypesItemColumnPositionsColumnDefinitionItemRequestBuilder) Get(ctx context.Context, requestConfiguration *ItemContentTypesItemColumnPositionsColumnDefinitionItemRequestBuilderGetRequestConfiguration) (ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ColumnDefinitionable, error) {
|
||||
requestInfo, err := m.CreateGetRequestInformation(ctx, requestConfiguration)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings{
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.Send(ctx, requestInfo, ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CreateColumnDefinitionFromDiscriminatorValue, errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ColumnDefinitionable), nil
|
||||
}
|
||||
|
||||
@ -1,87 +1,93 @@
|
||||
package sites
|
||||
|
||||
import (
|
||||
"context"
|
||||
i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f "github.com/microsoft/kiota-abstractions-go"
|
||||
i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models/odataerrors"
|
||||
"context"
|
||||
|
||||
i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models/odataerrors"
|
||||
i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f "github.com/microsoft/kiota-abstractions-go"
|
||||
)
|
||||
|
||||
// ItemContentTypesItemColumnPositionsCountRequestBuilder provides operations to count the resources in the collection.
|
||||
type ItemContentTypesItemColumnPositionsCountRequestBuilder struct {
|
||||
// Path parameters for the request
|
||||
pathParameters map[string]string
|
||||
// The request adapter to use to execute the requests.
|
||||
requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter
|
||||
// Url template to use to build the URL for the current request builder
|
||||
urlTemplate string
|
||||
// Path parameters for the request
|
||||
pathParameters map[string]string
|
||||
// The request adapter to use to execute the requests.
|
||||
requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter
|
||||
// Url template to use to build the URL for the current request builder
|
||||
urlTemplate string
|
||||
}
|
||||
|
||||
// ItemContentTypesItemColumnPositionsCountRequestBuilderGetQueryParameters get the number of the resource
|
||||
type ItemContentTypesItemColumnPositionsCountRequestBuilderGetQueryParameters struct {
|
||||
// Filter items by property values
|
||||
Filter *string `uriparametername:"%24filter"`
|
||||
// Search items by search phrases
|
||||
Search *string `uriparametername:"%24search"`
|
||||
// Filter items by property values
|
||||
Filter *string `uriparametername:"%24filter"`
|
||||
// Search items by search phrases
|
||||
Search *string `uriparametername:"%24search"`
|
||||
}
|
||||
|
||||
// ItemContentTypesItemColumnPositionsCountRequestBuilderGetRequestConfiguration configuration for the request such as headers, query parameters, and middleware options.
|
||||
type ItemContentTypesItemColumnPositionsCountRequestBuilderGetRequestConfiguration struct {
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
// Request query parameters
|
||||
QueryParameters *ItemContentTypesItemColumnPositionsCountRequestBuilderGetQueryParameters
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
// Request query parameters
|
||||
QueryParameters *ItemContentTypesItemColumnPositionsCountRequestBuilderGetQueryParameters
|
||||
}
|
||||
|
||||
// NewItemContentTypesItemColumnPositionsCountRequestBuilderInternal instantiates a new CountRequestBuilder and sets the default values.
|
||||
func NewItemContentTypesItemColumnPositionsCountRequestBuilderInternal(pathParameters map[string]string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemContentTypesItemColumnPositionsCountRequestBuilder) {
|
||||
m := &ItemContentTypesItemColumnPositionsCountRequestBuilder{
|
||||
}
|
||||
m.urlTemplate = "{+baseurl}/sites/{site%2Did}/contentTypes/{contentType%2Did}/columnPositions/$count{?%24search,%24filter}";
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
m.pathParameters = urlTplParams;
|
||||
m.requestAdapter = requestAdapter;
|
||||
return m
|
||||
func NewItemContentTypesItemColumnPositionsCountRequestBuilderInternal(pathParameters map[string]string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter) *ItemContentTypesItemColumnPositionsCountRequestBuilder {
|
||||
m := &ItemContentTypesItemColumnPositionsCountRequestBuilder{}
|
||||
m.urlTemplate = "{+baseurl}/sites/{site%2Did}/contentTypes/{contentType%2Did}/columnPositions/$count{?%24search,%24filter}"
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
m.pathParameters = urlTplParams
|
||||
m.requestAdapter = requestAdapter
|
||||
return m
|
||||
}
|
||||
|
||||
// NewItemContentTypesItemColumnPositionsCountRequestBuilder instantiates a new CountRequestBuilder and sets the default values.
|
||||
func NewItemContentTypesItemColumnPositionsCountRequestBuilder(rawUrl string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemContentTypesItemColumnPositionsCountRequestBuilder) {
|
||||
urlParams := make(map[string]string)
|
||||
urlParams["request-raw-url"] = rawUrl
|
||||
return NewItemContentTypesItemColumnPositionsCountRequestBuilderInternal(urlParams, requestAdapter)
|
||||
func NewItemContentTypesItemColumnPositionsCountRequestBuilder(rawUrl string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter) *ItemContentTypesItemColumnPositionsCountRequestBuilder {
|
||||
urlParams := make(map[string]string)
|
||||
urlParams["request-raw-url"] = rawUrl
|
||||
return NewItemContentTypesItemColumnPositionsCountRequestBuilderInternal(urlParams, requestAdapter)
|
||||
}
|
||||
|
||||
// CreateGetRequestInformation get the number of the resource
|
||||
func (m *ItemContentTypesItemColumnPositionsCountRequestBuilder) CreateGetRequestInformation(ctx context.Context, requestConfiguration *ItemContentTypesItemColumnPositionsCountRequestBuilderGetRequestConfiguration)(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.GET
|
||||
requestInfo.Headers.Add("Accept", "text/plain")
|
||||
if requestConfiguration != nil {
|
||||
if requestConfiguration.QueryParameters != nil {
|
||||
requestInfo.AddQueryParameters(*(requestConfiguration.QueryParameters))
|
||||
}
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
func (m *ItemContentTypesItemColumnPositionsCountRequestBuilder) CreateGetRequestInformation(ctx context.Context, requestConfiguration *ItemContentTypesItemColumnPositionsCountRequestBuilderGetRequestConfiguration) (*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.GET
|
||||
requestInfo.Headers.Add("Accept", "text/plain")
|
||||
if requestConfiguration != nil {
|
||||
if requestConfiguration.QueryParameters != nil {
|
||||
requestInfo.AddQueryParameters(*(requestConfiguration.QueryParameters))
|
||||
}
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
}
|
||||
|
||||
// Get get the number of the resource
|
||||
func (m *ItemContentTypesItemColumnPositionsCountRequestBuilder) Get(ctx context.Context, requestConfiguration *ItemContentTypesItemColumnPositionsCountRequestBuilderGetRequestConfiguration)(*int32, error) {
|
||||
requestInfo, err := m.CreateGetRequestInformation(ctx, requestConfiguration);
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings {
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.SendPrimitiveAsync(ctx, requestInfo, "int32", errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(*int32), nil
|
||||
func (m *ItemContentTypesItemColumnPositionsCountRequestBuilder) Get(ctx context.Context, requestConfiguration *ItemContentTypesItemColumnPositionsCountRequestBuilderGetRequestConfiguration) (*int32, error) {
|
||||
requestInfo, err := m.CreateGetRequestInformation(ctx, requestConfiguration)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings{
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.SendPrimitive(ctx, requestInfo, "int32", errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(*int32), nil
|
||||
}
|
||||
|
||||
@ -1,104 +1,111 @@
|
||||
package sites
|
||||
|
||||
import (
|
||||
"context"
|
||||
i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f "github.com/microsoft/kiota-abstractions-go"
|
||||
ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models"
|
||||
i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models/odataerrors"
|
||||
"context"
|
||||
|
||||
ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models"
|
||||
i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models/odataerrors"
|
||||
i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f "github.com/microsoft/kiota-abstractions-go"
|
||||
)
|
||||
|
||||
// ItemContentTypesItemColumnPositionsRequestBuilder provides operations to manage the columnPositions property of the microsoft.graph.contentType entity.
|
||||
type ItemContentTypesItemColumnPositionsRequestBuilder struct {
|
||||
// Path parameters for the request
|
||||
pathParameters map[string]string
|
||||
// The request adapter to use to execute the requests.
|
||||
requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter
|
||||
// Url template to use to build the URL for the current request builder
|
||||
urlTemplate string
|
||||
// Path parameters for the request
|
||||
pathParameters map[string]string
|
||||
// The request adapter to use to execute the requests.
|
||||
requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter
|
||||
// Url template to use to build the URL for the current request builder
|
||||
urlTemplate string
|
||||
}
|
||||
|
||||
// ItemContentTypesItemColumnPositionsRequestBuilderGetQueryParameters column order information in a content type.
|
||||
type ItemContentTypesItemColumnPositionsRequestBuilderGetQueryParameters struct {
|
||||
// Include count of items
|
||||
Count *bool `uriparametername:"%24count"`
|
||||
// Expand related entities
|
||||
Expand []string `uriparametername:"%24expand"`
|
||||
// Filter items by property values
|
||||
Filter *string `uriparametername:"%24filter"`
|
||||
// Order items by property values
|
||||
Orderby []string `uriparametername:"%24orderby"`
|
||||
// Search items by search phrases
|
||||
Search *string `uriparametername:"%24search"`
|
||||
// Select properties to be returned
|
||||
Select []string `uriparametername:"%24select"`
|
||||
// Skip the first n items
|
||||
Skip *int32 `uriparametername:"%24skip"`
|
||||
// Show only the first n items
|
||||
Top *int32 `uriparametername:"%24top"`
|
||||
// Include count of items
|
||||
Count *bool `uriparametername:"%24count"`
|
||||
// Expand related entities
|
||||
Expand []string `uriparametername:"%24expand"`
|
||||
// Filter items by property values
|
||||
Filter *string `uriparametername:"%24filter"`
|
||||
// Order items by property values
|
||||
Orderby []string `uriparametername:"%24orderby"`
|
||||
// Search items by search phrases
|
||||
Search *string `uriparametername:"%24search"`
|
||||
// Select properties to be returned
|
||||
Select []string `uriparametername:"%24select"`
|
||||
// Skip the first n items
|
||||
Skip *int32 `uriparametername:"%24skip"`
|
||||
// Show only the first n items
|
||||
Top *int32 `uriparametername:"%24top"`
|
||||
}
|
||||
|
||||
// ItemContentTypesItemColumnPositionsRequestBuilderGetRequestConfiguration configuration for the request such as headers, query parameters, and middleware options.
|
||||
type ItemContentTypesItemColumnPositionsRequestBuilderGetRequestConfiguration struct {
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
// Request query parameters
|
||||
QueryParameters *ItemContentTypesItemColumnPositionsRequestBuilderGetQueryParameters
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
// Request query parameters
|
||||
QueryParameters *ItemContentTypesItemColumnPositionsRequestBuilderGetQueryParameters
|
||||
}
|
||||
|
||||
// NewItemContentTypesItemColumnPositionsRequestBuilderInternal instantiates a new ColumnPositionsRequestBuilder and sets the default values.
|
||||
func NewItemContentTypesItemColumnPositionsRequestBuilderInternal(pathParameters map[string]string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemContentTypesItemColumnPositionsRequestBuilder) {
|
||||
m := &ItemContentTypesItemColumnPositionsRequestBuilder{
|
||||
}
|
||||
m.urlTemplate = "{+baseurl}/sites/{site%2Did}/contentTypes/{contentType%2Did}/columnPositions{?%24top,%24skip,%24search,%24filter,%24count,%24orderby,%24select,%24expand}";
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
m.pathParameters = urlTplParams;
|
||||
m.requestAdapter = requestAdapter;
|
||||
return m
|
||||
func NewItemContentTypesItemColumnPositionsRequestBuilderInternal(pathParameters map[string]string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter) *ItemContentTypesItemColumnPositionsRequestBuilder {
|
||||
m := &ItemContentTypesItemColumnPositionsRequestBuilder{}
|
||||
m.urlTemplate = "{+baseurl}/sites/{site%2Did}/contentTypes/{contentType%2Did}/columnPositions{?%24top,%24skip,%24search,%24filter,%24count,%24orderby,%24select,%24expand}"
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
m.pathParameters = urlTplParams
|
||||
m.requestAdapter = requestAdapter
|
||||
return m
|
||||
}
|
||||
|
||||
// NewItemContentTypesItemColumnPositionsRequestBuilder instantiates a new ColumnPositionsRequestBuilder and sets the default values.
|
||||
func NewItemContentTypesItemColumnPositionsRequestBuilder(rawUrl string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemContentTypesItemColumnPositionsRequestBuilder) {
|
||||
urlParams := make(map[string]string)
|
||||
urlParams["request-raw-url"] = rawUrl
|
||||
return NewItemContentTypesItemColumnPositionsRequestBuilderInternal(urlParams, requestAdapter)
|
||||
func NewItemContentTypesItemColumnPositionsRequestBuilder(rawUrl string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter) *ItemContentTypesItemColumnPositionsRequestBuilder {
|
||||
urlParams := make(map[string]string)
|
||||
urlParams["request-raw-url"] = rawUrl
|
||||
return NewItemContentTypesItemColumnPositionsRequestBuilderInternal(urlParams, requestAdapter)
|
||||
}
|
||||
|
||||
// Count provides operations to count the resources in the collection.
|
||||
func (m *ItemContentTypesItemColumnPositionsRequestBuilder) Count()(*ItemContentTypesItemColumnPositionsCountRequestBuilder) {
|
||||
return NewItemContentTypesItemColumnPositionsCountRequestBuilderInternal(m.pathParameters, m.requestAdapter);
|
||||
func (m *ItemContentTypesItemColumnPositionsRequestBuilder) Count() *ItemContentTypesItemColumnPositionsCountRequestBuilder {
|
||||
return NewItemContentTypesItemColumnPositionsCountRequestBuilderInternal(m.pathParameters, m.requestAdapter)
|
||||
}
|
||||
|
||||
// CreateGetRequestInformation column order information in a content type.
|
||||
func (m *ItemContentTypesItemColumnPositionsRequestBuilder) CreateGetRequestInformation(ctx context.Context, requestConfiguration *ItemContentTypesItemColumnPositionsRequestBuilderGetRequestConfiguration)(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.GET
|
||||
requestInfo.Headers.Add("Accept", "application/json")
|
||||
if requestConfiguration != nil {
|
||||
if requestConfiguration.QueryParameters != nil {
|
||||
requestInfo.AddQueryParameters(*(requestConfiguration.QueryParameters))
|
||||
}
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
func (m *ItemContentTypesItemColumnPositionsRequestBuilder) CreateGetRequestInformation(ctx context.Context, requestConfiguration *ItemContentTypesItemColumnPositionsRequestBuilderGetRequestConfiguration) (*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.GET
|
||||
requestInfo.Headers.Add("Accept", "application/json")
|
||||
if requestConfiguration != nil {
|
||||
if requestConfiguration.QueryParameters != nil {
|
||||
requestInfo.AddQueryParameters(*(requestConfiguration.QueryParameters))
|
||||
}
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
}
|
||||
|
||||
// Get column order information in a content type.
|
||||
func (m *ItemContentTypesItemColumnPositionsRequestBuilder) Get(ctx context.Context, requestConfiguration *ItemContentTypesItemColumnPositionsRequestBuilderGetRequestConfiguration)(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ColumnDefinitionCollectionResponseable, error) {
|
||||
requestInfo, err := m.CreateGetRequestInformation(ctx, requestConfiguration);
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings {
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.SendAsync(ctx, requestInfo, ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CreateColumnDefinitionCollectionResponseFromDiscriminatorValue, errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ColumnDefinitionCollectionResponseable), nil
|
||||
func (m *ItemContentTypesItemColumnPositionsRequestBuilder) Get(ctx context.Context, requestConfiguration *ItemContentTypesItemColumnPositionsRequestBuilderGetRequestConfiguration) (ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ColumnDefinitionCollectionResponseable, error) {
|
||||
requestInfo, err := m.CreateGetRequestInformation(ctx, requestConfiguration)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings{
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.Send(ctx, requestInfo, ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CreateColumnDefinitionCollectionResponseFromDiscriminatorValue, errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ColumnDefinitionCollectionResponseable), nil
|
||||
}
|
||||
|
||||
@ -1,167 +1,180 @@
|
||||
package sites
|
||||
|
||||
import (
|
||||
"context"
|
||||
i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f "github.com/microsoft/kiota-abstractions-go"
|
||||
ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models"
|
||||
i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models/odataerrors"
|
||||
"context"
|
||||
|
||||
ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models"
|
||||
i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models/odataerrors"
|
||||
i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f "github.com/microsoft/kiota-abstractions-go"
|
||||
)
|
||||
|
||||
// ItemContentTypesItemColumnsColumnDefinitionItemRequestBuilder provides operations to manage the columns property of the microsoft.graph.contentType entity.
|
||||
type ItemContentTypesItemColumnsColumnDefinitionItemRequestBuilder struct {
|
||||
// Path parameters for the request
|
||||
pathParameters map[string]string
|
||||
// The request adapter to use to execute the requests.
|
||||
requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter
|
||||
// Url template to use to build the URL for the current request builder
|
||||
urlTemplate string
|
||||
// Path parameters for the request
|
||||
pathParameters map[string]string
|
||||
// The request adapter to use to execute the requests.
|
||||
requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter
|
||||
// Url template to use to build the URL for the current request builder
|
||||
urlTemplate string
|
||||
}
|
||||
|
||||
// ItemContentTypesItemColumnsColumnDefinitionItemRequestBuilderDeleteRequestConfiguration configuration for the request such as headers, query parameters, and middleware options.
|
||||
type ItemContentTypesItemColumnsColumnDefinitionItemRequestBuilderDeleteRequestConfiguration struct {
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
}
|
||||
|
||||
// ItemContentTypesItemColumnsColumnDefinitionItemRequestBuilderGetQueryParameters the collection of column definitions for this contentType.
|
||||
type ItemContentTypesItemColumnsColumnDefinitionItemRequestBuilderGetQueryParameters struct {
|
||||
// Expand related entities
|
||||
Expand []string `uriparametername:"%24expand"`
|
||||
// Select properties to be returned
|
||||
Select []string `uriparametername:"%24select"`
|
||||
// Expand related entities
|
||||
Expand []string `uriparametername:"%24expand"`
|
||||
// Select properties to be returned
|
||||
Select []string `uriparametername:"%24select"`
|
||||
}
|
||||
|
||||
// ItemContentTypesItemColumnsColumnDefinitionItemRequestBuilderGetRequestConfiguration configuration for the request such as headers, query parameters, and middleware options.
|
||||
type ItemContentTypesItemColumnsColumnDefinitionItemRequestBuilderGetRequestConfiguration struct {
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
// Request query parameters
|
||||
QueryParameters *ItemContentTypesItemColumnsColumnDefinitionItemRequestBuilderGetQueryParameters
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
// Request query parameters
|
||||
QueryParameters *ItemContentTypesItemColumnsColumnDefinitionItemRequestBuilderGetQueryParameters
|
||||
}
|
||||
|
||||
// ItemContentTypesItemColumnsColumnDefinitionItemRequestBuilderPatchRequestConfiguration configuration for the request such as headers, query parameters, and middleware options.
|
||||
type ItemContentTypesItemColumnsColumnDefinitionItemRequestBuilderPatchRequestConfiguration struct {
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
}
|
||||
|
||||
// NewItemContentTypesItemColumnsColumnDefinitionItemRequestBuilderInternal instantiates a new ColumnDefinitionItemRequestBuilder and sets the default values.
|
||||
func NewItemContentTypesItemColumnsColumnDefinitionItemRequestBuilderInternal(pathParameters map[string]string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemContentTypesItemColumnsColumnDefinitionItemRequestBuilder) {
|
||||
m := &ItemContentTypesItemColumnsColumnDefinitionItemRequestBuilder{
|
||||
}
|
||||
m.urlTemplate = "{+baseurl}/sites/{site%2Did}/contentTypes/{contentType%2Did}/columns/{columnDefinition%2Did}{?%24select,%24expand}";
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
m.pathParameters = urlTplParams;
|
||||
m.requestAdapter = requestAdapter;
|
||||
return m
|
||||
func NewItemContentTypesItemColumnsColumnDefinitionItemRequestBuilderInternal(pathParameters map[string]string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter) *ItemContentTypesItemColumnsColumnDefinitionItemRequestBuilder {
|
||||
m := &ItemContentTypesItemColumnsColumnDefinitionItemRequestBuilder{}
|
||||
m.urlTemplate = "{+baseurl}/sites/{site%2Did}/contentTypes/{contentType%2Did}/columns/{columnDefinition%2Did}{?%24select,%24expand}"
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
m.pathParameters = urlTplParams
|
||||
m.requestAdapter = requestAdapter
|
||||
return m
|
||||
}
|
||||
|
||||
// NewItemContentTypesItemColumnsColumnDefinitionItemRequestBuilder instantiates a new ColumnDefinitionItemRequestBuilder and sets the default values.
|
||||
func NewItemContentTypesItemColumnsColumnDefinitionItemRequestBuilder(rawUrl string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemContentTypesItemColumnsColumnDefinitionItemRequestBuilder) {
|
||||
urlParams := make(map[string]string)
|
||||
urlParams["request-raw-url"] = rawUrl
|
||||
return NewItemContentTypesItemColumnsColumnDefinitionItemRequestBuilderInternal(urlParams, requestAdapter)
|
||||
func NewItemContentTypesItemColumnsColumnDefinitionItemRequestBuilder(rawUrl string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter) *ItemContentTypesItemColumnsColumnDefinitionItemRequestBuilder {
|
||||
urlParams := make(map[string]string)
|
||||
urlParams["request-raw-url"] = rawUrl
|
||||
return NewItemContentTypesItemColumnsColumnDefinitionItemRequestBuilderInternal(urlParams, requestAdapter)
|
||||
}
|
||||
|
||||
// CreateDeleteRequestInformation delete navigation property columns for sites
|
||||
func (m *ItemContentTypesItemColumnsColumnDefinitionItemRequestBuilder) CreateDeleteRequestInformation(ctx context.Context, requestConfiguration *ItemContentTypesItemColumnsColumnDefinitionItemRequestBuilderDeleteRequestConfiguration)(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.DELETE
|
||||
if requestConfiguration != nil {
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
func (m *ItemContentTypesItemColumnsColumnDefinitionItemRequestBuilder) CreateDeleteRequestInformation(ctx context.Context, requestConfiguration *ItemContentTypesItemColumnsColumnDefinitionItemRequestBuilderDeleteRequestConfiguration) (*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.DELETE
|
||||
if requestConfiguration != nil {
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
}
|
||||
|
||||
// CreateGetRequestInformation the collection of column definitions for this contentType.
|
||||
func (m *ItemContentTypesItemColumnsColumnDefinitionItemRequestBuilder) CreateGetRequestInformation(ctx context.Context, requestConfiguration *ItemContentTypesItemColumnsColumnDefinitionItemRequestBuilderGetRequestConfiguration)(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.GET
|
||||
requestInfo.Headers.Add("Accept", "application/json")
|
||||
if requestConfiguration != nil {
|
||||
if requestConfiguration.QueryParameters != nil {
|
||||
requestInfo.AddQueryParameters(*(requestConfiguration.QueryParameters))
|
||||
}
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
func (m *ItemContentTypesItemColumnsColumnDefinitionItemRequestBuilder) CreateGetRequestInformation(ctx context.Context, requestConfiguration *ItemContentTypesItemColumnsColumnDefinitionItemRequestBuilderGetRequestConfiguration) (*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.GET
|
||||
requestInfo.Headers.Add("Accept", "application/json")
|
||||
if requestConfiguration != nil {
|
||||
if requestConfiguration.QueryParameters != nil {
|
||||
requestInfo.AddQueryParameters(*(requestConfiguration.QueryParameters))
|
||||
}
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
}
|
||||
|
||||
// CreatePatchRequestInformation update the navigation property columns in sites
|
||||
func (m *ItemContentTypesItemColumnsColumnDefinitionItemRequestBuilder) CreatePatchRequestInformation(ctx context.Context, body ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ColumnDefinitionable, requestConfiguration *ItemContentTypesItemColumnsColumnDefinitionItemRequestBuilderPatchRequestConfiguration)(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.PATCH
|
||||
requestInfo.Headers.Add("Accept", "application/json")
|
||||
requestInfo.SetContentFromParsable(ctx, m.requestAdapter, "application/json", body)
|
||||
if requestConfiguration != nil {
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
func (m *ItemContentTypesItemColumnsColumnDefinitionItemRequestBuilder) CreatePatchRequestInformation(ctx context.Context, body ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ColumnDefinitionable, requestConfiguration *ItemContentTypesItemColumnsColumnDefinitionItemRequestBuilderPatchRequestConfiguration) (*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.PATCH
|
||||
requestInfo.Headers.Add("Accept", "application/json")
|
||||
requestInfo.SetContentFromParsable(ctx, m.requestAdapter, "application/json", body)
|
||||
if requestConfiguration != nil {
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
}
|
||||
|
||||
// Delete delete navigation property columns for sites
|
||||
func (m *ItemContentTypesItemColumnsColumnDefinitionItemRequestBuilder) Delete(ctx context.Context, requestConfiguration *ItemContentTypesItemColumnsColumnDefinitionItemRequestBuilderDeleteRequestConfiguration)(error) {
|
||||
requestInfo, err := m.CreateDeleteRequestInformation(ctx, requestConfiguration);
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings {
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
err = m.requestAdapter.SendNoContentAsync(ctx, requestInfo, errorMapping)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
return nil
|
||||
func (m *ItemContentTypesItemColumnsColumnDefinitionItemRequestBuilder) Delete(ctx context.Context, requestConfiguration *ItemContentTypesItemColumnsColumnDefinitionItemRequestBuilderDeleteRequestConfiguration) error {
|
||||
requestInfo, err := m.CreateDeleteRequestInformation(ctx, requestConfiguration)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings{
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
err = m.requestAdapter.SendNoContent(ctx, requestInfo, errorMapping)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
// Get the collection of column definitions for this contentType.
|
||||
func (m *ItemContentTypesItemColumnsColumnDefinitionItemRequestBuilder) Get(ctx context.Context, requestConfiguration *ItemContentTypesItemColumnsColumnDefinitionItemRequestBuilderGetRequestConfiguration)(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ColumnDefinitionable, error) {
|
||||
requestInfo, err := m.CreateGetRequestInformation(ctx, requestConfiguration);
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings {
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.SendAsync(ctx, requestInfo, ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CreateColumnDefinitionFromDiscriminatorValue, errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ColumnDefinitionable), nil
|
||||
func (m *ItemContentTypesItemColumnsColumnDefinitionItemRequestBuilder) Get(ctx context.Context, requestConfiguration *ItemContentTypesItemColumnsColumnDefinitionItemRequestBuilderGetRequestConfiguration) (ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ColumnDefinitionable, error) {
|
||||
requestInfo, err := m.CreateGetRequestInformation(ctx, requestConfiguration)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings{
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.Send(ctx, requestInfo, ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CreateColumnDefinitionFromDiscriminatorValue, errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ColumnDefinitionable), nil
|
||||
}
|
||||
|
||||
// Patch update the navigation property columns in sites
|
||||
func (m *ItemContentTypesItemColumnsColumnDefinitionItemRequestBuilder) Patch(ctx context.Context, body ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ColumnDefinitionable, requestConfiguration *ItemContentTypesItemColumnsColumnDefinitionItemRequestBuilderPatchRequestConfiguration)(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ColumnDefinitionable, error) {
|
||||
requestInfo, err := m.CreatePatchRequestInformation(ctx, body, requestConfiguration);
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings {
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.SendAsync(ctx, requestInfo, ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CreateColumnDefinitionFromDiscriminatorValue, errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ColumnDefinitionable), nil
|
||||
func (m *ItemContentTypesItemColumnsColumnDefinitionItemRequestBuilder) Patch(ctx context.Context, body ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ColumnDefinitionable, requestConfiguration *ItemContentTypesItemColumnsColumnDefinitionItemRequestBuilderPatchRequestConfiguration) (ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ColumnDefinitionable, error) {
|
||||
requestInfo, err := m.CreatePatchRequestInformation(ctx, body, requestConfiguration)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings{
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.Send(ctx, requestInfo, ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CreateColumnDefinitionFromDiscriminatorValue, errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ColumnDefinitionable), nil
|
||||
}
|
||||
|
||||
// SourceColumn provides operations to manage the sourceColumn property of the microsoft.graph.columnDefinition entity.
|
||||
func (m *ItemContentTypesItemColumnsColumnDefinitionItemRequestBuilder) SourceColumn()(*ItemContentTypesItemColumnsItemSourceColumnRequestBuilder) {
|
||||
return NewItemContentTypesItemColumnsItemSourceColumnRequestBuilderInternal(m.pathParameters, m.requestAdapter);
|
||||
func (m *ItemContentTypesItemColumnsColumnDefinitionItemRequestBuilder) SourceColumn() *ItemContentTypesItemColumnsItemSourceColumnRequestBuilder {
|
||||
return NewItemContentTypesItemColumnsItemSourceColumnRequestBuilderInternal(m.pathParameters, m.requestAdapter)
|
||||
}
|
||||
|
||||
@ -1,87 +1,93 @@
|
||||
package sites
|
||||
|
||||
import (
|
||||
"context"
|
||||
i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f "github.com/microsoft/kiota-abstractions-go"
|
||||
i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models/odataerrors"
|
||||
"context"
|
||||
|
||||
i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models/odataerrors"
|
||||
i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f "github.com/microsoft/kiota-abstractions-go"
|
||||
)
|
||||
|
||||
// ItemContentTypesItemColumnsCountRequestBuilder provides operations to count the resources in the collection.
|
||||
type ItemContentTypesItemColumnsCountRequestBuilder struct {
|
||||
// Path parameters for the request
|
||||
pathParameters map[string]string
|
||||
// The request adapter to use to execute the requests.
|
||||
requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter
|
||||
// Url template to use to build the URL for the current request builder
|
||||
urlTemplate string
|
||||
// Path parameters for the request
|
||||
pathParameters map[string]string
|
||||
// The request adapter to use to execute the requests.
|
||||
requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter
|
||||
// Url template to use to build the URL for the current request builder
|
||||
urlTemplate string
|
||||
}
|
||||
|
||||
// ItemContentTypesItemColumnsCountRequestBuilderGetQueryParameters get the number of the resource
|
||||
type ItemContentTypesItemColumnsCountRequestBuilderGetQueryParameters struct {
|
||||
// Filter items by property values
|
||||
Filter *string `uriparametername:"%24filter"`
|
||||
// Search items by search phrases
|
||||
Search *string `uriparametername:"%24search"`
|
||||
// Filter items by property values
|
||||
Filter *string `uriparametername:"%24filter"`
|
||||
// Search items by search phrases
|
||||
Search *string `uriparametername:"%24search"`
|
||||
}
|
||||
|
||||
// ItemContentTypesItemColumnsCountRequestBuilderGetRequestConfiguration configuration for the request such as headers, query parameters, and middleware options.
|
||||
type ItemContentTypesItemColumnsCountRequestBuilderGetRequestConfiguration struct {
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
// Request query parameters
|
||||
QueryParameters *ItemContentTypesItemColumnsCountRequestBuilderGetQueryParameters
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
// Request query parameters
|
||||
QueryParameters *ItemContentTypesItemColumnsCountRequestBuilderGetQueryParameters
|
||||
}
|
||||
|
||||
// NewItemContentTypesItemColumnsCountRequestBuilderInternal instantiates a new CountRequestBuilder and sets the default values.
|
||||
func NewItemContentTypesItemColumnsCountRequestBuilderInternal(pathParameters map[string]string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemContentTypesItemColumnsCountRequestBuilder) {
|
||||
m := &ItemContentTypesItemColumnsCountRequestBuilder{
|
||||
}
|
||||
m.urlTemplate = "{+baseurl}/sites/{site%2Did}/contentTypes/{contentType%2Did}/columns/$count{?%24search,%24filter}";
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
m.pathParameters = urlTplParams;
|
||||
m.requestAdapter = requestAdapter;
|
||||
return m
|
||||
func NewItemContentTypesItemColumnsCountRequestBuilderInternal(pathParameters map[string]string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter) *ItemContentTypesItemColumnsCountRequestBuilder {
|
||||
m := &ItemContentTypesItemColumnsCountRequestBuilder{}
|
||||
m.urlTemplate = "{+baseurl}/sites/{site%2Did}/contentTypes/{contentType%2Did}/columns/$count{?%24search,%24filter}"
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
m.pathParameters = urlTplParams
|
||||
m.requestAdapter = requestAdapter
|
||||
return m
|
||||
}
|
||||
|
||||
// NewItemContentTypesItemColumnsCountRequestBuilder instantiates a new CountRequestBuilder and sets the default values.
|
||||
func NewItemContentTypesItemColumnsCountRequestBuilder(rawUrl string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemContentTypesItemColumnsCountRequestBuilder) {
|
||||
urlParams := make(map[string]string)
|
||||
urlParams["request-raw-url"] = rawUrl
|
||||
return NewItemContentTypesItemColumnsCountRequestBuilderInternal(urlParams, requestAdapter)
|
||||
func NewItemContentTypesItemColumnsCountRequestBuilder(rawUrl string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter) *ItemContentTypesItemColumnsCountRequestBuilder {
|
||||
urlParams := make(map[string]string)
|
||||
urlParams["request-raw-url"] = rawUrl
|
||||
return NewItemContentTypesItemColumnsCountRequestBuilderInternal(urlParams, requestAdapter)
|
||||
}
|
||||
|
||||
// CreateGetRequestInformation get the number of the resource
|
||||
func (m *ItemContentTypesItemColumnsCountRequestBuilder) CreateGetRequestInformation(ctx context.Context, requestConfiguration *ItemContentTypesItemColumnsCountRequestBuilderGetRequestConfiguration)(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.GET
|
||||
requestInfo.Headers.Add("Accept", "text/plain")
|
||||
if requestConfiguration != nil {
|
||||
if requestConfiguration.QueryParameters != nil {
|
||||
requestInfo.AddQueryParameters(*(requestConfiguration.QueryParameters))
|
||||
}
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
func (m *ItemContentTypesItemColumnsCountRequestBuilder) CreateGetRequestInformation(ctx context.Context, requestConfiguration *ItemContentTypesItemColumnsCountRequestBuilderGetRequestConfiguration) (*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.GET
|
||||
requestInfo.Headers.Add("Accept", "text/plain")
|
||||
if requestConfiguration != nil {
|
||||
if requestConfiguration.QueryParameters != nil {
|
||||
requestInfo.AddQueryParameters(*(requestConfiguration.QueryParameters))
|
||||
}
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
}
|
||||
|
||||
// Get get the number of the resource
|
||||
func (m *ItemContentTypesItemColumnsCountRequestBuilder) Get(ctx context.Context, requestConfiguration *ItemContentTypesItemColumnsCountRequestBuilderGetRequestConfiguration)(*int32, error) {
|
||||
requestInfo, err := m.CreateGetRequestInformation(ctx, requestConfiguration);
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings {
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.SendPrimitiveAsync(ctx, requestInfo, "int32", errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(*int32), nil
|
||||
func (m *ItemContentTypesItemColumnsCountRequestBuilder) Get(ctx context.Context, requestConfiguration *ItemContentTypesItemColumnsCountRequestBuilderGetRequestConfiguration) (*int32, error) {
|
||||
requestInfo, err := m.CreateGetRequestInformation(ctx, requestConfiguration)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings{
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.SendPrimitive(ctx, requestInfo, "int32", errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(*int32), nil
|
||||
}
|
||||
|
||||
@ -1,88 +1,94 @@
|
||||
package sites
|
||||
|
||||
import (
|
||||
"context"
|
||||
i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f "github.com/microsoft/kiota-abstractions-go"
|
||||
ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models"
|
||||
i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models/odataerrors"
|
||||
"context"
|
||||
|
||||
ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models"
|
||||
i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models/odataerrors"
|
||||
i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f "github.com/microsoft/kiota-abstractions-go"
|
||||
)
|
||||
|
||||
// ItemContentTypesItemColumnsItemSourceColumnRequestBuilder provides operations to manage the sourceColumn property of the microsoft.graph.columnDefinition entity.
|
||||
type ItemContentTypesItemColumnsItemSourceColumnRequestBuilder struct {
|
||||
// Path parameters for the request
|
||||
pathParameters map[string]string
|
||||
// The request adapter to use to execute the requests.
|
||||
requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter
|
||||
// Url template to use to build the URL for the current request builder
|
||||
urlTemplate string
|
||||
// Path parameters for the request
|
||||
pathParameters map[string]string
|
||||
// The request adapter to use to execute the requests.
|
||||
requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter
|
||||
// Url template to use to build the URL for the current request builder
|
||||
urlTemplate string
|
||||
}
|
||||
|
||||
// ItemContentTypesItemColumnsItemSourceColumnRequestBuilderGetQueryParameters the source column for content type column.
|
||||
type ItemContentTypesItemColumnsItemSourceColumnRequestBuilderGetQueryParameters struct {
|
||||
// Expand related entities
|
||||
Expand []string `uriparametername:"%24expand"`
|
||||
// Select properties to be returned
|
||||
Select []string `uriparametername:"%24select"`
|
||||
// Expand related entities
|
||||
Expand []string `uriparametername:"%24expand"`
|
||||
// Select properties to be returned
|
||||
Select []string `uriparametername:"%24select"`
|
||||
}
|
||||
|
||||
// ItemContentTypesItemColumnsItemSourceColumnRequestBuilderGetRequestConfiguration configuration for the request such as headers, query parameters, and middleware options.
|
||||
type ItemContentTypesItemColumnsItemSourceColumnRequestBuilderGetRequestConfiguration struct {
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
// Request query parameters
|
||||
QueryParameters *ItemContentTypesItemColumnsItemSourceColumnRequestBuilderGetQueryParameters
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
// Request query parameters
|
||||
QueryParameters *ItemContentTypesItemColumnsItemSourceColumnRequestBuilderGetQueryParameters
|
||||
}
|
||||
|
||||
// NewItemContentTypesItemColumnsItemSourceColumnRequestBuilderInternal instantiates a new SourceColumnRequestBuilder and sets the default values.
|
||||
func NewItemContentTypesItemColumnsItemSourceColumnRequestBuilderInternal(pathParameters map[string]string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemContentTypesItemColumnsItemSourceColumnRequestBuilder) {
|
||||
m := &ItemContentTypesItemColumnsItemSourceColumnRequestBuilder{
|
||||
}
|
||||
m.urlTemplate = "{+baseurl}/sites/{site%2Did}/contentTypes/{contentType%2Did}/columns/{columnDefinition%2Did}/sourceColumn{?%24select,%24expand}";
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
m.pathParameters = urlTplParams;
|
||||
m.requestAdapter = requestAdapter;
|
||||
return m
|
||||
func NewItemContentTypesItemColumnsItemSourceColumnRequestBuilderInternal(pathParameters map[string]string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter) *ItemContentTypesItemColumnsItemSourceColumnRequestBuilder {
|
||||
m := &ItemContentTypesItemColumnsItemSourceColumnRequestBuilder{}
|
||||
m.urlTemplate = "{+baseurl}/sites/{site%2Did}/contentTypes/{contentType%2Did}/columns/{columnDefinition%2Did}/sourceColumn{?%24select,%24expand}"
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
m.pathParameters = urlTplParams
|
||||
m.requestAdapter = requestAdapter
|
||||
return m
|
||||
}
|
||||
|
||||
// NewItemContentTypesItemColumnsItemSourceColumnRequestBuilder instantiates a new SourceColumnRequestBuilder and sets the default values.
|
||||
func NewItemContentTypesItemColumnsItemSourceColumnRequestBuilder(rawUrl string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemContentTypesItemColumnsItemSourceColumnRequestBuilder) {
|
||||
urlParams := make(map[string]string)
|
||||
urlParams["request-raw-url"] = rawUrl
|
||||
return NewItemContentTypesItemColumnsItemSourceColumnRequestBuilderInternal(urlParams, requestAdapter)
|
||||
func NewItemContentTypesItemColumnsItemSourceColumnRequestBuilder(rawUrl string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter) *ItemContentTypesItemColumnsItemSourceColumnRequestBuilder {
|
||||
urlParams := make(map[string]string)
|
||||
urlParams["request-raw-url"] = rawUrl
|
||||
return NewItemContentTypesItemColumnsItemSourceColumnRequestBuilderInternal(urlParams, requestAdapter)
|
||||
}
|
||||
|
||||
// CreateGetRequestInformation the source column for content type column.
|
||||
func (m *ItemContentTypesItemColumnsItemSourceColumnRequestBuilder) CreateGetRequestInformation(ctx context.Context, requestConfiguration *ItemContentTypesItemColumnsItemSourceColumnRequestBuilderGetRequestConfiguration)(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.GET
|
||||
requestInfo.Headers.Add("Accept", "application/json")
|
||||
if requestConfiguration != nil {
|
||||
if requestConfiguration.QueryParameters != nil {
|
||||
requestInfo.AddQueryParameters(*(requestConfiguration.QueryParameters))
|
||||
}
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
func (m *ItemContentTypesItemColumnsItemSourceColumnRequestBuilder) CreateGetRequestInformation(ctx context.Context, requestConfiguration *ItemContentTypesItemColumnsItemSourceColumnRequestBuilderGetRequestConfiguration) (*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.GET
|
||||
requestInfo.Headers.Add("Accept", "application/json")
|
||||
if requestConfiguration != nil {
|
||||
if requestConfiguration.QueryParameters != nil {
|
||||
requestInfo.AddQueryParameters(*(requestConfiguration.QueryParameters))
|
||||
}
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
}
|
||||
|
||||
// Get the source column for content type column.
|
||||
func (m *ItemContentTypesItemColumnsItemSourceColumnRequestBuilder) Get(ctx context.Context, requestConfiguration *ItemContentTypesItemColumnsItemSourceColumnRequestBuilderGetRequestConfiguration)(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ColumnDefinitionable, error) {
|
||||
requestInfo, err := m.CreateGetRequestInformation(ctx, requestConfiguration);
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings {
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.SendAsync(ctx, requestInfo, ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CreateColumnDefinitionFromDiscriminatorValue, errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ColumnDefinitionable), nil
|
||||
func (m *ItemContentTypesItemColumnsItemSourceColumnRequestBuilder) Get(ctx context.Context, requestConfiguration *ItemContentTypesItemColumnsItemSourceColumnRequestBuilderGetRequestConfiguration) (ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ColumnDefinitionable, error) {
|
||||
requestInfo, err := m.CreateGetRequestInformation(ctx, requestConfiguration)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings{
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.Send(ctx, requestInfo, ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CreateColumnDefinitionFromDiscriminatorValue, errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ColumnDefinitionable), nil
|
||||
}
|
||||
|
||||
@ -1,150 +1,160 @@
|
||||
package sites
|
||||
|
||||
import (
|
||||
"context"
|
||||
i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f "github.com/microsoft/kiota-abstractions-go"
|
||||
ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models"
|
||||
i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models/odataerrors"
|
||||
"context"
|
||||
|
||||
ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models"
|
||||
i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models/odataerrors"
|
||||
i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f "github.com/microsoft/kiota-abstractions-go"
|
||||
)
|
||||
|
||||
// ItemContentTypesItemColumnsRequestBuilder provides operations to manage the columns property of the microsoft.graph.contentType entity.
|
||||
type ItemContentTypesItemColumnsRequestBuilder struct {
|
||||
// Path parameters for the request
|
||||
pathParameters map[string]string
|
||||
// The request adapter to use to execute the requests.
|
||||
requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter
|
||||
// Url template to use to build the URL for the current request builder
|
||||
urlTemplate string
|
||||
// Path parameters for the request
|
||||
pathParameters map[string]string
|
||||
// The request adapter to use to execute the requests.
|
||||
requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter
|
||||
// Url template to use to build the URL for the current request builder
|
||||
urlTemplate string
|
||||
}
|
||||
|
||||
// ItemContentTypesItemColumnsRequestBuilderGetQueryParameters get the collection of columns, represented as [columnDefinition][columnDefinition] resources, in a [content type][contentType].
|
||||
type ItemContentTypesItemColumnsRequestBuilderGetQueryParameters struct {
|
||||
// Include count of items
|
||||
Count *bool `uriparametername:"%24count"`
|
||||
// Expand related entities
|
||||
Expand []string `uriparametername:"%24expand"`
|
||||
// Filter items by property values
|
||||
Filter *string `uriparametername:"%24filter"`
|
||||
// Order items by property values
|
||||
Orderby []string `uriparametername:"%24orderby"`
|
||||
// Search items by search phrases
|
||||
Search *string `uriparametername:"%24search"`
|
||||
// Select properties to be returned
|
||||
Select []string `uriparametername:"%24select"`
|
||||
// Skip the first n items
|
||||
Skip *int32 `uriparametername:"%24skip"`
|
||||
// Show only the first n items
|
||||
Top *int32 `uriparametername:"%24top"`
|
||||
// Include count of items
|
||||
Count *bool `uriparametername:"%24count"`
|
||||
// Expand related entities
|
||||
Expand []string `uriparametername:"%24expand"`
|
||||
// Filter items by property values
|
||||
Filter *string `uriparametername:"%24filter"`
|
||||
// Order items by property values
|
||||
Orderby []string `uriparametername:"%24orderby"`
|
||||
// Search items by search phrases
|
||||
Search *string `uriparametername:"%24search"`
|
||||
// Select properties to be returned
|
||||
Select []string `uriparametername:"%24select"`
|
||||
// Skip the first n items
|
||||
Skip *int32 `uriparametername:"%24skip"`
|
||||
// Show only the first n items
|
||||
Top *int32 `uriparametername:"%24top"`
|
||||
}
|
||||
|
||||
// ItemContentTypesItemColumnsRequestBuilderGetRequestConfiguration configuration for the request such as headers, query parameters, and middleware options.
|
||||
type ItemContentTypesItemColumnsRequestBuilderGetRequestConfiguration struct {
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
// Request query parameters
|
||||
QueryParameters *ItemContentTypesItemColumnsRequestBuilderGetQueryParameters
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
// Request query parameters
|
||||
QueryParameters *ItemContentTypesItemColumnsRequestBuilderGetQueryParameters
|
||||
}
|
||||
|
||||
// ItemContentTypesItemColumnsRequestBuilderPostRequestConfiguration configuration for the request such as headers, query parameters, and middleware options.
|
||||
type ItemContentTypesItemColumnsRequestBuilderPostRequestConfiguration struct {
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
}
|
||||
|
||||
// NewItemContentTypesItemColumnsRequestBuilderInternal instantiates a new ColumnsRequestBuilder and sets the default values.
|
||||
func NewItemContentTypesItemColumnsRequestBuilderInternal(pathParameters map[string]string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemContentTypesItemColumnsRequestBuilder) {
|
||||
m := &ItemContentTypesItemColumnsRequestBuilder{
|
||||
}
|
||||
m.urlTemplate = "{+baseurl}/sites/{site%2Did}/contentTypes/{contentType%2Did}/columns{?%24top,%24skip,%24search,%24filter,%24count,%24orderby,%24select,%24expand}";
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
m.pathParameters = urlTplParams;
|
||||
m.requestAdapter = requestAdapter;
|
||||
return m
|
||||
func NewItemContentTypesItemColumnsRequestBuilderInternal(pathParameters map[string]string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter) *ItemContentTypesItemColumnsRequestBuilder {
|
||||
m := &ItemContentTypesItemColumnsRequestBuilder{}
|
||||
m.urlTemplate = "{+baseurl}/sites/{site%2Did}/contentTypes/{contentType%2Did}/columns{?%24top,%24skip,%24search,%24filter,%24count,%24orderby,%24select,%24expand}"
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
m.pathParameters = urlTplParams
|
||||
m.requestAdapter = requestAdapter
|
||||
return m
|
||||
}
|
||||
|
||||
// NewItemContentTypesItemColumnsRequestBuilder instantiates a new ColumnsRequestBuilder and sets the default values.
|
||||
func NewItemContentTypesItemColumnsRequestBuilder(rawUrl string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemContentTypesItemColumnsRequestBuilder) {
|
||||
urlParams := make(map[string]string)
|
||||
urlParams["request-raw-url"] = rawUrl
|
||||
return NewItemContentTypesItemColumnsRequestBuilderInternal(urlParams, requestAdapter)
|
||||
func NewItemContentTypesItemColumnsRequestBuilder(rawUrl string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter) *ItemContentTypesItemColumnsRequestBuilder {
|
||||
urlParams := make(map[string]string)
|
||||
urlParams["request-raw-url"] = rawUrl
|
||||
return NewItemContentTypesItemColumnsRequestBuilderInternal(urlParams, requestAdapter)
|
||||
}
|
||||
|
||||
// Count provides operations to count the resources in the collection.
|
||||
func (m *ItemContentTypesItemColumnsRequestBuilder) Count()(*ItemContentTypesItemColumnsCountRequestBuilder) {
|
||||
return NewItemContentTypesItemColumnsCountRequestBuilderInternal(m.pathParameters, m.requestAdapter);
|
||||
func (m *ItemContentTypesItemColumnsRequestBuilder) Count() *ItemContentTypesItemColumnsCountRequestBuilder {
|
||||
return NewItemContentTypesItemColumnsCountRequestBuilderInternal(m.pathParameters, m.requestAdapter)
|
||||
}
|
||||
|
||||
// CreateGetRequestInformation get the collection of columns, represented as [columnDefinition][columnDefinition] resources, in a [content type][contentType].
|
||||
func (m *ItemContentTypesItemColumnsRequestBuilder) CreateGetRequestInformation(ctx context.Context, requestConfiguration *ItemContentTypesItemColumnsRequestBuilderGetRequestConfiguration)(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.GET
|
||||
requestInfo.Headers.Add("Accept", "application/json")
|
||||
if requestConfiguration != nil {
|
||||
if requestConfiguration.QueryParameters != nil {
|
||||
requestInfo.AddQueryParameters(*(requestConfiguration.QueryParameters))
|
||||
}
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
func (m *ItemContentTypesItemColumnsRequestBuilder) CreateGetRequestInformation(ctx context.Context, requestConfiguration *ItemContentTypesItemColumnsRequestBuilderGetRequestConfiguration) (*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.GET
|
||||
requestInfo.Headers.Add("Accept", "application/json")
|
||||
if requestConfiguration != nil {
|
||||
if requestConfiguration.QueryParameters != nil {
|
||||
requestInfo.AddQueryParameters(*(requestConfiguration.QueryParameters))
|
||||
}
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
}
|
||||
|
||||
// CreatePostRequestInformation add a column to a [content type][contentType] in a site or list by specifying a [columnDefinition][columnDefinition].
|
||||
func (m *ItemContentTypesItemColumnsRequestBuilder) CreatePostRequestInformation(ctx context.Context, body ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ColumnDefinitionable, requestConfiguration *ItemContentTypesItemColumnsRequestBuilderPostRequestConfiguration)(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.POST
|
||||
requestInfo.Headers.Add("Accept", "application/json")
|
||||
requestInfo.SetContentFromParsable(ctx, m.requestAdapter, "application/json", body)
|
||||
if requestConfiguration != nil {
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
func (m *ItemContentTypesItemColumnsRequestBuilder) CreatePostRequestInformation(ctx context.Context, body ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ColumnDefinitionable, requestConfiguration *ItemContentTypesItemColumnsRequestBuilderPostRequestConfiguration) (*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.POST
|
||||
requestInfo.Headers.Add("Accept", "application/json")
|
||||
requestInfo.SetContentFromParsable(ctx, m.requestAdapter, "application/json", body)
|
||||
if requestConfiguration != nil {
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
}
|
||||
|
||||
// Get get the collection of columns, represented as [columnDefinition][columnDefinition] resources, in a [content type][contentType].
|
||||
// [Find more info here]
|
||||
//
|
||||
//
|
||||
// [Find more info here]: https://docs.microsoft.com/graph/api/contenttype-list-columns?view=graph-rest-1.0
|
||||
func (m *ItemContentTypesItemColumnsRequestBuilder) Get(ctx context.Context, requestConfiguration *ItemContentTypesItemColumnsRequestBuilderGetRequestConfiguration)(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ColumnDefinitionCollectionResponseable, error) {
|
||||
requestInfo, err := m.CreateGetRequestInformation(ctx, requestConfiguration);
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings {
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.SendAsync(ctx, requestInfo, ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CreateColumnDefinitionCollectionResponseFromDiscriminatorValue, errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ColumnDefinitionCollectionResponseable), nil
|
||||
func (m *ItemContentTypesItemColumnsRequestBuilder) Get(ctx context.Context, requestConfiguration *ItemContentTypesItemColumnsRequestBuilderGetRequestConfiguration) (ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ColumnDefinitionCollectionResponseable, error) {
|
||||
requestInfo, err := m.CreateGetRequestInformation(ctx, requestConfiguration)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings{
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.Send(ctx, requestInfo, ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CreateColumnDefinitionCollectionResponseFromDiscriminatorValue, errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ColumnDefinitionCollectionResponseable), nil
|
||||
}
|
||||
|
||||
// Post add a column to a [content type][contentType] in a site or list by specifying a [columnDefinition][columnDefinition].
|
||||
// [Find more info here]
|
||||
//
|
||||
//
|
||||
// [Find more info here]: https://docs.microsoft.com/graph/api/contenttype-post-columns?view=graph-rest-1.0
|
||||
func (m *ItemContentTypesItemColumnsRequestBuilder) Post(ctx context.Context, body ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ColumnDefinitionable, requestConfiguration *ItemContentTypesItemColumnsRequestBuilderPostRequestConfiguration)(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ColumnDefinitionable, error) {
|
||||
requestInfo, err := m.CreatePostRequestInformation(ctx, body, requestConfiguration);
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings {
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.SendAsync(ctx, requestInfo, ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CreateColumnDefinitionFromDiscriminatorValue, errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ColumnDefinitionable), nil
|
||||
func (m *ItemContentTypesItemColumnsRequestBuilder) Post(ctx context.Context, body ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ColumnDefinitionable, requestConfiguration *ItemContentTypesItemColumnsRequestBuilderPostRequestConfiguration) (ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ColumnDefinitionable, error) {
|
||||
requestInfo, err := m.CreatePostRequestInformation(ctx, body, requestConfiguration)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings{
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.Send(ctx, requestInfo, ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CreateColumnDefinitionFromDiscriminatorValue, errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ColumnDefinitionable), nil
|
||||
}
|
||||
|
||||
@ -1,75 +1,80 @@
|
||||
package sites
|
||||
|
||||
import (
|
||||
"context"
|
||||
i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f "github.com/microsoft/kiota-abstractions-go"
|
||||
i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models/odataerrors"
|
||||
"context"
|
||||
|
||||
i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models/odataerrors"
|
||||
i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f "github.com/microsoft/kiota-abstractions-go"
|
||||
)
|
||||
|
||||
// ItemContentTypesItemCopyToDefaultContentLocationRequestBuilder provides operations to call the copyToDefaultContentLocation method.
|
||||
type ItemContentTypesItemCopyToDefaultContentLocationRequestBuilder struct {
|
||||
// Path parameters for the request
|
||||
pathParameters map[string]string
|
||||
// The request adapter to use to execute the requests.
|
||||
requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter
|
||||
// Url template to use to build the URL for the current request builder
|
||||
urlTemplate string
|
||||
// Path parameters for the request
|
||||
pathParameters map[string]string
|
||||
// The request adapter to use to execute the requests.
|
||||
requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter
|
||||
// Url template to use to build the URL for the current request builder
|
||||
urlTemplate string
|
||||
}
|
||||
|
||||
// ItemContentTypesItemCopyToDefaultContentLocationRequestBuilderPostRequestConfiguration configuration for the request such as headers, query parameters, and middleware options.
|
||||
type ItemContentTypesItemCopyToDefaultContentLocationRequestBuilderPostRequestConfiguration struct {
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
}
|
||||
|
||||
// NewItemContentTypesItemCopyToDefaultContentLocationRequestBuilderInternal instantiates a new CopyToDefaultContentLocationRequestBuilder and sets the default values.
|
||||
func NewItemContentTypesItemCopyToDefaultContentLocationRequestBuilderInternal(pathParameters map[string]string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemContentTypesItemCopyToDefaultContentLocationRequestBuilder) {
|
||||
m := &ItemContentTypesItemCopyToDefaultContentLocationRequestBuilder{
|
||||
}
|
||||
m.urlTemplate = "{+baseurl}/sites/{site%2Did}/contentTypes/{contentType%2Did}/microsoft.graph.copyToDefaultContentLocation";
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
m.pathParameters = urlTplParams;
|
||||
m.requestAdapter = requestAdapter;
|
||||
return m
|
||||
func NewItemContentTypesItemCopyToDefaultContentLocationRequestBuilderInternal(pathParameters map[string]string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter) *ItemContentTypesItemCopyToDefaultContentLocationRequestBuilder {
|
||||
m := &ItemContentTypesItemCopyToDefaultContentLocationRequestBuilder{}
|
||||
m.urlTemplate = "{+baseurl}/sites/{site%2Did}/contentTypes/{contentType%2Did}/microsoft.graph.copyToDefaultContentLocation"
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
m.pathParameters = urlTplParams
|
||||
m.requestAdapter = requestAdapter
|
||||
return m
|
||||
}
|
||||
|
||||
// NewItemContentTypesItemCopyToDefaultContentLocationRequestBuilder instantiates a new CopyToDefaultContentLocationRequestBuilder and sets the default values.
|
||||
func NewItemContentTypesItemCopyToDefaultContentLocationRequestBuilder(rawUrl string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemContentTypesItemCopyToDefaultContentLocationRequestBuilder) {
|
||||
urlParams := make(map[string]string)
|
||||
urlParams["request-raw-url"] = rawUrl
|
||||
return NewItemContentTypesItemCopyToDefaultContentLocationRequestBuilderInternal(urlParams, requestAdapter)
|
||||
func NewItemContentTypesItemCopyToDefaultContentLocationRequestBuilder(rawUrl string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter) *ItemContentTypesItemCopyToDefaultContentLocationRequestBuilder {
|
||||
urlParams := make(map[string]string)
|
||||
urlParams["request-raw-url"] = rawUrl
|
||||
return NewItemContentTypesItemCopyToDefaultContentLocationRequestBuilderInternal(urlParams, requestAdapter)
|
||||
}
|
||||
|
||||
// CreatePostRequestInformation copy a file to a default content location in a [content type][contentType]. The file can then be added as a default file or template via a POST operation.
|
||||
func (m *ItemContentTypesItemCopyToDefaultContentLocationRequestBuilder) CreatePostRequestInformation(ctx context.Context, body ItemContentTypesItemCopyToDefaultContentLocationPostRequestBodyable, requestConfiguration *ItemContentTypesItemCopyToDefaultContentLocationRequestBuilderPostRequestConfiguration)(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.POST
|
||||
requestInfo.SetContentFromParsable(ctx, m.requestAdapter, "application/json", body)
|
||||
if requestConfiguration != nil {
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
func (m *ItemContentTypesItemCopyToDefaultContentLocationRequestBuilder) CreatePostRequestInformation(ctx context.Context, body ItemContentTypesItemCopyToDefaultContentLocationPostRequestBodyable, requestConfiguration *ItemContentTypesItemCopyToDefaultContentLocationRequestBuilderPostRequestConfiguration) (*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.POST
|
||||
requestInfo.SetContentFromParsable(ctx, m.requestAdapter, "application/json", body)
|
||||
if requestConfiguration != nil {
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
}
|
||||
|
||||
// Post copy a file to a default content location in a [content type][contentType]. The file can then be added as a default file or template via a POST operation.
|
||||
// [Find more info here]
|
||||
//
|
||||
//
|
||||
// [Find more info here]: https://docs.microsoft.com/graph/api/contenttype-copytodefaultcontentlocation?view=graph-rest-1.0
|
||||
func (m *ItemContentTypesItemCopyToDefaultContentLocationRequestBuilder) Post(ctx context.Context, body ItemContentTypesItemCopyToDefaultContentLocationPostRequestBodyable, requestConfiguration *ItemContentTypesItemCopyToDefaultContentLocationRequestBuilderPostRequestConfiguration)(error) {
|
||||
requestInfo, err := m.CreatePostRequestInformation(ctx, body, requestConfiguration);
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings {
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
err = m.requestAdapter.SendNoContentAsync(ctx, requestInfo, errorMapping)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
return nil
|
||||
func (m *ItemContentTypesItemCopyToDefaultContentLocationRequestBuilder) Post(ctx context.Context, body ItemContentTypesItemCopyToDefaultContentLocationPostRequestBodyable, requestConfiguration *ItemContentTypesItemCopyToDefaultContentLocationRequestBuilderPostRequestConfiguration) error {
|
||||
requestInfo, err := m.CreatePostRequestInformation(ctx, body, requestConfiguration)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings{
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
err = m.requestAdapter.SendNoContent(ctx, requestInfo, errorMapping)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
@ -1,75 +1,80 @@
|
||||
package sites
|
||||
|
||||
import (
|
||||
"context"
|
||||
i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f "github.com/microsoft/kiota-abstractions-go"
|
||||
i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models/odataerrors"
|
||||
"context"
|
||||
|
||||
i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models/odataerrors"
|
||||
i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f "github.com/microsoft/kiota-abstractions-go"
|
||||
)
|
||||
|
||||
// ItemContentTypesItemIsPublishedRequestBuilder provides operations to call the isPublished method.
|
||||
type ItemContentTypesItemIsPublishedRequestBuilder struct {
|
||||
// Path parameters for the request
|
||||
pathParameters map[string]string
|
||||
// The request adapter to use to execute the requests.
|
||||
requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter
|
||||
// Url template to use to build the URL for the current request builder
|
||||
urlTemplate string
|
||||
// Path parameters for the request
|
||||
pathParameters map[string]string
|
||||
// The request adapter to use to execute the requests.
|
||||
requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter
|
||||
// Url template to use to build the URL for the current request builder
|
||||
urlTemplate string
|
||||
}
|
||||
|
||||
// ItemContentTypesItemIsPublishedRequestBuilderGetRequestConfiguration configuration for the request such as headers, query parameters, and middleware options.
|
||||
type ItemContentTypesItemIsPublishedRequestBuilderGetRequestConfiguration struct {
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
}
|
||||
|
||||
// NewItemContentTypesItemIsPublishedRequestBuilderInternal instantiates a new IsPublishedRequestBuilder and sets the default values.
|
||||
func NewItemContentTypesItemIsPublishedRequestBuilderInternal(pathParameters map[string]string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemContentTypesItemIsPublishedRequestBuilder) {
|
||||
m := &ItemContentTypesItemIsPublishedRequestBuilder{
|
||||
}
|
||||
m.urlTemplate = "{+baseurl}/sites/{site%2Did}/contentTypes/{contentType%2Did}/microsoft.graph.isPublished()";
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
m.pathParameters = urlTplParams;
|
||||
m.requestAdapter = requestAdapter;
|
||||
return m
|
||||
func NewItemContentTypesItemIsPublishedRequestBuilderInternal(pathParameters map[string]string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter) *ItemContentTypesItemIsPublishedRequestBuilder {
|
||||
m := &ItemContentTypesItemIsPublishedRequestBuilder{}
|
||||
m.urlTemplate = "{+baseurl}/sites/{site%2Did}/contentTypes/{contentType%2Did}/microsoft.graph.isPublished()"
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
m.pathParameters = urlTplParams
|
||||
m.requestAdapter = requestAdapter
|
||||
return m
|
||||
}
|
||||
|
||||
// NewItemContentTypesItemIsPublishedRequestBuilder instantiates a new IsPublishedRequestBuilder and sets the default values.
|
||||
func NewItemContentTypesItemIsPublishedRequestBuilder(rawUrl string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemContentTypesItemIsPublishedRequestBuilder) {
|
||||
urlParams := make(map[string]string)
|
||||
urlParams["request-raw-url"] = rawUrl
|
||||
return NewItemContentTypesItemIsPublishedRequestBuilderInternal(urlParams, requestAdapter)
|
||||
func NewItemContentTypesItemIsPublishedRequestBuilder(rawUrl string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter) *ItemContentTypesItemIsPublishedRequestBuilder {
|
||||
urlParams := make(map[string]string)
|
||||
urlParams["request-raw-url"] = rawUrl
|
||||
return NewItemContentTypesItemIsPublishedRequestBuilderInternal(urlParams, requestAdapter)
|
||||
}
|
||||
|
||||
// CreateGetRequestInformation invoke function isPublished
|
||||
func (m *ItemContentTypesItemIsPublishedRequestBuilder) CreateGetRequestInformation(ctx context.Context, requestConfiguration *ItemContentTypesItemIsPublishedRequestBuilderGetRequestConfiguration)(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.GET
|
||||
requestInfo.Headers.Add("Accept", "application/json")
|
||||
if requestConfiguration != nil {
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
func (m *ItemContentTypesItemIsPublishedRequestBuilder) CreateGetRequestInformation(ctx context.Context, requestConfiguration *ItemContentTypesItemIsPublishedRequestBuilderGetRequestConfiguration) (*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.GET
|
||||
requestInfo.Headers.Add("Accept", "application/json")
|
||||
if requestConfiguration != nil {
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
}
|
||||
|
||||
// Get invoke function isPublished
|
||||
func (m *ItemContentTypesItemIsPublishedRequestBuilder) Get(ctx context.Context, requestConfiguration *ItemContentTypesItemIsPublishedRequestBuilderGetRequestConfiguration)(ItemContentTypesItemIsPublishedResponseable, error) {
|
||||
requestInfo, err := m.CreateGetRequestInformation(ctx, requestConfiguration);
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings {
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.SendAsync(ctx, requestInfo, CreateItemContentTypesItemIsPublishedResponseFromDiscriminatorValue, errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(ItemContentTypesItemIsPublishedResponseable), nil
|
||||
func (m *ItemContentTypesItemIsPublishedRequestBuilder) Get(ctx context.Context, requestConfiguration *ItemContentTypesItemIsPublishedRequestBuilderGetRequestConfiguration) (ItemContentTypesItemIsPublishedResponseable, error) {
|
||||
requestInfo, err := m.CreateGetRequestInformation(ctx, requestConfiguration)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings{
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.Send(ctx, requestInfo, CreateItemContentTypesItemIsPublishedResponseFromDiscriminatorValue, errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(ItemContentTypesItemIsPublishedResponseable), nil
|
||||
}
|
||||
|
||||
@ -1,74 +1,79 @@
|
||||
package sites
|
||||
|
||||
import (
|
||||
"context"
|
||||
i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f "github.com/microsoft/kiota-abstractions-go"
|
||||
i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models/odataerrors"
|
||||
"context"
|
||||
|
||||
i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models/odataerrors"
|
||||
i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f "github.com/microsoft/kiota-abstractions-go"
|
||||
)
|
||||
|
||||
// ItemContentTypesItemPublishRequestBuilder provides operations to call the publish method.
|
||||
type ItemContentTypesItemPublishRequestBuilder struct {
|
||||
// Path parameters for the request
|
||||
pathParameters map[string]string
|
||||
// The request adapter to use to execute the requests.
|
||||
requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter
|
||||
// Url template to use to build the URL for the current request builder
|
||||
urlTemplate string
|
||||
// Path parameters for the request
|
||||
pathParameters map[string]string
|
||||
// The request adapter to use to execute the requests.
|
||||
requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter
|
||||
// Url template to use to build the URL for the current request builder
|
||||
urlTemplate string
|
||||
}
|
||||
|
||||
// ItemContentTypesItemPublishRequestBuilderPostRequestConfiguration configuration for the request such as headers, query parameters, and middleware options.
|
||||
type ItemContentTypesItemPublishRequestBuilderPostRequestConfiguration struct {
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
}
|
||||
|
||||
// NewItemContentTypesItemPublishRequestBuilderInternal instantiates a new PublishRequestBuilder and sets the default values.
|
||||
func NewItemContentTypesItemPublishRequestBuilderInternal(pathParameters map[string]string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemContentTypesItemPublishRequestBuilder) {
|
||||
m := &ItemContentTypesItemPublishRequestBuilder{
|
||||
}
|
||||
m.urlTemplate = "{+baseurl}/sites/{site%2Did}/contentTypes/{contentType%2Did}/microsoft.graph.publish";
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
m.pathParameters = urlTplParams;
|
||||
m.requestAdapter = requestAdapter;
|
||||
return m
|
||||
func NewItemContentTypesItemPublishRequestBuilderInternal(pathParameters map[string]string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter) *ItemContentTypesItemPublishRequestBuilder {
|
||||
m := &ItemContentTypesItemPublishRequestBuilder{}
|
||||
m.urlTemplate = "{+baseurl}/sites/{site%2Did}/contentTypes/{contentType%2Did}/microsoft.graph.publish"
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
m.pathParameters = urlTplParams
|
||||
m.requestAdapter = requestAdapter
|
||||
return m
|
||||
}
|
||||
|
||||
// NewItemContentTypesItemPublishRequestBuilder instantiates a new PublishRequestBuilder and sets the default values.
|
||||
func NewItemContentTypesItemPublishRequestBuilder(rawUrl string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemContentTypesItemPublishRequestBuilder) {
|
||||
urlParams := make(map[string]string)
|
||||
urlParams["request-raw-url"] = rawUrl
|
||||
return NewItemContentTypesItemPublishRequestBuilderInternal(urlParams, requestAdapter)
|
||||
func NewItemContentTypesItemPublishRequestBuilder(rawUrl string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter) *ItemContentTypesItemPublishRequestBuilder {
|
||||
urlParams := make(map[string]string)
|
||||
urlParams["request-raw-url"] = rawUrl
|
||||
return NewItemContentTypesItemPublishRequestBuilderInternal(urlParams, requestAdapter)
|
||||
}
|
||||
|
||||
// CreatePostRequestInformation publishes a [contentType][] present in a content type hub site.
|
||||
func (m *ItemContentTypesItemPublishRequestBuilder) CreatePostRequestInformation(ctx context.Context, requestConfiguration *ItemContentTypesItemPublishRequestBuilderPostRequestConfiguration)(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.POST
|
||||
if requestConfiguration != nil {
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
func (m *ItemContentTypesItemPublishRequestBuilder) CreatePostRequestInformation(ctx context.Context, requestConfiguration *ItemContentTypesItemPublishRequestBuilderPostRequestConfiguration) (*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.POST
|
||||
if requestConfiguration != nil {
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
}
|
||||
|
||||
// Post publishes a [contentType][] present in a content type hub site.
|
||||
// [Find more info here]
|
||||
//
|
||||
//
|
||||
// [Find more info here]: https://docs.microsoft.com/graph/api/contenttype-publish?view=graph-rest-1.0
|
||||
func (m *ItemContentTypesItemPublishRequestBuilder) Post(ctx context.Context, requestConfiguration *ItemContentTypesItemPublishRequestBuilderPostRequestConfiguration)(error) {
|
||||
requestInfo, err := m.CreatePostRequestInformation(ctx, requestConfiguration);
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings {
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
err = m.requestAdapter.SendNoContentAsync(ctx, requestInfo, errorMapping)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
return nil
|
||||
func (m *ItemContentTypesItemPublishRequestBuilder) Post(ctx context.Context, requestConfiguration *ItemContentTypesItemPublishRequestBuilderPostRequestConfiguration) error {
|
||||
requestInfo, err := m.CreatePostRequestInformation(ctx, requestConfiguration)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings{
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
err = m.requestAdapter.SendNoContent(ctx, requestInfo, errorMapping)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
@ -1,74 +1,79 @@
|
||||
package sites
|
||||
|
||||
import (
|
||||
"context"
|
||||
i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f "github.com/microsoft/kiota-abstractions-go"
|
||||
i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models/odataerrors"
|
||||
"context"
|
||||
|
||||
i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models/odataerrors"
|
||||
i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f "github.com/microsoft/kiota-abstractions-go"
|
||||
)
|
||||
|
||||
// ItemContentTypesItemUnpublishRequestBuilder provides operations to call the unpublish method.
|
||||
type ItemContentTypesItemUnpublishRequestBuilder struct {
|
||||
// Path parameters for the request
|
||||
pathParameters map[string]string
|
||||
// The request adapter to use to execute the requests.
|
||||
requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter
|
||||
// Url template to use to build the URL for the current request builder
|
||||
urlTemplate string
|
||||
// Path parameters for the request
|
||||
pathParameters map[string]string
|
||||
// The request adapter to use to execute the requests.
|
||||
requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter
|
||||
// Url template to use to build the URL for the current request builder
|
||||
urlTemplate string
|
||||
}
|
||||
|
||||
// ItemContentTypesItemUnpublishRequestBuilderPostRequestConfiguration configuration for the request such as headers, query parameters, and middleware options.
|
||||
type ItemContentTypesItemUnpublishRequestBuilderPostRequestConfiguration struct {
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
}
|
||||
|
||||
// NewItemContentTypesItemUnpublishRequestBuilderInternal instantiates a new UnpublishRequestBuilder and sets the default values.
|
||||
func NewItemContentTypesItemUnpublishRequestBuilderInternal(pathParameters map[string]string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemContentTypesItemUnpublishRequestBuilder) {
|
||||
m := &ItemContentTypesItemUnpublishRequestBuilder{
|
||||
}
|
||||
m.urlTemplate = "{+baseurl}/sites/{site%2Did}/contentTypes/{contentType%2Did}/microsoft.graph.unpublish";
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
m.pathParameters = urlTplParams;
|
||||
m.requestAdapter = requestAdapter;
|
||||
return m
|
||||
func NewItemContentTypesItemUnpublishRequestBuilderInternal(pathParameters map[string]string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter) *ItemContentTypesItemUnpublishRequestBuilder {
|
||||
m := &ItemContentTypesItemUnpublishRequestBuilder{}
|
||||
m.urlTemplate = "{+baseurl}/sites/{site%2Did}/contentTypes/{contentType%2Did}/microsoft.graph.unpublish"
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
m.pathParameters = urlTplParams
|
||||
m.requestAdapter = requestAdapter
|
||||
return m
|
||||
}
|
||||
|
||||
// NewItemContentTypesItemUnpublishRequestBuilder instantiates a new UnpublishRequestBuilder and sets the default values.
|
||||
func NewItemContentTypesItemUnpublishRequestBuilder(rawUrl string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemContentTypesItemUnpublishRequestBuilder) {
|
||||
urlParams := make(map[string]string)
|
||||
urlParams["request-raw-url"] = rawUrl
|
||||
return NewItemContentTypesItemUnpublishRequestBuilderInternal(urlParams, requestAdapter)
|
||||
func NewItemContentTypesItemUnpublishRequestBuilder(rawUrl string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter) *ItemContentTypesItemUnpublishRequestBuilder {
|
||||
urlParams := make(map[string]string)
|
||||
urlParams["request-raw-url"] = rawUrl
|
||||
return NewItemContentTypesItemUnpublishRequestBuilderInternal(urlParams, requestAdapter)
|
||||
}
|
||||
|
||||
// CreatePostRequestInformation unpublish a [contentType][] from a content type hub site.
|
||||
func (m *ItemContentTypesItemUnpublishRequestBuilder) CreatePostRequestInformation(ctx context.Context, requestConfiguration *ItemContentTypesItemUnpublishRequestBuilderPostRequestConfiguration)(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.POST
|
||||
if requestConfiguration != nil {
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
func (m *ItemContentTypesItemUnpublishRequestBuilder) CreatePostRequestInformation(ctx context.Context, requestConfiguration *ItemContentTypesItemUnpublishRequestBuilderPostRequestConfiguration) (*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.POST
|
||||
if requestConfiguration != nil {
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
}
|
||||
|
||||
// Post unpublish a [contentType][] from a content type hub site.
|
||||
// [Find more info here]
|
||||
//
|
||||
//
|
||||
// [Find more info here]: https://docs.microsoft.com/graph/api/contenttype-unpublish?view=graph-rest-1.0
|
||||
func (m *ItemContentTypesItemUnpublishRequestBuilder) Post(ctx context.Context, requestConfiguration *ItemContentTypesItemUnpublishRequestBuilderPostRequestConfiguration)(error) {
|
||||
requestInfo, err := m.CreatePostRequestInformation(ctx, requestConfiguration);
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings {
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
err = m.requestAdapter.SendNoContentAsync(ctx, requestInfo, errorMapping)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
return nil
|
||||
func (m *ItemContentTypesItemUnpublishRequestBuilder) Post(ctx context.Context, requestConfiguration *ItemContentTypesItemUnpublishRequestBuilderPostRequestConfiguration) error {
|
||||
requestInfo, err := m.CreatePostRequestInformation(ctx, requestConfiguration)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings{
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
err = m.requestAdapter.SendNoContent(ctx, requestInfo, errorMapping)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
@ -1,162 +1,175 @@
|
||||
package sites
|
||||
|
||||
import (
|
||||
"context"
|
||||
i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f "github.com/microsoft/kiota-abstractions-go"
|
||||
ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models"
|
||||
i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models/odataerrors"
|
||||
"context"
|
||||
|
||||
ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models"
|
||||
i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models/odataerrors"
|
||||
i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f "github.com/microsoft/kiota-abstractions-go"
|
||||
)
|
||||
|
||||
// ItemContentTypesRequestBuilder provides operations to manage the contentTypes property of the microsoft.graph.site entity.
|
||||
type ItemContentTypesRequestBuilder struct {
|
||||
// Path parameters for the request
|
||||
pathParameters map[string]string
|
||||
// The request adapter to use to execute the requests.
|
||||
requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter
|
||||
// Url template to use to build the URL for the current request builder
|
||||
urlTemplate string
|
||||
// Path parameters for the request
|
||||
pathParameters map[string]string
|
||||
// The request adapter to use to execute the requests.
|
||||
requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter
|
||||
// Url template to use to build the URL for the current request builder
|
||||
urlTemplate string
|
||||
}
|
||||
|
||||
// ItemContentTypesRequestBuilderGetQueryParameters get the collection of [contentType][contentType] resources in a [site][].
|
||||
type ItemContentTypesRequestBuilderGetQueryParameters struct {
|
||||
// Include count of items
|
||||
Count *bool `uriparametername:"%24count"`
|
||||
// Expand related entities
|
||||
Expand []string `uriparametername:"%24expand"`
|
||||
// Filter items by property values
|
||||
Filter *string `uriparametername:"%24filter"`
|
||||
// Order items by property values
|
||||
Orderby []string `uriparametername:"%24orderby"`
|
||||
// Search items by search phrases
|
||||
Search *string `uriparametername:"%24search"`
|
||||
// Select properties to be returned
|
||||
Select []string `uriparametername:"%24select"`
|
||||
// Skip the first n items
|
||||
Skip *int32 `uriparametername:"%24skip"`
|
||||
// Show only the first n items
|
||||
Top *int32 `uriparametername:"%24top"`
|
||||
// Include count of items
|
||||
Count *bool `uriparametername:"%24count"`
|
||||
// Expand related entities
|
||||
Expand []string `uriparametername:"%24expand"`
|
||||
// Filter items by property values
|
||||
Filter *string `uriparametername:"%24filter"`
|
||||
// Order items by property values
|
||||
Orderby []string `uriparametername:"%24orderby"`
|
||||
// Search items by search phrases
|
||||
Search *string `uriparametername:"%24search"`
|
||||
// Select properties to be returned
|
||||
Select []string `uriparametername:"%24select"`
|
||||
// Skip the first n items
|
||||
Skip *int32 `uriparametername:"%24skip"`
|
||||
// Show only the first n items
|
||||
Top *int32 `uriparametername:"%24top"`
|
||||
}
|
||||
|
||||
// ItemContentTypesRequestBuilderGetRequestConfiguration configuration for the request such as headers, query parameters, and middleware options.
|
||||
type ItemContentTypesRequestBuilderGetRequestConfiguration struct {
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
// Request query parameters
|
||||
QueryParameters *ItemContentTypesRequestBuilderGetQueryParameters
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
// Request query parameters
|
||||
QueryParameters *ItemContentTypesRequestBuilderGetQueryParameters
|
||||
}
|
||||
|
||||
// ItemContentTypesRequestBuilderPostRequestConfiguration configuration for the request such as headers, query parameters, and middleware options.
|
||||
type ItemContentTypesRequestBuilderPostRequestConfiguration struct {
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
}
|
||||
|
||||
// AddCopy provides operations to call the addCopy method.
|
||||
func (m *ItemContentTypesRequestBuilder) AddCopy()(*ItemContentTypesAddCopyRequestBuilder) {
|
||||
return NewItemContentTypesAddCopyRequestBuilderInternal(m.pathParameters, m.requestAdapter);
|
||||
func (m *ItemContentTypesRequestBuilder) AddCopy() *ItemContentTypesAddCopyRequestBuilder {
|
||||
return NewItemContentTypesAddCopyRequestBuilderInternal(m.pathParameters, m.requestAdapter)
|
||||
}
|
||||
|
||||
// AddCopyFromContentTypeHub provides operations to call the addCopyFromContentTypeHub method.
|
||||
func (m *ItemContentTypesRequestBuilder) AddCopyFromContentTypeHub()(*ItemContentTypesAddCopyFromContentTypeHubRequestBuilder) {
|
||||
return NewItemContentTypesAddCopyFromContentTypeHubRequestBuilderInternal(m.pathParameters, m.requestAdapter);
|
||||
func (m *ItemContentTypesRequestBuilder) AddCopyFromContentTypeHub() *ItemContentTypesAddCopyFromContentTypeHubRequestBuilder {
|
||||
return NewItemContentTypesAddCopyFromContentTypeHubRequestBuilderInternal(m.pathParameters, m.requestAdapter)
|
||||
}
|
||||
|
||||
// NewItemContentTypesRequestBuilderInternal instantiates a new ContentTypesRequestBuilder and sets the default values.
|
||||
func NewItemContentTypesRequestBuilderInternal(pathParameters map[string]string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemContentTypesRequestBuilder) {
|
||||
m := &ItemContentTypesRequestBuilder{
|
||||
}
|
||||
m.urlTemplate = "{+baseurl}/sites/{site%2Did}/contentTypes{?%24top,%24skip,%24search,%24filter,%24count,%24orderby,%24select,%24expand}";
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
m.pathParameters = urlTplParams;
|
||||
m.requestAdapter = requestAdapter;
|
||||
return m
|
||||
func NewItemContentTypesRequestBuilderInternal(pathParameters map[string]string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter) *ItemContentTypesRequestBuilder {
|
||||
m := &ItemContentTypesRequestBuilder{}
|
||||
m.urlTemplate = "{+baseurl}/sites/{site%2Did}/contentTypes{?%24top,%24skip,%24search,%24filter,%24count,%24orderby,%24select,%24expand}"
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
m.pathParameters = urlTplParams
|
||||
m.requestAdapter = requestAdapter
|
||||
return m
|
||||
}
|
||||
|
||||
// NewItemContentTypesRequestBuilder instantiates a new ContentTypesRequestBuilder and sets the default values.
|
||||
func NewItemContentTypesRequestBuilder(rawUrl string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemContentTypesRequestBuilder) {
|
||||
urlParams := make(map[string]string)
|
||||
urlParams["request-raw-url"] = rawUrl
|
||||
return NewItemContentTypesRequestBuilderInternal(urlParams, requestAdapter)
|
||||
func NewItemContentTypesRequestBuilder(rawUrl string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter) *ItemContentTypesRequestBuilder {
|
||||
urlParams := make(map[string]string)
|
||||
urlParams["request-raw-url"] = rawUrl
|
||||
return NewItemContentTypesRequestBuilderInternal(urlParams, requestAdapter)
|
||||
}
|
||||
|
||||
// Count provides operations to count the resources in the collection.
|
||||
func (m *ItemContentTypesRequestBuilder) Count()(*ItemContentTypesCountRequestBuilder) {
|
||||
return NewItemContentTypesCountRequestBuilderInternal(m.pathParameters, m.requestAdapter);
|
||||
func (m *ItemContentTypesRequestBuilder) Count() *ItemContentTypesCountRequestBuilder {
|
||||
return NewItemContentTypesCountRequestBuilderInternal(m.pathParameters, m.requestAdapter)
|
||||
}
|
||||
|
||||
// CreateGetRequestInformation get the collection of [contentType][contentType] resources in a [site][].
|
||||
func (m *ItemContentTypesRequestBuilder) CreateGetRequestInformation(ctx context.Context, requestConfiguration *ItemContentTypesRequestBuilderGetRequestConfiguration)(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.GET
|
||||
requestInfo.Headers.Add("Accept", "application/json")
|
||||
if requestConfiguration != nil {
|
||||
if requestConfiguration.QueryParameters != nil {
|
||||
requestInfo.AddQueryParameters(*(requestConfiguration.QueryParameters))
|
||||
}
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
func (m *ItemContentTypesRequestBuilder) CreateGetRequestInformation(ctx context.Context, requestConfiguration *ItemContentTypesRequestBuilderGetRequestConfiguration) (*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.GET
|
||||
requestInfo.Headers.Add("Accept", "application/json")
|
||||
if requestConfiguration != nil {
|
||||
if requestConfiguration.QueryParameters != nil {
|
||||
requestInfo.AddQueryParameters(*(requestConfiguration.QueryParameters))
|
||||
}
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
}
|
||||
|
||||
// CreatePostRequestInformation create a new [contentType][] for a [site][].
|
||||
func (m *ItemContentTypesRequestBuilder) CreatePostRequestInformation(ctx context.Context, body ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ContentTypeable, requestConfiguration *ItemContentTypesRequestBuilderPostRequestConfiguration)(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.POST
|
||||
requestInfo.Headers.Add("Accept", "application/json")
|
||||
requestInfo.SetContentFromParsable(ctx, m.requestAdapter, "application/json", body)
|
||||
if requestConfiguration != nil {
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
func (m *ItemContentTypesRequestBuilder) CreatePostRequestInformation(ctx context.Context, body ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ContentTypeable, requestConfiguration *ItemContentTypesRequestBuilderPostRequestConfiguration) (*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.POST
|
||||
requestInfo.Headers.Add("Accept", "application/json")
|
||||
requestInfo.SetContentFromParsable(ctx, m.requestAdapter, "application/json", body)
|
||||
if requestConfiguration != nil {
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
}
|
||||
|
||||
// Get get the collection of [contentType][contentType] resources in a [site][].
|
||||
// [Find more info here]
|
||||
//
|
||||
//
|
||||
// [Find more info here]: https://docs.microsoft.com/graph/api/site-list-contenttypes?view=graph-rest-1.0
|
||||
func (m *ItemContentTypesRequestBuilder) Get(ctx context.Context, requestConfiguration *ItemContentTypesRequestBuilderGetRequestConfiguration)(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ContentTypeCollectionResponseable, error) {
|
||||
requestInfo, err := m.CreateGetRequestInformation(ctx, requestConfiguration);
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings {
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.SendAsync(ctx, requestInfo, ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CreateContentTypeCollectionResponseFromDiscriminatorValue, errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ContentTypeCollectionResponseable), nil
|
||||
func (m *ItemContentTypesRequestBuilder) Get(ctx context.Context, requestConfiguration *ItemContentTypesRequestBuilderGetRequestConfiguration) (ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ContentTypeCollectionResponseable, error) {
|
||||
requestInfo, err := m.CreateGetRequestInformation(ctx, requestConfiguration)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings{
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.Send(ctx, requestInfo, ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CreateContentTypeCollectionResponseFromDiscriminatorValue, errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ContentTypeCollectionResponseable), nil
|
||||
}
|
||||
|
||||
// GetCompatibleHubContentTypes provides operations to call the getCompatibleHubContentTypes method.
|
||||
func (m *ItemContentTypesRequestBuilder) GetCompatibleHubContentTypes()(*ItemContentTypesGetCompatibleHubContentTypesRequestBuilder) {
|
||||
return NewItemContentTypesGetCompatibleHubContentTypesRequestBuilderInternal(m.pathParameters, m.requestAdapter);
|
||||
func (m *ItemContentTypesRequestBuilder) GetCompatibleHubContentTypes() *ItemContentTypesGetCompatibleHubContentTypesRequestBuilder {
|
||||
return NewItemContentTypesGetCompatibleHubContentTypesRequestBuilderInternal(m.pathParameters, m.requestAdapter)
|
||||
}
|
||||
|
||||
// Post create a new [contentType][] for a [site][].
|
||||
// [Find more info here]
|
||||
//
|
||||
//
|
||||
// [Find more info here]: https://docs.microsoft.com/graph/api/site-post-contenttypes?view=graph-rest-1.0
|
||||
func (m *ItemContentTypesRequestBuilder) Post(ctx context.Context, body ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ContentTypeable, requestConfiguration *ItemContentTypesRequestBuilderPostRequestConfiguration)(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ContentTypeable, error) {
|
||||
requestInfo, err := m.CreatePostRequestInformation(ctx, body, requestConfiguration);
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings {
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.SendAsync(ctx, requestInfo, ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CreateContentTypeFromDiscriminatorValue, errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ContentTypeable), nil
|
||||
func (m *ItemContentTypesRequestBuilder) Post(ctx context.Context, body ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ContentTypeable, requestConfiguration *ItemContentTypesRequestBuilderPostRequestConfiguration) (ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ContentTypeable, error) {
|
||||
requestInfo, err := m.CreatePostRequestInformation(ctx, body, requestConfiguration)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings{
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.Send(ctx, requestInfo, ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CreateContentTypeFromDiscriminatorValue, errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ContentTypeable), nil
|
||||
}
|
||||
|
||||
@ -1,91 +0,0 @@
|
||||
package sites
|
||||
|
||||
import (
|
||||
"context"
|
||||
i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f "github.com/microsoft/kiota-abstractions-go"
|
||||
ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models"
|
||||
i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models/odataerrors"
|
||||
)
|
||||
|
||||
// ItemDriveRequestBuilder provides operations to manage the drive property of the microsoft.graph.site entity.
|
||||
type ItemDriveRequestBuilder struct {
|
||||
// Path parameters for the request
|
||||
pathParameters map[string]string
|
||||
// The request adapter to use to execute the requests.
|
||||
requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter
|
||||
// Url template to use to build the URL for the current request builder
|
||||
urlTemplate string
|
||||
}
|
||||
// ItemDriveRequestBuilderGetQueryParameters retrieve the properties and relationships of a Drive resource. A Drive is the top-level container for a file system, such as OneDrive or SharePoint document libraries.
|
||||
type ItemDriveRequestBuilderGetQueryParameters struct {
|
||||
// Expand related entities
|
||||
Expand []string `uriparametername:"%24expand"`
|
||||
// Select properties to be returned
|
||||
Select []string `uriparametername:"%24select"`
|
||||
}
|
||||
// ItemDriveRequestBuilderGetRequestConfiguration configuration for the request such as headers, query parameters, and middleware options.
|
||||
type ItemDriveRequestBuilderGetRequestConfiguration struct {
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
// Request query parameters
|
||||
QueryParameters *ItemDriveRequestBuilderGetQueryParameters
|
||||
}
|
||||
// NewItemDriveRequestBuilderInternal instantiates a new DriveRequestBuilder and sets the default values.
|
||||
func NewItemDriveRequestBuilderInternal(pathParameters map[string]string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemDriveRequestBuilder) {
|
||||
m := &ItemDriveRequestBuilder{
|
||||
}
|
||||
m.urlTemplate = "{+baseurl}/sites/{site%2Did}/drive{?%24select,%24expand}";
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
m.pathParameters = urlTplParams;
|
||||
m.requestAdapter = requestAdapter;
|
||||
return m
|
||||
}
|
||||
// NewItemDriveRequestBuilder instantiates a new DriveRequestBuilder and sets the default values.
|
||||
func NewItemDriveRequestBuilder(rawUrl string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemDriveRequestBuilder) {
|
||||
urlParams := make(map[string]string)
|
||||
urlParams["request-raw-url"] = rawUrl
|
||||
return NewItemDriveRequestBuilderInternal(urlParams, requestAdapter)
|
||||
}
|
||||
// CreateGetRequestInformation retrieve the properties and relationships of a Drive resource. A Drive is the top-level container for a file system, such as OneDrive or SharePoint document libraries.
|
||||
func (m *ItemDriveRequestBuilder) CreateGetRequestInformation(ctx context.Context, requestConfiguration *ItemDriveRequestBuilderGetRequestConfiguration)(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.GET
|
||||
requestInfo.Headers.Add("Accept", "application/json")
|
||||
if requestConfiguration != nil {
|
||||
if requestConfiguration.QueryParameters != nil {
|
||||
requestInfo.AddQueryParameters(*(requestConfiguration.QueryParameters))
|
||||
}
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
}
|
||||
// Get retrieve the properties and relationships of a Drive resource. A Drive is the top-level container for a file system, such as OneDrive or SharePoint document libraries.
|
||||
// [Find more info here]
|
||||
//
|
||||
// [Find more info here]: https://docs.microsoft.com/graph/api/drive-get?view=graph-rest-1.0
|
||||
func (m *ItemDriveRequestBuilder) Get(ctx context.Context, requestConfiguration *ItemDriveRequestBuilderGetRequestConfiguration)(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.Driveable, error) {
|
||||
requestInfo, err := m.CreateGetRequestInformation(ctx, requestConfiguration);
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings {
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.SendAsync(ctx, requestInfo, ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CreateDriveFromDiscriminatorValue, errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.Driveable), nil
|
||||
}
|
||||
@ -1,87 +0,0 @@
|
||||
package sites
|
||||
|
||||
import (
|
||||
"context"
|
||||
i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f "github.com/microsoft/kiota-abstractions-go"
|
||||
i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models/odataerrors"
|
||||
)
|
||||
|
||||
// ItemDrivesCountRequestBuilder provides operations to count the resources in the collection.
|
||||
type ItemDrivesCountRequestBuilder struct {
|
||||
// Path parameters for the request
|
||||
pathParameters map[string]string
|
||||
// The request adapter to use to execute the requests.
|
||||
requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter
|
||||
// Url template to use to build the URL for the current request builder
|
||||
urlTemplate string
|
||||
}
|
||||
// ItemDrivesCountRequestBuilderGetQueryParameters get the number of the resource
|
||||
type ItemDrivesCountRequestBuilderGetQueryParameters struct {
|
||||
// Filter items by property values
|
||||
Filter *string `uriparametername:"%24filter"`
|
||||
// Search items by search phrases
|
||||
Search *string `uriparametername:"%24search"`
|
||||
}
|
||||
// ItemDrivesCountRequestBuilderGetRequestConfiguration configuration for the request such as headers, query parameters, and middleware options.
|
||||
type ItemDrivesCountRequestBuilderGetRequestConfiguration struct {
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
// Request query parameters
|
||||
QueryParameters *ItemDrivesCountRequestBuilderGetQueryParameters
|
||||
}
|
||||
// NewItemDrivesCountRequestBuilderInternal instantiates a new CountRequestBuilder and sets the default values.
|
||||
func NewItemDrivesCountRequestBuilderInternal(pathParameters map[string]string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemDrivesCountRequestBuilder) {
|
||||
m := &ItemDrivesCountRequestBuilder{
|
||||
}
|
||||
m.urlTemplate = "{+baseurl}/sites/{site%2Did}/drives/$count{?%24search,%24filter}";
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
m.pathParameters = urlTplParams;
|
||||
m.requestAdapter = requestAdapter;
|
||||
return m
|
||||
}
|
||||
// NewItemDrivesCountRequestBuilder instantiates a new CountRequestBuilder and sets the default values.
|
||||
func NewItemDrivesCountRequestBuilder(rawUrl string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemDrivesCountRequestBuilder) {
|
||||
urlParams := make(map[string]string)
|
||||
urlParams["request-raw-url"] = rawUrl
|
||||
return NewItemDrivesCountRequestBuilderInternal(urlParams, requestAdapter)
|
||||
}
|
||||
// CreateGetRequestInformation get the number of the resource
|
||||
func (m *ItemDrivesCountRequestBuilder) CreateGetRequestInformation(ctx context.Context, requestConfiguration *ItemDrivesCountRequestBuilderGetRequestConfiguration)(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.GET
|
||||
requestInfo.Headers.Add("Accept", "text/plain")
|
||||
if requestConfiguration != nil {
|
||||
if requestConfiguration.QueryParameters != nil {
|
||||
requestInfo.AddQueryParameters(*(requestConfiguration.QueryParameters))
|
||||
}
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
}
|
||||
// Get get the number of the resource
|
||||
func (m *ItemDrivesCountRequestBuilder) Get(ctx context.Context, requestConfiguration *ItemDrivesCountRequestBuilderGetRequestConfiguration)(*int32, error) {
|
||||
requestInfo, err := m.CreateGetRequestInformation(ctx, requestConfiguration);
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings {
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.SendPrimitiveAsync(ctx, requestInfo, "int32", errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(*int32), nil
|
||||
}
|
||||
@ -1,88 +0,0 @@
|
||||
package sites
|
||||
|
||||
import (
|
||||
"context"
|
||||
i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f "github.com/microsoft/kiota-abstractions-go"
|
||||
ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models"
|
||||
i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models/odataerrors"
|
||||
)
|
||||
|
||||
// ItemDrivesDriveItemRequestBuilder provides operations to manage the drives property of the microsoft.graph.site entity.
|
||||
type ItemDrivesDriveItemRequestBuilder struct {
|
||||
// Path parameters for the request
|
||||
pathParameters map[string]string
|
||||
// The request adapter to use to execute the requests.
|
||||
requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter
|
||||
// Url template to use to build the URL for the current request builder
|
||||
urlTemplate string
|
||||
}
|
||||
// ItemDrivesDriveItemRequestBuilderGetQueryParameters the collection of drives (document libraries) under this site.
|
||||
type ItemDrivesDriveItemRequestBuilderGetQueryParameters struct {
|
||||
// Expand related entities
|
||||
Expand []string `uriparametername:"%24expand"`
|
||||
// Select properties to be returned
|
||||
Select []string `uriparametername:"%24select"`
|
||||
}
|
||||
// ItemDrivesDriveItemRequestBuilderGetRequestConfiguration configuration for the request such as headers, query parameters, and middleware options.
|
||||
type ItemDrivesDriveItemRequestBuilderGetRequestConfiguration struct {
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
// Request query parameters
|
||||
QueryParameters *ItemDrivesDriveItemRequestBuilderGetQueryParameters
|
||||
}
|
||||
// NewItemDrivesDriveItemRequestBuilderInternal instantiates a new DriveItemRequestBuilder and sets the default values.
|
||||
func NewItemDrivesDriveItemRequestBuilderInternal(pathParameters map[string]string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemDrivesDriveItemRequestBuilder) {
|
||||
m := &ItemDrivesDriveItemRequestBuilder{
|
||||
}
|
||||
m.urlTemplate = "{+baseurl}/sites/{site%2Did}/drives/{drive%2Did}{?%24select,%24expand}";
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
m.pathParameters = urlTplParams;
|
||||
m.requestAdapter = requestAdapter;
|
||||
return m
|
||||
}
|
||||
// NewItemDrivesDriveItemRequestBuilder instantiates a new DriveItemRequestBuilder and sets the default values.
|
||||
func NewItemDrivesDriveItemRequestBuilder(rawUrl string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemDrivesDriveItemRequestBuilder) {
|
||||
urlParams := make(map[string]string)
|
||||
urlParams["request-raw-url"] = rawUrl
|
||||
return NewItemDrivesDriveItemRequestBuilderInternal(urlParams, requestAdapter)
|
||||
}
|
||||
// CreateGetRequestInformation the collection of drives (document libraries) under this site.
|
||||
func (m *ItemDrivesDriveItemRequestBuilder) CreateGetRequestInformation(ctx context.Context, requestConfiguration *ItemDrivesDriveItemRequestBuilderGetRequestConfiguration)(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.GET
|
||||
requestInfo.Headers.Add("Accept", "application/json")
|
||||
if requestConfiguration != nil {
|
||||
if requestConfiguration.QueryParameters != nil {
|
||||
requestInfo.AddQueryParameters(*(requestConfiguration.QueryParameters))
|
||||
}
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
}
|
||||
// Get the collection of drives (document libraries) under this site.
|
||||
func (m *ItemDrivesDriveItemRequestBuilder) Get(ctx context.Context, requestConfiguration *ItemDrivesDriveItemRequestBuilderGetRequestConfiguration)(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.Driveable, error) {
|
||||
requestInfo, err := m.CreateGetRequestInformation(ctx, requestConfiguration);
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings {
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.SendAsync(ctx, requestInfo, ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CreateDriveFromDiscriminatorValue, errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.Driveable), nil
|
||||
}
|
||||
@ -1,107 +0,0 @@
|
||||
package sites
|
||||
|
||||
import (
|
||||
"context"
|
||||
i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f "github.com/microsoft/kiota-abstractions-go"
|
||||
ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models"
|
||||
i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models/odataerrors"
|
||||
)
|
||||
|
||||
// ItemDrivesRequestBuilder provides operations to manage the drives property of the microsoft.graph.site entity.
|
||||
type ItemDrivesRequestBuilder struct {
|
||||
// Path parameters for the request
|
||||
pathParameters map[string]string
|
||||
// The request adapter to use to execute the requests.
|
||||
requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter
|
||||
// Url template to use to build the URL for the current request builder
|
||||
urlTemplate string
|
||||
}
|
||||
// ItemDrivesRequestBuilderGetQueryParameters retrieve the list of Drive resources available for a target User, Group, or Site.
|
||||
type ItemDrivesRequestBuilderGetQueryParameters struct {
|
||||
// Include count of items
|
||||
Count *bool `uriparametername:"%24count"`
|
||||
// Expand related entities
|
||||
Expand []string `uriparametername:"%24expand"`
|
||||
// Filter items by property values
|
||||
Filter *string `uriparametername:"%24filter"`
|
||||
// Order items by property values
|
||||
Orderby []string `uriparametername:"%24orderby"`
|
||||
// Search items by search phrases
|
||||
Search *string `uriparametername:"%24search"`
|
||||
// Select properties to be returned
|
||||
Select []string `uriparametername:"%24select"`
|
||||
// Skip the first n items
|
||||
Skip *int32 `uriparametername:"%24skip"`
|
||||
// Show only the first n items
|
||||
Top *int32 `uriparametername:"%24top"`
|
||||
}
|
||||
// ItemDrivesRequestBuilderGetRequestConfiguration configuration for the request such as headers, query parameters, and middleware options.
|
||||
type ItemDrivesRequestBuilderGetRequestConfiguration struct {
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
// Request query parameters
|
||||
QueryParameters *ItemDrivesRequestBuilderGetQueryParameters
|
||||
}
|
||||
// NewItemDrivesRequestBuilderInternal instantiates a new DrivesRequestBuilder and sets the default values.
|
||||
func NewItemDrivesRequestBuilderInternal(pathParameters map[string]string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemDrivesRequestBuilder) {
|
||||
m := &ItemDrivesRequestBuilder{
|
||||
}
|
||||
m.urlTemplate = "{+baseurl}/sites/{site%2Did}/drives{?%24top,%24skip,%24search,%24filter,%24count,%24orderby,%24select,%24expand}";
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
m.pathParameters = urlTplParams;
|
||||
m.requestAdapter = requestAdapter;
|
||||
return m
|
||||
}
|
||||
// NewItemDrivesRequestBuilder instantiates a new DrivesRequestBuilder and sets the default values.
|
||||
func NewItemDrivesRequestBuilder(rawUrl string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemDrivesRequestBuilder) {
|
||||
urlParams := make(map[string]string)
|
||||
urlParams["request-raw-url"] = rawUrl
|
||||
return NewItemDrivesRequestBuilderInternal(urlParams, requestAdapter)
|
||||
}
|
||||
// Count provides operations to count the resources in the collection.
|
||||
func (m *ItemDrivesRequestBuilder) Count()(*ItemDrivesCountRequestBuilder) {
|
||||
return NewItemDrivesCountRequestBuilderInternal(m.pathParameters, m.requestAdapter);
|
||||
}
|
||||
// CreateGetRequestInformation retrieve the list of Drive resources available for a target User, Group, or Site.
|
||||
func (m *ItemDrivesRequestBuilder) CreateGetRequestInformation(ctx context.Context, requestConfiguration *ItemDrivesRequestBuilderGetRequestConfiguration)(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.GET
|
||||
requestInfo.Headers.Add("Accept", "application/json")
|
||||
if requestConfiguration != nil {
|
||||
if requestConfiguration.QueryParameters != nil {
|
||||
requestInfo.AddQueryParameters(*(requestConfiguration.QueryParameters))
|
||||
}
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
}
|
||||
// Get retrieve the list of Drive resources available for a target User, Group, or Site.
|
||||
// [Find more info here]
|
||||
//
|
||||
// [Find more info here]: https://docs.microsoft.com/graph/api/drive-list?view=graph-rest-1.0
|
||||
func (m *ItemDrivesRequestBuilder) Get(ctx context.Context, requestConfiguration *ItemDrivesRequestBuilderGetRequestConfiguration)(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.DriveCollectionResponseable, error) {
|
||||
requestInfo, err := m.CreateGetRequestInformation(ctx, requestConfiguration);
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings {
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.SendAsync(ctx, requestInfo, ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CreateDriveCollectionResponseFromDiscriminatorValue, errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.DriveCollectionResponseable), nil
|
||||
}
|
||||
@ -1,106 +0,0 @@
|
||||
package sites
|
||||
|
||||
import (
|
||||
"context"
|
||||
i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f "github.com/microsoft/kiota-abstractions-go"
|
||||
i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models/odataerrors"
|
||||
)
|
||||
|
||||
// ItemGetActivitiesByIntervalWithStartDateTimeWithEndDateTimeWithIntervalRequestBuilder provides operations to call the getActivitiesByInterval method.
|
||||
type ItemGetActivitiesByIntervalWithStartDateTimeWithEndDateTimeWithIntervalRequestBuilder struct {
|
||||
// Path parameters for the request
|
||||
pathParameters map[string]string
|
||||
// The request adapter to use to execute the requests.
|
||||
requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter
|
||||
// Url template to use to build the URL for the current request builder
|
||||
urlTemplate string
|
||||
}
|
||||
// ItemGetActivitiesByIntervalWithStartDateTimeWithEndDateTimeWithIntervalRequestBuilderGetQueryParameters invoke function getActivitiesByInterval
|
||||
type ItemGetActivitiesByIntervalWithStartDateTimeWithEndDateTimeWithIntervalRequestBuilderGetQueryParameters struct {
|
||||
// Include count of items
|
||||
Count *bool `uriparametername:"%24count"`
|
||||
// Filter items by property values
|
||||
Filter *string `uriparametername:"%24filter"`
|
||||
// Order items by property values
|
||||
Orderby []string `uriparametername:"%24orderby"`
|
||||
// Search items by search phrases
|
||||
Search *string `uriparametername:"%24search"`
|
||||
// Select properties to be returned
|
||||
Select []string `uriparametername:"%24select"`
|
||||
// Skip the first n items
|
||||
Skip *int32 `uriparametername:"%24skip"`
|
||||
// Show only the first n items
|
||||
Top *int32 `uriparametername:"%24top"`
|
||||
}
|
||||
// ItemGetActivitiesByIntervalWithStartDateTimeWithEndDateTimeWithIntervalRequestBuilderGetRequestConfiguration configuration for the request such as headers, query parameters, and middleware options.
|
||||
type ItemGetActivitiesByIntervalWithStartDateTimeWithEndDateTimeWithIntervalRequestBuilderGetRequestConfiguration struct {
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
// Request query parameters
|
||||
QueryParameters *ItemGetActivitiesByIntervalWithStartDateTimeWithEndDateTimeWithIntervalRequestBuilderGetQueryParameters
|
||||
}
|
||||
// NewItemGetActivitiesByIntervalWithStartDateTimeWithEndDateTimeWithIntervalRequestBuilderInternal instantiates a new GetActivitiesByIntervalWithStartDateTimeWithEndDateTimeWithIntervalRequestBuilder and sets the default values.
|
||||
func NewItemGetActivitiesByIntervalWithStartDateTimeWithEndDateTimeWithIntervalRequestBuilderInternal(pathParameters map[string]string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter, endDateTime *string, interval *string, startDateTime *string)(*ItemGetActivitiesByIntervalWithStartDateTimeWithEndDateTimeWithIntervalRequestBuilder) {
|
||||
m := &ItemGetActivitiesByIntervalWithStartDateTimeWithEndDateTimeWithIntervalRequestBuilder{
|
||||
}
|
||||
m.urlTemplate = "{+baseurl}/sites/{site%2Did}/microsoft.graph.getActivitiesByInterval(startDateTime='{startDateTime}',endDateTime='{endDateTime}',interval='{interval}'){?%24top,%24skip,%24search,%24filter,%24count,%24select,%24orderby}";
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
if endDateTime != nil {
|
||||
urlTplParams["endDateTime"] = *endDateTime
|
||||
}
|
||||
if interval != nil {
|
||||
urlTplParams["interval"] = *interval
|
||||
}
|
||||
if startDateTime != nil {
|
||||
urlTplParams["startDateTime"] = *startDateTime
|
||||
}
|
||||
m.pathParameters = urlTplParams;
|
||||
m.requestAdapter = requestAdapter;
|
||||
return m
|
||||
}
|
||||
// NewItemGetActivitiesByIntervalWithStartDateTimeWithEndDateTimeWithIntervalRequestBuilder instantiates a new GetActivitiesByIntervalWithStartDateTimeWithEndDateTimeWithIntervalRequestBuilder and sets the default values.
|
||||
func NewItemGetActivitiesByIntervalWithStartDateTimeWithEndDateTimeWithIntervalRequestBuilder(rawUrl string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemGetActivitiesByIntervalWithStartDateTimeWithEndDateTimeWithIntervalRequestBuilder) {
|
||||
urlParams := make(map[string]string)
|
||||
urlParams["request-raw-url"] = rawUrl
|
||||
return NewItemGetActivitiesByIntervalWithStartDateTimeWithEndDateTimeWithIntervalRequestBuilderInternal(urlParams, requestAdapter, nil, nil, nil)
|
||||
}
|
||||
// CreateGetRequestInformation invoke function getActivitiesByInterval
|
||||
func (m *ItemGetActivitiesByIntervalWithStartDateTimeWithEndDateTimeWithIntervalRequestBuilder) CreateGetRequestInformation(ctx context.Context, requestConfiguration *ItemGetActivitiesByIntervalWithStartDateTimeWithEndDateTimeWithIntervalRequestBuilderGetRequestConfiguration)(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.GET
|
||||
requestInfo.Headers.Add("Accept", "application/json")
|
||||
if requestConfiguration != nil {
|
||||
if requestConfiguration.QueryParameters != nil {
|
||||
requestInfo.AddQueryParameters(*(requestConfiguration.QueryParameters))
|
||||
}
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
}
|
||||
// Get invoke function getActivitiesByInterval
|
||||
func (m *ItemGetActivitiesByIntervalWithStartDateTimeWithEndDateTimeWithIntervalRequestBuilder) Get(ctx context.Context, requestConfiguration *ItemGetActivitiesByIntervalWithStartDateTimeWithEndDateTimeWithIntervalRequestBuilderGetRequestConfiguration)(ItemGetActivitiesByIntervalWithStartDateTimeWithEndDateTimeWithIntervalResponseable, error) {
|
||||
requestInfo, err := m.CreateGetRequestInformation(ctx, requestConfiguration);
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings {
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.SendAsync(ctx, requestInfo, CreateItemGetActivitiesByIntervalWithStartDateTimeWithEndDateTimeWithIntervalResponseFromDiscriminatorValue, errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(ItemGetActivitiesByIntervalWithStartDateTimeWithEndDateTimeWithIntervalResponseable), nil
|
||||
}
|
||||
@ -1,69 +0,0 @@
|
||||
package sites
|
||||
|
||||
import (
|
||||
i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91 "github.com/microsoft/kiota-abstractions-go/serialization"
|
||||
ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models"
|
||||
)
|
||||
|
||||
// ItemGetActivitiesByIntervalWithStartDateTimeWithEndDateTimeWithIntervalResponse provides operations to call the getActivitiesByInterval method.
|
||||
type ItemGetActivitiesByIntervalWithStartDateTimeWithEndDateTimeWithIntervalResponse struct {
|
||||
ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.BaseCollectionPaginationCountResponse
|
||||
// The value property
|
||||
value []ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ItemActivityStatable
|
||||
}
|
||||
// NewItemGetActivitiesByIntervalWithStartDateTimeWithEndDateTimeWithIntervalResponse instantiates a new ItemGetActivitiesByIntervalWithStartDateTimeWithEndDateTimeWithIntervalResponse and sets the default values.
|
||||
func NewItemGetActivitiesByIntervalWithStartDateTimeWithEndDateTimeWithIntervalResponse()(*ItemGetActivitiesByIntervalWithStartDateTimeWithEndDateTimeWithIntervalResponse) {
|
||||
m := &ItemGetActivitiesByIntervalWithStartDateTimeWithEndDateTimeWithIntervalResponse{
|
||||
BaseCollectionPaginationCountResponse: *ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.NewBaseCollectionPaginationCountResponse(),
|
||||
}
|
||||
return m
|
||||
}
|
||||
// CreateItemGetActivitiesByIntervalWithStartDateTimeWithEndDateTimeWithIntervalResponseFromDiscriminatorValue creates a new instance of the appropriate class based on discriminator value
|
||||
func CreateItemGetActivitiesByIntervalWithStartDateTimeWithEndDateTimeWithIntervalResponseFromDiscriminatorValue(parseNode i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.ParseNode)(i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.Parsable, error) {
|
||||
return NewItemGetActivitiesByIntervalWithStartDateTimeWithEndDateTimeWithIntervalResponse(), nil
|
||||
}
|
||||
// GetFieldDeserializers the deserialization information for the current model
|
||||
func (m *ItemGetActivitiesByIntervalWithStartDateTimeWithEndDateTimeWithIntervalResponse) GetFieldDeserializers()(map[string]func(i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.ParseNode)(error)) {
|
||||
res := m.BaseCollectionPaginationCountResponse.GetFieldDeserializers()
|
||||
res["value"] = func (n i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.ParseNode) error {
|
||||
val, err := n.GetCollectionOfObjectValues(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CreateItemActivityStatFromDiscriminatorValue)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
if val != nil {
|
||||
res := make([]ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ItemActivityStatable, len(val))
|
||||
for i, v := range val {
|
||||
res[i] = v.(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ItemActivityStatable)
|
||||
}
|
||||
m.SetValue(res)
|
||||
}
|
||||
return nil
|
||||
}
|
||||
return res
|
||||
}
|
||||
// GetValue gets the value property value. The value property
|
||||
func (m *ItemGetActivitiesByIntervalWithStartDateTimeWithEndDateTimeWithIntervalResponse) GetValue()([]ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ItemActivityStatable) {
|
||||
return m.value
|
||||
}
|
||||
// Serialize serializes information the current object
|
||||
func (m *ItemGetActivitiesByIntervalWithStartDateTimeWithEndDateTimeWithIntervalResponse) Serialize(writer i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.SerializationWriter)(error) {
|
||||
err := m.BaseCollectionPaginationCountResponse.Serialize(writer)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
if m.GetValue() != nil {
|
||||
cast := make([]i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.Parsable, len(m.GetValue()))
|
||||
for i, v := range m.GetValue() {
|
||||
cast[i] = v.(i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.Parsable)
|
||||
}
|
||||
err = writer.WriteCollectionOfObjectValues("value", cast)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
}
|
||||
return nil
|
||||
}
|
||||
// SetValue sets the value property value. The value property
|
||||
func (m *ItemGetActivitiesByIntervalWithStartDateTimeWithEndDateTimeWithIntervalResponse) SetValue(value []ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ItemActivityStatable)() {
|
||||
m.value = value
|
||||
}
|
||||
@ -1,14 +0,0 @@
|
||||
package sites
|
||||
|
||||
import (
|
||||
i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91 "github.com/microsoft/kiota-abstractions-go/serialization"
|
||||
ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models"
|
||||
)
|
||||
|
||||
// ItemGetActivitiesByIntervalWithStartDateTimeWithEndDateTimeWithIntervalResponseable
|
||||
type ItemGetActivitiesByIntervalWithStartDateTimeWithEndDateTimeWithIntervalResponseable interface {
|
||||
ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.BaseCollectionPaginationCountResponseable
|
||||
i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.Parsable
|
||||
GetValue()([]ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ItemActivityStatable)
|
||||
SetValue(value []ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ItemActivityStatable)()
|
||||
}
|
||||
@ -1,100 +0,0 @@
|
||||
package sites
|
||||
|
||||
import (
|
||||
"context"
|
||||
i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f "github.com/microsoft/kiota-abstractions-go"
|
||||
i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models/odataerrors"
|
||||
)
|
||||
|
||||
// ItemGetApplicableContentTypesForListWithListIdRequestBuilder provides operations to call the getApplicableContentTypesForList method.
|
||||
type ItemGetApplicableContentTypesForListWithListIdRequestBuilder struct {
|
||||
// Path parameters for the request
|
||||
pathParameters map[string]string
|
||||
// The request adapter to use to execute the requests.
|
||||
requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter
|
||||
// Url template to use to build the URL for the current request builder
|
||||
urlTemplate string
|
||||
}
|
||||
// ItemGetApplicableContentTypesForListWithListIdRequestBuilderGetQueryParameters invoke function getApplicableContentTypesForList
|
||||
type ItemGetApplicableContentTypesForListWithListIdRequestBuilderGetQueryParameters struct {
|
||||
// Include count of items
|
||||
Count *bool `uriparametername:"%24count"`
|
||||
// Filter items by property values
|
||||
Filter *string `uriparametername:"%24filter"`
|
||||
// Order items by property values
|
||||
Orderby []string `uriparametername:"%24orderby"`
|
||||
// Search items by search phrases
|
||||
Search *string `uriparametername:"%24search"`
|
||||
// Select properties to be returned
|
||||
Select []string `uriparametername:"%24select"`
|
||||
// Skip the first n items
|
||||
Skip *int32 `uriparametername:"%24skip"`
|
||||
// Show only the first n items
|
||||
Top *int32 `uriparametername:"%24top"`
|
||||
}
|
||||
// ItemGetApplicableContentTypesForListWithListIdRequestBuilderGetRequestConfiguration configuration for the request such as headers, query parameters, and middleware options.
|
||||
type ItemGetApplicableContentTypesForListWithListIdRequestBuilderGetRequestConfiguration struct {
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
// Request query parameters
|
||||
QueryParameters *ItemGetApplicableContentTypesForListWithListIdRequestBuilderGetQueryParameters
|
||||
}
|
||||
// NewItemGetApplicableContentTypesForListWithListIdRequestBuilderInternal instantiates a new GetApplicableContentTypesForListWithListIdRequestBuilder and sets the default values.
|
||||
func NewItemGetApplicableContentTypesForListWithListIdRequestBuilderInternal(pathParameters map[string]string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter, listId *string)(*ItemGetApplicableContentTypesForListWithListIdRequestBuilder) {
|
||||
m := &ItemGetApplicableContentTypesForListWithListIdRequestBuilder{
|
||||
}
|
||||
m.urlTemplate = "{+baseurl}/sites/{site%2Did}/microsoft.graph.getApplicableContentTypesForList(listId='{listId}'){?%24top,%24skip,%24search,%24filter,%24count,%24select,%24orderby}";
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
if listId != nil {
|
||||
urlTplParams["listId"] = *listId
|
||||
}
|
||||
m.pathParameters = urlTplParams;
|
||||
m.requestAdapter = requestAdapter;
|
||||
return m
|
||||
}
|
||||
// NewItemGetApplicableContentTypesForListWithListIdRequestBuilder instantiates a new GetApplicableContentTypesForListWithListIdRequestBuilder and sets the default values.
|
||||
func NewItemGetApplicableContentTypesForListWithListIdRequestBuilder(rawUrl string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemGetApplicableContentTypesForListWithListIdRequestBuilder) {
|
||||
urlParams := make(map[string]string)
|
||||
urlParams["request-raw-url"] = rawUrl
|
||||
return NewItemGetApplicableContentTypesForListWithListIdRequestBuilderInternal(urlParams, requestAdapter, nil)
|
||||
}
|
||||
// CreateGetRequestInformation invoke function getApplicableContentTypesForList
|
||||
func (m *ItemGetApplicableContentTypesForListWithListIdRequestBuilder) CreateGetRequestInformation(ctx context.Context, requestConfiguration *ItemGetApplicableContentTypesForListWithListIdRequestBuilderGetRequestConfiguration)(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.GET
|
||||
requestInfo.Headers.Add("Accept", "application/json")
|
||||
if requestConfiguration != nil {
|
||||
if requestConfiguration.QueryParameters != nil {
|
||||
requestInfo.AddQueryParameters(*(requestConfiguration.QueryParameters))
|
||||
}
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
}
|
||||
// Get invoke function getApplicableContentTypesForList
|
||||
func (m *ItemGetApplicableContentTypesForListWithListIdRequestBuilder) Get(ctx context.Context, requestConfiguration *ItemGetApplicableContentTypesForListWithListIdRequestBuilderGetRequestConfiguration)(ItemGetApplicableContentTypesForListWithListIdResponseable, error) {
|
||||
requestInfo, err := m.CreateGetRequestInformation(ctx, requestConfiguration);
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings {
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.SendAsync(ctx, requestInfo, CreateItemGetApplicableContentTypesForListWithListIdResponseFromDiscriminatorValue, errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(ItemGetApplicableContentTypesForListWithListIdResponseable), nil
|
||||
}
|
||||
@ -1,69 +0,0 @@
|
||||
package sites
|
||||
|
||||
import (
|
||||
i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91 "github.com/microsoft/kiota-abstractions-go/serialization"
|
||||
ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models"
|
||||
)
|
||||
|
||||
// ItemGetApplicableContentTypesForListWithListIdResponse provides operations to call the getApplicableContentTypesForList method.
|
||||
type ItemGetApplicableContentTypesForListWithListIdResponse struct {
|
||||
ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.BaseCollectionPaginationCountResponse
|
||||
// The value property
|
||||
value []ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ContentTypeable
|
||||
}
|
||||
// NewItemGetApplicableContentTypesForListWithListIdResponse instantiates a new ItemGetApplicableContentTypesForListWithListIdResponse and sets the default values.
|
||||
func NewItemGetApplicableContentTypesForListWithListIdResponse()(*ItemGetApplicableContentTypesForListWithListIdResponse) {
|
||||
m := &ItemGetApplicableContentTypesForListWithListIdResponse{
|
||||
BaseCollectionPaginationCountResponse: *ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.NewBaseCollectionPaginationCountResponse(),
|
||||
}
|
||||
return m
|
||||
}
|
||||
// CreateItemGetApplicableContentTypesForListWithListIdResponseFromDiscriminatorValue creates a new instance of the appropriate class based on discriminator value
|
||||
func CreateItemGetApplicableContentTypesForListWithListIdResponseFromDiscriminatorValue(parseNode i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.ParseNode)(i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.Parsable, error) {
|
||||
return NewItemGetApplicableContentTypesForListWithListIdResponse(), nil
|
||||
}
|
||||
// GetFieldDeserializers the deserialization information for the current model
|
||||
func (m *ItemGetApplicableContentTypesForListWithListIdResponse) GetFieldDeserializers()(map[string]func(i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.ParseNode)(error)) {
|
||||
res := m.BaseCollectionPaginationCountResponse.GetFieldDeserializers()
|
||||
res["value"] = func (n i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.ParseNode) error {
|
||||
val, err := n.GetCollectionOfObjectValues(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CreateContentTypeFromDiscriminatorValue)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
if val != nil {
|
||||
res := make([]ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ContentTypeable, len(val))
|
||||
for i, v := range val {
|
||||
res[i] = v.(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ContentTypeable)
|
||||
}
|
||||
m.SetValue(res)
|
||||
}
|
||||
return nil
|
||||
}
|
||||
return res
|
||||
}
|
||||
// GetValue gets the value property value. The value property
|
||||
func (m *ItemGetApplicableContentTypesForListWithListIdResponse) GetValue()([]ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ContentTypeable) {
|
||||
return m.value
|
||||
}
|
||||
// Serialize serializes information the current object
|
||||
func (m *ItemGetApplicableContentTypesForListWithListIdResponse) Serialize(writer i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.SerializationWriter)(error) {
|
||||
err := m.BaseCollectionPaginationCountResponse.Serialize(writer)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
if m.GetValue() != nil {
|
||||
cast := make([]i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.Parsable, len(m.GetValue()))
|
||||
for i, v := range m.GetValue() {
|
||||
cast[i] = v.(i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.Parsable)
|
||||
}
|
||||
err = writer.WriteCollectionOfObjectValues("value", cast)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
}
|
||||
return nil
|
||||
}
|
||||
// SetValue sets the value property value. The value property
|
||||
func (m *ItemGetApplicableContentTypesForListWithListIdResponse) SetValue(value []ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ContentTypeable)() {
|
||||
m.value = value
|
||||
}
|
||||
@ -1,14 +0,0 @@
|
||||
package sites
|
||||
|
||||
import (
|
||||
i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91 "github.com/microsoft/kiota-abstractions-go/serialization"
|
||||
ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models"
|
||||
)
|
||||
|
||||
// ItemGetApplicableContentTypesForListWithListIdResponseable
|
||||
type ItemGetApplicableContentTypesForListWithListIdResponseable interface {
|
||||
ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.BaseCollectionPaginationCountResponseable
|
||||
i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.Parsable
|
||||
GetValue()([]ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ContentTypeable)
|
||||
SetValue(value []ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ContentTypeable)()
|
||||
}
|
||||
@ -1,88 +0,0 @@
|
||||
package sites
|
||||
|
||||
import (
|
||||
"context"
|
||||
i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f "github.com/microsoft/kiota-abstractions-go"
|
||||
ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models"
|
||||
i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models/odataerrors"
|
||||
)
|
||||
|
||||
// ItemInformationProtectionBitlockerRecoveryKeysBitlockerRecoveryKeyItemRequestBuilder provides operations to manage the recoveryKeys property of the microsoft.graph.bitlocker entity.
|
||||
type ItemInformationProtectionBitlockerRecoveryKeysBitlockerRecoveryKeyItemRequestBuilder struct {
|
||||
// Path parameters for the request
|
||||
pathParameters map[string]string
|
||||
// The request adapter to use to execute the requests.
|
||||
requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter
|
||||
// Url template to use to build the URL for the current request builder
|
||||
urlTemplate string
|
||||
}
|
||||
// ItemInformationProtectionBitlockerRecoveryKeysBitlockerRecoveryKeyItemRequestBuilderGetQueryParameters the recovery keys associated with the bitlocker entity.
|
||||
type ItemInformationProtectionBitlockerRecoveryKeysBitlockerRecoveryKeyItemRequestBuilderGetQueryParameters struct {
|
||||
// Expand related entities
|
||||
Expand []string `uriparametername:"%24expand"`
|
||||
// Select properties to be returned
|
||||
Select []string `uriparametername:"%24select"`
|
||||
}
|
||||
// ItemInformationProtectionBitlockerRecoveryKeysBitlockerRecoveryKeyItemRequestBuilderGetRequestConfiguration configuration for the request such as headers, query parameters, and middleware options.
|
||||
type ItemInformationProtectionBitlockerRecoveryKeysBitlockerRecoveryKeyItemRequestBuilderGetRequestConfiguration struct {
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
// Request query parameters
|
||||
QueryParameters *ItemInformationProtectionBitlockerRecoveryKeysBitlockerRecoveryKeyItemRequestBuilderGetQueryParameters
|
||||
}
|
||||
// NewItemInformationProtectionBitlockerRecoveryKeysBitlockerRecoveryKeyItemRequestBuilderInternal instantiates a new BitlockerRecoveryKeyItemRequestBuilder and sets the default values.
|
||||
func NewItemInformationProtectionBitlockerRecoveryKeysBitlockerRecoveryKeyItemRequestBuilderInternal(pathParameters map[string]string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemInformationProtectionBitlockerRecoveryKeysBitlockerRecoveryKeyItemRequestBuilder) {
|
||||
m := &ItemInformationProtectionBitlockerRecoveryKeysBitlockerRecoveryKeyItemRequestBuilder{
|
||||
}
|
||||
m.urlTemplate = "{+baseurl}/sites/{site%2Did}/informationProtection/bitlocker/recoveryKeys/{bitlockerRecoveryKey%2Did}{?%24select,%24expand}";
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
m.pathParameters = urlTplParams;
|
||||
m.requestAdapter = requestAdapter;
|
||||
return m
|
||||
}
|
||||
// NewItemInformationProtectionBitlockerRecoveryKeysBitlockerRecoveryKeyItemRequestBuilder instantiates a new BitlockerRecoveryKeyItemRequestBuilder and sets the default values.
|
||||
func NewItemInformationProtectionBitlockerRecoveryKeysBitlockerRecoveryKeyItemRequestBuilder(rawUrl string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemInformationProtectionBitlockerRecoveryKeysBitlockerRecoveryKeyItemRequestBuilder) {
|
||||
urlParams := make(map[string]string)
|
||||
urlParams["request-raw-url"] = rawUrl
|
||||
return NewItemInformationProtectionBitlockerRecoveryKeysBitlockerRecoveryKeyItemRequestBuilderInternal(urlParams, requestAdapter)
|
||||
}
|
||||
// CreateGetRequestInformation the recovery keys associated with the bitlocker entity.
|
||||
func (m *ItemInformationProtectionBitlockerRecoveryKeysBitlockerRecoveryKeyItemRequestBuilder) CreateGetRequestInformation(ctx context.Context, requestConfiguration *ItemInformationProtectionBitlockerRecoveryKeysBitlockerRecoveryKeyItemRequestBuilderGetRequestConfiguration)(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.GET
|
||||
requestInfo.Headers.Add("Accept", "application/json")
|
||||
if requestConfiguration != nil {
|
||||
if requestConfiguration.QueryParameters != nil {
|
||||
requestInfo.AddQueryParameters(*(requestConfiguration.QueryParameters))
|
||||
}
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
}
|
||||
// Get the recovery keys associated with the bitlocker entity.
|
||||
func (m *ItemInformationProtectionBitlockerRecoveryKeysBitlockerRecoveryKeyItemRequestBuilder) Get(ctx context.Context, requestConfiguration *ItemInformationProtectionBitlockerRecoveryKeysBitlockerRecoveryKeyItemRequestBuilderGetRequestConfiguration)(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.BitlockerRecoveryKeyable, error) {
|
||||
requestInfo, err := m.CreateGetRequestInformation(ctx, requestConfiguration);
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings {
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.SendAsync(ctx, requestInfo, ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CreateBitlockerRecoveryKeyFromDiscriminatorValue, errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.BitlockerRecoveryKeyable), nil
|
||||
}
|
||||
@ -1,87 +0,0 @@
|
||||
package sites
|
||||
|
||||
import (
|
||||
"context"
|
||||
i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f "github.com/microsoft/kiota-abstractions-go"
|
||||
i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models/odataerrors"
|
||||
)
|
||||
|
||||
// ItemInformationProtectionBitlockerRecoveryKeysCountRequestBuilder provides operations to count the resources in the collection.
|
||||
type ItemInformationProtectionBitlockerRecoveryKeysCountRequestBuilder struct {
|
||||
// Path parameters for the request
|
||||
pathParameters map[string]string
|
||||
// The request adapter to use to execute the requests.
|
||||
requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter
|
||||
// Url template to use to build the URL for the current request builder
|
||||
urlTemplate string
|
||||
}
|
||||
// ItemInformationProtectionBitlockerRecoveryKeysCountRequestBuilderGetQueryParameters get the number of the resource
|
||||
type ItemInformationProtectionBitlockerRecoveryKeysCountRequestBuilderGetQueryParameters struct {
|
||||
// Filter items by property values
|
||||
Filter *string `uriparametername:"%24filter"`
|
||||
// Search items by search phrases
|
||||
Search *string `uriparametername:"%24search"`
|
||||
}
|
||||
// ItemInformationProtectionBitlockerRecoveryKeysCountRequestBuilderGetRequestConfiguration configuration for the request such as headers, query parameters, and middleware options.
|
||||
type ItemInformationProtectionBitlockerRecoveryKeysCountRequestBuilderGetRequestConfiguration struct {
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
// Request query parameters
|
||||
QueryParameters *ItemInformationProtectionBitlockerRecoveryKeysCountRequestBuilderGetQueryParameters
|
||||
}
|
||||
// NewItemInformationProtectionBitlockerRecoveryKeysCountRequestBuilderInternal instantiates a new CountRequestBuilder and sets the default values.
|
||||
func NewItemInformationProtectionBitlockerRecoveryKeysCountRequestBuilderInternal(pathParameters map[string]string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemInformationProtectionBitlockerRecoveryKeysCountRequestBuilder) {
|
||||
m := &ItemInformationProtectionBitlockerRecoveryKeysCountRequestBuilder{
|
||||
}
|
||||
m.urlTemplate = "{+baseurl}/sites/{site%2Did}/informationProtection/bitlocker/recoveryKeys/$count{?%24search,%24filter}";
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
m.pathParameters = urlTplParams;
|
||||
m.requestAdapter = requestAdapter;
|
||||
return m
|
||||
}
|
||||
// NewItemInformationProtectionBitlockerRecoveryKeysCountRequestBuilder instantiates a new CountRequestBuilder and sets the default values.
|
||||
func NewItemInformationProtectionBitlockerRecoveryKeysCountRequestBuilder(rawUrl string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemInformationProtectionBitlockerRecoveryKeysCountRequestBuilder) {
|
||||
urlParams := make(map[string]string)
|
||||
urlParams["request-raw-url"] = rawUrl
|
||||
return NewItemInformationProtectionBitlockerRecoveryKeysCountRequestBuilderInternal(urlParams, requestAdapter)
|
||||
}
|
||||
// CreateGetRequestInformation get the number of the resource
|
||||
func (m *ItemInformationProtectionBitlockerRecoveryKeysCountRequestBuilder) CreateGetRequestInformation(ctx context.Context, requestConfiguration *ItemInformationProtectionBitlockerRecoveryKeysCountRequestBuilderGetRequestConfiguration)(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.GET
|
||||
requestInfo.Headers.Add("Accept", "text/plain")
|
||||
if requestConfiguration != nil {
|
||||
if requestConfiguration.QueryParameters != nil {
|
||||
requestInfo.AddQueryParameters(*(requestConfiguration.QueryParameters))
|
||||
}
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
}
|
||||
// Get get the number of the resource
|
||||
func (m *ItemInformationProtectionBitlockerRecoveryKeysCountRequestBuilder) Get(ctx context.Context, requestConfiguration *ItemInformationProtectionBitlockerRecoveryKeysCountRequestBuilderGetRequestConfiguration)(*int32, error) {
|
||||
requestInfo, err := m.CreateGetRequestInformation(ctx, requestConfiguration);
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings {
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.SendPrimitiveAsync(ctx, requestInfo, "int32", errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(*int32), nil
|
||||
}
|
||||
@ -1,107 +0,0 @@
|
||||
package sites
|
||||
|
||||
import (
|
||||
"context"
|
||||
i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f "github.com/microsoft/kiota-abstractions-go"
|
||||
ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models"
|
||||
i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models/odataerrors"
|
||||
)
|
||||
|
||||
// ItemInformationProtectionBitlockerRecoveryKeysRequestBuilder provides operations to manage the recoveryKeys property of the microsoft.graph.bitlocker entity.
|
||||
type ItemInformationProtectionBitlockerRecoveryKeysRequestBuilder struct {
|
||||
// Path parameters for the request
|
||||
pathParameters map[string]string
|
||||
// The request adapter to use to execute the requests.
|
||||
requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter
|
||||
// Url template to use to build the URL for the current request builder
|
||||
urlTemplate string
|
||||
}
|
||||
// ItemInformationProtectionBitlockerRecoveryKeysRequestBuilderGetQueryParameters get a list of the bitlockerRecoveryKey objects and their properties. This operation does not return the **key** property. For information about how to read the **key** property, see Get bitlockerRecoveryKey.
|
||||
type ItemInformationProtectionBitlockerRecoveryKeysRequestBuilderGetQueryParameters struct {
|
||||
// Include count of items
|
||||
Count *bool `uriparametername:"%24count"`
|
||||
// Expand related entities
|
||||
Expand []string `uriparametername:"%24expand"`
|
||||
// Filter items by property values
|
||||
Filter *string `uriparametername:"%24filter"`
|
||||
// Order items by property values
|
||||
Orderby []string `uriparametername:"%24orderby"`
|
||||
// Search items by search phrases
|
||||
Search *string `uriparametername:"%24search"`
|
||||
// Select properties to be returned
|
||||
Select []string `uriparametername:"%24select"`
|
||||
// Skip the first n items
|
||||
Skip *int32 `uriparametername:"%24skip"`
|
||||
// Show only the first n items
|
||||
Top *int32 `uriparametername:"%24top"`
|
||||
}
|
||||
// ItemInformationProtectionBitlockerRecoveryKeysRequestBuilderGetRequestConfiguration configuration for the request such as headers, query parameters, and middleware options.
|
||||
type ItemInformationProtectionBitlockerRecoveryKeysRequestBuilderGetRequestConfiguration struct {
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
// Request query parameters
|
||||
QueryParameters *ItemInformationProtectionBitlockerRecoveryKeysRequestBuilderGetQueryParameters
|
||||
}
|
||||
// NewItemInformationProtectionBitlockerRecoveryKeysRequestBuilderInternal instantiates a new RecoveryKeysRequestBuilder and sets the default values.
|
||||
func NewItemInformationProtectionBitlockerRecoveryKeysRequestBuilderInternal(pathParameters map[string]string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemInformationProtectionBitlockerRecoveryKeysRequestBuilder) {
|
||||
m := &ItemInformationProtectionBitlockerRecoveryKeysRequestBuilder{
|
||||
}
|
||||
m.urlTemplate = "{+baseurl}/sites/{site%2Did}/informationProtection/bitlocker/recoveryKeys{?%24top,%24skip,%24search,%24filter,%24count,%24orderby,%24select,%24expand}";
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
m.pathParameters = urlTplParams;
|
||||
m.requestAdapter = requestAdapter;
|
||||
return m
|
||||
}
|
||||
// NewItemInformationProtectionBitlockerRecoveryKeysRequestBuilder instantiates a new RecoveryKeysRequestBuilder and sets the default values.
|
||||
func NewItemInformationProtectionBitlockerRecoveryKeysRequestBuilder(rawUrl string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemInformationProtectionBitlockerRecoveryKeysRequestBuilder) {
|
||||
urlParams := make(map[string]string)
|
||||
urlParams["request-raw-url"] = rawUrl
|
||||
return NewItemInformationProtectionBitlockerRecoveryKeysRequestBuilderInternal(urlParams, requestAdapter)
|
||||
}
|
||||
// Count provides operations to count the resources in the collection.
|
||||
func (m *ItemInformationProtectionBitlockerRecoveryKeysRequestBuilder) Count()(*ItemInformationProtectionBitlockerRecoveryKeysCountRequestBuilder) {
|
||||
return NewItemInformationProtectionBitlockerRecoveryKeysCountRequestBuilderInternal(m.pathParameters, m.requestAdapter);
|
||||
}
|
||||
// CreateGetRequestInformation get a list of the bitlockerRecoveryKey objects and their properties. This operation does not return the **key** property. For information about how to read the **key** property, see Get bitlockerRecoveryKey.
|
||||
func (m *ItemInformationProtectionBitlockerRecoveryKeysRequestBuilder) CreateGetRequestInformation(ctx context.Context, requestConfiguration *ItemInformationProtectionBitlockerRecoveryKeysRequestBuilderGetRequestConfiguration)(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.GET
|
||||
requestInfo.Headers.Add("Accept", "application/json")
|
||||
if requestConfiguration != nil {
|
||||
if requestConfiguration.QueryParameters != nil {
|
||||
requestInfo.AddQueryParameters(*(requestConfiguration.QueryParameters))
|
||||
}
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
}
|
||||
// Get get a list of the bitlockerRecoveryKey objects and their properties. This operation does not return the **key** property. For information about how to read the **key** property, see Get bitlockerRecoveryKey.
|
||||
// [Find more info here]
|
||||
//
|
||||
// [Find more info here]: https://docs.microsoft.com/graph/api/bitlocker-list-recoverykeys?view=graph-rest-1.0
|
||||
func (m *ItemInformationProtectionBitlockerRecoveryKeysRequestBuilder) Get(ctx context.Context, requestConfiguration *ItemInformationProtectionBitlockerRecoveryKeysRequestBuilderGetRequestConfiguration)(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.BitlockerRecoveryKeyCollectionResponseable, error) {
|
||||
requestInfo, err := m.CreateGetRequestInformation(ctx, requestConfiguration);
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings {
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.SendAsync(ctx, requestInfo, ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CreateBitlockerRecoveryKeyCollectionResponseFromDiscriminatorValue, errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.BitlockerRecoveryKeyCollectionResponseable), nil
|
||||
}
|
||||
@ -1,103 +0,0 @@
|
||||
package sites
|
||||
|
||||
import (
|
||||
"context"
|
||||
i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f "github.com/microsoft/kiota-abstractions-go"
|
||||
ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models"
|
||||
i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models/odataerrors"
|
||||
)
|
||||
|
||||
// ItemInformationProtectionBitlockerRequestBuilder provides operations to manage the bitlocker property of the microsoft.graph.informationProtection entity.
|
||||
type ItemInformationProtectionBitlockerRequestBuilder struct {
|
||||
// Path parameters for the request
|
||||
pathParameters map[string]string
|
||||
// The request adapter to use to execute the requests.
|
||||
requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter
|
||||
// Url template to use to build the URL for the current request builder
|
||||
urlTemplate string
|
||||
}
|
||||
// ItemInformationProtectionBitlockerRequestBuilderGetQueryParameters get bitlocker from sites
|
||||
type ItemInformationProtectionBitlockerRequestBuilderGetQueryParameters struct {
|
||||
// Expand related entities
|
||||
Expand []string `uriparametername:"%24expand"`
|
||||
// Select properties to be returned
|
||||
Select []string `uriparametername:"%24select"`
|
||||
}
|
||||
// ItemInformationProtectionBitlockerRequestBuilderGetRequestConfiguration configuration for the request such as headers, query parameters, and middleware options.
|
||||
type ItemInformationProtectionBitlockerRequestBuilderGetRequestConfiguration struct {
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
// Request query parameters
|
||||
QueryParameters *ItemInformationProtectionBitlockerRequestBuilderGetQueryParameters
|
||||
}
|
||||
// NewItemInformationProtectionBitlockerRequestBuilderInternal instantiates a new BitlockerRequestBuilder and sets the default values.
|
||||
func NewItemInformationProtectionBitlockerRequestBuilderInternal(pathParameters map[string]string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemInformationProtectionBitlockerRequestBuilder) {
|
||||
m := &ItemInformationProtectionBitlockerRequestBuilder{
|
||||
}
|
||||
m.urlTemplate = "{+baseurl}/sites/{site%2Did}/informationProtection/bitlocker{?%24select,%24expand}";
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
m.pathParameters = urlTplParams;
|
||||
m.requestAdapter = requestAdapter;
|
||||
return m
|
||||
}
|
||||
// NewItemInformationProtectionBitlockerRequestBuilder instantiates a new BitlockerRequestBuilder and sets the default values.
|
||||
func NewItemInformationProtectionBitlockerRequestBuilder(rawUrl string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemInformationProtectionBitlockerRequestBuilder) {
|
||||
urlParams := make(map[string]string)
|
||||
urlParams["request-raw-url"] = rawUrl
|
||||
return NewItemInformationProtectionBitlockerRequestBuilderInternal(urlParams, requestAdapter)
|
||||
}
|
||||
// CreateGetRequestInformation get bitlocker from sites
|
||||
func (m *ItemInformationProtectionBitlockerRequestBuilder) CreateGetRequestInformation(ctx context.Context, requestConfiguration *ItemInformationProtectionBitlockerRequestBuilderGetRequestConfiguration)(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.GET
|
||||
requestInfo.Headers.Add("Accept", "application/json")
|
||||
if requestConfiguration != nil {
|
||||
if requestConfiguration.QueryParameters != nil {
|
||||
requestInfo.AddQueryParameters(*(requestConfiguration.QueryParameters))
|
||||
}
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
}
|
||||
// Get get bitlocker from sites
|
||||
func (m *ItemInformationProtectionBitlockerRequestBuilder) Get(ctx context.Context, requestConfiguration *ItemInformationProtectionBitlockerRequestBuilderGetRequestConfiguration)(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.Bitlockerable, error) {
|
||||
requestInfo, err := m.CreateGetRequestInformation(ctx, requestConfiguration);
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings {
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.SendAsync(ctx, requestInfo, ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CreateBitlockerFromDiscriminatorValue, errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.Bitlockerable), nil
|
||||
}
|
||||
// RecoveryKeys provides operations to manage the recoveryKeys property of the microsoft.graph.bitlocker entity.
|
||||
func (m *ItemInformationProtectionBitlockerRequestBuilder) RecoveryKeys()(*ItemInformationProtectionBitlockerRecoveryKeysRequestBuilder) {
|
||||
return NewItemInformationProtectionBitlockerRecoveryKeysRequestBuilderInternal(m.pathParameters, m.requestAdapter);
|
||||
}
|
||||
// RecoveryKeysById provides operations to manage the recoveryKeys property of the microsoft.graph.bitlocker entity.
|
||||
func (m *ItemInformationProtectionBitlockerRequestBuilder) RecoveryKeysById(id string)(*ItemInformationProtectionBitlockerRecoveryKeysBitlockerRecoveryKeyItemRequestBuilder) {
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range m.pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
if id != "" {
|
||||
urlTplParams["bitlockerRecoveryKey%2Did"] = id
|
||||
}
|
||||
return NewItemInformationProtectionBitlockerRecoveryKeysBitlockerRecoveryKeyItemRequestBuilderInternal(urlTplParams, m.requestAdapter);
|
||||
}
|
||||
@ -1,87 +0,0 @@
|
||||
package sites
|
||||
|
||||
import (
|
||||
"context"
|
||||
i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f "github.com/microsoft/kiota-abstractions-go"
|
||||
i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models/odataerrors"
|
||||
)
|
||||
|
||||
// ItemInformationProtectionDataLossPreventionPoliciesCountRequestBuilder provides operations to count the resources in the collection.
|
||||
type ItemInformationProtectionDataLossPreventionPoliciesCountRequestBuilder struct {
|
||||
// Path parameters for the request
|
||||
pathParameters map[string]string
|
||||
// The request adapter to use to execute the requests.
|
||||
requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter
|
||||
// Url template to use to build the URL for the current request builder
|
||||
urlTemplate string
|
||||
}
|
||||
// ItemInformationProtectionDataLossPreventionPoliciesCountRequestBuilderGetQueryParameters get the number of the resource
|
||||
type ItemInformationProtectionDataLossPreventionPoliciesCountRequestBuilderGetQueryParameters struct {
|
||||
// Filter items by property values
|
||||
Filter *string `uriparametername:"%24filter"`
|
||||
// Search items by search phrases
|
||||
Search *string `uriparametername:"%24search"`
|
||||
}
|
||||
// ItemInformationProtectionDataLossPreventionPoliciesCountRequestBuilderGetRequestConfiguration configuration for the request such as headers, query parameters, and middleware options.
|
||||
type ItemInformationProtectionDataLossPreventionPoliciesCountRequestBuilderGetRequestConfiguration struct {
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
// Request query parameters
|
||||
QueryParameters *ItemInformationProtectionDataLossPreventionPoliciesCountRequestBuilderGetQueryParameters
|
||||
}
|
||||
// NewItemInformationProtectionDataLossPreventionPoliciesCountRequestBuilderInternal instantiates a new CountRequestBuilder and sets the default values.
|
||||
func NewItemInformationProtectionDataLossPreventionPoliciesCountRequestBuilderInternal(pathParameters map[string]string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemInformationProtectionDataLossPreventionPoliciesCountRequestBuilder) {
|
||||
m := &ItemInformationProtectionDataLossPreventionPoliciesCountRequestBuilder{
|
||||
}
|
||||
m.urlTemplate = "{+baseurl}/sites/{site%2Did}/informationProtection/dataLossPreventionPolicies/$count{?%24search,%24filter}";
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
m.pathParameters = urlTplParams;
|
||||
m.requestAdapter = requestAdapter;
|
||||
return m
|
||||
}
|
||||
// NewItemInformationProtectionDataLossPreventionPoliciesCountRequestBuilder instantiates a new CountRequestBuilder and sets the default values.
|
||||
func NewItemInformationProtectionDataLossPreventionPoliciesCountRequestBuilder(rawUrl string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemInformationProtectionDataLossPreventionPoliciesCountRequestBuilder) {
|
||||
urlParams := make(map[string]string)
|
||||
urlParams["request-raw-url"] = rawUrl
|
||||
return NewItemInformationProtectionDataLossPreventionPoliciesCountRequestBuilderInternal(urlParams, requestAdapter)
|
||||
}
|
||||
// CreateGetRequestInformation get the number of the resource
|
||||
func (m *ItemInformationProtectionDataLossPreventionPoliciesCountRequestBuilder) CreateGetRequestInformation(ctx context.Context, requestConfiguration *ItemInformationProtectionDataLossPreventionPoliciesCountRequestBuilderGetRequestConfiguration)(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.GET
|
||||
requestInfo.Headers.Add("Accept", "text/plain")
|
||||
if requestConfiguration != nil {
|
||||
if requestConfiguration.QueryParameters != nil {
|
||||
requestInfo.AddQueryParameters(*(requestConfiguration.QueryParameters))
|
||||
}
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
}
|
||||
// Get get the number of the resource
|
||||
func (m *ItemInformationProtectionDataLossPreventionPoliciesCountRequestBuilder) Get(ctx context.Context, requestConfiguration *ItemInformationProtectionDataLossPreventionPoliciesCountRequestBuilderGetRequestConfiguration)(*int32, error) {
|
||||
requestInfo, err := m.CreateGetRequestInformation(ctx, requestConfiguration);
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings {
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.SendPrimitiveAsync(ctx, requestInfo, "int32", errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(*int32), nil
|
||||
}
|
||||
@ -1,163 +0,0 @@
|
||||
package sites
|
||||
|
||||
import (
|
||||
"context"
|
||||
i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f "github.com/microsoft/kiota-abstractions-go"
|
||||
ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models"
|
||||
i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models/odataerrors"
|
||||
)
|
||||
|
||||
// ItemInformationProtectionDataLossPreventionPoliciesDataLossPreventionPolicyItemRequestBuilder provides operations to manage the dataLossPreventionPolicies property of the microsoft.graph.informationProtection entity.
|
||||
type ItemInformationProtectionDataLossPreventionPoliciesDataLossPreventionPolicyItemRequestBuilder struct {
|
||||
// Path parameters for the request
|
||||
pathParameters map[string]string
|
||||
// The request adapter to use to execute the requests.
|
||||
requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter
|
||||
// Url template to use to build the URL for the current request builder
|
||||
urlTemplate string
|
||||
}
|
||||
// ItemInformationProtectionDataLossPreventionPoliciesDataLossPreventionPolicyItemRequestBuilderDeleteRequestConfiguration configuration for the request such as headers, query parameters, and middleware options.
|
||||
type ItemInformationProtectionDataLossPreventionPoliciesDataLossPreventionPolicyItemRequestBuilderDeleteRequestConfiguration struct {
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
}
|
||||
// ItemInformationProtectionDataLossPreventionPoliciesDataLossPreventionPolicyItemRequestBuilderGetQueryParameters get dataLossPreventionPolicies from sites
|
||||
type ItemInformationProtectionDataLossPreventionPoliciesDataLossPreventionPolicyItemRequestBuilderGetQueryParameters struct {
|
||||
// Expand related entities
|
||||
Expand []string `uriparametername:"%24expand"`
|
||||
// Select properties to be returned
|
||||
Select []string `uriparametername:"%24select"`
|
||||
}
|
||||
// ItemInformationProtectionDataLossPreventionPoliciesDataLossPreventionPolicyItemRequestBuilderGetRequestConfiguration configuration for the request such as headers, query parameters, and middleware options.
|
||||
type ItemInformationProtectionDataLossPreventionPoliciesDataLossPreventionPolicyItemRequestBuilderGetRequestConfiguration struct {
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
// Request query parameters
|
||||
QueryParameters *ItemInformationProtectionDataLossPreventionPoliciesDataLossPreventionPolicyItemRequestBuilderGetQueryParameters
|
||||
}
|
||||
// ItemInformationProtectionDataLossPreventionPoliciesDataLossPreventionPolicyItemRequestBuilderPatchRequestConfiguration configuration for the request such as headers, query parameters, and middleware options.
|
||||
type ItemInformationProtectionDataLossPreventionPoliciesDataLossPreventionPolicyItemRequestBuilderPatchRequestConfiguration struct {
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
}
|
||||
// NewItemInformationProtectionDataLossPreventionPoliciesDataLossPreventionPolicyItemRequestBuilderInternal instantiates a new DataLossPreventionPolicyItemRequestBuilder and sets the default values.
|
||||
func NewItemInformationProtectionDataLossPreventionPoliciesDataLossPreventionPolicyItemRequestBuilderInternal(pathParameters map[string]string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemInformationProtectionDataLossPreventionPoliciesDataLossPreventionPolicyItemRequestBuilder) {
|
||||
m := &ItemInformationProtectionDataLossPreventionPoliciesDataLossPreventionPolicyItemRequestBuilder{
|
||||
}
|
||||
m.urlTemplate = "{+baseurl}/sites/{site%2Did}/informationProtection/dataLossPreventionPolicies/{dataLossPreventionPolicy%2Did}{?%24select,%24expand}";
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
m.pathParameters = urlTplParams;
|
||||
m.requestAdapter = requestAdapter;
|
||||
return m
|
||||
}
|
||||
// NewItemInformationProtectionDataLossPreventionPoliciesDataLossPreventionPolicyItemRequestBuilder instantiates a new DataLossPreventionPolicyItemRequestBuilder and sets the default values.
|
||||
func NewItemInformationProtectionDataLossPreventionPoliciesDataLossPreventionPolicyItemRequestBuilder(rawUrl string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemInformationProtectionDataLossPreventionPoliciesDataLossPreventionPolicyItemRequestBuilder) {
|
||||
urlParams := make(map[string]string)
|
||||
urlParams["request-raw-url"] = rawUrl
|
||||
return NewItemInformationProtectionDataLossPreventionPoliciesDataLossPreventionPolicyItemRequestBuilderInternal(urlParams, requestAdapter)
|
||||
}
|
||||
// CreateDeleteRequestInformation delete navigation property dataLossPreventionPolicies for sites
|
||||
func (m *ItemInformationProtectionDataLossPreventionPoliciesDataLossPreventionPolicyItemRequestBuilder) CreateDeleteRequestInformation(ctx context.Context, requestConfiguration *ItemInformationProtectionDataLossPreventionPoliciesDataLossPreventionPolicyItemRequestBuilderDeleteRequestConfiguration)(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.DELETE
|
||||
if requestConfiguration != nil {
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
}
|
||||
// CreateGetRequestInformation get dataLossPreventionPolicies from sites
|
||||
func (m *ItemInformationProtectionDataLossPreventionPoliciesDataLossPreventionPolicyItemRequestBuilder) CreateGetRequestInformation(ctx context.Context, requestConfiguration *ItemInformationProtectionDataLossPreventionPoliciesDataLossPreventionPolicyItemRequestBuilderGetRequestConfiguration)(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.GET
|
||||
requestInfo.Headers.Add("Accept", "application/json")
|
||||
if requestConfiguration != nil {
|
||||
if requestConfiguration.QueryParameters != nil {
|
||||
requestInfo.AddQueryParameters(*(requestConfiguration.QueryParameters))
|
||||
}
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
}
|
||||
// CreatePatchRequestInformation update the navigation property dataLossPreventionPolicies in sites
|
||||
func (m *ItemInformationProtectionDataLossPreventionPoliciesDataLossPreventionPolicyItemRequestBuilder) CreatePatchRequestInformation(ctx context.Context, body ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.DataLossPreventionPolicyable, requestConfiguration *ItemInformationProtectionDataLossPreventionPoliciesDataLossPreventionPolicyItemRequestBuilderPatchRequestConfiguration)(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.PATCH
|
||||
requestInfo.Headers.Add("Accept", "application/json")
|
||||
requestInfo.SetContentFromParsable(ctx, m.requestAdapter, "application/json", body)
|
||||
if requestConfiguration != nil {
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
}
|
||||
// Delete delete navigation property dataLossPreventionPolicies for sites
|
||||
func (m *ItemInformationProtectionDataLossPreventionPoliciesDataLossPreventionPolicyItemRequestBuilder) Delete(ctx context.Context, requestConfiguration *ItemInformationProtectionDataLossPreventionPoliciesDataLossPreventionPolicyItemRequestBuilderDeleteRequestConfiguration)(error) {
|
||||
requestInfo, err := m.CreateDeleteRequestInformation(ctx, requestConfiguration);
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings {
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
err = m.requestAdapter.SendNoContentAsync(ctx, requestInfo, errorMapping)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
return nil
|
||||
}
|
||||
// Get get dataLossPreventionPolicies from sites
|
||||
func (m *ItemInformationProtectionDataLossPreventionPoliciesDataLossPreventionPolicyItemRequestBuilder) Get(ctx context.Context, requestConfiguration *ItemInformationProtectionDataLossPreventionPoliciesDataLossPreventionPolicyItemRequestBuilderGetRequestConfiguration)(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.DataLossPreventionPolicyable, error) {
|
||||
requestInfo, err := m.CreateGetRequestInformation(ctx, requestConfiguration);
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings {
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.SendAsync(ctx, requestInfo, ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CreateDataLossPreventionPolicyFromDiscriminatorValue, errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.DataLossPreventionPolicyable), nil
|
||||
}
|
||||
// Patch update the navigation property dataLossPreventionPolicies in sites
|
||||
func (m *ItemInformationProtectionDataLossPreventionPoliciesDataLossPreventionPolicyItemRequestBuilder) Patch(ctx context.Context, body ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.DataLossPreventionPolicyable, requestConfiguration *ItemInformationProtectionDataLossPreventionPoliciesDataLossPreventionPolicyItemRequestBuilderPatchRequestConfiguration)(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.DataLossPreventionPolicyable, error) {
|
||||
requestInfo, err := m.CreatePatchRequestInformation(ctx, body, requestConfiguration);
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings {
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.SendAsync(ctx, requestInfo, ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CreateDataLossPreventionPolicyFromDiscriminatorValue, errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.DataLossPreventionPolicyable), nil
|
||||
}
|
||||
@ -1,124 +0,0 @@
|
||||
package sites
|
||||
|
||||
import (
|
||||
i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91 "github.com/microsoft/kiota-abstractions-go/serialization"
|
||||
ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models"
|
||||
)
|
||||
|
||||
// ItemInformationProtectionDataLossPreventionPoliciesEvaluatePostRequestBody provides operations to call the evaluate method.
|
||||
type ItemInformationProtectionDataLossPreventionPoliciesEvaluatePostRequestBody struct {
|
||||
// Stores additional data not described in the OpenAPI description found when deserializing. Can be used for serialization as well.
|
||||
additionalData map[string]interface{}
|
||||
// The evaluationInput property
|
||||
evaluationInput ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.DlpEvaluationInputable
|
||||
// The notificationInfo property
|
||||
notificationInfo ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.DlpNotificationable
|
||||
// The target property
|
||||
target *string
|
||||
}
|
||||
// NewItemInformationProtectionDataLossPreventionPoliciesEvaluatePostRequestBody instantiates a new ItemInformationProtectionDataLossPreventionPoliciesEvaluatePostRequestBody and sets the default values.
|
||||
func NewItemInformationProtectionDataLossPreventionPoliciesEvaluatePostRequestBody()(*ItemInformationProtectionDataLossPreventionPoliciesEvaluatePostRequestBody) {
|
||||
m := &ItemInformationProtectionDataLossPreventionPoliciesEvaluatePostRequestBody{
|
||||
}
|
||||
m.SetAdditionalData(make(map[string]interface{}));
|
||||
return m
|
||||
}
|
||||
// CreateItemInformationProtectionDataLossPreventionPoliciesEvaluatePostRequestBodyFromDiscriminatorValue creates a new instance of the appropriate class based on discriminator value
|
||||
func CreateItemInformationProtectionDataLossPreventionPoliciesEvaluatePostRequestBodyFromDiscriminatorValue(parseNode i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.ParseNode)(i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.Parsable, error) {
|
||||
return NewItemInformationProtectionDataLossPreventionPoliciesEvaluatePostRequestBody(), nil
|
||||
}
|
||||
// GetAdditionalData gets the additionalData property value. Stores additional data not described in the OpenAPI description found when deserializing. Can be used for serialization as well.
|
||||
func (m *ItemInformationProtectionDataLossPreventionPoliciesEvaluatePostRequestBody) GetAdditionalData()(map[string]interface{}) {
|
||||
return m.additionalData
|
||||
}
|
||||
// GetEvaluationInput gets the evaluationInput property value. The evaluationInput property
|
||||
func (m *ItemInformationProtectionDataLossPreventionPoliciesEvaluatePostRequestBody) GetEvaluationInput()(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.DlpEvaluationInputable) {
|
||||
return m.evaluationInput
|
||||
}
|
||||
// GetFieldDeserializers the deserialization information for the current model
|
||||
func (m *ItemInformationProtectionDataLossPreventionPoliciesEvaluatePostRequestBody) GetFieldDeserializers()(map[string]func(i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.ParseNode)(error)) {
|
||||
res := make(map[string]func(i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.ParseNode)(error))
|
||||
res["evaluationInput"] = func (n i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.ParseNode) error {
|
||||
val, err := n.GetObjectValue(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CreateDlpEvaluationInputFromDiscriminatorValue)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
if val != nil {
|
||||
m.SetEvaluationInput(val.(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.DlpEvaluationInputable))
|
||||
}
|
||||
return nil
|
||||
}
|
||||
res["notificationInfo"] = func (n i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.ParseNode) error {
|
||||
val, err := n.GetObjectValue(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CreateDlpNotificationFromDiscriminatorValue)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
if val != nil {
|
||||
m.SetNotificationInfo(val.(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.DlpNotificationable))
|
||||
}
|
||||
return nil
|
||||
}
|
||||
res["target"] = func (n i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.ParseNode) error {
|
||||
val, err := n.GetStringValue()
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
if val != nil {
|
||||
m.SetTarget(val)
|
||||
}
|
||||
return nil
|
||||
}
|
||||
return res
|
||||
}
|
||||
// GetNotificationInfo gets the notificationInfo property value. The notificationInfo property
|
||||
func (m *ItemInformationProtectionDataLossPreventionPoliciesEvaluatePostRequestBody) GetNotificationInfo()(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.DlpNotificationable) {
|
||||
return m.notificationInfo
|
||||
}
|
||||
// GetTarget gets the target property value. The target property
|
||||
func (m *ItemInformationProtectionDataLossPreventionPoliciesEvaluatePostRequestBody) GetTarget()(*string) {
|
||||
return m.target
|
||||
}
|
||||
// Serialize serializes information the current object
|
||||
func (m *ItemInformationProtectionDataLossPreventionPoliciesEvaluatePostRequestBody) Serialize(writer i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.SerializationWriter)(error) {
|
||||
{
|
||||
err := writer.WriteObjectValue("evaluationInput", m.GetEvaluationInput())
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
}
|
||||
{
|
||||
err := writer.WriteObjectValue("notificationInfo", m.GetNotificationInfo())
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
}
|
||||
{
|
||||
err := writer.WriteStringValue("target", m.GetTarget())
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
}
|
||||
{
|
||||
err := writer.WriteAdditionalData(m.GetAdditionalData())
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
}
|
||||
return nil
|
||||
}
|
||||
// SetAdditionalData sets the additionalData property value. Stores additional data not described in the OpenAPI description found when deserializing. Can be used for serialization as well.
|
||||
func (m *ItemInformationProtectionDataLossPreventionPoliciesEvaluatePostRequestBody) SetAdditionalData(value map[string]interface{})() {
|
||||
m.additionalData = value
|
||||
}
|
||||
// SetEvaluationInput sets the evaluationInput property value. The evaluationInput property
|
||||
func (m *ItemInformationProtectionDataLossPreventionPoliciesEvaluatePostRequestBody) SetEvaluationInput(value ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.DlpEvaluationInputable)() {
|
||||
m.evaluationInput = value
|
||||
}
|
||||
// SetNotificationInfo sets the notificationInfo property value. The notificationInfo property
|
||||
func (m *ItemInformationProtectionDataLossPreventionPoliciesEvaluatePostRequestBody) SetNotificationInfo(value ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.DlpNotificationable)() {
|
||||
m.notificationInfo = value
|
||||
}
|
||||
// SetTarget sets the target property value. The target property
|
||||
func (m *ItemInformationProtectionDataLossPreventionPoliciesEvaluatePostRequestBody) SetTarget(value *string)() {
|
||||
m.target = value
|
||||
}
|
||||
@ -1,18 +0,0 @@
|
||||
package sites
|
||||
|
||||
import (
|
||||
i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91 "github.com/microsoft/kiota-abstractions-go/serialization"
|
||||
ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models"
|
||||
)
|
||||
|
||||
// ItemInformationProtectionDataLossPreventionPoliciesEvaluatePostRequestBodyable
|
||||
type ItemInformationProtectionDataLossPreventionPoliciesEvaluatePostRequestBodyable interface {
|
||||
i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.AdditionalDataHolder
|
||||
i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.Parsable
|
||||
GetEvaluationInput()(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.DlpEvaluationInputable)
|
||||
GetNotificationInfo()(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.DlpNotificationable)
|
||||
GetTarget()(*string)
|
||||
SetEvaluationInput(value ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.DlpEvaluationInputable)()
|
||||
SetNotificationInfo(value ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.DlpNotificationable)()
|
||||
SetTarget(value *string)()
|
||||
}
|
||||
@ -1,77 +0,0 @@
|
||||
package sites
|
||||
|
||||
import (
|
||||
"context"
|
||||
i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f "github.com/microsoft/kiota-abstractions-go"
|
||||
ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models"
|
||||
i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models/odataerrors"
|
||||
)
|
||||
|
||||
// ItemInformationProtectionDataLossPreventionPoliciesEvaluateRequestBuilder provides operations to call the evaluate method.
|
||||
type ItemInformationProtectionDataLossPreventionPoliciesEvaluateRequestBuilder struct {
|
||||
// Path parameters for the request
|
||||
pathParameters map[string]string
|
||||
// The request adapter to use to execute the requests.
|
||||
requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter
|
||||
// Url template to use to build the URL for the current request builder
|
||||
urlTemplate string
|
||||
}
|
||||
// ItemInformationProtectionDataLossPreventionPoliciesEvaluateRequestBuilderPostRequestConfiguration configuration for the request such as headers, query parameters, and middleware options.
|
||||
type ItemInformationProtectionDataLossPreventionPoliciesEvaluateRequestBuilderPostRequestConfiguration struct {
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
}
|
||||
// NewItemInformationProtectionDataLossPreventionPoliciesEvaluateRequestBuilderInternal instantiates a new EvaluateRequestBuilder and sets the default values.
|
||||
func NewItemInformationProtectionDataLossPreventionPoliciesEvaluateRequestBuilderInternal(pathParameters map[string]string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemInformationProtectionDataLossPreventionPoliciesEvaluateRequestBuilder) {
|
||||
m := &ItemInformationProtectionDataLossPreventionPoliciesEvaluateRequestBuilder{
|
||||
}
|
||||
m.urlTemplate = "{+baseurl}/sites/{site%2Did}/informationProtection/dataLossPreventionPolicies/microsoft.graph.evaluate";
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
m.pathParameters = urlTplParams;
|
||||
m.requestAdapter = requestAdapter;
|
||||
return m
|
||||
}
|
||||
// NewItemInformationProtectionDataLossPreventionPoliciesEvaluateRequestBuilder instantiates a new EvaluateRequestBuilder and sets the default values.
|
||||
func NewItemInformationProtectionDataLossPreventionPoliciesEvaluateRequestBuilder(rawUrl string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemInformationProtectionDataLossPreventionPoliciesEvaluateRequestBuilder) {
|
||||
urlParams := make(map[string]string)
|
||||
urlParams["request-raw-url"] = rawUrl
|
||||
return NewItemInformationProtectionDataLossPreventionPoliciesEvaluateRequestBuilderInternal(urlParams, requestAdapter)
|
||||
}
|
||||
// CreatePostRequestInformation invoke action evaluate
|
||||
func (m *ItemInformationProtectionDataLossPreventionPoliciesEvaluateRequestBuilder) CreatePostRequestInformation(ctx context.Context, body ItemInformationProtectionDataLossPreventionPoliciesEvaluatePostRequestBodyable, requestConfiguration *ItemInformationProtectionDataLossPreventionPoliciesEvaluateRequestBuilderPostRequestConfiguration)(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.POST
|
||||
requestInfo.Headers.Add("Accept", "application/json")
|
||||
requestInfo.SetContentFromParsable(ctx, m.requestAdapter, "application/json", body)
|
||||
if requestConfiguration != nil {
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
}
|
||||
// Post invoke action evaluate
|
||||
func (m *ItemInformationProtectionDataLossPreventionPoliciesEvaluateRequestBuilder) Post(ctx context.Context, body ItemInformationProtectionDataLossPreventionPoliciesEvaluatePostRequestBodyable, requestConfiguration *ItemInformationProtectionDataLossPreventionPoliciesEvaluateRequestBuilderPostRequestConfiguration)(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.DlpEvaluatePoliciesJobResponseable, error) {
|
||||
requestInfo, err := m.CreatePostRequestInformation(ctx, body, requestConfiguration);
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings {
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.SendAsync(ctx, requestInfo, ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CreateDlpEvaluatePoliciesJobResponseFromDiscriminatorValue, errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.DlpEvaluatePoliciesJobResponseable), nil
|
||||
}
|
||||
@ -1,148 +0,0 @@
|
||||
package sites
|
||||
|
||||
import (
|
||||
"context"
|
||||
i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f "github.com/microsoft/kiota-abstractions-go"
|
||||
ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models"
|
||||
i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models/odataerrors"
|
||||
)
|
||||
|
||||
// ItemInformationProtectionDataLossPreventionPoliciesRequestBuilder provides operations to manage the dataLossPreventionPolicies property of the microsoft.graph.informationProtection entity.
|
||||
type ItemInformationProtectionDataLossPreventionPoliciesRequestBuilder struct {
|
||||
// Path parameters for the request
|
||||
pathParameters map[string]string
|
||||
// The request adapter to use to execute the requests.
|
||||
requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter
|
||||
// Url template to use to build the URL for the current request builder
|
||||
urlTemplate string
|
||||
}
|
||||
// ItemInformationProtectionDataLossPreventionPoliciesRequestBuilderGetQueryParameters get dataLossPreventionPolicies from sites
|
||||
type ItemInformationProtectionDataLossPreventionPoliciesRequestBuilderGetQueryParameters struct {
|
||||
// Include count of items
|
||||
Count *bool `uriparametername:"%24count"`
|
||||
// Expand related entities
|
||||
Expand []string `uriparametername:"%24expand"`
|
||||
// Filter items by property values
|
||||
Filter *string `uriparametername:"%24filter"`
|
||||
// Order items by property values
|
||||
Orderby []string `uriparametername:"%24orderby"`
|
||||
// Search items by search phrases
|
||||
Search *string `uriparametername:"%24search"`
|
||||
// Select properties to be returned
|
||||
Select []string `uriparametername:"%24select"`
|
||||
// Skip the first n items
|
||||
Skip *int32 `uriparametername:"%24skip"`
|
||||
// Show only the first n items
|
||||
Top *int32 `uriparametername:"%24top"`
|
||||
}
|
||||
// ItemInformationProtectionDataLossPreventionPoliciesRequestBuilderGetRequestConfiguration configuration for the request such as headers, query parameters, and middleware options.
|
||||
type ItemInformationProtectionDataLossPreventionPoliciesRequestBuilderGetRequestConfiguration struct {
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
// Request query parameters
|
||||
QueryParameters *ItemInformationProtectionDataLossPreventionPoliciesRequestBuilderGetQueryParameters
|
||||
}
|
||||
// ItemInformationProtectionDataLossPreventionPoliciesRequestBuilderPostRequestConfiguration configuration for the request such as headers, query parameters, and middleware options.
|
||||
type ItemInformationProtectionDataLossPreventionPoliciesRequestBuilderPostRequestConfiguration struct {
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
}
|
||||
// NewItemInformationProtectionDataLossPreventionPoliciesRequestBuilderInternal instantiates a new DataLossPreventionPoliciesRequestBuilder and sets the default values.
|
||||
func NewItemInformationProtectionDataLossPreventionPoliciesRequestBuilderInternal(pathParameters map[string]string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemInformationProtectionDataLossPreventionPoliciesRequestBuilder) {
|
||||
m := &ItemInformationProtectionDataLossPreventionPoliciesRequestBuilder{
|
||||
}
|
||||
m.urlTemplate = "{+baseurl}/sites/{site%2Did}/informationProtection/dataLossPreventionPolicies{?%24top,%24skip,%24search,%24filter,%24count,%24orderby,%24select,%24expand}";
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
m.pathParameters = urlTplParams;
|
||||
m.requestAdapter = requestAdapter;
|
||||
return m
|
||||
}
|
||||
// NewItemInformationProtectionDataLossPreventionPoliciesRequestBuilder instantiates a new DataLossPreventionPoliciesRequestBuilder and sets the default values.
|
||||
func NewItemInformationProtectionDataLossPreventionPoliciesRequestBuilder(rawUrl string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemInformationProtectionDataLossPreventionPoliciesRequestBuilder) {
|
||||
urlParams := make(map[string]string)
|
||||
urlParams["request-raw-url"] = rawUrl
|
||||
return NewItemInformationProtectionDataLossPreventionPoliciesRequestBuilderInternal(urlParams, requestAdapter)
|
||||
}
|
||||
// Count provides operations to count the resources in the collection.
|
||||
func (m *ItemInformationProtectionDataLossPreventionPoliciesRequestBuilder) Count()(*ItemInformationProtectionDataLossPreventionPoliciesCountRequestBuilder) {
|
||||
return NewItemInformationProtectionDataLossPreventionPoliciesCountRequestBuilderInternal(m.pathParameters, m.requestAdapter);
|
||||
}
|
||||
// CreateGetRequestInformation get dataLossPreventionPolicies from sites
|
||||
func (m *ItemInformationProtectionDataLossPreventionPoliciesRequestBuilder) CreateGetRequestInformation(ctx context.Context, requestConfiguration *ItemInformationProtectionDataLossPreventionPoliciesRequestBuilderGetRequestConfiguration)(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.GET
|
||||
requestInfo.Headers.Add("Accept", "application/json")
|
||||
if requestConfiguration != nil {
|
||||
if requestConfiguration.QueryParameters != nil {
|
||||
requestInfo.AddQueryParameters(*(requestConfiguration.QueryParameters))
|
||||
}
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
}
|
||||
// CreatePostRequestInformation create new navigation property to dataLossPreventionPolicies for sites
|
||||
func (m *ItemInformationProtectionDataLossPreventionPoliciesRequestBuilder) CreatePostRequestInformation(ctx context.Context, body ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.DataLossPreventionPolicyable, requestConfiguration *ItemInformationProtectionDataLossPreventionPoliciesRequestBuilderPostRequestConfiguration)(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.POST
|
||||
requestInfo.Headers.Add("Accept", "application/json")
|
||||
requestInfo.SetContentFromParsable(ctx, m.requestAdapter, "application/json", body)
|
||||
if requestConfiguration != nil {
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
}
|
||||
// Evaluate provides operations to call the evaluate method.
|
||||
func (m *ItemInformationProtectionDataLossPreventionPoliciesRequestBuilder) Evaluate()(*ItemInformationProtectionDataLossPreventionPoliciesEvaluateRequestBuilder) {
|
||||
return NewItemInformationProtectionDataLossPreventionPoliciesEvaluateRequestBuilderInternal(m.pathParameters, m.requestAdapter);
|
||||
}
|
||||
// Get get dataLossPreventionPolicies from sites
|
||||
func (m *ItemInformationProtectionDataLossPreventionPoliciesRequestBuilder) Get(ctx context.Context, requestConfiguration *ItemInformationProtectionDataLossPreventionPoliciesRequestBuilderGetRequestConfiguration)(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.DataLossPreventionPolicyCollectionResponseable, error) {
|
||||
requestInfo, err := m.CreateGetRequestInformation(ctx, requestConfiguration);
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings {
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.SendAsync(ctx, requestInfo, ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CreateDataLossPreventionPolicyCollectionResponseFromDiscriminatorValue, errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.DataLossPreventionPolicyCollectionResponseable), nil
|
||||
}
|
||||
// Post create new navigation property to dataLossPreventionPolicies for sites
|
||||
func (m *ItemInformationProtectionDataLossPreventionPoliciesRequestBuilder) Post(ctx context.Context, body ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.DataLossPreventionPolicyable, requestConfiguration *ItemInformationProtectionDataLossPreventionPoliciesRequestBuilderPostRequestConfiguration)(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.DataLossPreventionPolicyable, error) {
|
||||
requestInfo, err := m.CreatePostRequestInformation(ctx, body, requestConfiguration);
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings {
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.SendAsync(ctx, requestInfo, ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CreateDataLossPreventionPolicyFromDiscriminatorValue, errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.DataLossPreventionPolicyable), nil
|
||||
}
|
||||
@ -1,97 +0,0 @@
|
||||
package sites
|
||||
|
||||
import (
|
||||
i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91 "github.com/microsoft/kiota-abstractions-go/serialization"
|
||||
)
|
||||
|
||||
// ItemInformationProtectionDecryptBufferPostRequestBody provides operations to call the decryptBuffer method.
|
||||
type ItemInformationProtectionDecryptBufferPostRequestBody struct {
|
||||
// Stores additional data not described in the OpenAPI description found when deserializing. Can be used for serialization as well.
|
||||
additionalData map[string]interface{}
|
||||
// The encryptedBuffer property
|
||||
encryptedBuffer []byte
|
||||
// The publishingLicense property
|
||||
publishingLicense []byte
|
||||
}
|
||||
// NewItemInformationProtectionDecryptBufferPostRequestBody instantiates a new ItemInformationProtectionDecryptBufferPostRequestBody and sets the default values.
|
||||
func NewItemInformationProtectionDecryptBufferPostRequestBody()(*ItemInformationProtectionDecryptBufferPostRequestBody) {
|
||||
m := &ItemInformationProtectionDecryptBufferPostRequestBody{
|
||||
}
|
||||
m.SetAdditionalData(make(map[string]interface{}));
|
||||
return m
|
||||
}
|
||||
// CreateItemInformationProtectionDecryptBufferPostRequestBodyFromDiscriminatorValue creates a new instance of the appropriate class based on discriminator value
|
||||
func CreateItemInformationProtectionDecryptBufferPostRequestBodyFromDiscriminatorValue(parseNode i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.ParseNode)(i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.Parsable, error) {
|
||||
return NewItemInformationProtectionDecryptBufferPostRequestBody(), nil
|
||||
}
|
||||
// GetAdditionalData gets the additionalData property value. Stores additional data not described in the OpenAPI description found when deserializing. Can be used for serialization as well.
|
||||
func (m *ItemInformationProtectionDecryptBufferPostRequestBody) GetAdditionalData()(map[string]interface{}) {
|
||||
return m.additionalData
|
||||
}
|
||||
// GetEncryptedBuffer gets the encryptedBuffer property value. The encryptedBuffer property
|
||||
func (m *ItemInformationProtectionDecryptBufferPostRequestBody) GetEncryptedBuffer()([]byte) {
|
||||
return m.encryptedBuffer
|
||||
}
|
||||
// GetFieldDeserializers the deserialization information for the current model
|
||||
func (m *ItemInformationProtectionDecryptBufferPostRequestBody) GetFieldDeserializers()(map[string]func(i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.ParseNode)(error)) {
|
||||
res := make(map[string]func(i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.ParseNode)(error))
|
||||
res["encryptedBuffer"] = func (n i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.ParseNode) error {
|
||||
val, err := n.GetByteArrayValue()
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
if val != nil {
|
||||
m.SetEncryptedBuffer(val)
|
||||
}
|
||||
return nil
|
||||
}
|
||||
res["publishingLicense"] = func (n i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.ParseNode) error {
|
||||
val, err := n.GetByteArrayValue()
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
if val != nil {
|
||||
m.SetPublishingLicense(val)
|
||||
}
|
||||
return nil
|
||||
}
|
||||
return res
|
||||
}
|
||||
// GetPublishingLicense gets the publishingLicense property value. The publishingLicense property
|
||||
func (m *ItemInformationProtectionDecryptBufferPostRequestBody) GetPublishingLicense()([]byte) {
|
||||
return m.publishingLicense
|
||||
}
|
||||
// Serialize serializes information the current object
|
||||
func (m *ItemInformationProtectionDecryptBufferPostRequestBody) Serialize(writer i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.SerializationWriter)(error) {
|
||||
{
|
||||
err := writer.WriteByteArrayValue("encryptedBuffer", m.GetEncryptedBuffer())
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
}
|
||||
{
|
||||
err := writer.WriteByteArrayValue("publishingLicense", m.GetPublishingLicense())
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
}
|
||||
{
|
||||
err := writer.WriteAdditionalData(m.GetAdditionalData())
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
}
|
||||
return nil
|
||||
}
|
||||
// SetAdditionalData sets the additionalData property value. Stores additional data not described in the OpenAPI description found when deserializing. Can be used for serialization as well.
|
||||
func (m *ItemInformationProtectionDecryptBufferPostRequestBody) SetAdditionalData(value map[string]interface{})() {
|
||||
m.additionalData = value
|
||||
}
|
||||
// SetEncryptedBuffer sets the encryptedBuffer property value. The encryptedBuffer property
|
||||
func (m *ItemInformationProtectionDecryptBufferPostRequestBody) SetEncryptedBuffer(value []byte)() {
|
||||
m.encryptedBuffer = value
|
||||
}
|
||||
// SetPublishingLicense sets the publishingLicense property value. The publishingLicense property
|
||||
func (m *ItemInformationProtectionDecryptBufferPostRequestBody) SetPublishingLicense(value []byte)() {
|
||||
m.publishingLicense = value
|
||||
}
|
||||
@ -1,15 +0,0 @@
|
||||
package sites
|
||||
|
||||
import (
|
||||
i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91 "github.com/microsoft/kiota-abstractions-go/serialization"
|
||||
)
|
||||
|
||||
// ItemInformationProtectionDecryptBufferPostRequestBodyable
|
||||
type ItemInformationProtectionDecryptBufferPostRequestBodyable interface {
|
||||
i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.AdditionalDataHolder
|
||||
i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.Parsable
|
||||
GetEncryptedBuffer()([]byte)
|
||||
GetPublishingLicense()([]byte)
|
||||
SetEncryptedBuffer(value []byte)()
|
||||
SetPublishingLicense(value []byte)()
|
||||
}
|
||||
@ -1,77 +0,0 @@
|
||||
package sites
|
||||
|
||||
import (
|
||||
"context"
|
||||
i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f "github.com/microsoft/kiota-abstractions-go"
|
||||
ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models"
|
||||
i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models/odataerrors"
|
||||
)
|
||||
|
||||
// ItemInformationProtectionDecryptBufferRequestBuilder provides operations to call the decryptBuffer method.
|
||||
type ItemInformationProtectionDecryptBufferRequestBuilder struct {
|
||||
// Path parameters for the request
|
||||
pathParameters map[string]string
|
||||
// The request adapter to use to execute the requests.
|
||||
requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter
|
||||
// Url template to use to build the URL for the current request builder
|
||||
urlTemplate string
|
||||
}
|
||||
// ItemInformationProtectionDecryptBufferRequestBuilderPostRequestConfiguration configuration for the request such as headers, query parameters, and middleware options.
|
||||
type ItemInformationProtectionDecryptBufferRequestBuilderPostRequestConfiguration struct {
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
}
|
||||
// NewItemInformationProtectionDecryptBufferRequestBuilderInternal instantiates a new DecryptBufferRequestBuilder and sets the default values.
|
||||
func NewItemInformationProtectionDecryptBufferRequestBuilderInternal(pathParameters map[string]string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemInformationProtectionDecryptBufferRequestBuilder) {
|
||||
m := &ItemInformationProtectionDecryptBufferRequestBuilder{
|
||||
}
|
||||
m.urlTemplate = "{+baseurl}/sites/{site%2Did}/informationProtection/microsoft.graph.decryptBuffer";
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
m.pathParameters = urlTplParams;
|
||||
m.requestAdapter = requestAdapter;
|
||||
return m
|
||||
}
|
||||
// NewItemInformationProtectionDecryptBufferRequestBuilder instantiates a new DecryptBufferRequestBuilder and sets the default values.
|
||||
func NewItemInformationProtectionDecryptBufferRequestBuilder(rawUrl string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemInformationProtectionDecryptBufferRequestBuilder) {
|
||||
urlParams := make(map[string]string)
|
||||
urlParams["request-raw-url"] = rawUrl
|
||||
return NewItemInformationProtectionDecryptBufferRequestBuilderInternal(urlParams, requestAdapter)
|
||||
}
|
||||
// CreatePostRequestInformation invoke action decryptBuffer
|
||||
func (m *ItemInformationProtectionDecryptBufferRequestBuilder) CreatePostRequestInformation(ctx context.Context, body ItemInformationProtectionDecryptBufferPostRequestBodyable, requestConfiguration *ItemInformationProtectionDecryptBufferRequestBuilderPostRequestConfiguration)(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.POST
|
||||
requestInfo.Headers.Add("Accept", "application/json")
|
||||
requestInfo.SetContentFromParsable(ctx, m.requestAdapter, "application/json", body)
|
||||
if requestConfiguration != nil {
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
}
|
||||
// Post invoke action decryptBuffer
|
||||
func (m *ItemInformationProtectionDecryptBufferRequestBuilder) Post(ctx context.Context, body ItemInformationProtectionDecryptBufferPostRequestBodyable, requestConfiguration *ItemInformationProtectionDecryptBufferRequestBuilderPostRequestConfiguration)(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.BufferDecryptionResultable, error) {
|
||||
requestInfo, err := m.CreatePostRequestInformation(ctx, body, requestConfiguration);
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings {
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.SendAsync(ctx, requestInfo, ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CreateBufferDecryptionResultFromDiscriminatorValue, errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.BufferDecryptionResultable), nil
|
||||
}
|
||||
@ -1,98 +0,0 @@
|
||||
package sites
|
||||
|
||||
import (
|
||||
i561e97a8befe7661a44c8f54600992b4207a3a0cf6770e5559949bc276de2e22 "github.com/google/uuid"
|
||||
i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91 "github.com/microsoft/kiota-abstractions-go/serialization"
|
||||
)
|
||||
|
||||
// ItemInformationProtectionEncryptBufferPostRequestBody provides operations to call the encryptBuffer method.
|
||||
type ItemInformationProtectionEncryptBufferPostRequestBody struct {
|
||||
// Stores additional data not described in the OpenAPI description found when deserializing. Can be used for serialization as well.
|
||||
additionalData map[string]interface{}
|
||||
// The buffer property
|
||||
buffer []byte
|
||||
// The labelId property
|
||||
labelId *i561e97a8befe7661a44c8f54600992b4207a3a0cf6770e5559949bc276de2e22.UUID
|
||||
}
|
||||
// NewItemInformationProtectionEncryptBufferPostRequestBody instantiates a new ItemInformationProtectionEncryptBufferPostRequestBody and sets the default values.
|
||||
func NewItemInformationProtectionEncryptBufferPostRequestBody()(*ItemInformationProtectionEncryptBufferPostRequestBody) {
|
||||
m := &ItemInformationProtectionEncryptBufferPostRequestBody{
|
||||
}
|
||||
m.SetAdditionalData(make(map[string]interface{}));
|
||||
return m
|
||||
}
|
||||
// CreateItemInformationProtectionEncryptBufferPostRequestBodyFromDiscriminatorValue creates a new instance of the appropriate class based on discriminator value
|
||||
func CreateItemInformationProtectionEncryptBufferPostRequestBodyFromDiscriminatorValue(parseNode i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.ParseNode)(i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.Parsable, error) {
|
||||
return NewItemInformationProtectionEncryptBufferPostRequestBody(), nil
|
||||
}
|
||||
// GetAdditionalData gets the additionalData property value. Stores additional data not described in the OpenAPI description found when deserializing. Can be used for serialization as well.
|
||||
func (m *ItemInformationProtectionEncryptBufferPostRequestBody) GetAdditionalData()(map[string]interface{}) {
|
||||
return m.additionalData
|
||||
}
|
||||
// GetBuffer gets the buffer property value. The buffer property
|
||||
func (m *ItemInformationProtectionEncryptBufferPostRequestBody) GetBuffer()([]byte) {
|
||||
return m.buffer
|
||||
}
|
||||
// GetFieldDeserializers the deserialization information for the current model
|
||||
func (m *ItemInformationProtectionEncryptBufferPostRequestBody) GetFieldDeserializers()(map[string]func(i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.ParseNode)(error)) {
|
||||
res := make(map[string]func(i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.ParseNode)(error))
|
||||
res["buffer"] = func (n i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.ParseNode) error {
|
||||
val, err := n.GetByteArrayValue()
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
if val != nil {
|
||||
m.SetBuffer(val)
|
||||
}
|
||||
return nil
|
||||
}
|
||||
res["labelId"] = func (n i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.ParseNode) error {
|
||||
val, err := n.GetUUIDValue()
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
if val != nil {
|
||||
m.SetLabelId(val)
|
||||
}
|
||||
return nil
|
||||
}
|
||||
return res
|
||||
}
|
||||
// GetLabelId gets the labelId property value. The labelId property
|
||||
func (m *ItemInformationProtectionEncryptBufferPostRequestBody) GetLabelId()(*i561e97a8befe7661a44c8f54600992b4207a3a0cf6770e5559949bc276de2e22.UUID) {
|
||||
return m.labelId
|
||||
}
|
||||
// Serialize serializes information the current object
|
||||
func (m *ItemInformationProtectionEncryptBufferPostRequestBody) Serialize(writer i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.SerializationWriter)(error) {
|
||||
{
|
||||
err := writer.WriteByteArrayValue("buffer", m.GetBuffer())
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
}
|
||||
{
|
||||
err := writer.WriteUUIDValue("labelId", m.GetLabelId())
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
}
|
||||
{
|
||||
err := writer.WriteAdditionalData(m.GetAdditionalData())
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
}
|
||||
return nil
|
||||
}
|
||||
// SetAdditionalData sets the additionalData property value. Stores additional data not described in the OpenAPI description found when deserializing. Can be used for serialization as well.
|
||||
func (m *ItemInformationProtectionEncryptBufferPostRequestBody) SetAdditionalData(value map[string]interface{})() {
|
||||
m.additionalData = value
|
||||
}
|
||||
// SetBuffer sets the buffer property value. The buffer property
|
||||
func (m *ItemInformationProtectionEncryptBufferPostRequestBody) SetBuffer(value []byte)() {
|
||||
m.buffer = value
|
||||
}
|
||||
// SetLabelId sets the labelId property value. The labelId property
|
||||
func (m *ItemInformationProtectionEncryptBufferPostRequestBody) SetLabelId(value *i561e97a8befe7661a44c8f54600992b4207a3a0cf6770e5559949bc276de2e22.UUID)() {
|
||||
m.labelId = value
|
||||
}
|
||||
@ -1,16 +0,0 @@
|
||||
package sites
|
||||
|
||||
import (
|
||||
i561e97a8befe7661a44c8f54600992b4207a3a0cf6770e5559949bc276de2e22 "github.com/google/uuid"
|
||||
i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91 "github.com/microsoft/kiota-abstractions-go/serialization"
|
||||
)
|
||||
|
||||
// ItemInformationProtectionEncryptBufferPostRequestBodyable
|
||||
type ItemInformationProtectionEncryptBufferPostRequestBodyable interface {
|
||||
i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.AdditionalDataHolder
|
||||
i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.Parsable
|
||||
GetBuffer()([]byte)
|
||||
GetLabelId()(*i561e97a8befe7661a44c8f54600992b4207a3a0cf6770e5559949bc276de2e22.UUID)
|
||||
SetBuffer(value []byte)()
|
||||
SetLabelId(value *i561e97a8befe7661a44c8f54600992b4207a3a0cf6770e5559949bc276de2e22.UUID)()
|
||||
}
|
||||
@ -1,77 +0,0 @@
|
||||
package sites
|
||||
|
||||
import (
|
||||
"context"
|
||||
i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f "github.com/microsoft/kiota-abstractions-go"
|
||||
ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models"
|
||||
i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models/odataerrors"
|
||||
)
|
||||
|
||||
// ItemInformationProtectionEncryptBufferRequestBuilder provides operations to call the encryptBuffer method.
|
||||
type ItemInformationProtectionEncryptBufferRequestBuilder struct {
|
||||
// Path parameters for the request
|
||||
pathParameters map[string]string
|
||||
// The request adapter to use to execute the requests.
|
||||
requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter
|
||||
// Url template to use to build the URL for the current request builder
|
||||
urlTemplate string
|
||||
}
|
||||
// ItemInformationProtectionEncryptBufferRequestBuilderPostRequestConfiguration configuration for the request such as headers, query parameters, and middleware options.
|
||||
type ItemInformationProtectionEncryptBufferRequestBuilderPostRequestConfiguration struct {
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
}
|
||||
// NewItemInformationProtectionEncryptBufferRequestBuilderInternal instantiates a new EncryptBufferRequestBuilder and sets the default values.
|
||||
func NewItemInformationProtectionEncryptBufferRequestBuilderInternal(pathParameters map[string]string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemInformationProtectionEncryptBufferRequestBuilder) {
|
||||
m := &ItemInformationProtectionEncryptBufferRequestBuilder{
|
||||
}
|
||||
m.urlTemplate = "{+baseurl}/sites/{site%2Did}/informationProtection/microsoft.graph.encryptBuffer";
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
m.pathParameters = urlTplParams;
|
||||
m.requestAdapter = requestAdapter;
|
||||
return m
|
||||
}
|
||||
// NewItemInformationProtectionEncryptBufferRequestBuilder instantiates a new EncryptBufferRequestBuilder and sets the default values.
|
||||
func NewItemInformationProtectionEncryptBufferRequestBuilder(rawUrl string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemInformationProtectionEncryptBufferRequestBuilder) {
|
||||
urlParams := make(map[string]string)
|
||||
urlParams["request-raw-url"] = rawUrl
|
||||
return NewItemInformationProtectionEncryptBufferRequestBuilderInternal(urlParams, requestAdapter)
|
||||
}
|
||||
// CreatePostRequestInformation invoke action encryptBuffer
|
||||
func (m *ItemInformationProtectionEncryptBufferRequestBuilder) CreatePostRequestInformation(ctx context.Context, body ItemInformationProtectionEncryptBufferPostRequestBodyable, requestConfiguration *ItemInformationProtectionEncryptBufferRequestBuilderPostRequestConfiguration)(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.POST
|
||||
requestInfo.Headers.Add("Accept", "application/json")
|
||||
requestInfo.SetContentFromParsable(ctx, m.requestAdapter, "application/json", body)
|
||||
if requestConfiguration != nil {
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
}
|
||||
// Post invoke action encryptBuffer
|
||||
func (m *ItemInformationProtectionEncryptBufferRequestBuilder) Post(ctx context.Context, body ItemInformationProtectionEncryptBufferPostRequestBodyable, requestConfiguration *ItemInformationProtectionEncryptBufferRequestBuilderPostRequestConfiguration)(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.BufferEncryptionResultable, error) {
|
||||
requestInfo, err := m.CreatePostRequestInformation(ctx, body, requestConfiguration);
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings {
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.SendAsync(ctx, requestInfo, ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CreateBufferEncryptionResultFromDiscriminatorValue, errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.BufferEncryptionResultable), nil
|
||||
}
|
||||
@ -1,87 +0,0 @@
|
||||
package sites
|
||||
|
||||
import (
|
||||
"context"
|
||||
i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f "github.com/microsoft/kiota-abstractions-go"
|
||||
i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models/odataerrors"
|
||||
)
|
||||
|
||||
// ItemInformationProtectionPolicyLabelsCountRequestBuilder provides operations to count the resources in the collection.
|
||||
type ItemInformationProtectionPolicyLabelsCountRequestBuilder struct {
|
||||
// Path parameters for the request
|
||||
pathParameters map[string]string
|
||||
// The request adapter to use to execute the requests.
|
||||
requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter
|
||||
// Url template to use to build the URL for the current request builder
|
||||
urlTemplate string
|
||||
}
|
||||
// ItemInformationProtectionPolicyLabelsCountRequestBuilderGetQueryParameters get the number of the resource
|
||||
type ItemInformationProtectionPolicyLabelsCountRequestBuilderGetQueryParameters struct {
|
||||
// Filter items by property values
|
||||
Filter *string `uriparametername:"%24filter"`
|
||||
// Search items by search phrases
|
||||
Search *string `uriparametername:"%24search"`
|
||||
}
|
||||
// ItemInformationProtectionPolicyLabelsCountRequestBuilderGetRequestConfiguration configuration for the request such as headers, query parameters, and middleware options.
|
||||
type ItemInformationProtectionPolicyLabelsCountRequestBuilderGetRequestConfiguration struct {
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
// Request query parameters
|
||||
QueryParameters *ItemInformationProtectionPolicyLabelsCountRequestBuilderGetQueryParameters
|
||||
}
|
||||
// NewItemInformationProtectionPolicyLabelsCountRequestBuilderInternal instantiates a new CountRequestBuilder and sets the default values.
|
||||
func NewItemInformationProtectionPolicyLabelsCountRequestBuilderInternal(pathParameters map[string]string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemInformationProtectionPolicyLabelsCountRequestBuilder) {
|
||||
m := &ItemInformationProtectionPolicyLabelsCountRequestBuilder{
|
||||
}
|
||||
m.urlTemplate = "{+baseurl}/sites/{site%2Did}/informationProtection/policy/labels/$count{?%24search,%24filter}";
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
m.pathParameters = urlTplParams;
|
||||
m.requestAdapter = requestAdapter;
|
||||
return m
|
||||
}
|
||||
// NewItemInformationProtectionPolicyLabelsCountRequestBuilder instantiates a new CountRequestBuilder and sets the default values.
|
||||
func NewItemInformationProtectionPolicyLabelsCountRequestBuilder(rawUrl string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemInformationProtectionPolicyLabelsCountRequestBuilder) {
|
||||
urlParams := make(map[string]string)
|
||||
urlParams["request-raw-url"] = rawUrl
|
||||
return NewItemInformationProtectionPolicyLabelsCountRequestBuilderInternal(urlParams, requestAdapter)
|
||||
}
|
||||
// CreateGetRequestInformation get the number of the resource
|
||||
func (m *ItemInformationProtectionPolicyLabelsCountRequestBuilder) CreateGetRequestInformation(ctx context.Context, requestConfiguration *ItemInformationProtectionPolicyLabelsCountRequestBuilderGetRequestConfiguration)(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.GET
|
||||
requestInfo.Headers.Add("Accept", "text/plain")
|
||||
if requestConfiguration != nil {
|
||||
if requestConfiguration.QueryParameters != nil {
|
||||
requestInfo.AddQueryParameters(*(requestConfiguration.QueryParameters))
|
||||
}
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
}
|
||||
// Get get the number of the resource
|
||||
func (m *ItemInformationProtectionPolicyLabelsCountRequestBuilder) Get(ctx context.Context, requestConfiguration *ItemInformationProtectionPolicyLabelsCountRequestBuilderGetRequestConfiguration)(*int32, error) {
|
||||
requestInfo, err := m.CreateGetRequestInformation(ctx, requestConfiguration);
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings {
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.SendPrimitiveAsync(ctx, requestInfo, "int32", errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(*int32), nil
|
||||
}
|
||||
@ -1,98 +0,0 @@
|
||||
package sites
|
||||
|
||||
import (
|
||||
i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91 "github.com/microsoft/kiota-abstractions-go/serialization"
|
||||
ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models"
|
||||
)
|
||||
|
||||
// ItemInformationProtectionPolicyLabelsEvaluateApplicationPostRequestBody provides operations to call the evaluateApplication method.
|
||||
type ItemInformationProtectionPolicyLabelsEvaluateApplicationPostRequestBody struct {
|
||||
// Stores additional data not described in the OpenAPI description found when deserializing. Can be used for serialization as well.
|
||||
additionalData map[string]interface{}
|
||||
// The contentInfo property
|
||||
contentInfo ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ContentInfoable
|
||||
// The labelingOptions property
|
||||
labelingOptions ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.LabelingOptionsable
|
||||
}
|
||||
// NewItemInformationProtectionPolicyLabelsEvaluateApplicationPostRequestBody instantiates a new ItemInformationProtectionPolicyLabelsEvaluateApplicationPostRequestBody and sets the default values.
|
||||
func NewItemInformationProtectionPolicyLabelsEvaluateApplicationPostRequestBody()(*ItemInformationProtectionPolicyLabelsEvaluateApplicationPostRequestBody) {
|
||||
m := &ItemInformationProtectionPolicyLabelsEvaluateApplicationPostRequestBody{
|
||||
}
|
||||
m.SetAdditionalData(make(map[string]interface{}));
|
||||
return m
|
||||
}
|
||||
// CreateItemInformationProtectionPolicyLabelsEvaluateApplicationPostRequestBodyFromDiscriminatorValue creates a new instance of the appropriate class based on discriminator value
|
||||
func CreateItemInformationProtectionPolicyLabelsEvaluateApplicationPostRequestBodyFromDiscriminatorValue(parseNode i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.ParseNode)(i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.Parsable, error) {
|
||||
return NewItemInformationProtectionPolicyLabelsEvaluateApplicationPostRequestBody(), nil
|
||||
}
|
||||
// GetAdditionalData gets the additionalData property value. Stores additional data not described in the OpenAPI description found when deserializing. Can be used for serialization as well.
|
||||
func (m *ItemInformationProtectionPolicyLabelsEvaluateApplicationPostRequestBody) GetAdditionalData()(map[string]interface{}) {
|
||||
return m.additionalData
|
||||
}
|
||||
// GetContentInfo gets the contentInfo property value. The contentInfo property
|
||||
func (m *ItemInformationProtectionPolicyLabelsEvaluateApplicationPostRequestBody) GetContentInfo()(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ContentInfoable) {
|
||||
return m.contentInfo
|
||||
}
|
||||
// GetFieldDeserializers the deserialization information for the current model
|
||||
func (m *ItemInformationProtectionPolicyLabelsEvaluateApplicationPostRequestBody) GetFieldDeserializers()(map[string]func(i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.ParseNode)(error)) {
|
||||
res := make(map[string]func(i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.ParseNode)(error))
|
||||
res["contentInfo"] = func (n i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.ParseNode) error {
|
||||
val, err := n.GetObjectValue(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CreateContentInfoFromDiscriminatorValue)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
if val != nil {
|
||||
m.SetContentInfo(val.(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ContentInfoable))
|
||||
}
|
||||
return nil
|
||||
}
|
||||
res["labelingOptions"] = func (n i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.ParseNode) error {
|
||||
val, err := n.GetObjectValue(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CreateLabelingOptionsFromDiscriminatorValue)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
if val != nil {
|
||||
m.SetLabelingOptions(val.(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.LabelingOptionsable))
|
||||
}
|
||||
return nil
|
||||
}
|
||||
return res
|
||||
}
|
||||
// GetLabelingOptions gets the labelingOptions property value. The labelingOptions property
|
||||
func (m *ItemInformationProtectionPolicyLabelsEvaluateApplicationPostRequestBody) GetLabelingOptions()(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.LabelingOptionsable) {
|
||||
return m.labelingOptions
|
||||
}
|
||||
// Serialize serializes information the current object
|
||||
func (m *ItemInformationProtectionPolicyLabelsEvaluateApplicationPostRequestBody) Serialize(writer i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.SerializationWriter)(error) {
|
||||
{
|
||||
err := writer.WriteObjectValue("contentInfo", m.GetContentInfo())
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
}
|
||||
{
|
||||
err := writer.WriteObjectValue("labelingOptions", m.GetLabelingOptions())
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
}
|
||||
{
|
||||
err := writer.WriteAdditionalData(m.GetAdditionalData())
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
}
|
||||
return nil
|
||||
}
|
||||
// SetAdditionalData sets the additionalData property value. Stores additional data not described in the OpenAPI description found when deserializing. Can be used for serialization as well.
|
||||
func (m *ItemInformationProtectionPolicyLabelsEvaluateApplicationPostRequestBody) SetAdditionalData(value map[string]interface{})() {
|
||||
m.additionalData = value
|
||||
}
|
||||
// SetContentInfo sets the contentInfo property value. The contentInfo property
|
||||
func (m *ItemInformationProtectionPolicyLabelsEvaluateApplicationPostRequestBody) SetContentInfo(value ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ContentInfoable)() {
|
||||
m.contentInfo = value
|
||||
}
|
||||
// SetLabelingOptions sets the labelingOptions property value. The labelingOptions property
|
||||
func (m *ItemInformationProtectionPolicyLabelsEvaluateApplicationPostRequestBody) SetLabelingOptions(value ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.LabelingOptionsable)() {
|
||||
m.labelingOptions = value
|
||||
}
|
||||
@ -1,16 +0,0 @@
|
||||
package sites
|
||||
|
||||
import (
|
||||
i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91 "github.com/microsoft/kiota-abstractions-go/serialization"
|
||||
ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models"
|
||||
)
|
||||
|
||||
// ItemInformationProtectionPolicyLabelsEvaluateApplicationPostRequestBodyable
|
||||
type ItemInformationProtectionPolicyLabelsEvaluateApplicationPostRequestBodyable interface {
|
||||
i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.AdditionalDataHolder
|
||||
i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.Parsable
|
||||
GetContentInfo()(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ContentInfoable)
|
||||
GetLabelingOptions()(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.LabelingOptionsable)
|
||||
SetContentInfo(value ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ContentInfoable)()
|
||||
SetLabelingOptions(value ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.LabelingOptionsable)()
|
||||
}
|
||||
@ -1,79 +0,0 @@
|
||||
package sites
|
||||
|
||||
import (
|
||||
"context"
|
||||
i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f "github.com/microsoft/kiota-abstractions-go"
|
||||
i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models/odataerrors"
|
||||
)
|
||||
|
||||
// ItemInformationProtectionPolicyLabelsEvaluateApplicationRequestBuilder provides operations to call the evaluateApplication method.
|
||||
type ItemInformationProtectionPolicyLabelsEvaluateApplicationRequestBuilder struct {
|
||||
// Path parameters for the request
|
||||
pathParameters map[string]string
|
||||
// The request adapter to use to execute the requests.
|
||||
requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter
|
||||
// Url template to use to build the URL for the current request builder
|
||||
urlTemplate string
|
||||
}
|
||||
// ItemInformationProtectionPolicyLabelsEvaluateApplicationRequestBuilderPostRequestConfiguration configuration for the request such as headers, query parameters, and middleware options.
|
||||
type ItemInformationProtectionPolicyLabelsEvaluateApplicationRequestBuilderPostRequestConfiguration struct {
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
}
|
||||
// NewItemInformationProtectionPolicyLabelsEvaluateApplicationRequestBuilderInternal instantiates a new EvaluateApplicationRequestBuilder and sets the default values.
|
||||
func NewItemInformationProtectionPolicyLabelsEvaluateApplicationRequestBuilderInternal(pathParameters map[string]string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemInformationProtectionPolicyLabelsEvaluateApplicationRequestBuilder) {
|
||||
m := &ItemInformationProtectionPolicyLabelsEvaluateApplicationRequestBuilder{
|
||||
}
|
||||
m.urlTemplate = "{+baseurl}/sites/{site%2Did}/informationProtection/policy/labels/microsoft.graph.evaluateApplication";
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
m.pathParameters = urlTplParams;
|
||||
m.requestAdapter = requestAdapter;
|
||||
return m
|
||||
}
|
||||
// NewItemInformationProtectionPolicyLabelsEvaluateApplicationRequestBuilder instantiates a new EvaluateApplicationRequestBuilder and sets the default values.
|
||||
func NewItemInformationProtectionPolicyLabelsEvaluateApplicationRequestBuilder(rawUrl string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemInformationProtectionPolicyLabelsEvaluateApplicationRequestBuilder) {
|
||||
urlParams := make(map[string]string)
|
||||
urlParams["request-raw-url"] = rawUrl
|
||||
return NewItemInformationProtectionPolicyLabelsEvaluateApplicationRequestBuilderInternal(urlParams, requestAdapter)
|
||||
}
|
||||
// CreatePostRequestInformation compute the information protection label that should be applied and return the set of actions that must be taken to correctly label the information. This API is useful when a label should be set manually or explicitly by a user or service, rather than automatically based on file contents. Given contentInfo, which includes existing content metadata key/value pairs, and labelingOptions as an input, the API returns an informationProtectionAction object that contains one of more of the following:
|
||||
func (m *ItemInformationProtectionPolicyLabelsEvaluateApplicationRequestBuilder) CreatePostRequestInformation(ctx context.Context, body ItemInformationProtectionPolicyLabelsEvaluateApplicationPostRequestBodyable, requestConfiguration *ItemInformationProtectionPolicyLabelsEvaluateApplicationRequestBuilderPostRequestConfiguration)(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.POST
|
||||
requestInfo.Headers.Add("Accept", "application/json")
|
||||
requestInfo.SetContentFromParsable(ctx, m.requestAdapter, "application/json", body)
|
||||
if requestConfiguration != nil {
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
}
|
||||
// Post compute the information protection label that should be applied and return the set of actions that must be taken to correctly label the information. This API is useful when a label should be set manually or explicitly by a user or service, rather than automatically based on file contents. Given contentInfo, which includes existing content metadata key/value pairs, and labelingOptions as an input, the API returns an informationProtectionAction object that contains one of more of the following:
|
||||
// [Find more info here]
|
||||
//
|
||||
// [Find more info here]: https://docs.microsoft.com/graph/api/informationprotectionlabel-evaluateapplication?view=graph-rest-1.0
|
||||
func (m *ItemInformationProtectionPolicyLabelsEvaluateApplicationRequestBuilder) Post(ctx context.Context, body ItemInformationProtectionPolicyLabelsEvaluateApplicationPostRequestBodyable, requestConfiguration *ItemInformationProtectionPolicyLabelsEvaluateApplicationRequestBuilderPostRequestConfiguration)(ItemInformationProtectionPolicyLabelsEvaluateApplicationResponseable, error) {
|
||||
requestInfo, err := m.CreatePostRequestInformation(ctx, body, requestConfiguration);
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings {
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.SendAsync(ctx, requestInfo, CreateItemInformationProtectionPolicyLabelsEvaluateApplicationResponseFromDiscriminatorValue, errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(ItemInformationProtectionPolicyLabelsEvaluateApplicationResponseable), nil
|
||||
}
|
||||
@ -1,69 +0,0 @@
|
||||
package sites
|
||||
|
||||
import (
|
||||
i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91 "github.com/microsoft/kiota-abstractions-go/serialization"
|
||||
ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models"
|
||||
)
|
||||
|
||||
// ItemInformationProtectionPolicyLabelsEvaluateApplicationResponse provides operations to call the evaluateApplication method.
|
||||
type ItemInformationProtectionPolicyLabelsEvaluateApplicationResponse struct {
|
||||
ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.BaseCollectionPaginationCountResponse
|
||||
// The value property
|
||||
value []ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.InformationProtectionActionable
|
||||
}
|
||||
// NewItemInformationProtectionPolicyLabelsEvaluateApplicationResponse instantiates a new ItemInformationProtectionPolicyLabelsEvaluateApplicationResponse and sets the default values.
|
||||
func NewItemInformationProtectionPolicyLabelsEvaluateApplicationResponse()(*ItemInformationProtectionPolicyLabelsEvaluateApplicationResponse) {
|
||||
m := &ItemInformationProtectionPolicyLabelsEvaluateApplicationResponse{
|
||||
BaseCollectionPaginationCountResponse: *ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.NewBaseCollectionPaginationCountResponse(),
|
||||
}
|
||||
return m
|
||||
}
|
||||
// CreateItemInformationProtectionPolicyLabelsEvaluateApplicationResponseFromDiscriminatorValue creates a new instance of the appropriate class based on discriminator value
|
||||
func CreateItemInformationProtectionPolicyLabelsEvaluateApplicationResponseFromDiscriminatorValue(parseNode i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.ParseNode)(i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.Parsable, error) {
|
||||
return NewItemInformationProtectionPolicyLabelsEvaluateApplicationResponse(), nil
|
||||
}
|
||||
// GetFieldDeserializers the deserialization information for the current model
|
||||
func (m *ItemInformationProtectionPolicyLabelsEvaluateApplicationResponse) GetFieldDeserializers()(map[string]func(i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.ParseNode)(error)) {
|
||||
res := m.BaseCollectionPaginationCountResponse.GetFieldDeserializers()
|
||||
res["value"] = func (n i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.ParseNode) error {
|
||||
val, err := n.GetCollectionOfObjectValues(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CreateInformationProtectionActionFromDiscriminatorValue)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
if val != nil {
|
||||
res := make([]ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.InformationProtectionActionable, len(val))
|
||||
for i, v := range val {
|
||||
res[i] = v.(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.InformationProtectionActionable)
|
||||
}
|
||||
m.SetValue(res)
|
||||
}
|
||||
return nil
|
||||
}
|
||||
return res
|
||||
}
|
||||
// GetValue gets the value property value. The value property
|
||||
func (m *ItemInformationProtectionPolicyLabelsEvaluateApplicationResponse) GetValue()([]ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.InformationProtectionActionable) {
|
||||
return m.value
|
||||
}
|
||||
// Serialize serializes information the current object
|
||||
func (m *ItemInformationProtectionPolicyLabelsEvaluateApplicationResponse) Serialize(writer i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.SerializationWriter)(error) {
|
||||
err := m.BaseCollectionPaginationCountResponse.Serialize(writer)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
if m.GetValue() != nil {
|
||||
cast := make([]i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.Parsable, len(m.GetValue()))
|
||||
for i, v := range m.GetValue() {
|
||||
cast[i] = v.(i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.Parsable)
|
||||
}
|
||||
err = writer.WriteCollectionOfObjectValues("value", cast)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
}
|
||||
return nil
|
||||
}
|
||||
// SetValue sets the value property value. The value property
|
||||
func (m *ItemInformationProtectionPolicyLabelsEvaluateApplicationResponse) SetValue(value []ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.InformationProtectionActionable)() {
|
||||
m.value = value
|
||||
}
|
||||
@ -1,14 +0,0 @@
|
||||
package sites
|
||||
|
||||
import (
|
||||
i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91 "github.com/microsoft/kiota-abstractions-go/serialization"
|
||||
ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models"
|
||||
)
|
||||
|
||||
// ItemInformationProtectionPolicyLabelsEvaluateApplicationResponseable
|
||||
type ItemInformationProtectionPolicyLabelsEvaluateApplicationResponseable interface {
|
||||
ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.BaseCollectionPaginationCountResponseable
|
||||
i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.Parsable
|
||||
GetValue()([]ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.InformationProtectionActionable)
|
||||
SetValue(value []ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.InformationProtectionActionable)()
|
||||
}
|
||||
@ -1,106 +0,0 @@
|
||||
package sites
|
||||
|
||||
import (
|
||||
i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91 "github.com/microsoft/kiota-abstractions-go/serialization"
|
||||
ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models"
|
||||
)
|
||||
|
||||
// ItemInformationProtectionPolicyLabelsEvaluateClassificationResultsPostRequestBody provides operations to call the evaluateClassificationResults method.
|
||||
type ItemInformationProtectionPolicyLabelsEvaluateClassificationResultsPostRequestBody struct {
|
||||
// Stores additional data not described in the OpenAPI description found when deserializing. Can be used for serialization as well.
|
||||
additionalData map[string]interface{}
|
||||
// The classificationResults property
|
||||
classificationResults []ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ClassificationResultable
|
||||
// The contentInfo property
|
||||
contentInfo ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ContentInfoable
|
||||
}
|
||||
// NewItemInformationProtectionPolicyLabelsEvaluateClassificationResultsPostRequestBody instantiates a new ItemInformationProtectionPolicyLabelsEvaluateClassificationResultsPostRequestBody and sets the default values.
|
||||
func NewItemInformationProtectionPolicyLabelsEvaluateClassificationResultsPostRequestBody()(*ItemInformationProtectionPolicyLabelsEvaluateClassificationResultsPostRequestBody) {
|
||||
m := &ItemInformationProtectionPolicyLabelsEvaluateClassificationResultsPostRequestBody{
|
||||
}
|
||||
m.SetAdditionalData(make(map[string]interface{}));
|
||||
return m
|
||||
}
|
||||
// CreateItemInformationProtectionPolicyLabelsEvaluateClassificationResultsPostRequestBodyFromDiscriminatorValue creates a new instance of the appropriate class based on discriminator value
|
||||
func CreateItemInformationProtectionPolicyLabelsEvaluateClassificationResultsPostRequestBodyFromDiscriminatorValue(parseNode i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.ParseNode)(i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.Parsable, error) {
|
||||
return NewItemInformationProtectionPolicyLabelsEvaluateClassificationResultsPostRequestBody(), nil
|
||||
}
|
||||
// GetAdditionalData gets the additionalData property value. Stores additional data not described in the OpenAPI description found when deserializing. Can be used for serialization as well.
|
||||
func (m *ItemInformationProtectionPolicyLabelsEvaluateClassificationResultsPostRequestBody) GetAdditionalData()(map[string]interface{}) {
|
||||
return m.additionalData
|
||||
}
|
||||
// GetClassificationResults gets the classificationResults property value. The classificationResults property
|
||||
func (m *ItemInformationProtectionPolicyLabelsEvaluateClassificationResultsPostRequestBody) GetClassificationResults()([]ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ClassificationResultable) {
|
||||
return m.classificationResults
|
||||
}
|
||||
// GetContentInfo gets the contentInfo property value. The contentInfo property
|
||||
func (m *ItemInformationProtectionPolicyLabelsEvaluateClassificationResultsPostRequestBody) GetContentInfo()(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ContentInfoable) {
|
||||
return m.contentInfo
|
||||
}
|
||||
// GetFieldDeserializers the deserialization information for the current model
|
||||
func (m *ItemInformationProtectionPolicyLabelsEvaluateClassificationResultsPostRequestBody) GetFieldDeserializers()(map[string]func(i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.ParseNode)(error)) {
|
||||
res := make(map[string]func(i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.ParseNode)(error))
|
||||
res["classificationResults"] = func (n i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.ParseNode) error {
|
||||
val, err := n.GetCollectionOfObjectValues(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CreateClassificationResultFromDiscriminatorValue)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
if val != nil {
|
||||
res := make([]ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ClassificationResultable, len(val))
|
||||
for i, v := range val {
|
||||
res[i] = v.(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ClassificationResultable)
|
||||
}
|
||||
m.SetClassificationResults(res)
|
||||
}
|
||||
return nil
|
||||
}
|
||||
res["contentInfo"] = func (n i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.ParseNode) error {
|
||||
val, err := n.GetObjectValue(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CreateContentInfoFromDiscriminatorValue)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
if val != nil {
|
||||
m.SetContentInfo(val.(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ContentInfoable))
|
||||
}
|
||||
return nil
|
||||
}
|
||||
return res
|
||||
}
|
||||
// Serialize serializes information the current object
|
||||
func (m *ItemInformationProtectionPolicyLabelsEvaluateClassificationResultsPostRequestBody) Serialize(writer i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.SerializationWriter)(error) {
|
||||
if m.GetClassificationResults() != nil {
|
||||
cast := make([]i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.Parsable, len(m.GetClassificationResults()))
|
||||
for i, v := range m.GetClassificationResults() {
|
||||
cast[i] = v.(i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.Parsable)
|
||||
}
|
||||
err := writer.WriteCollectionOfObjectValues("classificationResults", cast)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
}
|
||||
{
|
||||
err := writer.WriteObjectValue("contentInfo", m.GetContentInfo())
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
}
|
||||
{
|
||||
err := writer.WriteAdditionalData(m.GetAdditionalData())
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
}
|
||||
return nil
|
||||
}
|
||||
// SetAdditionalData sets the additionalData property value. Stores additional data not described in the OpenAPI description found when deserializing. Can be used for serialization as well.
|
||||
func (m *ItemInformationProtectionPolicyLabelsEvaluateClassificationResultsPostRequestBody) SetAdditionalData(value map[string]interface{})() {
|
||||
m.additionalData = value
|
||||
}
|
||||
// SetClassificationResults sets the classificationResults property value. The classificationResults property
|
||||
func (m *ItemInformationProtectionPolicyLabelsEvaluateClassificationResultsPostRequestBody) SetClassificationResults(value []ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ClassificationResultable)() {
|
||||
m.classificationResults = value
|
||||
}
|
||||
// SetContentInfo sets the contentInfo property value. The contentInfo property
|
||||
func (m *ItemInformationProtectionPolicyLabelsEvaluateClassificationResultsPostRequestBody) SetContentInfo(value ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ContentInfoable)() {
|
||||
m.contentInfo = value
|
||||
}
|
||||
@ -1,16 +0,0 @@
|
||||
package sites
|
||||
|
||||
import (
|
||||
i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91 "github.com/microsoft/kiota-abstractions-go/serialization"
|
||||
ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models"
|
||||
)
|
||||
|
||||
// ItemInformationProtectionPolicyLabelsEvaluateClassificationResultsPostRequestBodyable
|
||||
type ItemInformationProtectionPolicyLabelsEvaluateClassificationResultsPostRequestBodyable interface {
|
||||
i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.AdditionalDataHolder
|
||||
i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.Parsable
|
||||
GetClassificationResults()([]ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ClassificationResultable)
|
||||
GetContentInfo()(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ContentInfoable)
|
||||
SetClassificationResults(value []ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ClassificationResultable)()
|
||||
SetContentInfo(value ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ContentInfoable)()
|
||||
}
|
||||
@ -1,79 +0,0 @@
|
||||
package sites
|
||||
|
||||
import (
|
||||
"context"
|
||||
i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f "github.com/microsoft/kiota-abstractions-go"
|
||||
i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models/odataerrors"
|
||||
)
|
||||
|
||||
// ItemInformationProtectionPolicyLabelsEvaluateClassificationResultsRequestBuilder provides operations to call the evaluateClassificationResults method.
|
||||
type ItemInformationProtectionPolicyLabelsEvaluateClassificationResultsRequestBuilder struct {
|
||||
// Path parameters for the request
|
||||
pathParameters map[string]string
|
||||
// The request adapter to use to execute the requests.
|
||||
requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter
|
||||
// Url template to use to build the URL for the current request builder
|
||||
urlTemplate string
|
||||
}
|
||||
// ItemInformationProtectionPolicyLabelsEvaluateClassificationResultsRequestBuilderPostRequestConfiguration configuration for the request such as headers, query parameters, and middleware options.
|
||||
type ItemInformationProtectionPolicyLabelsEvaluateClassificationResultsRequestBuilderPostRequestConfiguration struct {
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
}
|
||||
// NewItemInformationProtectionPolicyLabelsEvaluateClassificationResultsRequestBuilderInternal instantiates a new EvaluateClassificationResultsRequestBuilder and sets the default values.
|
||||
func NewItemInformationProtectionPolicyLabelsEvaluateClassificationResultsRequestBuilderInternal(pathParameters map[string]string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemInformationProtectionPolicyLabelsEvaluateClassificationResultsRequestBuilder) {
|
||||
m := &ItemInformationProtectionPolicyLabelsEvaluateClassificationResultsRequestBuilder{
|
||||
}
|
||||
m.urlTemplate = "{+baseurl}/sites/{site%2Did}/informationProtection/policy/labels/microsoft.graph.evaluateClassificationResults";
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
m.pathParameters = urlTplParams;
|
||||
m.requestAdapter = requestAdapter;
|
||||
return m
|
||||
}
|
||||
// NewItemInformationProtectionPolicyLabelsEvaluateClassificationResultsRequestBuilder instantiates a new EvaluateClassificationResultsRequestBuilder and sets the default values.
|
||||
func NewItemInformationProtectionPolicyLabelsEvaluateClassificationResultsRequestBuilder(rawUrl string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemInformationProtectionPolicyLabelsEvaluateClassificationResultsRequestBuilder) {
|
||||
urlParams := make(map[string]string)
|
||||
urlParams["request-raw-url"] = rawUrl
|
||||
return NewItemInformationProtectionPolicyLabelsEvaluateClassificationResultsRequestBuilderInternal(urlParams, requestAdapter)
|
||||
}
|
||||
// CreatePostRequestInformation using classification results, compute the information protection label that should be applied and return the set of actions that must be taken to correctly label the information. This API is useful when a label should be set automatically based on classification of the file contents, rather than labeled directly by a user or service. To evaluate based on classification results, provide contentInfo, which includes existing content metadata key/value pairs, and classification results. The API returns an informationProtectionAction that contains one of more of the following:
|
||||
func (m *ItemInformationProtectionPolicyLabelsEvaluateClassificationResultsRequestBuilder) CreatePostRequestInformation(ctx context.Context, body ItemInformationProtectionPolicyLabelsEvaluateClassificationResultsPostRequestBodyable, requestConfiguration *ItemInformationProtectionPolicyLabelsEvaluateClassificationResultsRequestBuilderPostRequestConfiguration)(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.POST
|
||||
requestInfo.Headers.Add("Accept", "application/json")
|
||||
requestInfo.SetContentFromParsable(ctx, m.requestAdapter, "application/json", body)
|
||||
if requestConfiguration != nil {
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
}
|
||||
// Post using classification results, compute the information protection label that should be applied and return the set of actions that must be taken to correctly label the information. This API is useful when a label should be set automatically based on classification of the file contents, rather than labeled directly by a user or service. To evaluate based on classification results, provide contentInfo, which includes existing content metadata key/value pairs, and classification results. The API returns an informationProtectionAction that contains one of more of the following:
|
||||
// [Find more info here]
|
||||
//
|
||||
// [Find more info here]: https://docs.microsoft.com/graph/api/informationprotectionlabel-evaluateclassificationresults?view=graph-rest-1.0
|
||||
func (m *ItemInformationProtectionPolicyLabelsEvaluateClassificationResultsRequestBuilder) Post(ctx context.Context, body ItemInformationProtectionPolicyLabelsEvaluateClassificationResultsPostRequestBodyable, requestConfiguration *ItemInformationProtectionPolicyLabelsEvaluateClassificationResultsRequestBuilderPostRequestConfiguration)(ItemInformationProtectionPolicyLabelsEvaluateClassificationResultsResponseable, error) {
|
||||
requestInfo, err := m.CreatePostRequestInformation(ctx, body, requestConfiguration);
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings {
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.SendAsync(ctx, requestInfo, CreateItemInformationProtectionPolicyLabelsEvaluateClassificationResultsResponseFromDiscriminatorValue, errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(ItemInformationProtectionPolicyLabelsEvaluateClassificationResultsResponseable), nil
|
||||
}
|
||||
@ -1,69 +0,0 @@
|
||||
package sites
|
||||
|
||||
import (
|
||||
i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91 "github.com/microsoft/kiota-abstractions-go/serialization"
|
||||
ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models"
|
||||
)
|
||||
|
||||
// ItemInformationProtectionPolicyLabelsEvaluateClassificationResultsResponse provides operations to call the evaluateClassificationResults method.
|
||||
type ItemInformationProtectionPolicyLabelsEvaluateClassificationResultsResponse struct {
|
||||
ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.BaseCollectionPaginationCountResponse
|
||||
// The value property
|
||||
value []ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.InformationProtectionActionable
|
||||
}
|
||||
// NewItemInformationProtectionPolicyLabelsEvaluateClassificationResultsResponse instantiates a new ItemInformationProtectionPolicyLabelsEvaluateClassificationResultsResponse and sets the default values.
|
||||
func NewItemInformationProtectionPolicyLabelsEvaluateClassificationResultsResponse()(*ItemInformationProtectionPolicyLabelsEvaluateClassificationResultsResponse) {
|
||||
m := &ItemInformationProtectionPolicyLabelsEvaluateClassificationResultsResponse{
|
||||
BaseCollectionPaginationCountResponse: *ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.NewBaseCollectionPaginationCountResponse(),
|
||||
}
|
||||
return m
|
||||
}
|
||||
// CreateItemInformationProtectionPolicyLabelsEvaluateClassificationResultsResponseFromDiscriminatorValue creates a new instance of the appropriate class based on discriminator value
|
||||
func CreateItemInformationProtectionPolicyLabelsEvaluateClassificationResultsResponseFromDiscriminatorValue(parseNode i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.ParseNode)(i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.Parsable, error) {
|
||||
return NewItemInformationProtectionPolicyLabelsEvaluateClassificationResultsResponse(), nil
|
||||
}
|
||||
// GetFieldDeserializers the deserialization information for the current model
|
||||
func (m *ItemInformationProtectionPolicyLabelsEvaluateClassificationResultsResponse) GetFieldDeserializers()(map[string]func(i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.ParseNode)(error)) {
|
||||
res := m.BaseCollectionPaginationCountResponse.GetFieldDeserializers()
|
||||
res["value"] = func (n i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.ParseNode) error {
|
||||
val, err := n.GetCollectionOfObjectValues(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CreateInformationProtectionActionFromDiscriminatorValue)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
if val != nil {
|
||||
res := make([]ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.InformationProtectionActionable, len(val))
|
||||
for i, v := range val {
|
||||
res[i] = v.(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.InformationProtectionActionable)
|
||||
}
|
||||
m.SetValue(res)
|
||||
}
|
||||
return nil
|
||||
}
|
||||
return res
|
||||
}
|
||||
// GetValue gets the value property value. The value property
|
||||
func (m *ItemInformationProtectionPolicyLabelsEvaluateClassificationResultsResponse) GetValue()([]ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.InformationProtectionActionable) {
|
||||
return m.value
|
||||
}
|
||||
// Serialize serializes information the current object
|
||||
func (m *ItemInformationProtectionPolicyLabelsEvaluateClassificationResultsResponse) Serialize(writer i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.SerializationWriter)(error) {
|
||||
err := m.BaseCollectionPaginationCountResponse.Serialize(writer)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
if m.GetValue() != nil {
|
||||
cast := make([]i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.Parsable, len(m.GetValue()))
|
||||
for i, v := range m.GetValue() {
|
||||
cast[i] = v.(i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.Parsable)
|
||||
}
|
||||
err = writer.WriteCollectionOfObjectValues("value", cast)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
}
|
||||
return nil
|
||||
}
|
||||
// SetValue sets the value property value. The value property
|
||||
func (m *ItemInformationProtectionPolicyLabelsEvaluateClassificationResultsResponse) SetValue(value []ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.InformationProtectionActionable)() {
|
||||
m.value = value
|
||||
}
|
||||
@ -1,14 +0,0 @@
|
||||
package sites
|
||||
|
||||
import (
|
||||
i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91 "github.com/microsoft/kiota-abstractions-go/serialization"
|
||||
ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models"
|
||||
)
|
||||
|
||||
// ItemInformationProtectionPolicyLabelsEvaluateClassificationResultsResponseable
|
||||
type ItemInformationProtectionPolicyLabelsEvaluateClassificationResultsResponseable interface {
|
||||
ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.BaseCollectionPaginationCountResponseable
|
||||
i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.Parsable
|
||||
GetValue()([]ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.InformationProtectionActionable)
|
||||
SetValue(value []ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.InformationProtectionActionable)()
|
||||
}
|
||||
@ -1,98 +0,0 @@
|
||||
package sites
|
||||
|
||||
import (
|
||||
i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91 "github.com/microsoft/kiota-abstractions-go/serialization"
|
||||
ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models"
|
||||
)
|
||||
|
||||
// ItemInformationProtectionPolicyLabelsEvaluateRemovalPostRequestBody provides operations to call the evaluateRemoval method.
|
||||
type ItemInformationProtectionPolicyLabelsEvaluateRemovalPostRequestBody struct {
|
||||
// Stores additional data not described in the OpenAPI description found when deserializing. Can be used for serialization as well.
|
||||
additionalData map[string]interface{}
|
||||
// The contentInfo property
|
||||
contentInfo ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ContentInfoable
|
||||
// The downgradeJustification property
|
||||
downgradeJustification ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.DowngradeJustificationable
|
||||
}
|
||||
// NewItemInformationProtectionPolicyLabelsEvaluateRemovalPostRequestBody instantiates a new ItemInformationProtectionPolicyLabelsEvaluateRemovalPostRequestBody and sets the default values.
|
||||
func NewItemInformationProtectionPolicyLabelsEvaluateRemovalPostRequestBody()(*ItemInformationProtectionPolicyLabelsEvaluateRemovalPostRequestBody) {
|
||||
m := &ItemInformationProtectionPolicyLabelsEvaluateRemovalPostRequestBody{
|
||||
}
|
||||
m.SetAdditionalData(make(map[string]interface{}));
|
||||
return m
|
||||
}
|
||||
// CreateItemInformationProtectionPolicyLabelsEvaluateRemovalPostRequestBodyFromDiscriminatorValue creates a new instance of the appropriate class based on discriminator value
|
||||
func CreateItemInformationProtectionPolicyLabelsEvaluateRemovalPostRequestBodyFromDiscriminatorValue(parseNode i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.ParseNode)(i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.Parsable, error) {
|
||||
return NewItemInformationProtectionPolicyLabelsEvaluateRemovalPostRequestBody(), nil
|
||||
}
|
||||
// GetAdditionalData gets the additionalData property value. Stores additional data not described in the OpenAPI description found when deserializing. Can be used for serialization as well.
|
||||
func (m *ItemInformationProtectionPolicyLabelsEvaluateRemovalPostRequestBody) GetAdditionalData()(map[string]interface{}) {
|
||||
return m.additionalData
|
||||
}
|
||||
// GetContentInfo gets the contentInfo property value. The contentInfo property
|
||||
func (m *ItemInformationProtectionPolicyLabelsEvaluateRemovalPostRequestBody) GetContentInfo()(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ContentInfoable) {
|
||||
return m.contentInfo
|
||||
}
|
||||
// GetDowngradeJustification gets the downgradeJustification property value. The downgradeJustification property
|
||||
func (m *ItemInformationProtectionPolicyLabelsEvaluateRemovalPostRequestBody) GetDowngradeJustification()(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.DowngradeJustificationable) {
|
||||
return m.downgradeJustification
|
||||
}
|
||||
// GetFieldDeserializers the deserialization information for the current model
|
||||
func (m *ItemInformationProtectionPolicyLabelsEvaluateRemovalPostRequestBody) GetFieldDeserializers()(map[string]func(i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.ParseNode)(error)) {
|
||||
res := make(map[string]func(i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.ParseNode)(error))
|
||||
res["contentInfo"] = func (n i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.ParseNode) error {
|
||||
val, err := n.GetObjectValue(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CreateContentInfoFromDiscriminatorValue)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
if val != nil {
|
||||
m.SetContentInfo(val.(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ContentInfoable))
|
||||
}
|
||||
return nil
|
||||
}
|
||||
res["downgradeJustification"] = func (n i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.ParseNode) error {
|
||||
val, err := n.GetObjectValue(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CreateDowngradeJustificationFromDiscriminatorValue)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
if val != nil {
|
||||
m.SetDowngradeJustification(val.(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.DowngradeJustificationable))
|
||||
}
|
||||
return nil
|
||||
}
|
||||
return res
|
||||
}
|
||||
// Serialize serializes information the current object
|
||||
func (m *ItemInformationProtectionPolicyLabelsEvaluateRemovalPostRequestBody) Serialize(writer i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.SerializationWriter)(error) {
|
||||
{
|
||||
err := writer.WriteObjectValue("contentInfo", m.GetContentInfo())
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
}
|
||||
{
|
||||
err := writer.WriteObjectValue("downgradeJustification", m.GetDowngradeJustification())
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
}
|
||||
{
|
||||
err := writer.WriteAdditionalData(m.GetAdditionalData())
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
}
|
||||
return nil
|
||||
}
|
||||
// SetAdditionalData sets the additionalData property value. Stores additional data not described in the OpenAPI description found when deserializing. Can be used for serialization as well.
|
||||
func (m *ItemInformationProtectionPolicyLabelsEvaluateRemovalPostRequestBody) SetAdditionalData(value map[string]interface{})() {
|
||||
m.additionalData = value
|
||||
}
|
||||
// SetContentInfo sets the contentInfo property value. The contentInfo property
|
||||
func (m *ItemInformationProtectionPolicyLabelsEvaluateRemovalPostRequestBody) SetContentInfo(value ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ContentInfoable)() {
|
||||
m.contentInfo = value
|
||||
}
|
||||
// SetDowngradeJustification sets the downgradeJustification property value. The downgradeJustification property
|
||||
func (m *ItemInformationProtectionPolicyLabelsEvaluateRemovalPostRequestBody) SetDowngradeJustification(value ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.DowngradeJustificationable)() {
|
||||
m.downgradeJustification = value
|
||||
}
|
||||
@ -1,16 +0,0 @@
|
||||
package sites
|
||||
|
||||
import (
|
||||
i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91 "github.com/microsoft/kiota-abstractions-go/serialization"
|
||||
ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models"
|
||||
)
|
||||
|
||||
// ItemInformationProtectionPolicyLabelsEvaluateRemovalPostRequestBodyable
|
||||
type ItemInformationProtectionPolicyLabelsEvaluateRemovalPostRequestBodyable interface {
|
||||
i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.AdditionalDataHolder
|
||||
i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.Parsable
|
||||
GetContentInfo()(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ContentInfoable)
|
||||
GetDowngradeJustification()(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.DowngradeJustificationable)
|
||||
SetContentInfo(value ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ContentInfoable)()
|
||||
SetDowngradeJustification(value ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.DowngradeJustificationable)()
|
||||
}
|
||||
@ -1,79 +0,0 @@
|
||||
package sites
|
||||
|
||||
import (
|
||||
"context"
|
||||
i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f "github.com/microsoft/kiota-abstractions-go"
|
||||
i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models/odataerrors"
|
||||
)
|
||||
|
||||
// ItemInformationProtectionPolicyLabelsEvaluateRemovalRequestBuilder provides operations to call the evaluateRemoval method.
|
||||
type ItemInformationProtectionPolicyLabelsEvaluateRemovalRequestBuilder struct {
|
||||
// Path parameters for the request
|
||||
pathParameters map[string]string
|
||||
// The request adapter to use to execute the requests.
|
||||
requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter
|
||||
// Url template to use to build the URL for the current request builder
|
||||
urlTemplate string
|
||||
}
|
||||
// ItemInformationProtectionPolicyLabelsEvaluateRemovalRequestBuilderPostRequestConfiguration configuration for the request such as headers, query parameters, and middleware options.
|
||||
type ItemInformationProtectionPolicyLabelsEvaluateRemovalRequestBuilderPostRequestConfiguration struct {
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
}
|
||||
// NewItemInformationProtectionPolicyLabelsEvaluateRemovalRequestBuilderInternal instantiates a new EvaluateRemovalRequestBuilder and sets the default values.
|
||||
func NewItemInformationProtectionPolicyLabelsEvaluateRemovalRequestBuilderInternal(pathParameters map[string]string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemInformationProtectionPolicyLabelsEvaluateRemovalRequestBuilder) {
|
||||
m := &ItemInformationProtectionPolicyLabelsEvaluateRemovalRequestBuilder{
|
||||
}
|
||||
m.urlTemplate = "{+baseurl}/sites/{site%2Did}/informationProtection/policy/labels/microsoft.graph.evaluateRemoval";
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
m.pathParameters = urlTplParams;
|
||||
m.requestAdapter = requestAdapter;
|
||||
return m
|
||||
}
|
||||
// NewItemInformationProtectionPolicyLabelsEvaluateRemovalRequestBuilder instantiates a new EvaluateRemovalRequestBuilder and sets the default values.
|
||||
func NewItemInformationProtectionPolicyLabelsEvaluateRemovalRequestBuilder(rawUrl string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemInformationProtectionPolicyLabelsEvaluateRemovalRequestBuilder) {
|
||||
urlParams := make(map[string]string)
|
||||
urlParams["request-raw-url"] = rawUrl
|
||||
return NewItemInformationProtectionPolicyLabelsEvaluateRemovalRequestBuilderInternal(urlParams, requestAdapter)
|
||||
}
|
||||
// CreatePostRequestInformation indicate to the consuming application what actions it should take to remove the label information. Given contentInfo as an input, which includes existing content metadata key/value pairs, the API returns an informationProtectionAction that contains some combination of one of more of the following:
|
||||
func (m *ItemInformationProtectionPolicyLabelsEvaluateRemovalRequestBuilder) CreatePostRequestInformation(ctx context.Context, body ItemInformationProtectionPolicyLabelsEvaluateRemovalPostRequestBodyable, requestConfiguration *ItemInformationProtectionPolicyLabelsEvaluateRemovalRequestBuilderPostRequestConfiguration)(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.POST
|
||||
requestInfo.Headers.Add("Accept", "application/json")
|
||||
requestInfo.SetContentFromParsable(ctx, m.requestAdapter, "application/json", body)
|
||||
if requestConfiguration != nil {
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
}
|
||||
// Post indicate to the consuming application what actions it should take to remove the label information. Given contentInfo as an input, which includes existing content metadata key/value pairs, the API returns an informationProtectionAction that contains some combination of one of more of the following:
|
||||
// [Find more info here]
|
||||
//
|
||||
// [Find more info here]: https://docs.microsoft.com/graph/api/informationprotectionlabel-evaluateremoval?view=graph-rest-1.0
|
||||
func (m *ItemInformationProtectionPolicyLabelsEvaluateRemovalRequestBuilder) Post(ctx context.Context, body ItemInformationProtectionPolicyLabelsEvaluateRemovalPostRequestBodyable, requestConfiguration *ItemInformationProtectionPolicyLabelsEvaluateRemovalRequestBuilderPostRequestConfiguration)(ItemInformationProtectionPolicyLabelsEvaluateRemovalResponseable, error) {
|
||||
requestInfo, err := m.CreatePostRequestInformation(ctx, body, requestConfiguration);
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings {
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.SendAsync(ctx, requestInfo, CreateItemInformationProtectionPolicyLabelsEvaluateRemovalResponseFromDiscriminatorValue, errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(ItemInformationProtectionPolicyLabelsEvaluateRemovalResponseable), nil
|
||||
}
|
||||
@ -1,69 +0,0 @@
|
||||
package sites
|
||||
|
||||
import (
|
||||
i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91 "github.com/microsoft/kiota-abstractions-go/serialization"
|
||||
ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models"
|
||||
)
|
||||
|
||||
// ItemInformationProtectionPolicyLabelsEvaluateRemovalResponse provides operations to call the evaluateRemoval method.
|
||||
type ItemInformationProtectionPolicyLabelsEvaluateRemovalResponse struct {
|
||||
ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.BaseCollectionPaginationCountResponse
|
||||
// The value property
|
||||
value []ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.InformationProtectionActionable
|
||||
}
|
||||
// NewItemInformationProtectionPolicyLabelsEvaluateRemovalResponse instantiates a new ItemInformationProtectionPolicyLabelsEvaluateRemovalResponse and sets the default values.
|
||||
func NewItemInformationProtectionPolicyLabelsEvaluateRemovalResponse()(*ItemInformationProtectionPolicyLabelsEvaluateRemovalResponse) {
|
||||
m := &ItemInformationProtectionPolicyLabelsEvaluateRemovalResponse{
|
||||
BaseCollectionPaginationCountResponse: *ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.NewBaseCollectionPaginationCountResponse(),
|
||||
}
|
||||
return m
|
||||
}
|
||||
// CreateItemInformationProtectionPolicyLabelsEvaluateRemovalResponseFromDiscriminatorValue creates a new instance of the appropriate class based on discriminator value
|
||||
func CreateItemInformationProtectionPolicyLabelsEvaluateRemovalResponseFromDiscriminatorValue(parseNode i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.ParseNode)(i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.Parsable, error) {
|
||||
return NewItemInformationProtectionPolicyLabelsEvaluateRemovalResponse(), nil
|
||||
}
|
||||
// GetFieldDeserializers the deserialization information for the current model
|
||||
func (m *ItemInformationProtectionPolicyLabelsEvaluateRemovalResponse) GetFieldDeserializers()(map[string]func(i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.ParseNode)(error)) {
|
||||
res := m.BaseCollectionPaginationCountResponse.GetFieldDeserializers()
|
||||
res["value"] = func (n i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.ParseNode) error {
|
||||
val, err := n.GetCollectionOfObjectValues(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CreateInformationProtectionActionFromDiscriminatorValue)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
if val != nil {
|
||||
res := make([]ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.InformationProtectionActionable, len(val))
|
||||
for i, v := range val {
|
||||
res[i] = v.(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.InformationProtectionActionable)
|
||||
}
|
||||
m.SetValue(res)
|
||||
}
|
||||
return nil
|
||||
}
|
||||
return res
|
||||
}
|
||||
// GetValue gets the value property value. The value property
|
||||
func (m *ItemInformationProtectionPolicyLabelsEvaluateRemovalResponse) GetValue()([]ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.InformationProtectionActionable) {
|
||||
return m.value
|
||||
}
|
||||
// Serialize serializes information the current object
|
||||
func (m *ItemInformationProtectionPolicyLabelsEvaluateRemovalResponse) Serialize(writer i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.SerializationWriter)(error) {
|
||||
err := m.BaseCollectionPaginationCountResponse.Serialize(writer)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
if m.GetValue() != nil {
|
||||
cast := make([]i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.Parsable, len(m.GetValue()))
|
||||
for i, v := range m.GetValue() {
|
||||
cast[i] = v.(i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.Parsable)
|
||||
}
|
||||
err = writer.WriteCollectionOfObjectValues("value", cast)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
}
|
||||
return nil
|
||||
}
|
||||
// SetValue sets the value property value. The value property
|
||||
func (m *ItemInformationProtectionPolicyLabelsEvaluateRemovalResponse) SetValue(value []ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.InformationProtectionActionable)() {
|
||||
m.value = value
|
||||
}
|
||||
@ -1,14 +0,0 @@
|
||||
package sites
|
||||
|
||||
import (
|
||||
i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91 "github.com/microsoft/kiota-abstractions-go/serialization"
|
||||
ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models"
|
||||
)
|
||||
|
||||
// ItemInformationProtectionPolicyLabelsEvaluateRemovalResponseable
|
||||
type ItemInformationProtectionPolicyLabelsEvaluateRemovalResponseable interface {
|
||||
ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.BaseCollectionPaginationCountResponseable
|
||||
i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.Parsable
|
||||
GetValue()([]ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.InformationProtectionActionable)
|
||||
SetValue(value []ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.InformationProtectionActionable)()
|
||||
}
|
||||
@ -1,72 +0,0 @@
|
||||
package sites
|
||||
|
||||
import (
|
||||
i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91 "github.com/microsoft/kiota-abstractions-go/serialization"
|
||||
ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models"
|
||||
)
|
||||
|
||||
// ItemInformationProtectionPolicyLabelsExtractLabelPostRequestBody provides operations to call the extractLabel method.
|
||||
type ItemInformationProtectionPolicyLabelsExtractLabelPostRequestBody struct {
|
||||
// Stores additional data not described in the OpenAPI description found when deserializing. Can be used for serialization as well.
|
||||
additionalData map[string]interface{}
|
||||
// The contentInfo property
|
||||
contentInfo ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ContentInfoable
|
||||
}
|
||||
// NewItemInformationProtectionPolicyLabelsExtractLabelPostRequestBody instantiates a new ItemInformationProtectionPolicyLabelsExtractLabelPostRequestBody and sets the default values.
|
||||
func NewItemInformationProtectionPolicyLabelsExtractLabelPostRequestBody()(*ItemInformationProtectionPolicyLabelsExtractLabelPostRequestBody) {
|
||||
m := &ItemInformationProtectionPolicyLabelsExtractLabelPostRequestBody{
|
||||
}
|
||||
m.SetAdditionalData(make(map[string]interface{}));
|
||||
return m
|
||||
}
|
||||
// CreateItemInformationProtectionPolicyLabelsExtractLabelPostRequestBodyFromDiscriminatorValue creates a new instance of the appropriate class based on discriminator value
|
||||
func CreateItemInformationProtectionPolicyLabelsExtractLabelPostRequestBodyFromDiscriminatorValue(parseNode i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.ParseNode)(i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.Parsable, error) {
|
||||
return NewItemInformationProtectionPolicyLabelsExtractLabelPostRequestBody(), nil
|
||||
}
|
||||
// GetAdditionalData gets the additionalData property value. Stores additional data not described in the OpenAPI description found when deserializing. Can be used for serialization as well.
|
||||
func (m *ItemInformationProtectionPolicyLabelsExtractLabelPostRequestBody) GetAdditionalData()(map[string]interface{}) {
|
||||
return m.additionalData
|
||||
}
|
||||
// GetContentInfo gets the contentInfo property value. The contentInfo property
|
||||
func (m *ItemInformationProtectionPolicyLabelsExtractLabelPostRequestBody) GetContentInfo()(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ContentInfoable) {
|
||||
return m.contentInfo
|
||||
}
|
||||
// GetFieldDeserializers the deserialization information for the current model
|
||||
func (m *ItemInformationProtectionPolicyLabelsExtractLabelPostRequestBody) GetFieldDeserializers()(map[string]func(i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.ParseNode)(error)) {
|
||||
res := make(map[string]func(i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.ParseNode)(error))
|
||||
res["contentInfo"] = func (n i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.ParseNode) error {
|
||||
val, err := n.GetObjectValue(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CreateContentInfoFromDiscriminatorValue)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
if val != nil {
|
||||
m.SetContentInfo(val.(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ContentInfoable))
|
||||
}
|
||||
return nil
|
||||
}
|
||||
return res
|
||||
}
|
||||
// Serialize serializes information the current object
|
||||
func (m *ItemInformationProtectionPolicyLabelsExtractLabelPostRequestBody) Serialize(writer i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.SerializationWriter)(error) {
|
||||
{
|
||||
err := writer.WriteObjectValue("contentInfo", m.GetContentInfo())
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
}
|
||||
{
|
||||
err := writer.WriteAdditionalData(m.GetAdditionalData())
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
}
|
||||
return nil
|
||||
}
|
||||
// SetAdditionalData sets the additionalData property value. Stores additional data not described in the OpenAPI description found when deserializing. Can be used for serialization as well.
|
||||
func (m *ItemInformationProtectionPolicyLabelsExtractLabelPostRequestBody) SetAdditionalData(value map[string]interface{})() {
|
||||
m.additionalData = value
|
||||
}
|
||||
// SetContentInfo sets the contentInfo property value. The contentInfo property
|
||||
func (m *ItemInformationProtectionPolicyLabelsExtractLabelPostRequestBody) SetContentInfo(value ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ContentInfoable)() {
|
||||
m.contentInfo = value
|
||||
}
|
||||
@ -1,14 +0,0 @@
|
||||
package sites
|
||||
|
||||
import (
|
||||
i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91 "github.com/microsoft/kiota-abstractions-go/serialization"
|
||||
ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models"
|
||||
)
|
||||
|
||||
// ItemInformationProtectionPolicyLabelsExtractLabelPostRequestBodyable
|
||||
type ItemInformationProtectionPolicyLabelsExtractLabelPostRequestBodyable interface {
|
||||
i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.AdditionalDataHolder
|
||||
i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.Parsable
|
||||
GetContentInfo()(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ContentInfoable)
|
||||
SetContentInfo(value ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.ContentInfoable)()
|
||||
}
|
||||
@ -1,80 +0,0 @@
|
||||
package sites
|
||||
|
||||
import (
|
||||
"context"
|
||||
i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f "github.com/microsoft/kiota-abstractions-go"
|
||||
ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models"
|
||||
i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models/odataerrors"
|
||||
)
|
||||
|
||||
// ItemInformationProtectionPolicyLabelsExtractLabelRequestBuilder provides operations to call the extractLabel method.
|
||||
type ItemInformationProtectionPolicyLabelsExtractLabelRequestBuilder struct {
|
||||
// Path parameters for the request
|
||||
pathParameters map[string]string
|
||||
// The request adapter to use to execute the requests.
|
||||
requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter
|
||||
// Url template to use to build the URL for the current request builder
|
||||
urlTemplate string
|
||||
}
|
||||
// ItemInformationProtectionPolicyLabelsExtractLabelRequestBuilderPostRequestConfiguration configuration for the request such as headers, query parameters, and middleware options.
|
||||
type ItemInformationProtectionPolicyLabelsExtractLabelRequestBuilderPostRequestConfiguration struct {
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
}
|
||||
// NewItemInformationProtectionPolicyLabelsExtractLabelRequestBuilderInternal instantiates a new ExtractLabelRequestBuilder and sets the default values.
|
||||
func NewItemInformationProtectionPolicyLabelsExtractLabelRequestBuilderInternal(pathParameters map[string]string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemInformationProtectionPolicyLabelsExtractLabelRequestBuilder) {
|
||||
m := &ItemInformationProtectionPolicyLabelsExtractLabelRequestBuilder{
|
||||
}
|
||||
m.urlTemplate = "{+baseurl}/sites/{site%2Did}/informationProtection/policy/labels/microsoft.graph.extractLabel";
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
m.pathParameters = urlTplParams;
|
||||
m.requestAdapter = requestAdapter;
|
||||
return m
|
||||
}
|
||||
// NewItemInformationProtectionPolicyLabelsExtractLabelRequestBuilder instantiates a new ExtractLabelRequestBuilder and sets the default values.
|
||||
func NewItemInformationProtectionPolicyLabelsExtractLabelRequestBuilder(rawUrl string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemInformationProtectionPolicyLabelsExtractLabelRequestBuilder) {
|
||||
urlParams := make(map[string]string)
|
||||
urlParams["request-raw-url"] = rawUrl
|
||||
return NewItemInformationProtectionPolicyLabelsExtractLabelRequestBuilderInternal(urlParams, requestAdapter)
|
||||
}
|
||||
// CreatePostRequestInformation using the metadata that exists on an already-labeled piece of information, resolve the metadata to a specific sensitivity label. The contentInfo input is resolved to informationProtectionContentLabel.
|
||||
func (m *ItemInformationProtectionPolicyLabelsExtractLabelRequestBuilder) CreatePostRequestInformation(ctx context.Context, body ItemInformationProtectionPolicyLabelsExtractLabelPostRequestBodyable, requestConfiguration *ItemInformationProtectionPolicyLabelsExtractLabelRequestBuilderPostRequestConfiguration)(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.POST
|
||||
requestInfo.Headers.Add("Accept", "application/json")
|
||||
requestInfo.SetContentFromParsable(ctx, m.requestAdapter, "application/json", body)
|
||||
if requestConfiguration != nil {
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
}
|
||||
// Post using the metadata that exists on an already-labeled piece of information, resolve the metadata to a specific sensitivity label. The contentInfo input is resolved to informationProtectionContentLabel.
|
||||
// [Find more info here]
|
||||
//
|
||||
// [Find more info here]: https://docs.microsoft.com/graph/api/informationprotectionlabel-extractlabel?view=graph-rest-1.0
|
||||
func (m *ItemInformationProtectionPolicyLabelsExtractLabelRequestBuilder) Post(ctx context.Context, body ItemInformationProtectionPolicyLabelsExtractLabelPostRequestBodyable, requestConfiguration *ItemInformationProtectionPolicyLabelsExtractLabelRequestBuilderPostRequestConfiguration)(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.InformationProtectionContentLabelable, error) {
|
||||
requestInfo, err := m.CreatePostRequestInformation(ctx, body, requestConfiguration);
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings {
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.SendAsync(ctx, requestInfo, ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CreateInformationProtectionContentLabelFromDiscriminatorValue, errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.InformationProtectionContentLabelable), nil
|
||||
}
|
||||
@ -1,163 +0,0 @@
|
||||
package sites
|
||||
|
||||
import (
|
||||
"context"
|
||||
i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f "github.com/microsoft/kiota-abstractions-go"
|
||||
ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models"
|
||||
i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models/odataerrors"
|
||||
)
|
||||
|
||||
// ItemInformationProtectionPolicyLabelsInformationProtectionLabelItemRequestBuilder provides operations to manage the labels property of the microsoft.graph.informationProtectionPolicy entity.
|
||||
type ItemInformationProtectionPolicyLabelsInformationProtectionLabelItemRequestBuilder struct {
|
||||
// Path parameters for the request
|
||||
pathParameters map[string]string
|
||||
// The request adapter to use to execute the requests.
|
||||
requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter
|
||||
// Url template to use to build the URL for the current request builder
|
||||
urlTemplate string
|
||||
}
|
||||
// ItemInformationProtectionPolicyLabelsInformationProtectionLabelItemRequestBuilderDeleteRequestConfiguration configuration for the request such as headers, query parameters, and middleware options.
|
||||
type ItemInformationProtectionPolicyLabelsInformationProtectionLabelItemRequestBuilderDeleteRequestConfiguration struct {
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
}
|
||||
// ItemInformationProtectionPolicyLabelsInformationProtectionLabelItemRequestBuilderGetQueryParameters get labels from sites
|
||||
type ItemInformationProtectionPolicyLabelsInformationProtectionLabelItemRequestBuilderGetQueryParameters struct {
|
||||
// Expand related entities
|
||||
Expand []string `uriparametername:"%24expand"`
|
||||
// Select properties to be returned
|
||||
Select []string `uriparametername:"%24select"`
|
||||
}
|
||||
// ItemInformationProtectionPolicyLabelsInformationProtectionLabelItemRequestBuilderGetRequestConfiguration configuration for the request such as headers, query parameters, and middleware options.
|
||||
type ItemInformationProtectionPolicyLabelsInformationProtectionLabelItemRequestBuilderGetRequestConfiguration struct {
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
// Request query parameters
|
||||
QueryParameters *ItemInformationProtectionPolicyLabelsInformationProtectionLabelItemRequestBuilderGetQueryParameters
|
||||
}
|
||||
// ItemInformationProtectionPolicyLabelsInformationProtectionLabelItemRequestBuilderPatchRequestConfiguration configuration for the request such as headers, query parameters, and middleware options.
|
||||
type ItemInformationProtectionPolicyLabelsInformationProtectionLabelItemRequestBuilderPatchRequestConfiguration struct {
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
}
|
||||
// NewItemInformationProtectionPolicyLabelsInformationProtectionLabelItemRequestBuilderInternal instantiates a new InformationProtectionLabelItemRequestBuilder and sets the default values.
|
||||
func NewItemInformationProtectionPolicyLabelsInformationProtectionLabelItemRequestBuilderInternal(pathParameters map[string]string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemInformationProtectionPolicyLabelsInformationProtectionLabelItemRequestBuilder) {
|
||||
m := &ItemInformationProtectionPolicyLabelsInformationProtectionLabelItemRequestBuilder{
|
||||
}
|
||||
m.urlTemplate = "{+baseurl}/sites/{site%2Did}/informationProtection/policy/labels/{informationProtectionLabel%2Did}{?%24select,%24expand}";
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
m.pathParameters = urlTplParams;
|
||||
m.requestAdapter = requestAdapter;
|
||||
return m
|
||||
}
|
||||
// NewItemInformationProtectionPolicyLabelsInformationProtectionLabelItemRequestBuilder instantiates a new InformationProtectionLabelItemRequestBuilder and sets the default values.
|
||||
func NewItemInformationProtectionPolicyLabelsInformationProtectionLabelItemRequestBuilder(rawUrl string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemInformationProtectionPolicyLabelsInformationProtectionLabelItemRequestBuilder) {
|
||||
urlParams := make(map[string]string)
|
||||
urlParams["request-raw-url"] = rawUrl
|
||||
return NewItemInformationProtectionPolicyLabelsInformationProtectionLabelItemRequestBuilderInternal(urlParams, requestAdapter)
|
||||
}
|
||||
// CreateDeleteRequestInformation delete navigation property labels for sites
|
||||
func (m *ItemInformationProtectionPolicyLabelsInformationProtectionLabelItemRequestBuilder) CreateDeleteRequestInformation(ctx context.Context, requestConfiguration *ItemInformationProtectionPolicyLabelsInformationProtectionLabelItemRequestBuilderDeleteRequestConfiguration)(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.DELETE
|
||||
if requestConfiguration != nil {
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
}
|
||||
// CreateGetRequestInformation get labels from sites
|
||||
func (m *ItemInformationProtectionPolicyLabelsInformationProtectionLabelItemRequestBuilder) CreateGetRequestInformation(ctx context.Context, requestConfiguration *ItemInformationProtectionPolicyLabelsInformationProtectionLabelItemRequestBuilderGetRequestConfiguration)(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.GET
|
||||
requestInfo.Headers.Add("Accept", "application/json")
|
||||
if requestConfiguration != nil {
|
||||
if requestConfiguration.QueryParameters != nil {
|
||||
requestInfo.AddQueryParameters(*(requestConfiguration.QueryParameters))
|
||||
}
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
}
|
||||
// CreatePatchRequestInformation update the navigation property labels in sites
|
||||
func (m *ItemInformationProtectionPolicyLabelsInformationProtectionLabelItemRequestBuilder) CreatePatchRequestInformation(ctx context.Context, body ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.InformationProtectionLabelable, requestConfiguration *ItemInformationProtectionPolicyLabelsInformationProtectionLabelItemRequestBuilderPatchRequestConfiguration)(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.PATCH
|
||||
requestInfo.Headers.Add("Accept", "application/json")
|
||||
requestInfo.SetContentFromParsable(ctx, m.requestAdapter, "application/json", body)
|
||||
if requestConfiguration != nil {
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
}
|
||||
// Delete delete navigation property labels for sites
|
||||
func (m *ItemInformationProtectionPolicyLabelsInformationProtectionLabelItemRequestBuilder) Delete(ctx context.Context, requestConfiguration *ItemInformationProtectionPolicyLabelsInformationProtectionLabelItemRequestBuilderDeleteRequestConfiguration)(error) {
|
||||
requestInfo, err := m.CreateDeleteRequestInformation(ctx, requestConfiguration);
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings {
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
err = m.requestAdapter.SendNoContentAsync(ctx, requestInfo, errorMapping)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
return nil
|
||||
}
|
||||
// Get get labels from sites
|
||||
func (m *ItemInformationProtectionPolicyLabelsInformationProtectionLabelItemRequestBuilder) Get(ctx context.Context, requestConfiguration *ItemInformationProtectionPolicyLabelsInformationProtectionLabelItemRequestBuilderGetRequestConfiguration)(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.InformationProtectionLabelable, error) {
|
||||
requestInfo, err := m.CreateGetRequestInformation(ctx, requestConfiguration);
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings {
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.SendAsync(ctx, requestInfo, ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CreateInformationProtectionLabelFromDiscriminatorValue, errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.InformationProtectionLabelable), nil
|
||||
}
|
||||
// Patch update the navigation property labels in sites
|
||||
func (m *ItemInformationProtectionPolicyLabelsInformationProtectionLabelItemRequestBuilder) Patch(ctx context.Context, body ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.InformationProtectionLabelable, requestConfiguration *ItemInformationProtectionPolicyLabelsInformationProtectionLabelItemRequestBuilderPatchRequestConfiguration)(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.InformationProtectionLabelable, error) {
|
||||
requestInfo, err := m.CreatePatchRequestInformation(ctx, body, requestConfiguration);
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings {
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.SendAsync(ctx, requestInfo, ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CreateInformationProtectionLabelFromDiscriminatorValue, errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.InformationProtectionLabelable), nil
|
||||
}
|
||||
@ -1,163 +0,0 @@
|
||||
package sites
|
||||
|
||||
import (
|
||||
"context"
|
||||
i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f "github.com/microsoft/kiota-abstractions-go"
|
||||
ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models"
|
||||
i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models/odataerrors"
|
||||
)
|
||||
|
||||
// ItemInformationProtectionPolicyLabelsRequestBuilder provides operations to manage the labels property of the microsoft.graph.informationProtectionPolicy entity.
|
||||
type ItemInformationProtectionPolicyLabelsRequestBuilder struct {
|
||||
// Path parameters for the request
|
||||
pathParameters map[string]string
|
||||
// The request adapter to use to execute the requests.
|
||||
requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter
|
||||
// Url template to use to build the URL for the current request builder
|
||||
urlTemplate string
|
||||
}
|
||||
// ItemInformationProtectionPolicyLabelsRequestBuilderGetQueryParameters get a collection of information protection labels available to the user or to the organization.
|
||||
type ItemInformationProtectionPolicyLabelsRequestBuilderGetQueryParameters struct {
|
||||
// Include count of items
|
||||
Count *bool `uriparametername:"%24count"`
|
||||
// Expand related entities
|
||||
Expand []string `uriparametername:"%24expand"`
|
||||
// Filter items by property values
|
||||
Filter *string `uriparametername:"%24filter"`
|
||||
// Order items by property values
|
||||
Orderby []string `uriparametername:"%24orderby"`
|
||||
// Search items by search phrases
|
||||
Search *string `uriparametername:"%24search"`
|
||||
// Select properties to be returned
|
||||
Select []string `uriparametername:"%24select"`
|
||||
// Skip the first n items
|
||||
Skip *int32 `uriparametername:"%24skip"`
|
||||
// Show only the first n items
|
||||
Top *int32 `uriparametername:"%24top"`
|
||||
}
|
||||
// ItemInformationProtectionPolicyLabelsRequestBuilderGetRequestConfiguration configuration for the request such as headers, query parameters, and middleware options.
|
||||
type ItemInformationProtectionPolicyLabelsRequestBuilderGetRequestConfiguration struct {
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
// Request query parameters
|
||||
QueryParameters *ItemInformationProtectionPolicyLabelsRequestBuilderGetQueryParameters
|
||||
}
|
||||
// ItemInformationProtectionPolicyLabelsRequestBuilderPostRequestConfiguration configuration for the request such as headers, query parameters, and middleware options.
|
||||
type ItemInformationProtectionPolicyLabelsRequestBuilderPostRequestConfiguration struct {
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
}
|
||||
// NewItemInformationProtectionPolicyLabelsRequestBuilderInternal instantiates a new LabelsRequestBuilder and sets the default values.
|
||||
func NewItemInformationProtectionPolicyLabelsRequestBuilderInternal(pathParameters map[string]string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemInformationProtectionPolicyLabelsRequestBuilder) {
|
||||
m := &ItemInformationProtectionPolicyLabelsRequestBuilder{
|
||||
}
|
||||
m.urlTemplate = "{+baseurl}/sites/{site%2Did}/informationProtection/policy/labels{?%24top,%24skip,%24search,%24filter,%24count,%24orderby,%24select,%24expand}";
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
m.pathParameters = urlTplParams;
|
||||
m.requestAdapter = requestAdapter;
|
||||
return m
|
||||
}
|
||||
// NewItemInformationProtectionPolicyLabelsRequestBuilder instantiates a new LabelsRequestBuilder and sets the default values.
|
||||
func NewItemInformationProtectionPolicyLabelsRequestBuilder(rawUrl string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemInformationProtectionPolicyLabelsRequestBuilder) {
|
||||
urlParams := make(map[string]string)
|
||||
urlParams["request-raw-url"] = rawUrl
|
||||
return NewItemInformationProtectionPolicyLabelsRequestBuilderInternal(urlParams, requestAdapter)
|
||||
}
|
||||
// Count provides operations to count the resources in the collection.
|
||||
func (m *ItemInformationProtectionPolicyLabelsRequestBuilder) Count()(*ItemInformationProtectionPolicyLabelsCountRequestBuilder) {
|
||||
return NewItemInformationProtectionPolicyLabelsCountRequestBuilderInternal(m.pathParameters, m.requestAdapter);
|
||||
}
|
||||
// CreateGetRequestInformation get a collection of information protection labels available to the user or to the organization.
|
||||
func (m *ItemInformationProtectionPolicyLabelsRequestBuilder) CreateGetRequestInformation(ctx context.Context, requestConfiguration *ItemInformationProtectionPolicyLabelsRequestBuilderGetRequestConfiguration)(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.GET
|
||||
requestInfo.Headers.Add("Accept", "application/json")
|
||||
if requestConfiguration != nil {
|
||||
if requestConfiguration.QueryParameters != nil {
|
||||
requestInfo.AddQueryParameters(*(requestConfiguration.QueryParameters))
|
||||
}
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
}
|
||||
// CreatePostRequestInformation create new navigation property to labels for sites
|
||||
func (m *ItemInformationProtectionPolicyLabelsRequestBuilder) CreatePostRequestInformation(ctx context.Context, body ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.InformationProtectionLabelable, requestConfiguration *ItemInformationProtectionPolicyLabelsRequestBuilderPostRequestConfiguration)(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.POST
|
||||
requestInfo.Headers.Add("Accept", "application/json")
|
||||
requestInfo.SetContentFromParsable(ctx, m.requestAdapter, "application/json", body)
|
||||
if requestConfiguration != nil {
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
}
|
||||
// EvaluateApplication provides operations to call the evaluateApplication method.
|
||||
func (m *ItemInformationProtectionPolicyLabelsRequestBuilder) EvaluateApplication()(*ItemInformationProtectionPolicyLabelsEvaluateApplicationRequestBuilder) {
|
||||
return NewItemInformationProtectionPolicyLabelsEvaluateApplicationRequestBuilderInternal(m.pathParameters, m.requestAdapter);
|
||||
}
|
||||
// EvaluateClassificationResults provides operations to call the evaluateClassificationResults method.
|
||||
func (m *ItemInformationProtectionPolicyLabelsRequestBuilder) EvaluateClassificationResults()(*ItemInformationProtectionPolicyLabelsEvaluateClassificationResultsRequestBuilder) {
|
||||
return NewItemInformationProtectionPolicyLabelsEvaluateClassificationResultsRequestBuilderInternal(m.pathParameters, m.requestAdapter);
|
||||
}
|
||||
// EvaluateRemoval provides operations to call the evaluateRemoval method.
|
||||
func (m *ItemInformationProtectionPolicyLabelsRequestBuilder) EvaluateRemoval()(*ItemInformationProtectionPolicyLabelsEvaluateRemovalRequestBuilder) {
|
||||
return NewItemInformationProtectionPolicyLabelsEvaluateRemovalRequestBuilderInternal(m.pathParameters, m.requestAdapter);
|
||||
}
|
||||
// ExtractLabel provides operations to call the extractLabel method.
|
||||
func (m *ItemInformationProtectionPolicyLabelsRequestBuilder) ExtractLabel()(*ItemInformationProtectionPolicyLabelsExtractLabelRequestBuilder) {
|
||||
return NewItemInformationProtectionPolicyLabelsExtractLabelRequestBuilderInternal(m.pathParameters, m.requestAdapter);
|
||||
}
|
||||
// Get get a collection of information protection labels available to the user or to the organization.
|
||||
// [Find more info here]
|
||||
//
|
||||
// [Find more info here]: https://docs.microsoft.com/graph/api/informationprotectionpolicy-list-labels?view=graph-rest-1.0
|
||||
func (m *ItemInformationProtectionPolicyLabelsRequestBuilder) Get(ctx context.Context, requestConfiguration *ItemInformationProtectionPolicyLabelsRequestBuilderGetRequestConfiguration)(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.InformationProtectionLabelCollectionResponseable, error) {
|
||||
requestInfo, err := m.CreateGetRequestInformation(ctx, requestConfiguration);
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings {
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.SendAsync(ctx, requestInfo, ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CreateInformationProtectionLabelCollectionResponseFromDiscriminatorValue, errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.InformationProtectionLabelCollectionResponseable), nil
|
||||
}
|
||||
// Post create new navigation property to labels for sites
|
||||
func (m *ItemInformationProtectionPolicyLabelsRequestBuilder) Post(ctx context.Context, body ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.InformationProtectionLabelable, requestConfiguration *ItemInformationProtectionPolicyLabelsRequestBuilderPostRequestConfiguration)(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.InformationProtectionLabelable, error) {
|
||||
requestInfo, err := m.CreatePostRequestInformation(ctx, body, requestConfiguration);
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings {
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.SendAsync(ctx, requestInfo, ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CreateInformationProtectionLabelFromDiscriminatorValue, errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.InformationProtectionLabelable), nil
|
||||
}
|
||||
@ -1,178 +0,0 @@
|
||||
package sites
|
||||
|
||||
import (
|
||||
"context"
|
||||
i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f "github.com/microsoft/kiota-abstractions-go"
|
||||
ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models"
|
||||
i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models/odataerrors"
|
||||
)
|
||||
|
||||
// ItemInformationProtectionPolicyRequestBuilder provides operations to manage the policy property of the microsoft.graph.informationProtection entity.
|
||||
type ItemInformationProtectionPolicyRequestBuilder struct {
|
||||
// Path parameters for the request
|
||||
pathParameters map[string]string
|
||||
// The request adapter to use to execute the requests.
|
||||
requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter
|
||||
// Url template to use to build the URL for the current request builder
|
||||
urlTemplate string
|
||||
}
|
||||
// ItemInformationProtectionPolicyRequestBuilderDeleteRequestConfiguration configuration for the request such as headers, query parameters, and middleware options.
|
||||
type ItemInformationProtectionPolicyRequestBuilderDeleteRequestConfiguration struct {
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
}
|
||||
// ItemInformationProtectionPolicyRequestBuilderGetQueryParameters get policy from sites
|
||||
type ItemInformationProtectionPolicyRequestBuilderGetQueryParameters struct {
|
||||
// Expand related entities
|
||||
Expand []string `uriparametername:"%24expand"`
|
||||
// Select properties to be returned
|
||||
Select []string `uriparametername:"%24select"`
|
||||
}
|
||||
// ItemInformationProtectionPolicyRequestBuilderGetRequestConfiguration configuration for the request such as headers, query parameters, and middleware options.
|
||||
type ItemInformationProtectionPolicyRequestBuilderGetRequestConfiguration struct {
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
// Request query parameters
|
||||
QueryParameters *ItemInformationProtectionPolicyRequestBuilderGetQueryParameters
|
||||
}
|
||||
// ItemInformationProtectionPolicyRequestBuilderPatchRequestConfiguration configuration for the request such as headers, query parameters, and middleware options.
|
||||
type ItemInformationProtectionPolicyRequestBuilderPatchRequestConfiguration struct {
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
}
|
||||
// NewItemInformationProtectionPolicyRequestBuilderInternal instantiates a new PolicyRequestBuilder and sets the default values.
|
||||
func NewItemInformationProtectionPolicyRequestBuilderInternal(pathParameters map[string]string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemInformationProtectionPolicyRequestBuilder) {
|
||||
m := &ItemInformationProtectionPolicyRequestBuilder{
|
||||
}
|
||||
m.urlTemplate = "{+baseurl}/sites/{site%2Did}/informationProtection/policy{?%24select,%24expand}";
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
m.pathParameters = urlTplParams;
|
||||
m.requestAdapter = requestAdapter;
|
||||
return m
|
||||
}
|
||||
// NewItemInformationProtectionPolicyRequestBuilder instantiates a new PolicyRequestBuilder and sets the default values.
|
||||
func NewItemInformationProtectionPolicyRequestBuilder(rawUrl string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemInformationProtectionPolicyRequestBuilder) {
|
||||
urlParams := make(map[string]string)
|
||||
urlParams["request-raw-url"] = rawUrl
|
||||
return NewItemInformationProtectionPolicyRequestBuilderInternal(urlParams, requestAdapter)
|
||||
}
|
||||
// CreateDeleteRequestInformation delete navigation property policy for sites
|
||||
func (m *ItemInformationProtectionPolicyRequestBuilder) CreateDeleteRequestInformation(ctx context.Context, requestConfiguration *ItemInformationProtectionPolicyRequestBuilderDeleteRequestConfiguration)(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.DELETE
|
||||
if requestConfiguration != nil {
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
}
|
||||
// CreateGetRequestInformation get policy from sites
|
||||
func (m *ItemInformationProtectionPolicyRequestBuilder) CreateGetRequestInformation(ctx context.Context, requestConfiguration *ItemInformationProtectionPolicyRequestBuilderGetRequestConfiguration)(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.GET
|
||||
requestInfo.Headers.Add("Accept", "application/json")
|
||||
if requestConfiguration != nil {
|
||||
if requestConfiguration.QueryParameters != nil {
|
||||
requestInfo.AddQueryParameters(*(requestConfiguration.QueryParameters))
|
||||
}
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
}
|
||||
// CreatePatchRequestInformation update the navigation property policy in sites
|
||||
func (m *ItemInformationProtectionPolicyRequestBuilder) CreatePatchRequestInformation(ctx context.Context, body ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.InformationProtectionPolicyable, requestConfiguration *ItemInformationProtectionPolicyRequestBuilderPatchRequestConfiguration)(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.PATCH
|
||||
requestInfo.Headers.Add("Accept", "application/json")
|
||||
requestInfo.SetContentFromParsable(ctx, m.requestAdapter, "application/json", body)
|
||||
if requestConfiguration != nil {
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
}
|
||||
// Delete delete navigation property policy for sites
|
||||
func (m *ItemInformationProtectionPolicyRequestBuilder) Delete(ctx context.Context, requestConfiguration *ItemInformationProtectionPolicyRequestBuilderDeleteRequestConfiguration)(error) {
|
||||
requestInfo, err := m.CreateDeleteRequestInformation(ctx, requestConfiguration);
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings {
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
err = m.requestAdapter.SendNoContentAsync(ctx, requestInfo, errorMapping)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
return nil
|
||||
}
|
||||
// Get get policy from sites
|
||||
func (m *ItemInformationProtectionPolicyRequestBuilder) Get(ctx context.Context, requestConfiguration *ItemInformationProtectionPolicyRequestBuilderGetRequestConfiguration)(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.InformationProtectionPolicyable, error) {
|
||||
requestInfo, err := m.CreateGetRequestInformation(ctx, requestConfiguration);
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings {
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.SendAsync(ctx, requestInfo, ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CreateInformationProtectionPolicyFromDiscriminatorValue, errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.InformationProtectionPolicyable), nil
|
||||
}
|
||||
// Labels provides operations to manage the labels property of the microsoft.graph.informationProtectionPolicy entity.
|
||||
func (m *ItemInformationProtectionPolicyRequestBuilder) Labels()(*ItemInformationProtectionPolicyLabelsRequestBuilder) {
|
||||
return NewItemInformationProtectionPolicyLabelsRequestBuilderInternal(m.pathParameters, m.requestAdapter);
|
||||
}
|
||||
// LabelsById provides operations to manage the labels property of the microsoft.graph.informationProtectionPolicy entity.
|
||||
func (m *ItemInformationProtectionPolicyRequestBuilder) LabelsById(id string)(*ItemInformationProtectionPolicyLabelsInformationProtectionLabelItemRequestBuilder) {
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range m.pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
if id != "" {
|
||||
urlTplParams["informationProtectionLabel%2Did"] = id
|
||||
}
|
||||
return NewItemInformationProtectionPolicyLabelsInformationProtectionLabelItemRequestBuilderInternal(urlTplParams, m.requestAdapter);
|
||||
}
|
||||
// Patch update the navigation property policy in sites
|
||||
func (m *ItemInformationProtectionPolicyRequestBuilder) Patch(ctx context.Context, body ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.InformationProtectionPolicyable, requestConfiguration *ItemInformationProtectionPolicyRequestBuilderPatchRequestConfiguration)(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.InformationProtectionPolicyable, error) {
|
||||
requestInfo, err := m.CreatePatchRequestInformation(ctx, body, requestConfiguration);
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings {
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.SendAsync(ctx, requestInfo, ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CreateInformationProtectionPolicyFromDiscriminatorValue, errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.InformationProtectionPolicyable), nil
|
||||
}
|
||||
@ -1,236 +0,0 @@
|
||||
package sites
|
||||
|
||||
import (
|
||||
"context"
|
||||
i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f "github.com/microsoft/kiota-abstractions-go"
|
||||
ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models"
|
||||
i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models/odataerrors"
|
||||
)
|
||||
|
||||
// ItemInformationProtectionRequestBuilder provides operations to manage the informationProtection property of the microsoft.graph.site entity.
|
||||
type ItemInformationProtectionRequestBuilder struct {
|
||||
// Path parameters for the request
|
||||
pathParameters map[string]string
|
||||
// The request adapter to use to execute the requests.
|
||||
requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter
|
||||
// Url template to use to build the URL for the current request builder
|
||||
urlTemplate string
|
||||
}
|
||||
// ItemInformationProtectionRequestBuilderDeleteRequestConfiguration configuration for the request such as headers, query parameters, and middleware options.
|
||||
type ItemInformationProtectionRequestBuilderDeleteRequestConfiguration struct {
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
}
|
||||
// ItemInformationProtectionRequestBuilderGetQueryParameters get informationProtection from sites
|
||||
type ItemInformationProtectionRequestBuilderGetQueryParameters struct {
|
||||
// Expand related entities
|
||||
Expand []string `uriparametername:"%24expand"`
|
||||
// Select properties to be returned
|
||||
Select []string `uriparametername:"%24select"`
|
||||
}
|
||||
// ItemInformationProtectionRequestBuilderGetRequestConfiguration configuration for the request such as headers, query parameters, and middleware options.
|
||||
type ItemInformationProtectionRequestBuilderGetRequestConfiguration struct {
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
// Request query parameters
|
||||
QueryParameters *ItemInformationProtectionRequestBuilderGetQueryParameters
|
||||
}
|
||||
// ItemInformationProtectionRequestBuilderPatchRequestConfiguration configuration for the request such as headers, query parameters, and middleware options.
|
||||
type ItemInformationProtectionRequestBuilderPatchRequestConfiguration struct {
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
}
|
||||
// Bitlocker provides operations to manage the bitlocker property of the microsoft.graph.informationProtection entity.
|
||||
func (m *ItemInformationProtectionRequestBuilder) Bitlocker()(*ItemInformationProtectionBitlockerRequestBuilder) {
|
||||
return NewItemInformationProtectionBitlockerRequestBuilderInternal(m.pathParameters, m.requestAdapter);
|
||||
}
|
||||
// NewItemInformationProtectionRequestBuilderInternal instantiates a new InformationProtectionRequestBuilder and sets the default values.
|
||||
func NewItemInformationProtectionRequestBuilderInternal(pathParameters map[string]string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemInformationProtectionRequestBuilder) {
|
||||
m := &ItemInformationProtectionRequestBuilder{
|
||||
}
|
||||
m.urlTemplate = "{+baseurl}/sites/{site%2Did}/informationProtection{?%24select,%24expand}";
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
m.pathParameters = urlTplParams;
|
||||
m.requestAdapter = requestAdapter;
|
||||
return m
|
||||
}
|
||||
// NewItemInformationProtectionRequestBuilder instantiates a new InformationProtectionRequestBuilder and sets the default values.
|
||||
func NewItemInformationProtectionRequestBuilder(rawUrl string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemInformationProtectionRequestBuilder) {
|
||||
urlParams := make(map[string]string)
|
||||
urlParams["request-raw-url"] = rawUrl
|
||||
return NewItemInformationProtectionRequestBuilderInternal(urlParams, requestAdapter)
|
||||
}
|
||||
// CreateDeleteRequestInformation delete navigation property informationProtection for sites
|
||||
func (m *ItemInformationProtectionRequestBuilder) CreateDeleteRequestInformation(ctx context.Context, requestConfiguration *ItemInformationProtectionRequestBuilderDeleteRequestConfiguration)(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.DELETE
|
||||
if requestConfiguration != nil {
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
}
|
||||
// CreateGetRequestInformation get informationProtection from sites
|
||||
func (m *ItemInformationProtectionRequestBuilder) CreateGetRequestInformation(ctx context.Context, requestConfiguration *ItemInformationProtectionRequestBuilderGetRequestConfiguration)(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.GET
|
||||
requestInfo.Headers.Add("Accept", "application/json")
|
||||
if requestConfiguration != nil {
|
||||
if requestConfiguration.QueryParameters != nil {
|
||||
requestInfo.AddQueryParameters(*(requestConfiguration.QueryParameters))
|
||||
}
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
}
|
||||
// CreatePatchRequestInformation update the navigation property informationProtection in sites
|
||||
func (m *ItemInformationProtectionRequestBuilder) CreatePatchRequestInformation(ctx context.Context, body ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.InformationProtectionable, requestConfiguration *ItemInformationProtectionRequestBuilderPatchRequestConfiguration)(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.PATCH
|
||||
requestInfo.Headers.Add("Accept", "application/json")
|
||||
requestInfo.SetContentFromParsable(ctx, m.requestAdapter, "application/json", body)
|
||||
if requestConfiguration != nil {
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
}
|
||||
// DataLossPreventionPolicies provides operations to manage the dataLossPreventionPolicies property of the microsoft.graph.informationProtection entity.
|
||||
func (m *ItemInformationProtectionRequestBuilder) DataLossPreventionPolicies()(*ItemInformationProtectionDataLossPreventionPoliciesRequestBuilder) {
|
||||
return NewItemInformationProtectionDataLossPreventionPoliciesRequestBuilderInternal(m.pathParameters, m.requestAdapter);
|
||||
}
|
||||
// DataLossPreventionPoliciesById provides operations to manage the dataLossPreventionPolicies property of the microsoft.graph.informationProtection entity.
|
||||
func (m *ItemInformationProtectionRequestBuilder) DataLossPreventionPoliciesById(id string)(*ItemInformationProtectionDataLossPreventionPoliciesDataLossPreventionPolicyItemRequestBuilder) {
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range m.pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
if id != "" {
|
||||
urlTplParams["dataLossPreventionPolicy%2Did"] = id
|
||||
}
|
||||
return NewItemInformationProtectionDataLossPreventionPoliciesDataLossPreventionPolicyItemRequestBuilderInternal(urlTplParams, m.requestAdapter);
|
||||
}
|
||||
// DecryptBuffer provides operations to call the decryptBuffer method.
|
||||
func (m *ItemInformationProtectionRequestBuilder) DecryptBuffer()(*ItemInformationProtectionDecryptBufferRequestBuilder) {
|
||||
return NewItemInformationProtectionDecryptBufferRequestBuilderInternal(m.pathParameters, m.requestAdapter);
|
||||
}
|
||||
// Delete delete navigation property informationProtection for sites
|
||||
func (m *ItemInformationProtectionRequestBuilder) Delete(ctx context.Context, requestConfiguration *ItemInformationProtectionRequestBuilderDeleteRequestConfiguration)(error) {
|
||||
requestInfo, err := m.CreateDeleteRequestInformation(ctx, requestConfiguration);
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings {
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
err = m.requestAdapter.SendNoContentAsync(ctx, requestInfo, errorMapping)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
return nil
|
||||
}
|
||||
// EncryptBuffer provides operations to call the encryptBuffer method.
|
||||
func (m *ItemInformationProtectionRequestBuilder) EncryptBuffer()(*ItemInformationProtectionEncryptBufferRequestBuilder) {
|
||||
return NewItemInformationProtectionEncryptBufferRequestBuilderInternal(m.pathParameters, m.requestAdapter);
|
||||
}
|
||||
// Get get informationProtection from sites
|
||||
func (m *ItemInformationProtectionRequestBuilder) Get(ctx context.Context, requestConfiguration *ItemInformationProtectionRequestBuilderGetRequestConfiguration)(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.InformationProtectionable, error) {
|
||||
requestInfo, err := m.CreateGetRequestInformation(ctx, requestConfiguration);
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings {
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.SendAsync(ctx, requestInfo, ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CreateInformationProtectionFromDiscriminatorValue, errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.InformationProtectionable), nil
|
||||
}
|
||||
// Patch update the navigation property informationProtection in sites
|
||||
func (m *ItemInformationProtectionRequestBuilder) Patch(ctx context.Context, body ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.InformationProtectionable, requestConfiguration *ItemInformationProtectionRequestBuilderPatchRequestConfiguration)(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.InformationProtectionable, error) {
|
||||
requestInfo, err := m.CreatePatchRequestInformation(ctx, body, requestConfiguration);
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings {
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.SendAsync(ctx, requestInfo, ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CreateInformationProtectionFromDiscriminatorValue, errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.InformationProtectionable), nil
|
||||
}
|
||||
// Policy provides operations to manage the policy property of the microsoft.graph.informationProtection entity.
|
||||
func (m *ItemInformationProtectionRequestBuilder) Policy()(*ItemInformationProtectionPolicyRequestBuilder) {
|
||||
return NewItemInformationProtectionPolicyRequestBuilderInternal(m.pathParameters, m.requestAdapter);
|
||||
}
|
||||
// SensitivityLabels provides operations to manage the sensitivityLabels property of the microsoft.graph.informationProtection entity.
|
||||
func (m *ItemInformationProtectionRequestBuilder) SensitivityLabels()(*ItemInformationProtectionSensitivityLabelsRequestBuilder) {
|
||||
return NewItemInformationProtectionSensitivityLabelsRequestBuilderInternal(m.pathParameters, m.requestAdapter);
|
||||
}
|
||||
// SensitivityLabelsById provides operations to manage the sensitivityLabels property of the microsoft.graph.informationProtection entity.
|
||||
func (m *ItemInformationProtectionRequestBuilder) SensitivityLabelsById(id string)(*ItemInformationProtectionSensitivityLabelsSensitivityLabelItemRequestBuilder) {
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range m.pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
if id != "" {
|
||||
urlTplParams["sensitivityLabel%2Did"] = id
|
||||
}
|
||||
return NewItemInformationProtectionSensitivityLabelsSensitivityLabelItemRequestBuilderInternal(urlTplParams, m.requestAdapter);
|
||||
}
|
||||
// SensitivityPolicySettings provides operations to manage the sensitivityPolicySettings property of the microsoft.graph.informationProtection entity.
|
||||
func (m *ItemInformationProtectionRequestBuilder) SensitivityPolicySettings()(*ItemInformationProtectionSensitivityPolicySettingsRequestBuilder) {
|
||||
return NewItemInformationProtectionSensitivityPolicySettingsRequestBuilderInternal(m.pathParameters, m.requestAdapter);
|
||||
}
|
||||
// SignDigest provides operations to call the signDigest method.
|
||||
func (m *ItemInformationProtectionRequestBuilder) SignDigest()(*ItemInformationProtectionSignDigestRequestBuilder) {
|
||||
return NewItemInformationProtectionSignDigestRequestBuilderInternal(m.pathParameters, m.requestAdapter);
|
||||
}
|
||||
// ThreatAssessmentRequests provides operations to manage the threatAssessmentRequests property of the microsoft.graph.informationProtection entity.
|
||||
func (m *ItemInformationProtectionRequestBuilder) ThreatAssessmentRequests()(*ItemInformationProtectionThreatAssessmentRequestsRequestBuilder) {
|
||||
return NewItemInformationProtectionThreatAssessmentRequestsRequestBuilderInternal(m.pathParameters, m.requestAdapter);
|
||||
}
|
||||
// ThreatAssessmentRequestsById provides operations to manage the threatAssessmentRequests property of the microsoft.graph.informationProtection entity.
|
||||
func (m *ItemInformationProtectionRequestBuilder) ThreatAssessmentRequestsById(id string)(*ItemInformationProtectionThreatAssessmentRequestsThreatAssessmentRequestItemRequestBuilder) {
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range m.pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
if id != "" {
|
||||
urlTplParams["threatAssessmentRequest%2Did"] = id
|
||||
}
|
||||
return NewItemInformationProtectionThreatAssessmentRequestsThreatAssessmentRequestItemRequestBuilderInternal(urlTplParams, m.requestAdapter);
|
||||
}
|
||||
// VerifySignature provides operations to call the verifySignature method.
|
||||
func (m *ItemInformationProtectionRequestBuilder) VerifySignature()(*ItemInformationProtectionVerifySignatureRequestBuilder) {
|
||||
return NewItemInformationProtectionVerifySignatureRequestBuilderInternal(m.pathParameters, m.requestAdapter);
|
||||
}
|
||||
@ -1,87 +0,0 @@
|
||||
package sites
|
||||
|
||||
import (
|
||||
"context"
|
||||
i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f "github.com/microsoft/kiota-abstractions-go"
|
||||
i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models/odataerrors"
|
||||
)
|
||||
|
||||
// ItemInformationProtectionSensitivityLabelsCountRequestBuilder provides operations to count the resources in the collection.
|
||||
type ItemInformationProtectionSensitivityLabelsCountRequestBuilder struct {
|
||||
// Path parameters for the request
|
||||
pathParameters map[string]string
|
||||
// The request adapter to use to execute the requests.
|
||||
requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter
|
||||
// Url template to use to build the URL for the current request builder
|
||||
urlTemplate string
|
||||
}
|
||||
// ItemInformationProtectionSensitivityLabelsCountRequestBuilderGetQueryParameters get the number of the resource
|
||||
type ItemInformationProtectionSensitivityLabelsCountRequestBuilderGetQueryParameters struct {
|
||||
// Filter items by property values
|
||||
Filter *string `uriparametername:"%24filter"`
|
||||
// Search items by search phrases
|
||||
Search *string `uriparametername:"%24search"`
|
||||
}
|
||||
// ItemInformationProtectionSensitivityLabelsCountRequestBuilderGetRequestConfiguration configuration for the request such as headers, query parameters, and middleware options.
|
||||
type ItemInformationProtectionSensitivityLabelsCountRequestBuilderGetRequestConfiguration struct {
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
// Request query parameters
|
||||
QueryParameters *ItemInformationProtectionSensitivityLabelsCountRequestBuilderGetQueryParameters
|
||||
}
|
||||
// NewItemInformationProtectionSensitivityLabelsCountRequestBuilderInternal instantiates a new CountRequestBuilder and sets the default values.
|
||||
func NewItemInformationProtectionSensitivityLabelsCountRequestBuilderInternal(pathParameters map[string]string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemInformationProtectionSensitivityLabelsCountRequestBuilder) {
|
||||
m := &ItemInformationProtectionSensitivityLabelsCountRequestBuilder{
|
||||
}
|
||||
m.urlTemplate = "{+baseurl}/sites/{site%2Did}/informationProtection/sensitivityLabels/$count{?%24search,%24filter}";
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
m.pathParameters = urlTplParams;
|
||||
m.requestAdapter = requestAdapter;
|
||||
return m
|
||||
}
|
||||
// NewItemInformationProtectionSensitivityLabelsCountRequestBuilder instantiates a new CountRequestBuilder and sets the default values.
|
||||
func NewItemInformationProtectionSensitivityLabelsCountRequestBuilder(rawUrl string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemInformationProtectionSensitivityLabelsCountRequestBuilder) {
|
||||
urlParams := make(map[string]string)
|
||||
urlParams["request-raw-url"] = rawUrl
|
||||
return NewItemInformationProtectionSensitivityLabelsCountRequestBuilderInternal(urlParams, requestAdapter)
|
||||
}
|
||||
// CreateGetRequestInformation get the number of the resource
|
||||
func (m *ItemInformationProtectionSensitivityLabelsCountRequestBuilder) CreateGetRequestInformation(ctx context.Context, requestConfiguration *ItemInformationProtectionSensitivityLabelsCountRequestBuilderGetRequestConfiguration)(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.GET
|
||||
requestInfo.Headers.Add("Accept", "text/plain")
|
||||
if requestConfiguration != nil {
|
||||
if requestConfiguration.QueryParameters != nil {
|
||||
requestInfo.AddQueryParameters(*(requestConfiguration.QueryParameters))
|
||||
}
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
}
|
||||
// Get get the number of the resource
|
||||
func (m *ItemInformationProtectionSensitivityLabelsCountRequestBuilder) Get(ctx context.Context, requestConfiguration *ItemInformationProtectionSensitivityLabelsCountRequestBuilderGetRequestConfiguration)(*int32, error) {
|
||||
requestInfo, err := m.CreateGetRequestInformation(ctx, requestConfiguration);
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings {
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.SendPrimitiveAsync(ctx, requestInfo, "int32", errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(*int32), nil
|
||||
}
|
||||
@ -1,106 +0,0 @@
|
||||
package sites
|
||||
|
||||
import (
|
||||
i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91 "github.com/microsoft/kiota-abstractions-go/serialization"
|
||||
ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models"
|
||||
)
|
||||
|
||||
// ItemInformationProtectionSensitivityLabelsEvaluatePostRequestBody provides operations to call the evaluate method.
|
||||
type ItemInformationProtectionSensitivityLabelsEvaluatePostRequestBody struct {
|
||||
// Stores additional data not described in the OpenAPI description found when deserializing. Can be used for serialization as well.
|
||||
additionalData map[string]interface{}
|
||||
// The currentLabel property
|
||||
currentLabel ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CurrentLabelable
|
||||
// The discoveredSensitiveTypes property
|
||||
discoveredSensitiveTypes []ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.DiscoveredSensitiveTypeable
|
||||
}
|
||||
// NewItemInformationProtectionSensitivityLabelsEvaluatePostRequestBody instantiates a new ItemInformationProtectionSensitivityLabelsEvaluatePostRequestBody and sets the default values.
|
||||
func NewItemInformationProtectionSensitivityLabelsEvaluatePostRequestBody()(*ItemInformationProtectionSensitivityLabelsEvaluatePostRequestBody) {
|
||||
m := &ItemInformationProtectionSensitivityLabelsEvaluatePostRequestBody{
|
||||
}
|
||||
m.SetAdditionalData(make(map[string]interface{}));
|
||||
return m
|
||||
}
|
||||
// CreateItemInformationProtectionSensitivityLabelsEvaluatePostRequestBodyFromDiscriminatorValue creates a new instance of the appropriate class based on discriminator value
|
||||
func CreateItemInformationProtectionSensitivityLabelsEvaluatePostRequestBodyFromDiscriminatorValue(parseNode i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.ParseNode)(i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.Parsable, error) {
|
||||
return NewItemInformationProtectionSensitivityLabelsEvaluatePostRequestBody(), nil
|
||||
}
|
||||
// GetAdditionalData gets the additionalData property value. Stores additional data not described in the OpenAPI description found when deserializing. Can be used for serialization as well.
|
||||
func (m *ItemInformationProtectionSensitivityLabelsEvaluatePostRequestBody) GetAdditionalData()(map[string]interface{}) {
|
||||
return m.additionalData
|
||||
}
|
||||
// GetCurrentLabel gets the currentLabel property value. The currentLabel property
|
||||
func (m *ItemInformationProtectionSensitivityLabelsEvaluatePostRequestBody) GetCurrentLabel()(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CurrentLabelable) {
|
||||
return m.currentLabel
|
||||
}
|
||||
// GetDiscoveredSensitiveTypes gets the discoveredSensitiveTypes property value. The discoveredSensitiveTypes property
|
||||
func (m *ItemInformationProtectionSensitivityLabelsEvaluatePostRequestBody) GetDiscoveredSensitiveTypes()([]ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.DiscoveredSensitiveTypeable) {
|
||||
return m.discoveredSensitiveTypes
|
||||
}
|
||||
// GetFieldDeserializers the deserialization information for the current model
|
||||
func (m *ItemInformationProtectionSensitivityLabelsEvaluatePostRequestBody) GetFieldDeserializers()(map[string]func(i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.ParseNode)(error)) {
|
||||
res := make(map[string]func(i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.ParseNode)(error))
|
||||
res["currentLabel"] = func (n i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.ParseNode) error {
|
||||
val, err := n.GetObjectValue(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CreateCurrentLabelFromDiscriminatorValue)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
if val != nil {
|
||||
m.SetCurrentLabel(val.(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CurrentLabelable))
|
||||
}
|
||||
return nil
|
||||
}
|
||||
res["discoveredSensitiveTypes"] = func (n i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.ParseNode) error {
|
||||
val, err := n.GetCollectionOfObjectValues(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CreateDiscoveredSensitiveTypeFromDiscriminatorValue)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
if val != nil {
|
||||
res := make([]ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.DiscoveredSensitiveTypeable, len(val))
|
||||
for i, v := range val {
|
||||
res[i] = v.(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.DiscoveredSensitiveTypeable)
|
||||
}
|
||||
m.SetDiscoveredSensitiveTypes(res)
|
||||
}
|
||||
return nil
|
||||
}
|
||||
return res
|
||||
}
|
||||
// Serialize serializes information the current object
|
||||
func (m *ItemInformationProtectionSensitivityLabelsEvaluatePostRequestBody) Serialize(writer i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.SerializationWriter)(error) {
|
||||
{
|
||||
err := writer.WriteObjectValue("currentLabel", m.GetCurrentLabel())
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
}
|
||||
if m.GetDiscoveredSensitiveTypes() != nil {
|
||||
cast := make([]i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.Parsable, len(m.GetDiscoveredSensitiveTypes()))
|
||||
for i, v := range m.GetDiscoveredSensitiveTypes() {
|
||||
cast[i] = v.(i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.Parsable)
|
||||
}
|
||||
err := writer.WriteCollectionOfObjectValues("discoveredSensitiveTypes", cast)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
}
|
||||
{
|
||||
err := writer.WriteAdditionalData(m.GetAdditionalData())
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
}
|
||||
return nil
|
||||
}
|
||||
// SetAdditionalData sets the additionalData property value. Stores additional data not described in the OpenAPI description found when deserializing. Can be used for serialization as well.
|
||||
func (m *ItemInformationProtectionSensitivityLabelsEvaluatePostRequestBody) SetAdditionalData(value map[string]interface{})() {
|
||||
m.additionalData = value
|
||||
}
|
||||
// SetCurrentLabel sets the currentLabel property value. The currentLabel property
|
||||
func (m *ItemInformationProtectionSensitivityLabelsEvaluatePostRequestBody) SetCurrentLabel(value ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CurrentLabelable)() {
|
||||
m.currentLabel = value
|
||||
}
|
||||
// SetDiscoveredSensitiveTypes sets the discoveredSensitiveTypes property value. The discoveredSensitiveTypes property
|
||||
func (m *ItemInformationProtectionSensitivityLabelsEvaluatePostRequestBody) SetDiscoveredSensitiveTypes(value []ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.DiscoveredSensitiveTypeable)() {
|
||||
m.discoveredSensitiveTypes = value
|
||||
}
|
||||
@ -1,16 +0,0 @@
|
||||
package sites
|
||||
|
||||
import (
|
||||
i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91 "github.com/microsoft/kiota-abstractions-go/serialization"
|
||||
ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models"
|
||||
)
|
||||
|
||||
// ItemInformationProtectionSensitivityLabelsEvaluatePostRequestBodyable
|
||||
type ItemInformationProtectionSensitivityLabelsEvaluatePostRequestBodyable interface {
|
||||
i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.AdditionalDataHolder
|
||||
i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.Parsable
|
||||
GetCurrentLabel()(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CurrentLabelable)
|
||||
GetDiscoveredSensitiveTypes()([]ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.DiscoveredSensitiveTypeable)
|
||||
SetCurrentLabel(value ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CurrentLabelable)()
|
||||
SetDiscoveredSensitiveTypes(value []ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.DiscoveredSensitiveTypeable)()
|
||||
}
|
||||
@ -1,77 +0,0 @@
|
||||
package sites
|
||||
|
||||
import (
|
||||
"context"
|
||||
i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f "github.com/microsoft/kiota-abstractions-go"
|
||||
ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models"
|
||||
i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models/odataerrors"
|
||||
)
|
||||
|
||||
// ItemInformationProtectionSensitivityLabelsEvaluateRequestBuilder provides operations to call the evaluate method.
|
||||
type ItemInformationProtectionSensitivityLabelsEvaluateRequestBuilder struct {
|
||||
// Path parameters for the request
|
||||
pathParameters map[string]string
|
||||
// The request adapter to use to execute the requests.
|
||||
requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter
|
||||
// Url template to use to build the URL for the current request builder
|
||||
urlTemplate string
|
||||
}
|
||||
// ItemInformationProtectionSensitivityLabelsEvaluateRequestBuilderPostRequestConfiguration configuration for the request such as headers, query parameters, and middleware options.
|
||||
type ItemInformationProtectionSensitivityLabelsEvaluateRequestBuilderPostRequestConfiguration struct {
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
}
|
||||
// NewItemInformationProtectionSensitivityLabelsEvaluateRequestBuilderInternal instantiates a new EvaluateRequestBuilder and sets the default values.
|
||||
func NewItemInformationProtectionSensitivityLabelsEvaluateRequestBuilderInternal(pathParameters map[string]string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemInformationProtectionSensitivityLabelsEvaluateRequestBuilder) {
|
||||
m := &ItemInformationProtectionSensitivityLabelsEvaluateRequestBuilder{
|
||||
}
|
||||
m.urlTemplate = "{+baseurl}/sites/{site%2Did}/informationProtection/sensitivityLabels/microsoft.graph.evaluate";
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
m.pathParameters = urlTplParams;
|
||||
m.requestAdapter = requestAdapter;
|
||||
return m
|
||||
}
|
||||
// NewItemInformationProtectionSensitivityLabelsEvaluateRequestBuilder instantiates a new EvaluateRequestBuilder and sets the default values.
|
||||
func NewItemInformationProtectionSensitivityLabelsEvaluateRequestBuilder(rawUrl string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemInformationProtectionSensitivityLabelsEvaluateRequestBuilder) {
|
||||
urlParams := make(map[string]string)
|
||||
urlParams["request-raw-url"] = rawUrl
|
||||
return NewItemInformationProtectionSensitivityLabelsEvaluateRequestBuilderInternal(urlParams, requestAdapter)
|
||||
}
|
||||
// CreatePostRequestInformation invoke action evaluate
|
||||
func (m *ItemInformationProtectionSensitivityLabelsEvaluateRequestBuilder) CreatePostRequestInformation(ctx context.Context, body ItemInformationProtectionSensitivityLabelsEvaluatePostRequestBodyable, requestConfiguration *ItemInformationProtectionSensitivityLabelsEvaluateRequestBuilderPostRequestConfiguration)(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.POST
|
||||
requestInfo.Headers.Add("Accept", "application/json")
|
||||
requestInfo.SetContentFromParsable(ctx, m.requestAdapter, "application/json", body)
|
||||
if requestConfiguration != nil {
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
}
|
||||
// Post invoke action evaluate
|
||||
func (m *ItemInformationProtectionSensitivityLabelsEvaluateRequestBuilder) Post(ctx context.Context, body ItemInformationProtectionSensitivityLabelsEvaluatePostRequestBodyable, requestConfiguration *ItemInformationProtectionSensitivityLabelsEvaluateRequestBuilderPostRequestConfiguration)(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.EvaluateLabelJobResponseable, error) {
|
||||
requestInfo, err := m.CreatePostRequestInformation(ctx, body, requestConfiguration);
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings {
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.SendAsync(ctx, requestInfo, ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CreateEvaluateLabelJobResponseFromDiscriminatorValue, errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.EvaluateLabelJobResponseable), nil
|
||||
}
|
||||
@ -1,87 +0,0 @@
|
||||
package sites
|
||||
|
||||
import (
|
||||
"context"
|
||||
i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f "github.com/microsoft/kiota-abstractions-go"
|
||||
i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models/odataerrors"
|
||||
)
|
||||
|
||||
// ItemInformationProtectionSensitivityLabelsItemSublabelsCountRequestBuilder provides operations to count the resources in the collection.
|
||||
type ItemInformationProtectionSensitivityLabelsItemSublabelsCountRequestBuilder struct {
|
||||
// Path parameters for the request
|
||||
pathParameters map[string]string
|
||||
// The request adapter to use to execute the requests.
|
||||
requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter
|
||||
// Url template to use to build the URL for the current request builder
|
||||
urlTemplate string
|
||||
}
|
||||
// ItemInformationProtectionSensitivityLabelsItemSublabelsCountRequestBuilderGetQueryParameters get the number of the resource
|
||||
type ItemInformationProtectionSensitivityLabelsItemSublabelsCountRequestBuilderGetQueryParameters struct {
|
||||
// Filter items by property values
|
||||
Filter *string `uriparametername:"%24filter"`
|
||||
// Search items by search phrases
|
||||
Search *string `uriparametername:"%24search"`
|
||||
}
|
||||
// ItemInformationProtectionSensitivityLabelsItemSublabelsCountRequestBuilderGetRequestConfiguration configuration for the request such as headers, query parameters, and middleware options.
|
||||
type ItemInformationProtectionSensitivityLabelsItemSublabelsCountRequestBuilderGetRequestConfiguration struct {
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
// Request query parameters
|
||||
QueryParameters *ItemInformationProtectionSensitivityLabelsItemSublabelsCountRequestBuilderGetQueryParameters
|
||||
}
|
||||
// NewItemInformationProtectionSensitivityLabelsItemSublabelsCountRequestBuilderInternal instantiates a new CountRequestBuilder and sets the default values.
|
||||
func NewItemInformationProtectionSensitivityLabelsItemSublabelsCountRequestBuilderInternal(pathParameters map[string]string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemInformationProtectionSensitivityLabelsItemSublabelsCountRequestBuilder) {
|
||||
m := &ItemInformationProtectionSensitivityLabelsItemSublabelsCountRequestBuilder{
|
||||
}
|
||||
m.urlTemplate = "{+baseurl}/sites/{site%2Did}/informationProtection/sensitivityLabels/{sensitivityLabel%2Did}/sublabels/$count{?%24search,%24filter}";
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
m.pathParameters = urlTplParams;
|
||||
m.requestAdapter = requestAdapter;
|
||||
return m
|
||||
}
|
||||
// NewItemInformationProtectionSensitivityLabelsItemSublabelsCountRequestBuilder instantiates a new CountRequestBuilder and sets the default values.
|
||||
func NewItemInformationProtectionSensitivityLabelsItemSublabelsCountRequestBuilder(rawUrl string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemInformationProtectionSensitivityLabelsItemSublabelsCountRequestBuilder) {
|
||||
urlParams := make(map[string]string)
|
||||
urlParams["request-raw-url"] = rawUrl
|
||||
return NewItemInformationProtectionSensitivityLabelsItemSublabelsCountRequestBuilderInternal(urlParams, requestAdapter)
|
||||
}
|
||||
// CreateGetRequestInformation get the number of the resource
|
||||
func (m *ItemInformationProtectionSensitivityLabelsItemSublabelsCountRequestBuilder) CreateGetRequestInformation(ctx context.Context, requestConfiguration *ItemInformationProtectionSensitivityLabelsItemSublabelsCountRequestBuilderGetRequestConfiguration)(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.GET
|
||||
requestInfo.Headers.Add("Accept", "text/plain")
|
||||
if requestConfiguration != nil {
|
||||
if requestConfiguration.QueryParameters != nil {
|
||||
requestInfo.AddQueryParameters(*(requestConfiguration.QueryParameters))
|
||||
}
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
}
|
||||
// Get get the number of the resource
|
||||
func (m *ItemInformationProtectionSensitivityLabelsItemSublabelsCountRequestBuilder) Get(ctx context.Context, requestConfiguration *ItemInformationProtectionSensitivityLabelsItemSublabelsCountRequestBuilderGetRequestConfiguration)(*int32, error) {
|
||||
requestInfo, err := m.CreateGetRequestInformation(ctx, requestConfiguration);
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings {
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.SendPrimitiveAsync(ctx, requestInfo, "int32", errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(*int32), nil
|
||||
}
|
||||
@ -1,106 +0,0 @@
|
||||
package sites
|
||||
|
||||
import (
|
||||
i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91 "github.com/microsoft/kiota-abstractions-go/serialization"
|
||||
ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models"
|
||||
)
|
||||
|
||||
// ItemInformationProtectionSensitivityLabelsItemSublabelsEvaluatePostRequestBody provides operations to call the evaluate method.
|
||||
type ItemInformationProtectionSensitivityLabelsItemSublabelsEvaluatePostRequestBody struct {
|
||||
// Stores additional data not described in the OpenAPI description found when deserializing. Can be used for serialization as well.
|
||||
additionalData map[string]interface{}
|
||||
// The currentLabel property
|
||||
currentLabel ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CurrentLabelable
|
||||
// The discoveredSensitiveTypes property
|
||||
discoveredSensitiveTypes []ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.DiscoveredSensitiveTypeable
|
||||
}
|
||||
// NewItemInformationProtectionSensitivityLabelsItemSublabelsEvaluatePostRequestBody instantiates a new ItemInformationProtectionSensitivityLabelsItemSublabelsEvaluatePostRequestBody and sets the default values.
|
||||
func NewItemInformationProtectionSensitivityLabelsItemSublabelsEvaluatePostRequestBody()(*ItemInformationProtectionSensitivityLabelsItemSublabelsEvaluatePostRequestBody) {
|
||||
m := &ItemInformationProtectionSensitivityLabelsItemSublabelsEvaluatePostRequestBody{
|
||||
}
|
||||
m.SetAdditionalData(make(map[string]interface{}));
|
||||
return m
|
||||
}
|
||||
// CreateItemInformationProtectionSensitivityLabelsItemSublabelsEvaluatePostRequestBodyFromDiscriminatorValue creates a new instance of the appropriate class based on discriminator value
|
||||
func CreateItemInformationProtectionSensitivityLabelsItemSublabelsEvaluatePostRequestBodyFromDiscriminatorValue(parseNode i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.ParseNode)(i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.Parsable, error) {
|
||||
return NewItemInformationProtectionSensitivityLabelsItemSublabelsEvaluatePostRequestBody(), nil
|
||||
}
|
||||
// GetAdditionalData gets the additionalData property value. Stores additional data not described in the OpenAPI description found when deserializing. Can be used for serialization as well.
|
||||
func (m *ItemInformationProtectionSensitivityLabelsItemSublabelsEvaluatePostRequestBody) GetAdditionalData()(map[string]interface{}) {
|
||||
return m.additionalData
|
||||
}
|
||||
// GetCurrentLabel gets the currentLabel property value. The currentLabel property
|
||||
func (m *ItemInformationProtectionSensitivityLabelsItemSublabelsEvaluatePostRequestBody) GetCurrentLabel()(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CurrentLabelable) {
|
||||
return m.currentLabel
|
||||
}
|
||||
// GetDiscoveredSensitiveTypes gets the discoveredSensitiveTypes property value. The discoveredSensitiveTypes property
|
||||
func (m *ItemInformationProtectionSensitivityLabelsItemSublabelsEvaluatePostRequestBody) GetDiscoveredSensitiveTypes()([]ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.DiscoveredSensitiveTypeable) {
|
||||
return m.discoveredSensitiveTypes
|
||||
}
|
||||
// GetFieldDeserializers the deserialization information for the current model
|
||||
func (m *ItemInformationProtectionSensitivityLabelsItemSublabelsEvaluatePostRequestBody) GetFieldDeserializers()(map[string]func(i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.ParseNode)(error)) {
|
||||
res := make(map[string]func(i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.ParseNode)(error))
|
||||
res["currentLabel"] = func (n i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.ParseNode) error {
|
||||
val, err := n.GetObjectValue(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CreateCurrentLabelFromDiscriminatorValue)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
if val != nil {
|
||||
m.SetCurrentLabel(val.(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CurrentLabelable))
|
||||
}
|
||||
return nil
|
||||
}
|
||||
res["discoveredSensitiveTypes"] = func (n i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.ParseNode) error {
|
||||
val, err := n.GetCollectionOfObjectValues(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CreateDiscoveredSensitiveTypeFromDiscriminatorValue)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
if val != nil {
|
||||
res := make([]ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.DiscoveredSensitiveTypeable, len(val))
|
||||
for i, v := range val {
|
||||
res[i] = v.(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.DiscoveredSensitiveTypeable)
|
||||
}
|
||||
m.SetDiscoveredSensitiveTypes(res)
|
||||
}
|
||||
return nil
|
||||
}
|
||||
return res
|
||||
}
|
||||
// Serialize serializes information the current object
|
||||
func (m *ItemInformationProtectionSensitivityLabelsItemSublabelsEvaluatePostRequestBody) Serialize(writer i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.SerializationWriter)(error) {
|
||||
{
|
||||
err := writer.WriteObjectValue("currentLabel", m.GetCurrentLabel())
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
}
|
||||
if m.GetDiscoveredSensitiveTypes() != nil {
|
||||
cast := make([]i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.Parsable, len(m.GetDiscoveredSensitiveTypes()))
|
||||
for i, v := range m.GetDiscoveredSensitiveTypes() {
|
||||
cast[i] = v.(i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.Parsable)
|
||||
}
|
||||
err := writer.WriteCollectionOfObjectValues("discoveredSensitiveTypes", cast)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
}
|
||||
{
|
||||
err := writer.WriteAdditionalData(m.GetAdditionalData())
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
}
|
||||
return nil
|
||||
}
|
||||
// SetAdditionalData sets the additionalData property value. Stores additional data not described in the OpenAPI description found when deserializing. Can be used for serialization as well.
|
||||
func (m *ItemInformationProtectionSensitivityLabelsItemSublabelsEvaluatePostRequestBody) SetAdditionalData(value map[string]interface{})() {
|
||||
m.additionalData = value
|
||||
}
|
||||
// SetCurrentLabel sets the currentLabel property value. The currentLabel property
|
||||
func (m *ItemInformationProtectionSensitivityLabelsItemSublabelsEvaluatePostRequestBody) SetCurrentLabel(value ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CurrentLabelable)() {
|
||||
m.currentLabel = value
|
||||
}
|
||||
// SetDiscoveredSensitiveTypes sets the discoveredSensitiveTypes property value. The discoveredSensitiveTypes property
|
||||
func (m *ItemInformationProtectionSensitivityLabelsItemSublabelsEvaluatePostRequestBody) SetDiscoveredSensitiveTypes(value []ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.DiscoveredSensitiveTypeable)() {
|
||||
m.discoveredSensitiveTypes = value
|
||||
}
|
||||
@ -1,16 +0,0 @@
|
||||
package sites
|
||||
|
||||
import (
|
||||
i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91 "github.com/microsoft/kiota-abstractions-go/serialization"
|
||||
ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models"
|
||||
)
|
||||
|
||||
// ItemInformationProtectionSensitivityLabelsItemSublabelsEvaluatePostRequestBodyable
|
||||
type ItemInformationProtectionSensitivityLabelsItemSublabelsEvaluatePostRequestBodyable interface {
|
||||
i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.AdditionalDataHolder
|
||||
i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.Parsable
|
||||
GetCurrentLabel()(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CurrentLabelable)
|
||||
GetDiscoveredSensitiveTypes()([]ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.DiscoveredSensitiveTypeable)
|
||||
SetCurrentLabel(value ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CurrentLabelable)()
|
||||
SetDiscoveredSensitiveTypes(value []ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.DiscoveredSensitiveTypeable)()
|
||||
}
|
||||
@ -1,77 +0,0 @@
|
||||
package sites
|
||||
|
||||
import (
|
||||
"context"
|
||||
i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f "github.com/microsoft/kiota-abstractions-go"
|
||||
ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models"
|
||||
i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models/odataerrors"
|
||||
)
|
||||
|
||||
// ItemInformationProtectionSensitivityLabelsItemSublabelsEvaluateRequestBuilder provides operations to call the evaluate method.
|
||||
type ItemInformationProtectionSensitivityLabelsItemSublabelsEvaluateRequestBuilder struct {
|
||||
// Path parameters for the request
|
||||
pathParameters map[string]string
|
||||
// The request adapter to use to execute the requests.
|
||||
requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter
|
||||
// Url template to use to build the URL for the current request builder
|
||||
urlTemplate string
|
||||
}
|
||||
// ItemInformationProtectionSensitivityLabelsItemSublabelsEvaluateRequestBuilderPostRequestConfiguration configuration for the request such as headers, query parameters, and middleware options.
|
||||
type ItemInformationProtectionSensitivityLabelsItemSublabelsEvaluateRequestBuilderPostRequestConfiguration struct {
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
}
|
||||
// NewItemInformationProtectionSensitivityLabelsItemSublabelsEvaluateRequestBuilderInternal instantiates a new EvaluateRequestBuilder and sets the default values.
|
||||
func NewItemInformationProtectionSensitivityLabelsItemSublabelsEvaluateRequestBuilderInternal(pathParameters map[string]string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemInformationProtectionSensitivityLabelsItemSublabelsEvaluateRequestBuilder) {
|
||||
m := &ItemInformationProtectionSensitivityLabelsItemSublabelsEvaluateRequestBuilder{
|
||||
}
|
||||
m.urlTemplate = "{+baseurl}/sites/{site%2Did}/informationProtection/sensitivityLabels/{sensitivityLabel%2Did}/sublabels/microsoft.graph.evaluate";
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
m.pathParameters = urlTplParams;
|
||||
m.requestAdapter = requestAdapter;
|
||||
return m
|
||||
}
|
||||
// NewItemInformationProtectionSensitivityLabelsItemSublabelsEvaluateRequestBuilder instantiates a new EvaluateRequestBuilder and sets the default values.
|
||||
func NewItemInformationProtectionSensitivityLabelsItemSublabelsEvaluateRequestBuilder(rawUrl string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemInformationProtectionSensitivityLabelsItemSublabelsEvaluateRequestBuilder) {
|
||||
urlParams := make(map[string]string)
|
||||
urlParams["request-raw-url"] = rawUrl
|
||||
return NewItemInformationProtectionSensitivityLabelsItemSublabelsEvaluateRequestBuilderInternal(urlParams, requestAdapter)
|
||||
}
|
||||
// CreatePostRequestInformation invoke action evaluate
|
||||
func (m *ItemInformationProtectionSensitivityLabelsItemSublabelsEvaluateRequestBuilder) CreatePostRequestInformation(ctx context.Context, body ItemInformationProtectionSensitivityLabelsItemSublabelsEvaluatePostRequestBodyable, requestConfiguration *ItemInformationProtectionSensitivityLabelsItemSublabelsEvaluateRequestBuilderPostRequestConfiguration)(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.POST
|
||||
requestInfo.Headers.Add("Accept", "application/json")
|
||||
requestInfo.SetContentFromParsable(ctx, m.requestAdapter, "application/json", body)
|
||||
if requestConfiguration != nil {
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
}
|
||||
// Post invoke action evaluate
|
||||
func (m *ItemInformationProtectionSensitivityLabelsItemSublabelsEvaluateRequestBuilder) Post(ctx context.Context, body ItemInformationProtectionSensitivityLabelsItemSublabelsEvaluatePostRequestBodyable, requestConfiguration *ItemInformationProtectionSensitivityLabelsItemSublabelsEvaluateRequestBuilderPostRequestConfiguration)(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.EvaluateLabelJobResponseable, error) {
|
||||
requestInfo, err := m.CreatePostRequestInformation(ctx, body, requestConfiguration);
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings {
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.SendAsync(ctx, requestInfo, ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CreateEvaluateLabelJobResponseFromDiscriminatorValue, errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.EvaluateLabelJobResponseable), nil
|
||||
}
|
||||
@ -1,148 +0,0 @@
|
||||
package sites
|
||||
|
||||
import (
|
||||
"context"
|
||||
i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f "github.com/microsoft/kiota-abstractions-go"
|
||||
ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models"
|
||||
i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models/odataerrors"
|
||||
)
|
||||
|
||||
// ItemInformationProtectionSensitivityLabelsItemSublabelsRequestBuilder provides operations to manage the sublabels property of the microsoft.graph.sensitivityLabel entity.
|
||||
type ItemInformationProtectionSensitivityLabelsItemSublabelsRequestBuilder struct {
|
||||
// Path parameters for the request
|
||||
pathParameters map[string]string
|
||||
// The request adapter to use to execute the requests.
|
||||
requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter
|
||||
// Url template to use to build the URL for the current request builder
|
||||
urlTemplate string
|
||||
}
|
||||
// ItemInformationProtectionSensitivityLabelsItemSublabelsRequestBuilderGetQueryParameters get sublabels from sites
|
||||
type ItemInformationProtectionSensitivityLabelsItemSublabelsRequestBuilderGetQueryParameters struct {
|
||||
// Include count of items
|
||||
Count *bool `uriparametername:"%24count"`
|
||||
// Expand related entities
|
||||
Expand []string `uriparametername:"%24expand"`
|
||||
// Filter items by property values
|
||||
Filter *string `uriparametername:"%24filter"`
|
||||
// Order items by property values
|
||||
Orderby []string `uriparametername:"%24orderby"`
|
||||
// Search items by search phrases
|
||||
Search *string `uriparametername:"%24search"`
|
||||
// Select properties to be returned
|
||||
Select []string `uriparametername:"%24select"`
|
||||
// Skip the first n items
|
||||
Skip *int32 `uriparametername:"%24skip"`
|
||||
// Show only the first n items
|
||||
Top *int32 `uriparametername:"%24top"`
|
||||
}
|
||||
// ItemInformationProtectionSensitivityLabelsItemSublabelsRequestBuilderGetRequestConfiguration configuration for the request such as headers, query parameters, and middleware options.
|
||||
type ItemInformationProtectionSensitivityLabelsItemSublabelsRequestBuilderGetRequestConfiguration struct {
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
// Request query parameters
|
||||
QueryParameters *ItemInformationProtectionSensitivityLabelsItemSublabelsRequestBuilderGetQueryParameters
|
||||
}
|
||||
// ItemInformationProtectionSensitivityLabelsItemSublabelsRequestBuilderPostRequestConfiguration configuration for the request such as headers, query parameters, and middleware options.
|
||||
type ItemInformationProtectionSensitivityLabelsItemSublabelsRequestBuilderPostRequestConfiguration struct {
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
}
|
||||
// NewItemInformationProtectionSensitivityLabelsItemSublabelsRequestBuilderInternal instantiates a new SublabelsRequestBuilder and sets the default values.
|
||||
func NewItemInformationProtectionSensitivityLabelsItemSublabelsRequestBuilderInternal(pathParameters map[string]string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemInformationProtectionSensitivityLabelsItemSublabelsRequestBuilder) {
|
||||
m := &ItemInformationProtectionSensitivityLabelsItemSublabelsRequestBuilder{
|
||||
}
|
||||
m.urlTemplate = "{+baseurl}/sites/{site%2Did}/informationProtection/sensitivityLabels/{sensitivityLabel%2Did}/sublabels{?%24top,%24skip,%24search,%24filter,%24count,%24orderby,%24select,%24expand}";
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
m.pathParameters = urlTplParams;
|
||||
m.requestAdapter = requestAdapter;
|
||||
return m
|
||||
}
|
||||
// NewItemInformationProtectionSensitivityLabelsItemSublabelsRequestBuilder instantiates a new SublabelsRequestBuilder and sets the default values.
|
||||
func NewItemInformationProtectionSensitivityLabelsItemSublabelsRequestBuilder(rawUrl string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemInformationProtectionSensitivityLabelsItemSublabelsRequestBuilder) {
|
||||
urlParams := make(map[string]string)
|
||||
urlParams["request-raw-url"] = rawUrl
|
||||
return NewItemInformationProtectionSensitivityLabelsItemSublabelsRequestBuilderInternal(urlParams, requestAdapter)
|
||||
}
|
||||
// Count provides operations to count the resources in the collection.
|
||||
func (m *ItemInformationProtectionSensitivityLabelsItemSublabelsRequestBuilder) Count()(*ItemInformationProtectionSensitivityLabelsItemSublabelsCountRequestBuilder) {
|
||||
return NewItemInformationProtectionSensitivityLabelsItemSublabelsCountRequestBuilderInternal(m.pathParameters, m.requestAdapter);
|
||||
}
|
||||
// CreateGetRequestInformation get sublabels from sites
|
||||
func (m *ItemInformationProtectionSensitivityLabelsItemSublabelsRequestBuilder) CreateGetRequestInformation(ctx context.Context, requestConfiguration *ItemInformationProtectionSensitivityLabelsItemSublabelsRequestBuilderGetRequestConfiguration)(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.GET
|
||||
requestInfo.Headers.Add("Accept", "application/json")
|
||||
if requestConfiguration != nil {
|
||||
if requestConfiguration.QueryParameters != nil {
|
||||
requestInfo.AddQueryParameters(*(requestConfiguration.QueryParameters))
|
||||
}
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
}
|
||||
// CreatePostRequestInformation create new navigation property to sublabels for sites
|
||||
func (m *ItemInformationProtectionSensitivityLabelsItemSublabelsRequestBuilder) CreatePostRequestInformation(ctx context.Context, body ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.SensitivityLabelable, requestConfiguration *ItemInformationProtectionSensitivityLabelsItemSublabelsRequestBuilderPostRequestConfiguration)(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.POST
|
||||
requestInfo.Headers.Add("Accept", "application/json")
|
||||
requestInfo.SetContentFromParsable(ctx, m.requestAdapter, "application/json", body)
|
||||
if requestConfiguration != nil {
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
}
|
||||
// Evaluate provides operations to call the evaluate method.
|
||||
func (m *ItemInformationProtectionSensitivityLabelsItemSublabelsRequestBuilder) Evaluate()(*ItemInformationProtectionSensitivityLabelsItemSublabelsEvaluateRequestBuilder) {
|
||||
return NewItemInformationProtectionSensitivityLabelsItemSublabelsEvaluateRequestBuilderInternal(m.pathParameters, m.requestAdapter);
|
||||
}
|
||||
// Get get sublabels from sites
|
||||
func (m *ItemInformationProtectionSensitivityLabelsItemSublabelsRequestBuilder) Get(ctx context.Context, requestConfiguration *ItemInformationProtectionSensitivityLabelsItemSublabelsRequestBuilderGetRequestConfiguration)(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.SensitivityLabelCollectionResponseable, error) {
|
||||
requestInfo, err := m.CreateGetRequestInformation(ctx, requestConfiguration);
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings {
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.SendAsync(ctx, requestInfo, ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CreateSensitivityLabelCollectionResponseFromDiscriminatorValue, errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.SensitivityLabelCollectionResponseable), nil
|
||||
}
|
||||
// Post create new navigation property to sublabels for sites
|
||||
func (m *ItemInformationProtectionSensitivityLabelsItemSublabelsRequestBuilder) Post(ctx context.Context, body ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.SensitivityLabelable, requestConfiguration *ItemInformationProtectionSensitivityLabelsItemSublabelsRequestBuilderPostRequestConfiguration)(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.SensitivityLabelable, error) {
|
||||
requestInfo, err := m.CreatePostRequestInformation(ctx, body, requestConfiguration);
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings {
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.SendAsync(ctx, requestInfo, ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CreateSensitivityLabelFromDiscriminatorValue, errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.SensitivityLabelable), nil
|
||||
}
|
||||
@ -1,163 +0,0 @@
|
||||
package sites
|
||||
|
||||
import (
|
||||
"context"
|
||||
i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f "github.com/microsoft/kiota-abstractions-go"
|
||||
ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models"
|
||||
i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models/odataerrors"
|
||||
)
|
||||
|
||||
// ItemInformationProtectionSensitivityLabelsItemSublabelsSensitivityLabelItemRequestBuilder provides operations to manage the sublabels property of the microsoft.graph.sensitivityLabel entity.
|
||||
type ItemInformationProtectionSensitivityLabelsItemSublabelsSensitivityLabelItemRequestBuilder struct {
|
||||
// Path parameters for the request
|
||||
pathParameters map[string]string
|
||||
// The request adapter to use to execute the requests.
|
||||
requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter
|
||||
// Url template to use to build the URL for the current request builder
|
||||
urlTemplate string
|
||||
}
|
||||
// ItemInformationProtectionSensitivityLabelsItemSublabelsSensitivityLabelItemRequestBuilderDeleteRequestConfiguration configuration for the request such as headers, query parameters, and middleware options.
|
||||
type ItemInformationProtectionSensitivityLabelsItemSublabelsSensitivityLabelItemRequestBuilderDeleteRequestConfiguration struct {
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
}
|
||||
// ItemInformationProtectionSensitivityLabelsItemSublabelsSensitivityLabelItemRequestBuilderGetQueryParameters get sublabels from sites
|
||||
type ItemInformationProtectionSensitivityLabelsItemSublabelsSensitivityLabelItemRequestBuilderGetQueryParameters struct {
|
||||
// Expand related entities
|
||||
Expand []string `uriparametername:"%24expand"`
|
||||
// Select properties to be returned
|
||||
Select []string `uriparametername:"%24select"`
|
||||
}
|
||||
// ItemInformationProtectionSensitivityLabelsItemSublabelsSensitivityLabelItemRequestBuilderGetRequestConfiguration configuration for the request such as headers, query parameters, and middleware options.
|
||||
type ItemInformationProtectionSensitivityLabelsItemSublabelsSensitivityLabelItemRequestBuilderGetRequestConfiguration struct {
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
// Request query parameters
|
||||
QueryParameters *ItemInformationProtectionSensitivityLabelsItemSublabelsSensitivityLabelItemRequestBuilderGetQueryParameters
|
||||
}
|
||||
// ItemInformationProtectionSensitivityLabelsItemSublabelsSensitivityLabelItemRequestBuilderPatchRequestConfiguration configuration for the request such as headers, query parameters, and middleware options.
|
||||
type ItemInformationProtectionSensitivityLabelsItemSublabelsSensitivityLabelItemRequestBuilderPatchRequestConfiguration struct {
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
}
|
||||
// NewItemInformationProtectionSensitivityLabelsItemSublabelsSensitivityLabelItemRequestBuilderInternal instantiates a new SensitivityLabelItemRequestBuilder and sets the default values.
|
||||
func NewItemInformationProtectionSensitivityLabelsItemSublabelsSensitivityLabelItemRequestBuilderInternal(pathParameters map[string]string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemInformationProtectionSensitivityLabelsItemSublabelsSensitivityLabelItemRequestBuilder) {
|
||||
m := &ItemInformationProtectionSensitivityLabelsItemSublabelsSensitivityLabelItemRequestBuilder{
|
||||
}
|
||||
m.urlTemplate = "{+baseurl}/sites/{site%2Did}/informationProtection/sensitivityLabels/{sensitivityLabel%2Did}/sublabels/{sensitivityLabel%2Did1}{?%24select,%24expand}";
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
m.pathParameters = urlTplParams;
|
||||
m.requestAdapter = requestAdapter;
|
||||
return m
|
||||
}
|
||||
// NewItemInformationProtectionSensitivityLabelsItemSublabelsSensitivityLabelItemRequestBuilder instantiates a new SensitivityLabelItemRequestBuilder and sets the default values.
|
||||
func NewItemInformationProtectionSensitivityLabelsItemSublabelsSensitivityLabelItemRequestBuilder(rawUrl string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemInformationProtectionSensitivityLabelsItemSublabelsSensitivityLabelItemRequestBuilder) {
|
||||
urlParams := make(map[string]string)
|
||||
urlParams["request-raw-url"] = rawUrl
|
||||
return NewItemInformationProtectionSensitivityLabelsItemSublabelsSensitivityLabelItemRequestBuilderInternal(urlParams, requestAdapter)
|
||||
}
|
||||
// CreateDeleteRequestInformation delete navigation property sublabels for sites
|
||||
func (m *ItemInformationProtectionSensitivityLabelsItemSublabelsSensitivityLabelItemRequestBuilder) CreateDeleteRequestInformation(ctx context.Context, requestConfiguration *ItemInformationProtectionSensitivityLabelsItemSublabelsSensitivityLabelItemRequestBuilderDeleteRequestConfiguration)(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.DELETE
|
||||
if requestConfiguration != nil {
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
}
|
||||
// CreateGetRequestInformation get sublabels from sites
|
||||
func (m *ItemInformationProtectionSensitivityLabelsItemSublabelsSensitivityLabelItemRequestBuilder) CreateGetRequestInformation(ctx context.Context, requestConfiguration *ItemInformationProtectionSensitivityLabelsItemSublabelsSensitivityLabelItemRequestBuilderGetRequestConfiguration)(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.GET
|
||||
requestInfo.Headers.Add("Accept", "application/json")
|
||||
if requestConfiguration != nil {
|
||||
if requestConfiguration.QueryParameters != nil {
|
||||
requestInfo.AddQueryParameters(*(requestConfiguration.QueryParameters))
|
||||
}
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
}
|
||||
// CreatePatchRequestInformation update the navigation property sublabels in sites
|
||||
func (m *ItemInformationProtectionSensitivityLabelsItemSublabelsSensitivityLabelItemRequestBuilder) CreatePatchRequestInformation(ctx context.Context, body ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.SensitivityLabelable, requestConfiguration *ItemInformationProtectionSensitivityLabelsItemSublabelsSensitivityLabelItemRequestBuilderPatchRequestConfiguration)(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.PATCH
|
||||
requestInfo.Headers.Add("Accept", "application/json")
|
||||
requestInfo.SetContentFromParsable(ctx, m.requestAdapter, "application/json", body)
|
||||
if requestConfiguration != nil {
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
}
|
||||
// Delete delete navigation property sublabels for sites
|
||||
func (m *ItemInformationProtectionSensitivityLabelsItemSublabelsSensitivityLabelItemRequestBuilder) Delete(ctx context.Context, requestConfiguration *ItemInformationProtectionSensitivityLabelsItemSublabelsSensitivityLabelItemRequestBuilderDeleteRequestConfiguration)(error) {
|
||||
requestInfo, err := m.CreateDeleteRequestInformation(ctx, requestConfiguration);
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings {
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
err = m.requestAdapter.SendNoContentAsync(ctx, requestInfo, errorMapping)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
return nil
|
||||
}
|
||||
// Get get sublabels from sites
|
||||
func (m *ItemInformationProtectionSensitivityLabelsItemSublabelsSensitivityLabelItemRequestBuilder) Get(ctx context.Context, requestConfiguration *ItemInformationProtectionSensitivityLabelsItemSublabelsSensitivityLabelItemRequestBuilderGetRequestConfiguration)(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.SensitivityLabelable, error) {
|
||||
requestInfo, err := m.CreateGetRequestInformation(ctx, requestConfiguration);
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings {
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.SendAsync(ctx, requestInfo, ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CreateSensitivityLabelFromDiscriminatorValue, errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.SensitivityLabelable), nil
|
||||
}
|
||||
// Patch update the navigation property sublabels in sites
|
||||
func (m *ItemInformationProtectionSensitivityLabelsItemSublabelsSensitivityLabelItemRequestBuilder) Patch(ctx context.Context, body ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.SensitivityLabelable, requestConfiguration *ItemInformationProtectionSensitivityLabelsItemSublabelsSensitivityLabelItemRequestBuilderPatchRequestConfiguration)(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.SensitivityLabelable, error) {
|
||||
requestInfo, err := m.CreatePatchRequestInformation(ctx, body, requestConfiguration);
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings {
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.SendAsync(ctx, requestInfo, ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CreateSensitivityLabelFromDiscriminatorValue, errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.SensitivityLabelable), nil
|
||||
}
|
||||
@ -1,148 +0,0 @@
|
||||
package sites
|
||||
|
||||
import (
|
||||
"context"
|
||||
i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f "github.com/microsoft/kiota-abstractions-go"
|
||||
ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models"
|
||||
i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models/odataerrors"
|
||||
)
|
||||
|
||||
// ItemInformationProtectionSensitivityLabelsRequestBuilder provides operations to manage the sensitivityLabels property of the microsoft.graph.informationProtection entity.
|
||||
type ItemInformationProtectionSensitivityLabelsRequestBuilder struct {
|
||||
// Path parameters for the request
|
||||
pathParameters map[string]string
|
||||
// The request adapter to use to execute the requests.
|
||||
requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter
|
||||
// Url template to use to build the URL for the current request builder
|
||||
urlTemplate string
|
||||
}
|
||||
// ItemInformationProtectionSensitivityLabelsRequestBuilderGetQueryParameters get sensitivityLabels from sites
|
||||
type ItemInformationProtectionSensitivityLabelsRequestBuilderGetQueryParameters struct {
|
||||
// Include count of items
|
||||
Count *bool `uriparametername:"%24count"`
|
||||
// Expand related entities
|
||||
Expand []string `uriparametername:"%24expand"`
|
||||
// Filter items by property values
|
||||
Filter *string `uriparametername:"%24filter"`
|
||||
// Order items by property values
|
||||
Orderby []string `uriparametername:"%24orderby"`
|
||||
// Search items by search phrases
|
||||
Search *string `uriparametername:"%24search"`
|
||||
// Select properties to be returned
|
||||
Select []string `uriparametername:"%24select"`
|
||||
// Skip the first n items
|
||||
Skip *int32 `uriparametername:"%24skip"`
|
||||
// Show only the first n items
|
||||
Top *int32 `uriparametername:"%24top"`
|
||||
}
|
||||
// ItemInformationProtectionSensitivityLabelsRequestBuilderGetRequestConfiguration configuration for the request such as headers, query parameters, and middleware options.
|
||||
type ItemInformationProtectionSensitivityLabelsRequestBuilderGetRequestConfiguration struct {
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
// Request query parameters
|
||||
QueryParameters *ItemInformationProtectionSensitivityLabelsRequestBuilderGetQueryParameters
|
||||
}
|
||||
// ItemInformationProtectionSensitivityLabelsRequestBuilderPostRequestConfiguration configuration for the request such as headers, query parameters, and middleware options.
|
||||
type ItemInformationProtectionSensitivityLabelsRequestBuilderPostRequestConfiguration struct {
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
}
|
||||
// NewItemInformationProtectionSensitivityLabelsRequestBuilderInternal instantiates a new SensitivityLabelsRequestBuilder and sets the default values.
|
||||
func NewItemInformationProtectionSensitivityLabelsRequestBuilderInternal(pathParameters map[string]string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemInformationProtectionSensitivityLabelsRequestBuilder) {
|
||||
m := &ItemInformationProtectionSensitivityLabelsRequestBuilder{
|
||||
}
|
||||
m.urlTemplate = "{+baseurl}/sites/{site%2Did}/informationProtection/sensitivityLabels{?%24top,%24skip,%24search,%24filter,%24count,%24orderby,%24select,%24expand}";
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
m.pathParameters = urlTplParams;
|
||||
m.requestAdapter = requestAdapter;
|
||||
return m
|
||||
}
|
||||
// NewItemInformationProtectionSensitivityLabelsRequestBuilder instantiates a new SensitivityLabelsRequestBuilder and sets the default values.
|
||||
func NewItemInformationProtectionSensitivityLabelsRequestBuilder(rawUrl string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemInformationProtectionSensitivityLabelsRequestBuilder) {
|
||||
urlParams := make(map[string]string)
|
||||
urlParams["request-raw-url"] = rawUrl
|
||||
return NewItemInformationProtectionSensitivityLabelsRequestBuilderInternal(urlParams, requestAdapter)
|
||||
}
|
||||
// Count provides operations to count the resources in the collection.
|
||||
func (m *ItemInformationProtectionSensitivityLabelsRequestBuilder) Count()(*ItemInformationProtectionSensitivityLabelsCountRequestBuilder) {
|
||||
return NewItemInformationProtectionSensitivityLabelsCountRequestBuilderInternal(m.pathParameters, m.requestAdapter);
|
||||
}
|
||||
// CreateGetRequestInformation get sensitivityLabels from sites
|
||||
func (m *ItemInformationProtectionSensitivityLabelsRequestBuilder) CreateGetRequestInformation(ctx context.Context, requestConfiguration *ItemInformationProtectionSensitivityLabelsRequestBuilderGetRequestConfiguration)(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.GET
|
||||
requestInfo.Headers.Add("Accept", "application/json")
|
||||
if requestConfiguration != nil {
|
||||
if requestConfiguration.QueryParameters != nil {
|
||||
requestInfo.AddQueryParameters(*(requestConfiguration.QueryParameters))
|
||||
}
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
}
|
||||
// CreatePostRequestInformation create new navigation property to sensitivityLabels for sites
|
||||
func (m *ItemInformationProtectionSensitivityLabelsRequestBuilder) CreatePostRequestInformation(ctx context.Context, body ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.SensitivityLabelable, requestConfiguration *ItemInformationProtectionSensitivityLabelsRequestBuilderPostRequestConfiguration)(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.POST
|
||||
requestInfo.Headers.Add("Accept", "application/json")
|
||||
requestInfo.SetContentFromParsable(ctx, m.requestAdapter, "application/json", body)
|
||||
if requestConfiguration != nil {
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
}
|
||||
// Evaluate provides operations to call the evaluate method.
|
||||
func (m *ItemInformationProtectionSensitivityLabelsRequestBuilder) Evaluate()(*ItemInformationProtectionSensitivityLabelsEvaluateRequestBuilder) {
|
||||
return NewItemInformationProtectionSensitivityLabelsEvaluateRequestBuilderInternal(m.pathParameters, m.requestAdapter);
|
||||
}
|
||||
// Get get sensitivityLabels from sites
|
||||
func (m *ItemInformationProtectionSensitivityLabelsRequestBuilder) Get(ctx context.Context, requestConfiguration *ItemInformationProtectionSensitivityLabelsRequestBuilderGetRequestConfiguration)(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.SensitivityLabelCollectionResponseable, error) {
|
||||
requestInfo, err := m.CreateGetRequestInformation(ctx, requestConfiguration);
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings {
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.SendAsync(ctx, requestInfo, ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CreateSensitivityLabelCollectionResponseFromDiscriminatorValue, errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.SensitivityLabelCollectionResponseable), nil
|
||||
}
|
||||
// Post create new navigation property to sensitivityLabels for sites
|
||||
func (m *ItemInformationProtectionSensitivityLabelsRequestBuilder) Post(ctx context.Context, body ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.SensitivityLabelable, requestConfiguration *ItemInformationProtectionSensitivityLabelsRequestBuilderPostRequestConfiguration)(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.SensitivityLabelable, error) {
|
||||
requestInfo, err := m.CreatePostRequestInformation(ctx, body, requestConfiguration);
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings {
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.SendAsync(ctx, requestInfo, ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CreateSensitivityLabelFromDiscriminatorValue, errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.SensitivityLabelable), nil
|
||||
}
|
||||
@ -1,178 +0,0 @@
|
||||
package sites
|
||||
|
||||
import (
|
||||
"context"
|
||||
i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f "github.com/microsoft/kiota-abstractions-go"
|
||||
ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models"
|
||||
i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models/odataerrors"
|
||||
)
|
||||
|
||||
// ItemInformationProtectionSensitivityLabelsSensitivityLabelItemRequestBuilder provides operations to manage the sensitivityLabels property of the microsoft.graph.informationProtection entity.
|
||||
type ItemInformationProtectionSensitivityLabelsSensitivityLabelItemRequestBuilder struct {
|
||||
// Path parameters for the request
|
||||
pathParameters map[string]string
|
||||
// The request adapter to use to execute the requests.
|
||||
requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter
|
||||
// Url template to use to build the URL for the current request builder
|
||||
urlTemplate string
|
||||
}
|
||||
// ItemInformationProtectionSensitivityLabelsSensitivityLabelItemRequestBuilderDeleteRequestConfiguration configuration for the request such as headers, query parameters, and middleware options.
|
||||
type ItemInformationProtectionSensitivityLabelsSensitivityLabelItemRequestBuilderDeleteRequestConfiguration struct {
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
}
|
||||
// ItemInformationProtectionSensitivityLabelsSensitivityLabelItemRequestBuilderGetQueryParameters get sensitivityLabels from sites
|
||||
type ItemInformationProtectionSensitivityLabelsSensitivityLabelItemRequestBuilderGetQueryParameters struct {
|
||||
// Expand related entities
|
||||
Expand []string `uriparametername:"%24expand"`
|
||||
// Select properties to be returned
|
||||
Select []string `uriparametername:"%24select"`
|
||||
}
|
||||
// ItemInformationProtectionSensitivityLabelsSensitivityLabelItemRequestBuilderGetRequestConfiguration configuration for the request such as headers, query parameters, and middleware options.
|
||||
type ItemInformationProtectionSensitivityLabelsSensitivityLabelItemRequestBuilderGetRequestConfiguration struct {
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
// Request query parameters
|
||||
QueryParameters *ItemInformationProtectionSensitivityLabelsSensitivityLabelItemRequestBuilderGetQueryParameters
|
||||
}
|
||||
// ItemInformationProtectionSensitivityLabelsSensitivityLabelItemRequestBuilderPatchRequestConfiguration configuration for the request such as headers, query parameters, and middleware options.
|
||||
type ItemInformationProtectionSensitivityLabelsSensitivityLabelItemRequestBuilderPatchRequestConfiguration struct {
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
}
|
||||
// NewItemInformationProtectionSensitivityLabelsSensitivityLabelItemRequestBuilderInternal instantiates a new SensitivityLabelItemRequestBuilder and sets the default values.
|
||||
func NewItemInformationProtectionSensitivityLabelsSensitivityLabelItemRequestBuilderInternal(pathParameters map[string]string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemInformationProtectionSensitivityLabelsSensitivityLabelItemRequestBuilder) {
|
||||
m := &ItemInformationProtectionSensitivityLabelsSensitivityLabelItemRequestBuilder{
|
||||
}
|
||||
m.urlTemplate = "{+baseurl}/sites/{site%2Did}/informationProtection/sensitivityLabels/{sensitivityLabel%2Did}{?%24select,%24expand}";
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
m.pathParameters = urlTplParams;
|
||||
m.requestAdapter = requestAdapter;
|
||||
return m
|
||||
}
|
||||
// NewItemInformationProtectionSensitivityLabelsSensitivityLabelItemRequestBuilder instantiates a new SensitivityLabelItemRequestBuilder and sets the default values.
|
||||
func NewItemInformationProtectionSensitivityLabelsSensitivityLabelItemRequestBuilder(rawUrl string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemInformationProtectionSensitivityLabelsSensitivityLabelItemRequestBuilder) {
|
||||
urlParams := make(map[string]string)
|
||||
urlParams["request-raw-url"] = rawUrl
|
||||
return NewItemInformationProtectionSensitivityLabelsSensitivityLabelItemRequestBuilderInternal(urlParams, requestAdapter)
|
||||
}
|
||||
// CreateDeleteRequestInformation delete navigation property sensitivityLabels for sites
|
||||
func (m *ItemInformationProtectionSensitivityLabelsSensitivityLabelItemRequestBuilder) CreateDeleteRequestInformation(ctx context.Context, requestConfiguration *ItemInformationProtectionSensitivityLabelsSensitivityLabelItemRequestBuilderDeleteRequestConfiguration)(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.DELETE
|
||||
if requestConfiguration != nil {
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
}
|
||||
// CreateGetRequestInformation get sensitivityLabels from sites
|
||||
func (m *ItemInformationProtectionSensitivityLabelsSensitivityLabelItemRequestBuilder) CreateGetRequestInformation(ctx context.Context, requestConfiguration *ItemInformationProtectionSensitivityLabelsSensitivityLabelItemRequestBuilderGetRequestConfiguration)(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.GET
|
||||
requestInfo.Headers.Add("Accept", "application/json")
|
||||
if requestConfiguration != nil {
|
||||
if requestConfiguration.QueryParameters != nil {
|
||||
requestInfo.AddQueryParameters(*(requestConfiguration.QueryParameters))
|
||||
}
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
}
|
||||
// CreatePatchRequestInformation update the navigation property sensitivityLabels in sites
|
||||
func (m *ItemInformationProtectionSensitivityLabelsSensitivityLabelItemRequestBuilder) CreatePatchRequestInformation(ctx context.Context, body ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.SensitivityLabelable, requestConfiguration *ItemInformationProtectionSensitivityLabelsSensitivityLabelItemRequestBuilderPatchRequestConfiguration)(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.PATCH
|
||||
requestInfo.Headers.Add("Accept", "application/json")
|
||||
requestInfo.SetContentFromParsable(ctx, m.requestAdapter, "application/json", body)
|
||||
if requestConfiguration != nil {
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
}
|
||||
// Delete delete navigation property sensitivityLabels for sites
|
||||
func (m *ItemInformationProtectionSensitivityLabelsSensitivityLabelItemRequestBuilder) Delete(ctx context.Context, requestConfiguration *ItemInformationProtectionSensitivityLabelsSensitivityLabelItemRequestBuilderDeleteRequestConfiguration)(error) {
|
||||
requestInfo, err := m.CreateDeleteRequestInformation(ctx, requestConfiguration);
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings {
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
err = m.requestAdapter.SendNoContentAsync(ctx, requestInfo, errorMapping)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
return nil
|
||||
}
|
||||
// Get get sensitivityLabels from sites
|
||||
func (m *ItemInformationProtectionSensitivityLabelsSensitivityLabelItemRequestBuilder) Get(ctx context.Context, requestConfiguration *ItemInformationProtectionSensitivityLabelsSensitivityLabelItemRequestBuilderGetRequestConfiguration)(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.SensitivityLabelable, error) {
|
||||
requestInfo, err := m.CreateGetRequestInformation(ctx, requestConfiguration);
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings {
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.SendAsync(ctx, requestInfo, ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CreateSensitivityLabelFromDiscriminatorValue, errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.SensitivityLabelable), nil
|
||||
}
|
||||
// Patch update the navigation property sensitivityLabels in sites
|
||||
func (m *ItemInformationProtectionSensitivityLabelsSensitivityLabelItemRequestBuilder) Patch(ctx context.Context, body ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.SensitivityLabelable, requestConfiguration *ItemInformationProtectionSensitivityLabelsSensitivityLabelItemRequestBuilderPatchRequestConfiguration)(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.SensitivityLabelable, error) {
|
||||
requestInfo, err := m.CreatePatchRequestInformation(ctx, body, requestConfiguration);
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings {
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.SendAsync(ctx, requestInfo, ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CreateSensitivityLabelFromDiscriminatorValue, errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.SensitivityLabelable), nil
|
||||
}
|
||||
// Sublabels provides operations to manage the sublabels property of the microsoft.graph.sensitivityLabel entity.
|
||||
func (m *ItemInformationProtectionSensitivityLabelsSensitivityLabelItemRequestBuilder) Sublabels()(*ItemInformationProtectionSensitivityLabelsItemSublabelsRequestBuilder) {
|
||||
return NewItemInformationProtectionSensitivityLabelsItemSublabelsRequestBuilderInternal(m.pathParameters, m.requestAdapter);
|
||||
}
|
||||
// SublabelsById provides operations to manage the sublabels property of the microsoft.graph.sensitivityLabel entity.
|
||||
func (m *ItemInformationProtectionSensitivityLabelsSensitivityLabelItemRequestBuilder) SublabelsById(id string)(*ItemInformationProtectionSensitivityLabelsItemSublabelsSensitivityLabelItemRequestBuilder) {
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range m.pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
if id != "" {
|
||||
urlTplParams["sensitivityLabel%2Did1"] = id
|
||||
}
|
||||
return NewItemInformationProtectionSensitivityLabelsItemSublabelsSensitivityLabelItemRequestBuilderInternal(urlTplParams, m.requestAdapter);
|
||||
}
|
||||
@ -1,163 +0,0 @@
|
||||
package sites
|
||||
|
||||
import (
|
||||
"context"
|
||||
i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f "github.com/microsoft/kiota-abstractions-go"
|
||||
ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models"
|
||||
i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models/odataerrors"
|
||||
)
|
||||
|
||||
// ItemInformationProtectionSensitivityPolicySettingsRequestBuilder provides operations to manage the sensitivityPolicySettings property of the microsoft.graph.informationProtection entity.
|
||||
type ItemInformationProtectionSensitivityPolicySettingsRequestBuilder struct {
|
||||
// Path parameters for the request
|
||||
pathParameters map[string]string
|
||||
// The request adapter to use to execute the requests.
|
||||
requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter
|
||||
// Url template to use to build the URL for the current request builder
|
||||
urlTemplate string
|
||||
}
|
||||
// ItemInformationProtectionSensitivityPolicySettingsRequestBuilderDeleteRequestConfiguration configuration for the request such as headers, query parameters, and middleware options.
|
||||
type ItemInformationProtectionSensitivityPolicySettingsRequestBuilderDeleteRequestConfiguration struct {
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
}
|
||||
// ItemInformationProtectionSensitivityPolicySettingsRequestBuilderGetQueryParameters get sensitivityPolicySettings from sites
|
||||
type ItemInformationProtectionSensitivityPolicySettingsRequestBuilderGetQueryParameters struct {
|
||||
// Expand related entities
|
||||
Expand []string `uriparametername:"%24expand"`
|
||||
// Select properties to be returned
|
||||
Select []string `uriparametername:"%24select"`
|
||||
}
|
||||
// ItemInformationProtectionSensitivityPolicySettingsRequestBuilderGetRequestConfiguration configuration for the request such as headers, query parameters, and middleware options.
|
||||
type ItemInformationProtectionSensitivityPolicySettingsRequestBuilderGetRequestConfiguration struct {
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
// Request query parameters
|
||||
QueryParameters *ItemInformationProtectionSensitivityPolicySettingsRequestBuilderGetQueryParameters
|
||||
}
|
||||
// ItemInformationProtectionSensitivityPolicySettingsRequestBuilderPatchRequestConfiguration configuration for the request such as headers, query parameters, and middleware options.
|
||||
type ItemInformationProtectionSensitivityPolicySettingsRequestBuilderPatchRequestConfiguration struct {
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
}
|
||||
// NewItemInformationProtectionSensitivityPolicySettingsRequestBuilderInternal instantiates a new SensitivityPolicySettingsRequestBuilder and sets the default values.
|
||||
func NewItemInformationProtectionSensitivityPolicySettingsRequestBuilderInternal(pathParameters map[string]string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemInformationProtectionSensitivityPolicySettingsRequestBuilder) {
|
||||
m := &ItemInformationProtectionSensitivityPolicySettingsRequestBuilder{
|
||||
}
|
||||
m.urlTemplate = "{+baseurl}/sites/{site%2Did}/informationProtection/sensitivityPolicySettings{?%24select,%24expand}";
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
m.pathParameters = urlTplParams;
|
||||
m.requestAdapter = requestAdapter;
|
||||
return m
|
||||
}
|
||||
// NewItemInformationProtectionSensitivityPolicySettingsRequestBuilder instantiates a new SensitivityPolicySettingsRequestBuilder and sets the default values.
|
||||
func NewItemInformationProtectionSensitivityPolicySettingsRequestBuilder(rawUrl string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemInformationProtectionSensitivityPolicySettingsRequestBuilder) {
|
||||
urlParams := make(map[string]string)
|
||||
urlParams["request-raw-url"] = rawUrl
|
||||
return NewItemInformationProtectionSensitivityPolicySettingsRequestBuilderInternal(urlParams, requestAdapter)
|
||||
}
|
||||
// CreateDeleteRequestInformation delete navigation property sensitivityPolicySettings for sites
|
||||
func (m *ItemInformationProtectionSensitivityPolicySettingsRequestBuilder) CreateDeleteRequestInformation(ctx context.Context, requestConfiguration *ItemInformationProtectionSensitivityPolicySettingsRequestBuilderDeleteRequestConfiguration)(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.DELETE
|
||||
if requestConfiguration != nil {
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
}
|
||||
// CreateGetRequestInformation get sensitivityPolicySettings from sites
|
||||
func (m *ItemInformationProtectionSensitivityPolicySettingsRequestBuilder) CreateGetRequestInformation(ctx context.Context, requestConfiguration *ItemInformationProtectionSensitivityPolicySettingsRequestBuilderGetRequestConfiguration)(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.GET
|
||||
requestInfo.Headers.Add("Accept", "application/json")
|
||||
if requestConfiguration != nil {
|
||||
if requestConfiguration.QueryParameters != nil {
|
||||
requestInfo.AddQueryParameters(*(requestConfiguration.QueryParameters))
|
||||
}
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
}
|
||||
// CreatePatchRequestInformation update the navigation property sensitivityPolicySettings in sites
|
||||
func (m *ItemInformationProtectionSensitivityPolicySettingsRequestBuilder) CreatePatchRequestInformation(ctx context.Context, body ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.SensitivityPolicySettingsable, requestConfiguration *ItemInformationProtectionSensitivityPolicySettingsRequestBuilderPatchRequestConfiguration)(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.PATCH
|
||||
requestInfo.Headers.Add("Accept", "application/json")
|
||||
requestInfo.SetContentFromParsable(ctx, m.requestAdapter, "application/json", body)
|
||||
if requestConfiguration != nil {
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
}
|
||||
// Delete delete navigation property sensitivityPolicySettings for sites
|
||||
func (m *ItemInformationProtectionSensitivityPolicySettingsRequestBuilder) Delete(ctx context.Context, requestConfiguration *ItemInformationProtectionSensitivityPolicySettingsRequestBuilderDeleteRequestConfiguration)(error) {
|
||||
requestInfo, err := m.CreateDeleteRequestInformation(ctx, requestConfiguration);
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings {
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
err = m.requestAdapter.SendNoContentAsync(ctx, requestInfo, errorMapping)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
return nil
|
||||
}
|
||||
// Get get sensitivityPolicySettings from sites
|
||||
func (m *ItemInformationProtectionSensitivityPolicySettingsRequestBuilder) Get(ctx context.Context, requestConfiguration *ItemInformationProtectionSensitivityPolicySettingsRequestBuilderGetRequestConfiguration)(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.SensitivityPolicySettingsable, error) {
|
||||
requestInfo, err := m.CreateGetRequestInformation(ctx, requestConfiguration);
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings {
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.SendAsync(ctx, requestInfo, ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CreateSensitivityPolicySettingsFromDiscriminatorValue, errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.SensitivityPolicySettingsable), nil
|
||||
}
|
||||
// Patch update the navigation property sensitivityPolicySettings in sites
|
||||
func (m *ItemInformationProtectionSensitivityPolicySettingsRequestBuilder) Patch(ctx context.Context, body ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.SensitivityPolicySettingsable, requestConfiguration *ItemInformationProtectionSensitivityPolicySettingsRequestBuilderPatchRequestConfiguration)(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.SensitivityPolicySettingsable, error) {
|
||||
requestInfo, err := m.CreatePatchRequestInformation(ctx, body, requestConfiguration);
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings {
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.SendAsync(ctx, requestInfo, ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CreateSensitivityPolicySettingsFromDiscriminatorValue, errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.SensitivityPolicySettingsable), nil
|
||||
}
|
||||
@ -1,71 +0,0 @@
|
||||
package sites
|
||||
|
||||
import (
|
||||
i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91 "github.com/microsoft/kiota-abstractions-go/serialization"
|
||||
)
|
||||
|
||||
// ItemInformationProtectionSignDigestPostRequestBody provides operations to call the signDigest method.
|
||||
type ItemInformationProtectionSignDigestPostRequestBody struct {
|
||||
// Stores additional data not described in the OpenAPI description found when deserializing. Can be used for serialization as well.
|
||||
additionalData map[string]interface{}
|
||||
// The digest property
|
||||
digest []byte
|
||||
}
|
||||
// NewItemInformationProtectionSignDigestPostRequestBody instantiates a new ItemInformationProtectionSignDigestPostRequestBody and sets the default values.
|
||||
func NewItemInformationProtectionSignDigestPostRequestBody()(*ItemInformationProtectionSignDigestPostRequestBody) {
|
||||
m := &ItemInformationProtectionSignDigestPostRequestBody{
|
||||
}
|
||||
m.SetAdditionalData(make(map[string]interface{}));
|
||||
return m
|
||||
}
|
||||
// CreateItemInformationProtectionSignDigestPostRequestBodyFromDiscriminatorValue creates a new instance of the appropriate class based on discriminator value
|
||||
func CreateItemInformationProtectionSignDigestPostRequestBodyFromDiscriminatorValue(parseNode i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.ParseNode)(i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.Parsable, error) {
|
||||
return NewItemInformationProtectionSignDigestPostRequestBody(), nil
|
||||
}
|
||||
// GetAdditionalData gets the additionalData property value. Stores additional data not described in the OpenAPI description found when deserializing. Can be used for serialization as well.
|
||||
func (m *ItemInformationProtectionSignDigestPostRequestBody) GetAdditionalData()(map[string]interface{}) {
|
||||
return m.additionalData
|
||||
}
|
||||
// GetDigest gets the digest property value. The digest property
|
||||
func (m *ItemInformationProtectionSignDigestPostRequestBody) GetDigest()([]byte) {
|
||||
return m.digest
|
||||
}
|
||||
// GetFieldDeserializers the deserialization information for the current model
|
||||
func (m *ItemInformationProtectionSignDigestPostRequestBody) GetFieldDeserializers()(map[string]func(i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.ParseNode)(error)) {
|
||||
res := make(map[string]func(i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.ParseNode)(error))
|
||||
res["digest"] = func (n i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.ParseNode) error {
|
||||
val, err := n.GetByteArrayValue()
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
if val != nil {
|
||||
m.SetDigest(val)
|
||||
}
|
||||
return nil
|
||||
}
|
||||
return res
|
||||
}
|
||||
// Serialize serializes information the current object
|
||||
func (m *ItemInformationProtectionSignDigestPostRequestBody) Serialize(writer i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.SerializationWriter)(error) {
|
||||
{
|
||||
err := writer.WriteByteArrayValue("digest", m.GetDigest())
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
}
|
||||
{
|
||||
err := writer.WriteAdditionalData(m.GetAdditionalData())
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
}
|
||||
return nil
|
||||
}
|
||||
// SetAdditionalData sets the additionalData property value. Stores additional data not described in the OpenAPI description found when deserializing. Can be used for serialization as well.
|
||||
func (m *ItemInformationProtectionSignDigestPostRequestBody) SetAdditionalData(value map[string]interface{})() {
|
||||
m.additionalData = value
|
||||
}
|
||||
// SetDigest sets the digest property value. The digest property
|
||||
func (m *ItemInformationProtectionSignDigestPostRequestBody) SetDigest(value []byte)() {
|
||||
m.digest = value
|
||||
}
|
||||
@ -1,13 +0,0 @@
|
||||
package sites
|
||||
|
||||
import (
|
||||
i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91 "github.com/microsoft/kiota-abstractions-go/serialization"
|
||||
)
|
||||
|
||||
// ItemInformationProtectionSignDigestPostRequestBodyable
|
||||
type ItemInformationProtectionSignDigestPostRequestBodyable interface {
|
||||
i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.AdditionalDataHolder
|
||||
i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.Parsable
|
||||
GetDigest()([]byte)
|
||||
SetDigest(value []byte)()
|
||||
}
|
||||
@ -1,77 +0,0 @@
|
||||
package sites
|
||||
|
||||
import (
|
||||
"context"
|
||||
i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f "github.com/microsoft/kiota-abstractions-go"
|
||||
ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models"
|
||||
i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models/odataerrors"
|
||||
)
|
||||
|
||||
// ItemInformationProtectionSignDigestRequestBuilder provides operations to call the signDigest method.
|
||||
type ItemInformationProtectionSignDigestRequestBuilder struct {
|
||||
// Path parameters for the request
|
||||
pathParameters map[string]string
|
||||
// The request adapter to use to execute the requests.
|
||||
requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter
|
||||
// Url template to use to build the URL for the current request builder
|
||||
urlTemplate string
|
||||
}
|
||||
// ItemInformationProtectionSignDigestRequestBuilderPostRequestConfiguration configuration for the request such as headers, query parameters, and middleware options.
|
||||
type ItemInformationProtectionSignDigestRequestBuilderPostRequestConfiguration struct {
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
}
|
||||
// NewItemInformationProtectionSignDigestRequestBuilderInternal instantiates a new SignDigestRequestBuilder and sets the default values.
|
||||
func NewItemInformationProtectionSignDigestRequestBuilderInternal(pathParameters map[string]string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemInformationProtectionSignDigestRequestBuilder) {
|
||||
m := &ItemInformationProtectionSignDigestRequestBuilder{
|
||||
}
|
||||
m.urlTemplate = "{+baseurl}/sites/{site%2Did}/informationProtection/microsoft.graph.signDigest";
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
m.pathParameters = urlTplParams;
|
||||
m.requestAdapter = requestAdapter;
|
||||
return m
|
||||
}
|
||||
// NewItemInformationProtectionSignDigestRequestBuilder instantiates a new SignDigestRequestBuilder and sets the default values.
|
||||
func NewItemInformationProtectionSignDigestRequestBuilder(rawUrl string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemInformationProtectionSignDigestRequestBuilder) {
|
||||
urlParams := make(map[string]string)
|
||||
urlParams["request-raw-url"] = rawUrl
|
||||
return NewItemInformationProtectionSignDigestRequestBuilderInternal(urlParams, requestAdapter)
|
||||
}
|
||||
// CreatePostRequestInformation invoke action signDigest
|
||||
func (m *ItemInformationProtectionSignDigestRequestBuilder) CreatePostRequestInformation(ctx context.Context, body ItemInformationProtectionSignDigestPostRequestBodyable, requestConfiguration *ItemInformationProtectionSignDigestRequestBuilderPostRequestConfiguration)(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.POST
|
||||
requestInfo.Headers.Add("Accept", "application/json")
|
||||
requestInfo.SetContentFromParsable(ctx, m.requestAdapter, "application/json", body)
|
||||
if requestConfiguration != nil {
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
}
|
||||
// Post invoke action signDigest
|
||||
func (m *ItemInformationProtectionSignDigestRequestBuilder) Post(ctx context.Context, body ItemInformationProtectionSignDigestPostRequestBodyable, requestConfiguration *ItemInformationProtectionSignDigestRequestBuilderPostRequestConfiguration)(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.SigningResultable, error) {
|
||||
requestInfo, err := m.CreatePostRequestInformation(ctx, body, requestConfiguration);
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings {
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.SendAsync(ctx, requestInfo, ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.CreateSigningResultFromDiscriminatorValue, errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(ifda19816f54f079134d70c11e75d6b26799300cf72079e282f1d3bb9a6750354.SigningResultable), nil
|
||||
}
|
||||
@ -1,87 +0,0 @@
|
||||
package sites
|
||||
|
||||
import (
|
||||
"context"
|
||||
i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f "github.com/microsoft/kiota-abstractions-go"
|
||||
i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models/odataerrors"
|
||||
)
|
||||
|
||||
// ItemInformationProtectionThreatAssessmentRequestsCountRequestBuilder provides operations to count the resources in the collection.
|
||||
type ItemInformationProtectionThreatAssessmentRequestsCountRequestBuilder struct {
|
||||
// Path parameters for the request
|
||||
pathParameters map[string]string
|
||||
// The request adapter to use to execute the requests.
|
||||
requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter
|
||||
// Url template to use to build the URL for the current request builder
|
||||
urlTemplate string
|
||||
}
|
||||
// ItemInformationProtectionThreatAssessmentRequestsCountRequestBuilderGetQueryParameters get the number of the resource
|
||||
type ItemInformationProtectionThreatAssessmentRequestsCountRequestBuilderGetQueryParameters struct {
|
||||
// Filter items by property values
|
||||
Filter *string `uriparametername:"%24filter"`
|
||||
// Search items by search phrases
|
||||
Search *string `uriparametername:"%24search"`
|
||||
}
|
||||
// ItemInformationProtectionThreatAssessmentRequestsCountRequestBuilderGetRequestConfiguration configuration for the request such as headers, query parameters, and middleware options.
|
||||
type ItemInformationProtectionThreatAssessmentRequestsCountRequestBuilderGetRequestConfiguration struct {
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
// Request query parameters
|
||||
QueryParameters *ItemInformationProtectionThreatAssessmentRequestsCountRequestBuilderGetQueryParameters
|
||||
}
|
||||
// NewItemInformationProtectionThreatAssessmentRequestsCountRequestBuilderInternal instantiates a new CountRequestBuilder and sets the default values.
|
||||
func NewItemInformationProtectionThreatAssessmentRequestsCountRequestBuilderInternal(pathParameters map[string]string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemInformationProtectionThreatAssessmentRequestsCountRequestBuilder) {
|
||||
m := &ItemInformationProtectionThreatAssessmentRequestsCountRequestBuilder{
|
||||
}
|
||||
m.urlTemplate = "{+baseurl}/sites/{site%2Did}/informationProtection/threatAssessmentRequests/$count{?%24search,%24filter}";
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
m.pathParameters = urlTplParams;
|
||||
m.requestAdapter = requestAdapter;
|
||||
return m
|
||||
}
|
||||
// NewItemInformationProtectionThreatAssessmentRequestsCountRequestBuilder instantiates a new CountRequestBuilder and sets the default values.
|
||||
func NewItemInformationProtectionThreatAssessmentRequestsCountRequestBuilder(rawUrl string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemInformationProtectionThreatAssessmentRequestsCountRequestBuilder) {
|
||||
urlParams := make(map[string]string)
|
||||
urlParams["request-raw-url"] = rawUrl
|
||||
return NewItemInformationProtectionThreatAssessmentRequestsCountRequestBuilderInternal(urlParams, requestAdapter)
|
||||
}
|
||||
// CreateGetRequestInformation get the number of the resource
|
||||
func (m *ItemInformationProtectionThreatAssessmentRequestsCountRequestBuilder) CreateGetRequestInformation(ctx context.Context, requestConfiguration *ItemInformationProtectionThreatAssessmentRequestsCountRequestBuilderGetRequestConfiguration)(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.GET
|
||||
requestInfo.Headers.Add("Accept", "text/plain")
|
||||
if requestConfiguration != nil {
|
||||
if requestConfiguration.QueryParameters != nil {
|
||||
requestInfo.AddQueryParameters(*(requestConfiguration.QueryParameters))
|
||||
}
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
}
|
||||
// Get get the number of the resource
|
||||
func (m *ItemInformationProtectionThreatAssessmentRequestsCountRequestBuilder) Get(ctx context.Context, requestConfiguration *ItemInformationProtectionThreatAssessmentRequestsCountRequestBuilderGetRequestConfiguration)(*int32, error) {
|
||||
requestInfo, err := m.CreateGetRequestInformation(ctx, requestConfiguration);
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings {
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.SendPrimitiveAsync(ctx, requestInfo, "int32", errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(*int32), nil
|
||||
}
|
||||
@ -1,87 +0,0 @@
|
||||
package sites
|
||||
|
||||
import (
|
||||
"context"
|
||||
i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f "github.com/microsoft/kiota-abstractions-go"
|
||||
i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0 "github.com/alcionai/corso/src/internal/connector/graph/betasdk/models/odataerrors"
|
||||
)
|
||||
|
||||
// ItemInformationProtectionThreatAssessmentRequestsItemResultsCountRequestBuilder provides operations to count the resources in the collection.
|
||||
type ItemInformationProtectionThreatAssessmentRequestsItemResultsCountRequestBuilder struct {
|
||||
// Path parameters for the request
|
||||
pathParameters map[string]string
|
||||
// The request adapter to use to execute the requests.
|
||||
requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter
|
||||
// Url template to use to build the URL for the current request builder
|
||||
urlTemplate string
|
||||
}
|
||||
// ItemInformationProtectionThreatAssessmentRequestsItemResultsCountRequestBuilderGetQueryParameters get the number of the resource
|
||||
type ItemInformationProtectionThreatAssessmentRequestsItemResultsCountRequestBuilderGetQueryParameters struct {
|
||||
// Filter items by property values
|
||||
Filter *string `uriparametername:"%24filter"`
|
||||
// Search items by search phrases
|
||||
Search *string `uriparametername:"%24search"`
|
||||
}
|
||||
// ItemInformationProtectionThreatAssessmentRequestsItemResultsCountRequestBuilderGetRequestConfiguration configuration for the request such as headers, query parameters, and middleware options.
|
||||
type ItemInformationProtectionThreatAssessmentRequestsItemResultsCountRequestBuilderGetRequestConfiguration struct {
|
||||
// Request headers
|
||||
Headers *i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestHeaders
|
||||
// Request options
|
||||
Options []i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestOption
|
||||
// Request query parameters
|
||||
QueryParameters *ItemInformationProtectionThreatAssessmentRequestsItemResultsCountRequestBuilderGetQueryParameters
|
||||
}
|
||||
// NewItemInformationProtectionThreatAssessmentRequestsItemResultsCountRequestBuilderInternal instantiates a new CountRequestBuilder and sets the default values.
|
||||
func NewItemInformationProtectionThreatAssessmentRequestsItemResultsCountRequestBuilderInternal(pathParameters map[string]string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemInformationProtectionThreatAssessmentRequestsItemResultsCountRequestBuilder) {
|
||||
m := &ItemInformationProtectionThreatAssessmentRequestsItemResultsCountRequestBuilder{
|
||||
}
|
||||
m.urlTemplate = "{+baseurl}/sites/{site%2Did}/informationProtection/threatAssessmentRequests/{threatAssessmentRequest%2Did}/results/$count{?%24search,%24filter}";
|
||||
urlTplParams := make(map[string]string)
|
||||
for idx, item := range pathParameters {
|
||||
urlTplParams[idx] = item
|
||||
}
|
||||
m.pathParameters = urlTplParams;
|
||||
m.requestAdapter = requestAdapter;
|
||||
return m
|
||||
}
|
||||
// NewItemInformationProtectionThreatAssessmentRequestsItemResultsCountRequestBuilder instantiates a new CountRequestBuilder and sets the default values.
|
||||
func NewItemInformationProtectionThreatAssessmentRequestsItemResultsCountRequestBuilder(rawUrl string, requestAdapter i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestAdapter)(*ItemInformationProtectionThreatAssessmentRequestsItemResultsCountRequestBuilder) {
|
||||
urlParams := make(map[string]string)
|
||||
urlParams["request-raw-url"] = rawUrl
|
||||
return NewItemInformationProtectionThreatAssessmentRequestsItemResultsCountRequestBuilderInternal(urlParams, requestAdapter)
|
||||
}
|
||||
// CreateGetRequestInformation get the number of the resource
|
||||
func (m *ItemInformationProtectionThreatAssessmentRequestsItemResultsCountRequestBuilder) CreateGetRequestInformation(ctx context.Context, requestConfiguration *ItemInformationProtectionThreatAssessmentRequestsItemResultsCountRequestBuilderGetRequestConfiguration)(*i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.RequestInformation, error) {
|
||||
requestInfo := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.NewRequestInformation()
|
||||
requestInfo.UrlTemplate = m.urlTemplate
|
||||
requestInfo.PathParameters = m.pathParameters
|
||||
requestInfo.Method = i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.GET
|
||||
requestInfo.Headers.Add("Accept", "text/plain")
|
||||
if requestConfiguration != nil {
|
||||
if requestConfiguration.QueryParameters != nil {
|
||||
requestInfo.AddQueryParameters(*(requestConfiguration.QueryParameters))
|
||||
}
|
||||
requestInfo.Headers.AddAll(requestConfiguration.Headers)
|
||||
requestInfo.AddRequestOptions(requestConfiguration.Options)
|
||||
}
|
||||
return requestInfo, nil
|
||||
}
|
||||
// Get get the number of the resource
|
||||
func (m *ItemInformationProtectionThreatAssessmentRequestsItemResultsCountRequestBuilder) Get(ctx context.Context, requestConfiguration *ItemInformationProtectionThreatAssessmentRequestsItemResultsCountRequestBuilderGetRequestConfiguration)(*int32, error) {
|
||||
requestInfo, err := m.CreateGetRequestInformation(ctx, requestConfiguration);
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
errorMapping := i2ae4187f7daee263371cb1c977df639813ab50ffa529013b7437480d1ec0158f.ErrorMappings {
|
||||
"4XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
"5XX": i7ad325c11fbf3db4d761c429267362d8b24daa1eda0081f914ebc3cdc85181a0.CreateODataErrorFromDiscriminatorValue,
|
||||
}
|
||||
res, err := m.requestAdapter.SendPrimitiveAsync(ctx, requestInfo, "int32", errorMapping)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if res == nil {
|
||||
return nil, nil
|
||||
}
|
||||
return res.(*int32), nil
|
||||
}
|
||||
Some files were not shown because too many files have changed in this diff Show More
Loading…
x
Reference in New Issue
Block a user