Class: Orb::Models::BetaCreatePlanVersionParams::AddAdjustment
- Inherits:
-
Internal::Type::BaseModel
- Object
- Internal::Type::BaseModel
- Orb::Models::BetaCreatePlanVersionParams::AddAdjustment
- Defined in:
- lib/orb/models/beta_create_plan_version_params.rb
Defined Under Namespace
Modules: Adjustment
Instance Attribute Summary collapse
-
#adjustment ⇒ Orb::Models::NewPercentageDiscount, ...
The definition of a new adjustment to create and add to the plan.
-
#plan_phase_order ⇒ Integer?
The phase to add this adjustment to.
Instance Method Summary collapse
Methods inherited from Internal::Type::BaseModel
==, #==, #[], coerce, #deconstruct_keys, #deep_to_h, dump, fields, hash, #hash, inherited, inspect, #inspect, known_fields, optional, recursively_to_h, required, #to_h, #to_json, #to_s, to_sorbet_type, #to_yaml
Methods included from Internal::Type::Converter
#coerce, coerce, #dump, dump, inspect, #inspect, meta_info, new_coerce_state, type_info
Methods included from Internal::Util::SorbetRuntimeSupport
#const_missing, #define_sorbet_constant!, #sorbet_constant_defined?, #to_sorbet_type, to_sorbet_type
Constructor Details
#initialize(adjustment: , plan_phase_order: nil) ⇒ Object
89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 |
# File 'lib/orb/models/beta_create_plan_version_params.rb', line 89 class AddAdjustment < Orb::Internal::Type::BaseModel # @!attribute adjustment # The definition of a new adjustment to create and add to the plan. # # @return [Orb::Models::NewPercentageDiscount, Orb::Models::NewUsageDiscount, Orb::Models::NewAmountDiscount, Orb::Models::NewMinimum, Orb::Models::NewMaximum] required :adjustment, union: -> { Orb::BetaCreatePlanVersionParams::AddAdjustment::Adjustment } # @!attribute plan_phase_order # The phase to add this adjustment to. # # @return [Integer, nil] optional :plan_phase_order, Integer, nil?: true # @!method initialize(adjustment:, plan_phase_order: nil) # @param adjustment [Orb::Models::NewPercentageDiscount, Orb::Models::NewUsageDiscount, Orb::Models::NewAmountDiscount, Orb::Models::NewMinimum, Orb::Models::NewMaximum] The definition of a new adjustment to create and add to the plan. # # @param plan_phase_order [Integer, nil] The phase to add this adjustment to. # The definition of a new adjustment to create and add to the plan. # # @see Orb::Models::BetaCreatePlanVersionParams::AddAdjustment#adjustment module Adjustment extend Orb::Internal::Type::Union discriminator :adjustment_type variant :percentage_discount, -> { Orb::NewPercentageDiscount } variant :usage_discount, -> { Orb::NewUsageDiscount } variant :amount_discount, -> { Orb::NewAmountDiscount } variant :minimum, -> { Orb::NewMinimum } variant :maximum, -> { Orb::NewMaximum } # @!method self.variants # @return [Array(Orb::Models::NewPercentageDiscount, Orb::Models::NewUsageDiscount, Orb::Models::NewAmountDiscount, Orb::Models::NewMinimum, Orb::Models::NewMaximum)] end end |
Instance Attribute Details
#adjustment ⇒ Orb::Models::NewPercentageDiscount, ...
The definition of a new adjustment to create and add to the plan.
94 |
# File 'lib/orb/models/beta_create_plan_version_params.rb', line 94 required :adjustment, union: -> { Orb::BetaCreatePlanVersionParams::AddAdjustment::Adjustment } |
#plan_phase_order ⇒ Integer?
The phase to add this adjustment to.
100 |
# File 'lib/orb/models/beta_create_plan_version_params.rb', line 100 optional :plan_phase_order, Integer, nil?: true |