Class: MicrosoftGraph::Directory::DeletedItems::DeletedItemsRequestBuilder
- Inherits:
-
MicrosoftKiotaAbstractions::BaseRequestBuilder
- Object
- MicrosoftKiotaAbstractions::BaseRequestBuilder
- MicrosoftGraph::Directory::DeletedItems::DeletedItemsRequestBuilder
- Defined in:
- lib/directory/deleted_items/deleted_items_request_builder.rb
Overview
Provides operations to manage the deletedItems property of the microsoft.graph.directory entity.
Defined Under Namespace
Classes: DeletedItemsRequestBuilderGetQueryParameters
Instance Method Summary collapse
-
#by_directory_object_id(directory_object_id) ⇒ Object
Provides operations to manage the deletedItems property of the microsoft.graph.directory entity.
-
#count ⇒ Object
Provides operations to count the resources in the collection.
-
#delta ⇒ Object
Provides operations to call the delta method.
-
#get(request_configuration = nil) ⇒ Object
Retrieve the properties of a recently deleted application, group, servicePrincipal, administrative unit, or user object from deleted items.
-
#get_available_extension_properties ⇒ Object
Provides operations to call the getAvailableExtensionProperties method.
-
#get_by_ids ⇒ Object
Provides operations to call the getByIds method.
-
#graph_administrative_unit ⇒ Object
Casts the previous resource to administrativeUnit.
-
#graph_application ⇒ Object
Casts the previous resource to application.
-
#graph_device ⇒ Object
Casts the previous resource to device.
-
#graph_group ⇒ Object
Casts the previous resource to group.
-
#graph_service_principal ⇒ Object
Casts the previous resource to servicePrincipal.
-
#graph_user ⇒ Object
Casts the previous resource to user.
-
#initialize(path_parameters, request_adapter) ⇒ Object
constructor
Instantiates a new DeletedItemsRequestBuilder and sets the default values.
-
#post(body, request_configuration = nil) ⇒ Object
Create new navigation property to deletedItems for directory.
-
#to_get_request_information(request_configuration = nil) ⇒ Object
Retrieve the properties of a recently deleted application, group, servicePrincipal, administrative unit, or user object from deleted items.
-
#to_post_request_information(body, request_configuration = nil) ⇒ Object
Create new navigation property to deletedItems for directory.
-
#validate_properties ⇒ Object
Provides operations to call the validateProperties method.
Constructor Details
#initialize(path_parameters, request_adapter) ⇒ Object
Instantiates a new DeletedItemsRequestBuilder and sets the default values.
100 101 102 |
# File 'lib/directory/deleted_items/deleted_items_request_builder.rb', line 100 def initialize(path_parameters, request_adapter) super(path_parameters, request_adapter, "{+baseurl}/directory/deletedItems{?%24top,%24skip,%24search,%24filter,%24count,%24orderby,%24select,%24expand}") end |
Instance Method Details
#by_directory_object_id(directory_object_id) ⇒ Object
Provides operations to manage the deletedItems property of the microsoft.graph.directory entity.
88 89 90 91 92 93 |
# File 'lib/directory/deleted_items/deleted_items_request_builder.rb', line 88 def by_directory_object_id(directory_object_id) raise StandardError, 'directory_object_id cannot be null' if directory_object_id.nil? url_tpl_params = @path_parameters.clone url_tpl_params["directoryObject%2Did"] = directory_object_id return MicrosoftGraph::Directory::DeletedItems::Item::DirectoryObjectItemRequestBuilder.new(url_tpl_params, @request_adapter) end |
#count ⇒ Object
Provides operations to count the resources in the collection.
30 31 32 |
# File 'lib/directory/deleted_items/deleted_items_request_builder.rb', line 30 def count() return MicrosoftGraph::Directory::DeletedItems::Count::CountRequestBuilder.new(@path_parameters, @request_adapter) end |
#delta ⇒ Object
Provides operations to call the delta method.
35 36 37 |
# File 'lib/directory/deleted_items/deleted_items_request_builder.rb', line 35 def delta() return MicrosoftGraph::Directory::DeletedItems::Delta::DeltaRequestBuilder.new(@path_parameters, @request_adapter) end |
#get(request_configuration = nil) ⇒ Object
Retrieve the properties of a recently deleted application, group, servicePrincipal, administrative unit, or user object from deleted items.
108 109 110 111 112 113 114 115 116 |
# File 'lib/directory/deleted_items/deleted_items_request_builder.rb', line 108 def get(request_configuration=nil) request_info = self.to_get_request_information( request_configuration ) error_mapping = Hash.new error_mapping["4XX"] = lambda {|pn| MicrosoftGraph::Models::ODataErrorsODataError.create_from_discriminator_value(pn) } error_mapping["5XX"] = lambda {|pn| MicrosoftGraph::Models::ODataErrorsODataError.create_from_discriminator_value(pn) } return @request_adapter.send_async(request_info, lambda {|pn| MicrosoftGraph::Models::DirectoryObjectCollectionResponse.create_from_discriminator_value(pn) }, error_mapping) end |
#get_available_extension_properties ⇒ Object
Provides operations to call the getAvailableExtensionProperties method.
40 41 42 |
# File 'lib/directory/deleted_items/deleted_items_request_builder.rb', line 40 def get_available_extension_properties() return MicrosoftGraph::Directory::DeletedItems::GetAvailableExtensionProperties::GetAvailableExtensionPropertiesRequestBuilder.new(@path_parameters, @request_adapter) end |
#get_by_ids ⇒ Object
Provides operations to call the getByIds method.
45 46 47 |
# File 'lib/directory/deleted_items/deleted_items_request_builder.rb', line 45 def get_by_ids() return MicrosoftGraph::Directory::DeletedItems::GetByIds::GetByIdsRequestBuilder.new(@path_parameters, @request_adapter) end |
#graph_administrative_unit ⇒ Object
Casts the previous resource to administrativeUnit.
50 51 52 |
# File 'lib/directory/deleted_items/deleted_items_request_builder.rb', line 50 def graph_administrative_unit() return MicrosoftGraph::Directory::DeletedItems::GraphAdministrativeUnit::GraphAdministrativeUnitRequestBuilder.new(@path_parameters, @request_adapter) end |
#graph_application ⇒ Object
Casts the previous resource to application.
55 56 57 |
# File 'lib/directory/deleted_items/deleted_items_request_builder.rb', line 55 def graph_application() return MicrosoftGraph::Directory::DeletedItems::GraphApplication::GraphApplicationRequestBuilder.new(@path_parameters, @request_adapter) end |
#graph_device ⇒ Object
Casts the previous resource to device.
60 61 62 |
# File 'lib/directory/deleted_items/deleted_items_request_builder.rb', line 60 def graph_device() return MicrosoftGraph::Directory::DeletedItems::GraphDevice::GraphDeviceRequestBuilder.new(@path_parameters, @request_adapter) end |
#graph_group ⇒ Object
Casts the previous resource to group.
65 66 67 |
# File 'lib/directory/deleted_items/deleted_items_request_builder.rb', line 65 def graph_group() return MicrosoftGraph::Directory::DeletedItems::GraphGroup::GraphGroupRequestBuilder.new(@path_parameters, @request_adapter) end |
#graph_service_principal ⇒ Object
Casts the previous resource to servicePrincipal.
70 71 72 |
# File 'lib/directory/deleted_items/deleted_items_request_builder.rb', line 70 def graph_service_principal() return MicrosoftGraph::Directory::DeletedItems::GraphServicePrincipal::GraphServicePrincipalRequestBuilder.new(@path_parameters, @request_adapter) end |
#graph_user ⇒ Object
Casts the previous resource to user.
75 76 77 |
# File 'lib/directory/deleted_items/deleted_items_request_builder.rb', line 75 def graph_user() return MicrosoftGraph::Directory::DeletedItems::GraphUser::GraphUserRequestBuilder.new(@path_parameters, @request_adapter) end |
#post(body, request_configuration = nil) ⇒ Object
Create new navigation property to deletedItems for directory
123 124 125 126 127 128 129 130 131 132 |
# File 'lib/directory/deleted_items/deleted_items_request_builder.rb', line 123 def post(body, request_configuration=nil) raise StandardError, 'body cannot be null' if body.nil? request_info = self.to_post_request_information( body, request_configuration ) error_mapping = Hash.new error_mapping["4XX"] = lambda {|pn| MicrosoftGraph::Models::ODataErrorsODataError.create_from_discriminator_value(pn) } error_mapping["5XX"] = lambda {|pn| MicrosoftGraph::Models::ODataErrorsODataError.create_from_discriminator_value(pn) } return @request_adapter.send_async(request_info, lambda {|pn| MicrosoftGraph::Models::DirectoryObject.create_from_discriminator_value(pn) }, error_mapping) end |
#to_get_request_information(request_configuration = nil) ⇒ Object
Retrieve the properties of a recently deleted application, group, servicePrincipal, administrative unit, or user object from deleted items.
138 139 140 141 142 143 144 145 146 147 148 149 150 |
# File 'lib/directory/deleted_items/deleted_items_request_builder.rb', line 138 def to_get_request_information(request_configuration=nil) request_info = MicrosoftKiotaAbstractions::RequestInformation.new() request_info.url_template = @url_template request_info.path_parameters = @path_parameters request_info.http_method = :GET request_info.headers.add('Accept', 'application/json') unless request_configuration.nil? request_info.add_headers_from_raw_object(request_configuration.headers) request_info.set_query_string_parameters_from_raw_object(request_configuration.query_parameters) request_info.(request_configuration.) end return request_info end |
#to_post_request_information(body, request_configuration = nil) ⇒ Object
Create new navigation property to deletedItems for directory
157 158 159 160 161 162 163 164 165 166 167 168 169 170 |
# File 'lib/directory/deleted_items/deleted_items_request_builder.rb', line 157 def to_post_request_information(body, request_configuration=nil) raise StandardError, 'body cannot be null' if body.nil? request_info = MicrosoftKiotaAbstractions::RequestInformation.new() request_info.url_template = @url_template request_info.path_parameters = @path_parameters request_info.http_method = :POST request_info.headers.add('Accept', 'application/json') unless request_configuration.nil? request_info.add_headers_from_raw_object(request_configuration.headers) request_info.(request_configuration.) end request_info.set_content_from_parsable(@request_adapter, "application/json", body) return request_info end |
#validate_properties ⇒ Object
Provides operations to call the validateProperties method.
80 81 82 |
# File 'lib/directory/deleted_items/deleted_items_request_builder.rb', line 80 def validate_properties() return MicrosoftGraph::Directory::DeletedItems::ValidateProperties::ValidatePropertiesRequestBuilder.new(@path_parameters, @request_adapter) end |