Class: Stripe::Price::Tier
- Inherits:
-
StripeObject
- Object
- StripeObject
- Stripe::Price::Tier
- Defined in:
- lib/stripe/resources/price.rb
Constant Summary
Constants inherited from StripeObject
StripeObject::RESERVED_FIELD_NAMES
Instance Attribute Summary collapse
-
#flat_amount ⇒ Object
readonly
Price for the entire tier.
-
#flat_amount_decimal ⇒ Object
readonly
Same as ‘flat_amount`, but contains a decimal value with at most 12 decimal places.
-
#unit_amount ⇒ Object
readonly
Per unit price for units relevant to the tier.
-
#unit_amount_decimal ⇒ Object
readonly
Same as ‘unit_amount`, but contains a decimal value with at most 12 decimal places.
-
#up_to ⇒ Object
readonly
Up to and including to this quantity will be contained in the tier.
Attributes inherited from StripeObject
Class Method Summary collapse
Methods inherited from StripeObject
#==, #[], #[]=, #_get_inner_class_type, additive_object_param, additive_object_param?, #as_json, construct_from, #deleted?, #dirty!, #each, #eql?, #hash, #initialize, #inspect, #keys, #marshal_dump, #marshal_load, protected_fields, #serialize_params, #to_hash, #to_json, #to_s, #update_attributes, #values
Constructor Details
This class inherits a constructor from Stripe::StripeObject
Dynamic Method Handling
This class handles dynamic methods through the method_missing method in the class Stripe::StripeObject
Instance Attribute Details
#flat_amount ⇒ Object (readonly)
Price for the entire tier.
157 158 159 |
# File 'lib/stripe/resources/price.rb', line 157 def flat_amount @flat_amount end |
#flat_amount_decimal ⇒ Object (readonly)
Same as ‘flat_amount`, but contains a decimal value with at most 12 decimal places.
159 160 161 |
# File 'lib/stripe/resources/price.rb', line 159 def flat_amount_decimal @flat_amount_decimal end |
#unit_amount ⇒ Object (readonly)
Per unit price for units relevant to the tier.
161 162 163 |
# File 'lib/stripe/resources/price.rb', line 161 def unit_amount @unit_amount end |
#unit_amount_decimal ⇒ Object (readonly)
Same as ‘unit_amount`, but contains a decimal value with at most 12 decimal places.
163 164 165 |
# File 'lib/stripe/resources/price.rb', line 163 def unit_amount_decimal @unit_amount_decimal end |
#up_to ⇒ Object (readonly)
Up to and including to this quantity will be contained in the tier.
165 166 167 |
# File 'lib/stripe/resources/price.rb', line 165 def up_to @up_to end |
Class Method Details
.field_encodings ⇒ Object
175 176 177 178 179 180 |
# File 'lib/stripe/resources/price.rb', line 175 def self.field_encodings @field_encodings = { flat_amount_decimal: :decimal_string, unit_amount_decimal: :decimal_string, } end |
.field_remappings ⇒ Object
171 172 173 |
# File 'lib/stripe/resources/price.rb', line 171 def self.field_remappings @field_remappings = {} end |
.inner_class_types ⇒ Object
167 168 169 |
# File 'lib/stripe/resources/price.rb', line 167 def self.inner_class_types @inner_class_types = {} end |