Class: MicrosoftGraph::Models::PrinterShare
- Inherits:
-
PrinterBase
- Object
- Entity
- PrinterBase
- MicrosoftGraph::Models::PrinterShare
- Includes:
- MicrosoftKiotaAbstractions::Parsable
- Defined in:
- lib/models/printer_share.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
-
#allow_all_users ⇒ Object
Gets the allowAllUsers property value.
-
#allow_all_users=(value) ⇒ Object
Sets the allowAllUsers property value.
-
#allowed_groups ⇒ Object
Gets the allowedGroups property value.
-
#allowed_groups=(value) ⇒ Object
Sets the allowedGroups property value.
-
#allowed_users ⇒ Object
Gets the allowedUsers property value.
-
#allowed_users=(value) ⇒ Object
Sets the allowedUsers property value.
-
#created_date_time ⇒ Object
Gets the createdDateTime property value.
-
#created_date_time=(value) ⇒ Object
Sets the createdDateTime property value.
-
#get_field_deserializers ⇒ Object
The deserialization information for the current model.
-
#initialize ⇒ Object
constructor
Instantiates a new printerShare and sets the default values.
-
#printer ⇒ Object
Gets the printer property value.
-
#printer=(value) ⇒ Object
Sets the printer property value.
-
#serialize(writer) ⇒ Object
Serializes information the current object.
-
#view_point ⇒ Object
Gets the viewPoint property value.
-
#view_point=(value) ⇒ Object
Sets the viewPoint property value.
Methods inherited from PrinterBase
#capabilities, #capabilities=, #defaults, #defaults=, #display_name, #display_name=, #is_accepting_jobs, #is_accepting_jobs=, #jobs, #jobs=, #location, #location=, #manufacturer, #manufacturer=, #model, #model=, #status, #status=
Methods inherited from Entity
#additional_data, #additional_data=, #id, #id=, #odata_type, #odata_type=
Constructor Details
#initialize ⇒ Object
Instantiates a new printerShare and sets the default values.
77 78 79 80 |
# File 'lib/models/printer_share.rb', line 77 def initialize() super @odata_type = "#microsoft.graph.printerShare" end |
Class Method Details
.create_from_discriminator_value(parse_node) ⇒ Object
Creates a new instance of the appropriate class based on discriminator value
101 102 103 104 |
# File 'lib/models/printer_share.rb', line 101 def self.create_from_discriminator_value(parse_node) raise StandardError, 'parse_node cannot be null' if parse_node.nil? return PrinterShare.new end |
Instance Method Details
#allow_all_users ⇒ Object
Gets the allowAllUsers property value. If true, all users and groups will be granted access to this printer share. This supersedes the allow lists defined by the allowedUsers and allowedGroups navigation properties.
32 33 34 |
# File 'lib/models/printer_share.rb', line 32 def allow_all_users return @allow_all_users end |
#allow_all_users=(value) ⇒ Object
Sets the allowAllUsers property value. If true, all users and groups will be granted access to this printer share. This supersedes the allow lists defined by the allowedUsers and allowedGroups navigation properties.
40 41 42 |
# File 'lib/models/printer_share.rb', line 40 def allow_all_users=(value) @allow_all_users = value end |
#allowed_groups ⇒ Object
Gets the allowedGroups property value. The groups whose users have access to print using the printer.
47 48 49 |
# File 'lib/models/printer_share.rb', line 47 def allowed_groups return @allowed_groups end |
#allowed_groups=(value) ⇒ Object
Sets the allowedGroups property value. The groups whose users have access to print using the printer.
55 56 57 |
# File 'lib/models/printer_share.rb', line 55 def allowed_groups=(value) @allowed_groups = value end |
#allowed_users ⇒ Object
Gets the allowedUsers property value. The users who have access to print using the printer.
62 63 64 |
# File 'lib/models/printer_share.rb', line 62 def allowed_users return @allowed_users end |
#allowed_users=(value) ⇒ Object
Sets the allowedUsers property value. The users who have access to print using the printer.
70 71 72 |
# File 'lib/models/printer_share.rb', line 70 def allowed_users=(value) @allowed_users = value end |
#created_date_time ⇒ Object
Gets the createdDateTime property value. The DateTimeOffset when the printer share was created. Read-only.
85 86 87 |
# File 'lib/models/printer_share.rb', line 85 def created_date_time return @created_date_time end |
#created_date_time=(value) ⇒ Object
Sets the createdDateTime property value. The DateTimeOffset when the printer share was created. Read-only.
93 94 95 |
# File 'lib/models/printer_share.rb', line 93 def created_date_time=(value) @created_date_time = value end |
#get_field_deserializers ⇒ Object
The deserialization information for the current model
109 110 111 112 113 114 115 116 117 118 |
# File 'lib/models/printer_share.rb', line 109 def get_field_deserializers() return super.merge({ "allowAllUsers" => lambda {|n| @allow_all_users = n.get_boolean_value() }, "allowedGroups" => lambda {|n| @allowed_groups = n.get_collection_of_object_values(lambda {|pn| MicrosoftGraph::Models::Group.create_from_discriminator_value(pn) }) }, "allowedUsers" => lambda {|n| @allowed_users = n.get_collection_of_object_values(lambda {|pn| MicrosoftGraph::Models::User.create_from_discriminator_value(pn) }) }, "createdDateTime" => lambda {|n| @created_date_time = n.get_date_time_value() }, "printer" => lambda {|n| @printer = n.get_object_value(lambda {|pn| MicrosoftGraph::Models::Printer.create_from_discriminator_value(pn) }) }, "viewPoint" => lambda {|n| @view_point = n.get_object_value(lambda {|pn| MicrosoftGraph::Models::PrinterShareViewpoint.create_from_discriminator_value(pn) }) }, }) end |
#printer ⇒ Object
Gets the printer property value. The printer that this printer share is related to.
123 124 125 |
# File 'lib/models/printer_share.rb', line 123 def printer return @printer end |
#printer=(value) ⇒ Object
Sets the printer property value. The printer that this printer share is related to.
131 132 133 |
# File 'lib/models/printer_share.rb', line 131 def printer=(value) @printer = value end |
#serialize(writer) ⇒ Object
Serializes information the current object
139 140 141 142 143 144 145 146 147 148 |
# File 'lib/models/printer_share.rb', line 139 def serialize(writer) raise StandardError, 'writer cannot be null' if writer.nil? super writer.write_boolean_value("allowAllUsers", @allow_all_users) writer.write_collection_of_object_values("allowedGroups", @allowed_groups) writer.write_collection_of_object_values("allowedUsers", @allowed_users) writer.write_date_time_value("createdDateTime", @created_date_time) writer.write_object_value("printer", @printer) writer.write_object_value("viewPoint", @view_point) end |
#view_point ⇒ Object
Gets the viewPoint property value. Additional data for a printer share as viewed by the signed-in user.
153 154 155 |
# File 'lib/models/printer_share.rb', line 153 def view_point return @view_point end |
#view_point=(value) ⇒ Object
Sets the viewPoint property value. Additional data for a printer share as viewed by the signed-in user.
161 162 163 |
# File 'lib/models/printer_share.rb', line 161 def view_point=(value) @view_point = value end |