Class: MicrosoftGraph::Models::Print

Inherits:
Object
  • Object
show all
Includes:
MicrosoftKiotaAbstractions::AdditionalDataHolder, MicrosoftKiotaAbstractions::Parsable
Defined in:
lib/models/print.rb

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initializeObject

Instantiates a new print and sets the default values.



70
71
72
# File 'lib/models/print.rb', line 70

def initialize()
    @additional_data = Hash.new
end

Class Method Details

.create_from_discriminator_value(parse_node) ⇒ Object

Creates a new instance of the appropriate class based on discriminator value

Parameters:

  • parse_node

    The parse node to use to read the discriminator value and create the object

Returns:

  • a print

Raises:

  • (StandardError)


78
79
80
81
# File 'lib/models/print.rb', line 78

def self.create_from_discriminator_value(parse_node)
    raise StandardError, 'parse_node cannot be null' if parse_node.nil?
    return Print.new
end

Instance Method Details

#additional_dataObject

Gets the additionalData property value. Stores additional data not described in the OpenAPI description found when deserializing. Can be used for serialization as well.

Returns:

  • a i_dictionary



40
41
42
# File 'lib/models/print.rb', line 40

def additional_data
    return @additional_data
end

#additional_data=(value) ⇒ Object

Sets the additionalData property value. Stores additional data not described in the OpenAPI description found when deserializing. Can be used for serialization as well.

Parameters:

  • value

    Value to set for the additionalData property.

Returns:

  • a void



48
49
50
# File 'lib/models/print.rb', line 48

def additional_data=(value)
    @additional_data = value
end

#connectorsObject

Gets the connectors property value. The list of available print connectors.

Returns:

  • a print_connector



55
56
57
# File 'lib/models/print.rb', line 55

def connectors
    return @connectors
end

#connectors=(value) ⇒ Object

Sets the connectors property value. The list of available print connectors.

Parameters:

  • value

    Value to set for the connectors property.

Returns:

  • a void



63
64
65
# File 'lib/models/print.rb', line 63

def connectors=(value)
    @connectors = value
end

#get_field_deserializersObject

The deserialization information for the current model

Returns:

  • a i_dictionary



86
87
88
89
90
91
92
93
94
95
96
97
# File 'lib/models/print.rb', line 86

def get_field_deserializers()
    return {
        "connectors" => lambda {|n| @connectors = n.get_collection_of_object_values(lambda {|pn| MicrosoftGraph::Models::PrintConnector.create_from_discriminator_value(pn) }) },
        "@odata.type" => lambda {|n| @odata_type = n.get_string_value() },
        "operations" => lambda {|n| @operations = n.get_collection_of_object_values(lambda {|pn| MicrosoftGraph::Models::PrintOperation.create_from_discriminator_value(pn) }) },
        "printers" => lambda {|n| @printers = n.get_collection_of_object_values(lambda {|pn| MicrosoftGraph::Models::Printer.create_from_discriminator_value(pn) }) },
        "services" => lambda {|n| @services = n.get_collection_of_object_values(lambda {|pn| MicrosoftGraph::Models::PrintService.create_from_discriminator_value(pn) }) },
        "settings" => lambda {|n| @settings = n.get_object_value(lambda {|pn| MicrosoftGraph::Models::PrintSettings.create_from_discriminator_value(pn) }) },
        "shares" => lambda {|n| @shares = n.get_collection_of_object_values(lambda {|pn| MicrosoftGraph::Models::PrinterShare.create_from_discriminator_value(pn) }) },
        "taskDefinitions" => lambda {|n| @task_definitions = n.get_collection_of_object_values(lambda {|pn| MicrosoftGraph::Models::PrintTaskDefinition.create_from_discriminator_value(pn) }) },
    }
end

#odata_typeObject

Gets the @odata.type property value. The OdataType property

Returns:

  • a string



102
103
104
# File 'lib/models/print.rb', line 102

def odata_type
    return @odata_type
end

#odata_type=(value) ⇒ Object

Sets the @odata.type property value. The OdataType property

Parameters:

  • value

    Value to set for the @odata.type property.

Returns:

  • a void



110
111
112
# File 'lib/models/print.rb', line 110

def odata_type=(value)
    @odata_type = value
end

#operationsObject

Gets the operations property value. The list of print long running operations.

Returns:

  • a print_operation



117
118
119
# File 'lib/models/print.rb', line 117

def operations
    return @operations
end

#operations=(value) ⇒ Object

Sets the operations property value. The list of print long running operations.

Parameters:

  • value

    Value to set for the operations property.

Returns:

  • a void



125
126
127
# File 'lib/models/print.rb', line 125

def operations=(value)
    @operations = value
end

#printersObject

Gets the printers property value. The list of printers registered in the tenant.

Returns:

  • a printer



132
133
134
# File 'lib/models/print.rb', line 132

def printers
    return @printers
end

#printers=(value) ⇒ Object

Sets the printers property value. The list of printers registered in the tenant.

Parameters:

  • value

    Value to set for the printers property.

Returns:

  • a void



140
141
142
# File 'lib/models/print.rb', line 140

def printers=(value)
    @printers = value
end

#serialize(writer) ⇒ Object

Serializes information the current object

Parameters:

  • writer

    Serialization writer to use to serialize this model

Returns:

  • a void

Raises:

  • (StandardError)


148
149
150
151
152
153
154
155
156
157
158
159
# File 'lib/models/print.rb', line 148

def serialize(writer)
    raise StandardError, 'writer cannot be null' if writer.nil?
    writer.write_collection_of_object_values("connectors", @connectors)
    writer.write_string_value("@odata.type", @odata_type)
    writer.write_collection_of_object_values("operations", @operations)
    writer.write_collection_of_object_values("printers", @printers)
    writer.write_collection_of_object_values("services", @services)
    writer.write_object_value("settings", @settings)
    writer.write_collection_of_object_values("shares", @shares)
    writer.write_collection_of_object_values("taskDefinitions", @task_definitions)
    writer.write_additional_data(@additional_data)
end

#servicesObject

Gets the services property value. The list of available Universal Print service endpoints.

Returns:

  • a print_service



164
165
166
# File 'lib/models/print.rb', line 164

def services
    return @services
end

#services=(value) ⇒ Object

Sets the services property value. The list of available Universal Print service endpoints.

Parameters:

  • value

    Value to set for the services property.

Returns:

  • a void



172
173
174
# File 'lib/models/print.rb', line 172

def services=(value)
    @services = value
end

#settingsObject

Gets the settings property value. Tenant-wide settings for the Universal Print service.

Returns:

  • a print_settings



179
180
181
# File 'lib/models/print.rb', line 179

def settings
    return @settings
end

#settings=(value) ⇒ Object

Sets the settings property value. Tenant-wide settings for the Universal Print service.

Parameters:

  • value

    Value to set for the settings property.

Returns:

  • a void



187
188
189
# File 'lib/models/print.rb', line 187

def settings=(value)
    @settings = value
end

#sharesObject

Gets the shares property value. The list of printer shares registered in the tenant.

Returns:

  • a printer_share



194
195
196
# File 'lib/models/print.rb', line 194

def shares
    return @shares
end

#shares=(value) ⇒ Object

Sets the shares property value. The list of printer shares registered in the tenant.

Parameters:

  • value

    Value to set for the shares property.

Returns:

  • a void



202
203
204
# File 'lib/models/print.rb', line 202

def shares=(value)
    @shares = value
end

#task_definitionsObject

Gets the taskDefinitions property value. List of abstract definition for a task that can be triggered when various events occur within Universal Print.

Returns:

  • a print_task_definition



209
210
211
# File 'lib/models/print.rb', line 209

def task_definitions
    return @task_definitions
end

#task_definitions=(value) ⇒ Object

Sets the taskDefinitions property value. List of abstract definition for a task that can be triggered when various events occur within Universal Print.

Parameters:

  • value

    Value to set for the taskDefinitions property.

Returns:

  • a void



217
218
219
# File 'lib/models/print.rb', line 217

def task_definitions=(value)
    @task_definitions = value
end