Class: Io::Flow::V0::Models::OrganizationStatus
- Inherits:
-
Object
- Object
- Io::Flow::V0::Models::OrganizationStatus
- Defined in:
- lib/flow_commerce/flow_api_v0_client.rb
Instance Attribute Summary collapse
-
#value ⇒ Object
readonly
Returns the value of attribute value.
Class Method Summary collapse
- .active ⇒ Object
- .ALL ⇒ Object
-
.apply(value) ⇒ Object
Returns the instance of OrganizationStatus for this value, creating a new instance for an unknown value.
-
.deactivated ⇒ Object
Manually deactivated.
-
.from_string(value) ⇒ Object
Returns the instance of OrganizationStatus for this value, or nil if not found.
-
.inactive ⇒ Object
Determined by usage: ex: orders placed, experience updated, catalog items updated, etc…
Instance Method Summary collapse
-
#initialize(value) ⇒ OrganizationStatus
constructor
A new instance of OrganizationStatus.
- #to_hash ⇒ Object
Constructor Details
#initialize(value) ⇒ OrganizationStatus
Returns a new instance of OrganizationStatus.
21128 21129 21130 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 21128 def initialize(value) @value = HttpClient::Preconditions.assert_class('value', value, String) end |
Instance Attribute Details
#value ⇒ Object (readonly)
Returns the value of attribute value.
21126 21127 21128 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 21126 def value @value end |
Class Method Details
.active ⇒ Object
21152 21153 21154 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 21152 def OrganizationStatus.active @@_active ||= OrganizationStatus.new('active') end |
.ALL ⇒ Object
21148 21149 21150 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 21148 def OrganizationStatus.ALL @@all ||= [OrganizationStatus.active, OrganizationStatus.inactive, OrganizationStatus.deactivated] end |
.apply(value) ⇒ Object
Returns the instance of OrganizationStatus for this value, creating a new instance for an unknown value
21133 21134 21135 21136 21137 21138 21139 21140 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 21133 def OrganizationStatus.apply(value) if value.instance_of?(OrganizationStatus) value else HttpClient::Preconditions.assert_class_or_nil('value', value, String) value.nil? ? nil : (from_string(value) || OrganizationStatus.new(value)) end end |
.deactivated ⇒ Object
Manually deactivated
21163 21164 21165 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 21163 def OrganizationStatus.deactivated @@_deactivated ||= OrganizationStatus.new('deactivated') end |
.from_string(value) ⇒ Object
Returns the instance of OrganizationStatus for this value, or nil if not found
21143 21144 21145 21146 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 21143 def OrganizationStatus.from_string(value) HttpClient::Preconditions.assert_class('value', value, String) OrganizationStatus.ALL.find { |v| v.value == value } end |
.inactive ⇒ Object
Determined by usage: ex: orders placed, experience updated, catalog items updated, etc…
21158 21159 21160 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 21158 def OrganizationStatus.inactive @@_inactive ||= OrganizationStatus.new('inactive') end |
Instance Method Details
#to_hash ⇒ Object
21167 21168 21169 |
# File 'lib/flow_commerce/flow_api_v0_client.rb', line 21167 def to_hash value end |