Class: VoiceML::PricingOutboundCallPriceWithOrigin
- Inherits:
-
Object
- Object
- VoiceML::PricingOutboundCallPriceWithOrigin
- Defined in:
- lib/voiceml/models/pricing.rb
Instance Attribute Summary collapse
-
#base_price ⇒ Object
readonly
Returns the value of attribute base_price.
-
#current_price ⇒ Object
readonly
Returns the value of attribute current_price.
-
#origination_prefixes ⇒ Object
readonly
Returns the value of attribute origination_prefixes.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(attrs = {}) ⇒ PricingOutboundCallPriceWithOrigin
constructor
A new instance of PricingOutboundCallPriceWithOrigin.
Constructor Details
#initialize(attrs = {}) ⇒ PricingOutboundCallPriceWithOrigin
Returns a new instance of PricingOutboundCallPriceWithOrigin.
36 37 38 39 40 |
# File 'lib/voiceml/models/pricing.rb', line 36 def initialize(attrs = {}) @origination_prefixes = attrs['origination_prefixes'] || attrs[:origination_prefixes] || [] @base_price = attrs['base_price'] || attrs[:base_price] @current_price = attrs['current_price'] || attrs[:current_price] end |
Instance Attribute Details
#base_price ⇒ Object (readonly)
Returns the value of attribute base_price.
35 36 37 |
# File 'lib/voiceml/models/pricing.rb', line 35 def base_price @base_price end |
#current_price ⇒ Object (readonly)
Returns the value of attribute current_price.
35 36 37 |
# File 'lib/voiceml/models/pricing.rb', line 35 def current_price @current_price end |
#origination_prefixes ⇒ Object (readonly)
Returns the value of attribute origination_prefixes.
35 36 37 |
# File 'lib/voiceml/models/pricing.rb', line 35 def origination_prefixes @origination_prefixes end |
Class Method Details
.from_hash(h) ⇒ Object
41 |
# File 'lib/voiceml/models/pricing.rb', line 41 def self.from_hash(h); h.nil? ? nil : new(h); end |