Class: MicrosoftGraph::Models::Drive
- Includes:
- MicrosoftKiotaAbstractions::Parsable
- Defined in:
- lib/models/drive.rb
Class Method Summary collapse
-
.create_from_discriminator_value(parse_node) ⇒ Object
Creates a new instance of the appropriate class based on discriminator value.
Instance Method Summary collapse
-
#bundles ⇒ Object
Gets the bundles property value.
-
#bundles=(value) ⇒ Object
Sets the bundles property value.
-
#drive_type ⇒ Object
Gets the driveType property value.
-
#drive_type=(value) ⇒ Object
Sets the driveType property value.
-
#following ⇒ Object
Gets the following property value.
-
#following=(value) ⇒ Object
Sets the following property value.
-
#get_field_deserializers ⇒ Object
The deserialization information for the current model.
-
#initialize ⇒ Object
constructor
Instantiates a new drive and sets the default values.
-
#items ⇒ Object
Gets the items property value.
-
#items=(value) ⇒ Object
Sets the items property value.
-
#list ⇒ Object
Gets the list property value.
-
#list=(value) ⇒ Object
Sets the list property value.
-
#owner ⇒ Object
Gets the owner property value.
-
#owner=(value) ⇒ Object
Sets the owner property value.
-
#quota ⇒ Object
Gets the quota property value.
-
#quota=(value) ⇒ Object
Sets the quota property value.
-
#root ⇒ Object
Gets the root property value.
-
#root=(value) ⇒ Object
Sets the root property value.
-
#serialize(writer) ⇒ Object
Serializes information the current object.
-
#share_point_ids ⇒ Object
Gets the sharePointIds property value.
-
#share_point_ids=(value) ⇒ Object
Sets the sharePointIds property value.
-
#special ⇒ Object
Gets the special property value.
-
#special=(value) ⇒ Object
Sets the special property value.
-
#system ⇒ Object
Gets the system property value.
-
#system=(value) ⇒ Object
Sets the system property value.
Methods inherited from BaseItem
#created_by, #created_by=, #created_by_user, #created_by_user=, #created_date_time, #created_date_time=, #description, #description=, #e_tag, #e_tag=, #last_modified_by, #last_modified_by=, #last_modified_by_user, #last_modified_by_user=, #last_modified_date_time, #last_modified_date_time=, #name, #name=, #parent_reference, #parent_reference=, #web_url, #web_url=
Methods inherited from Entity
#additional_data, #additional_data=, #id, #id=, #odata_type, #odata_type=
Constructor Details
#initialize ⇒ Object
Instantiates a new drive and sets the default values.
61 62 63 64 |
# File 'lib/models/drive.rb', line 61 def initialize() super @odata_type = "#microsoft.graph.drive" end |
Class Method Details
.create_from_discriminator_value(parse_node) ⇒ Object
Creates a new instance of the appropriate class based on discriminator value
70 71 72 73 |
# File 'lib/models/drive.rb', line 70 def self.create_from_discriminator_value(parse_node) raise StandardError, 'parse_node cannot be null' if parse_node.nil? return Drive.new end |
Instance Method Details
#bundles ⇒ Object
Gets the bundles property value. Collection of [bundles] (albums and multi-select-shared sets of items). Only in personal OneDrive.
46 47 48 |
# File 'lib/models/drive.rb', line 46 def bundles return @bundles end |
#bundles=(value) ⇒ Object
Sets the bundles property value. Collection of [bundles] (albums and multi-select-shared sets of items). Only in personal OneDrive.
54 55 56 |
# File 'lib/models/drive.rb', line 54 def bundles=(value) @bundles = value end |
#drive_type ⇒ Object
Gets the driveType property value. Describes the type of drive represented by this resource. OneDrive personal drives will return personal. OneDrive for Business will return business. SharePoint document libraries will return documentLibrary. Read-only.
78 79 80 |
# File 'lib/models/drive.rb', line 78 def drive_type return @drive_type end |
#drive_type=(value) ⇒ Object
Sets the driveType property value. Describes the type of drive represented by this resource. OneDrive personal drives will return personal. OneDrive for Business will return business. SharePoint document libraries will return documentLibrary. Read-only.
86 87 88 |
# File 'lib/models/drive.rb', line 86 def drive_type=(value) @drive_type = value end |
#following ⇒ Object
Gets the following property value. The list of items the user is following. Only in OneDrive for Business.
93 94 95 |
# File 'lib/models/drive.rb', line 93 def following return @following end |
#following=(value) ⇒ Object
Sets the following property value. The list of items the user is following. Only in OneDrive for Business.
101 102 103 |
# File 'lib/models/drive.rb', line 101 def following=(value) @following = value end |
#get_field_deserializers ⇒ Object
The deserialization information for the current model
108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 |
# File 'lib/models/drive.rb', line 108 def get_field_deserializers() return super.merge({ "bundles" => lambda {|n| @bundles = n.get_collection_of_object_values(lambda {|pn| MicrosoftGraph::Models::DriveItem.create_from_discriminator_value(pn) }) }, "driveType" => lambda {|n| @drive_type = n.get_string_value() }, "following" => lambda {|n| @following = n.get_collection_of_object_values(lambda {|pn| MicrosoftGraph::Models::DriveItem.create_from_discriminator_value(pn) }) }, "items" => lambda {|n| @items = n.get_collection_of_object_values(lambda {|pn| MicrosoftGraph::Models::DriveItem.create_from_discriminator_value(pn) }) }, "list" => lambda {|n| @list = n.get_object_value(lambda {|pn| MicrosoftGraph::Models::List.create_from_discriminator_value(pn) }) }, "owner" => lambda {|n| @owner = n.get_object_value(lambda {|pn| MicrosoftGraph::Models::IdentitySet.create_from_discriminator_value(pn) }) }, "quota" => lambda {|n| @quota = n.get_object_value(lambda {|pn| MicrosoftGraph::Models::Quota.create_from_discriminator_value(pn) }) }, "root" => lambda {|n| @root = n.get_object_value(lambda {|pn| MicrosoftGraph::Models::DriveItem.create_from_discriminator_value(pn) }) }, "sharePointIds" => lambda {|n| @share_point_ids = n.get_object_value(lambda {|pn| MicrosoftGraph::Models::SharepointIds.create_from_discriminator_value(pn) }) }, "special" => lambda {|n| @special = n.get_collection_of_object_values(lambda {|pn| MicrosoftGraph::Models::DriveItem.create_from_discriminator_value(pn) }) }, "system" => lambda {|n| @system = n.get_object_value(lambda {|pn| MicrosoftGraph::Models::SystemFacet.create_from_discriminator_value(pn) }) }, }) end |
#items ⇒ Object
Gets the items property value. All items contained in the drive. Read-only. Nullable.
127 128 129 |
# File 'lib/models/drive.rb', line 127 def items return @items end |
#items=(value) ⇒ Object
Sets the items property value. All items contained in the drive. Read-only. Nullable.
135 136 137 |
# File 'lib/models/drive.rb', line 135 def items=(value) @items = value end |
#list ⇒ Object
Gets the list property value. For drives in SharePoint, the underlying document library list. Read-only. Nullable.
142 143 144 |
# File 'lib/models/drive.rb', line 142 def list return @list end |
#list=(value) ⇒ Object
Sets the list property value. For drives in SharePoint, the underlying document library list. Read-only. Nullable.
150 151 152 |
# File 'lib/models/drive.rb', line 150 def list=(value) @list = value end |
#owner ⇒ Object
Gets the owner property value. Optional. The user account that owns the drive. Read-only.
157 158 159 |
# File 'lib/models/drive.rb', line 157 def owner return @owner end |
#owner=(value) ⇒ Object
Sets the owner property value. Optional. The user account that owns the drive. Read-only.
165 166 167 |
# File 'lib/models/drive.rb', line 165 def owner=(value) @owner = value end |
#quota ⇒ Object
Gets the quota property value. Optional. Information about the drive’s storage space quota. Read-only.
172 173 174 |
# File 'lib/models/drive.rb', line 172 def quota return @quota end |
#quota=(value) ⇒ Object
Sets the quota property value. Optional. Information about the drive’s storage space quota. Read-only.
180 181 182 |
# File 'lib/models/drive.rb', line 180 def quota=(value) @quota = value end |
#root ⇒ Object
Gets the root property value. The root folder of the drive. Read-only.
187 188 189 |
# File 'lib/models/drive.rb', line 187 def root return @root end |
#root=(value) ⇒ Object
Sets the root property value. The root folder of the drive. Read-only.
195 196 197 |
# File 'lib/models/drive.rb', line 195 def root=(value) @root = value end |
#serialize(writer) ⇒ Object
Serializes information the current object
203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 |
# File 'lib/models/drive.rb', line 203 def serialize(writer) raise StandardError, 'writer cannot be null' if writer.nil? super writer.write_collection_of_object_values("bundles", @bundles) writer.write_string_value("driveType", @drive_type) writer.write_collection_of_object_values("following", @following) writer.write_collection_of_object_values("items", @items) writer.write_object_value("list", @list) writer.write_object_value("owner", @owner) writer.write_object_value("quota", @quota) writer.write_object_value("root", @root) writer.write_object_value("sharePointIds", @share_point_ids) writer.write_collection_of_object_values("special", @special) writer.write_object_value("system", @system) end |
#share_point_ids ⇒ Object
Gets the sharePointIds property value. The sharePointIds property
222 223 224 |
# File 'lib/models/drive.rb', line 222 def share_point_ids return @share_point_ids end |
#share_point_ids=(value) ⇒ Object
Sets the sharePointIds property value. The sharePointIds property
230 231 232 |
# File 'lib/models/drive.rb', line 230 def share_point_ids=(value) @share_point_ids = value end |
#special ⇒ Object
Gets the special property value. Collection of common folders available in OneDrive. Read-only. Nullable.
237 238 239 |
# File 'lib/models/drive.rb', line 237 def special return @special end |
#special=(value) ⇒ Object
Sets the special property value. Collection of common folders available in OneDrive. Read-only. Nullable.
245 246 247 |
# File 'lib/models/drive.rb', line 245 def special=(value) @special = value end |
#system ⇒ Object
Gets the system property value. If present, indicates that this is a system-managed drive. Read-only.
252 253 254 |
# File 'lib/models/drive.rb', line 252 def system return @system end |
#system=(value) ⇒ Object
Sets the system property value. If present, indicates that this is a system-managed drive. Read-only.
260 261 262 |
# File 'lib/models/drive.rb', line 260 def system=(value) @system = value end |