Class: MicrosoftGraph::Drives::Item::Items::Item::Workbook::Functions::Price::PricePostRequestBody

Inherits:
Object
  • Object
show all
Includes:
MicrosoftKiotaAbstractions::AdditionalDataHolder, MicrosoftKiotaAbstractions::Parsable
Defined in:
lib/drives/item/items/item/workbook/functions/price/price_post_request_body.rb

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initializeObject

Instantiates a new pricePostRequestBody and sets the default values.



80
81
82
# File 'lib/drives/item/items/item/workbook/functions/price/price_post_request_body.rb', line 80

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 price_post_request_body

Raises:

  • (StandardError)


88
89
90
91
# File 'lib/drives/item/items/item/workbook/functions/price/price_post_request_body.rb', line 88

def self.create_from_discriminator_value(parse_node)
    raise StandardError, 'parse_node cannot be null' if parse_node.nil?
    return PricePostRequestBody.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



50
51
52
# File 'lib/drives/item/items/item/workbook/functions/price/price_post_request_body.rb', line 50

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



58
59
60
# File 'lib/drives/item/items/item/workbook/functions/price/price_post_request_body.rb', line 58

def additional_data=(value)
    @additional_data = value
end

#basisObject

Gets the basis property value. The basis property

Returns:

  • a json



65
66
67
# File 'lib/drives/item/items/item/workbook/functions/price/price_post_request_body.rb', line 65

def basis
    return @basis
end

#basis=(value) ⇒ Object

Sets the basis property value. The basis property

Parameters:

  • value

    Value to set for the basis property.

Returns:

  • a void



73
74
75
# File 'lib/drives/item/items/item/workbook/functions/price/price_post_request_body.rb', line 73

def basis=(value)
    @basis = value
end

#frequencyObject

Gets the frequency property value. The frequency property

Returns:

  • a json



96
97
98
# File 'lib/drives/item/items/item/workbook/functions/price/price_post_request_body.rb', line 96

def frequency
    return @frequency
end

#frequency=(value) ⇒ Object

Sets the frequency property value. The frequency property

Parameters:

  • value

    Value to set for the frequency property.

Returns:

  • a void



104
105
106
# File 'lib/drives/item/items/item/workbook/functions/price/price_post_request_body.rb', line 104

def frequency=(value)
    @frequency = value
end

#get_field_deserializersObject

The deserialization information for the current model

Returns:

  • a i_dictionary



111
112
113
114
115
116
117
118
119
120
121
# File 'lib/drives/item/items/item/workbook/functions/price/price_post_request_body.rb', line 111

def get_field_deserializers()
    return {
        "basis" => lambda {|n| @basis = n.get_object_value(lambda {|pn| MicrosoftGraph::Models::Json.create_from_discriminator_value(pn) }) },
        "frequency" => lambda {|n| @frequency = n.get_object_value(lambda {|pn| MicrosoftGraph::Models::Json.create_from_discriminator_value(pn) }) },
        "maturity" => lambda {|n| @maturity = n.get_object_value(lambda {|pn| MicrosoftGraph::Models::Json.create_from_discriminator_value(pn) }) },
        "rate" => lambda {|n| @rate = n.get_object_value(lambda {|pn| MicrosoftGraph::Models::Json.create_from_discriminator_value(pn) }) },
        "redemption" => lambda {|n| @redemption = n.get_object_value(lambda {|pn| MicrosoftGraph::Models::Json.create_from_discriminator_value(pn) }) },
        "settlement" => lambda {|n| @settlement = n.get_object_value(lambda {|pn| MicrosoftGraph::Models::Json.create_from_discriminator_value(pn) }) },
        "yld" => lambda {|n| @yld = n.get_object_value(lambda {|pn| MicrosoftGraph::Models::Json.create_from_discriminator_value(pn) }) },
    }
end

#maturityObject

Gets the maturity property value. The maturity property

Returns:

  • a json



126
127
128
# File 'lib/drives/item/items/item/workbook/functions/price/price_post_request_body.rb', line 126

def maturity
    return @maturity
end

#maturity=(value) ⇒ Object

Sets the maturity property value. The maturity property

Parameters:

  • value

    Value to set for the maturity property.

Returns:

  • a void



134
135
136
# File 'lib/drives/item/items/item/workbook/functions/price/price_post_request_body.rb', line 134

def maturity=(value)
    @maturity = value
end

#rateObject

Gets the rate property value. The rate property

Returns:

  • a json



141
142
143
# File 'lib/drives/item/items/item/workbook/functions/price/price_post_request_body.rb', line 141

def rate
    return @rate
end

#rate=(value) ⇒ Object

Sets the rate property value. The rate property

Parameters:

  • value

    Value to set for the rate property.

Returns:

  • a void



149
150
151
# File 'lib/drives/item/items/item/workbook/functions/price/price_post_request_body.rb', line 149

def rate=(value)
    @rate = value
end

#redemptionObject

Gets the redemption property value. The redemption property

Returns:

  • a json



156
157
158
# File 'lib/drives/item/items/item/workbook/functions/price/price_post_request_body.rb', line 156

def redemption
    return @redemption
end

#redemption=(value) ⇒ Object

Sets the redemption property value. The redemption property

Parameters:

  • value

    Value to set for the redemption property.

Returns:

  • a void



164
165
166
# File 'lib/drives/item/items/item/workbook/functions/price/price_post_request_body.rb', line 164

def redemption=(value)
    @redemption = 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)


172
173
174
175
176
177
178
179
180
181
182
# File 'lib/drives/item/items/item/workbook/functions/price/price_post_request_body.rb', line 172

def serialize(writer)
    raise StandardError, 'writer cannot be null' if writer.nil?
    writer.write_object_value("basis", @basis)
    writer.write_object_value("frequency", @frequency)
    writer.write_object_value("maturity", @maturity)
    writer.write_object_value("rate", @rate)
    writer.write_object_value("redemption", @redemption)
    writer.write_object_value("settlement", @settlement)
    writer.write_object_value("yld", @yld)
    writer.write_additional_data(@additional_data)
end

#settlementObject

Gets the settlement property value. The settlement property

Returns:

  • a json



187
188
189
# File 'lib/drives/item/items/item/workbook/functions/price/price_post_request_body.rb', line 187

def settlement
    return @settlement
end

#settlement=(value) ⇒ Object

Sets the settlement property value. The settlement property

Parameters:

  • value

    Value to set for the settlement property.

Returns:

  • a void



195
196
197
# File 'lib/drives/item/items/item/workbook/functions/price/price_post_request_body.rb', line 195

def settlement=(value)
    @settlement = value
end

#yldObject

Gets the yld property value. The yld property

Returns:

  • a json



202
203
204
# File 'lib/drives/item/items/item/workbook/functions/price/price_post_request_body.rb', line 202

def yld
    return @yld
end

#yld=(value) ⇒ Object

Sets the yld property value. The yld property

Parameters:

  • value

    Value to set for the yld property.

Returns:

  • a void



210
211
212
# File 'lib/drives/item/items/item/workbook/functions/price/price_post_request_body.rb', line 210

def yld=(value)
    @yld = value
end