Class: Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddAdjustment
- Inherits:
-
Internal::Type::BaseModel
- Object
- Internal::Type::BaseModel
- Orb::Models::Beta::ExternalPlanIDCreatePlanVersionParams::AddAdjustment
- Defined in:
- lib/orb/models/beta/external_plan_id_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
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 129 130 131 132 133 134 135 136 137 138 139 140 141 142 |
# File 'lib/orb/models/beta/external_plan_id_create_plan_version_params.rb', line 102 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::Beta::ExternalPlanIDCreatePlanVersionParams::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::Beta::ExternalPlanIDCreatePlanVersionParams::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.
107 108 |
# File 'lib/orb/models/beta/external_plan_id_create_plan_version_params.rb', line 107 required :adjustment, union: -> { Orb::Beta::ExternalPlanIDCreatePlanVersionParams::AddAdjustment::Adjustment } |
#plan_phase_order ⇒ Integer?
The phase to add this adjustment to.
114 |
# File 'lib/orb/models/beta/external_plan_id_create_plan_version_params.rb', line 114 optional :plan_phase_order, Integer, nil?: true |