class Io::Flow::V0::Models::FlowBehavior

Attributes

value[R]

Public Class Methods

ALL() click to toggle source
# File lib/flow_commerce/flow_api_v0_client.rb, line 20568
def FlowBehavior.ALL
  @@all ||= [FlowBehavior.view_consumer_data]
end
apply(value) click to toggle source

Returns the instance of FlowBehavior for this value, creating a new instance for an unknown value

# File lib/flow_commerce/flow_api_v0_client.rb, line 20553
def FlowBehavior.apply(value)
  if value.instance_of?(FlowBehavior)
    value
  else
    HttpClient::Preconditions.assert_class_or_nil('value', value, String)
    value.nil? ? nil : (from_string(value) || FlowBehavior.new(value))
  end
end
from_string(value) click to toggle source

Returns the instance of FlowBehavior for this value, or nil if not found

# File lib/flow_commerce/flow_api_v0_client.rb, line 20563
def FlowBehavior.from_string(value)
  HttpClient::Preconditions.assert_class('value', value, String)
  FlowBehavior.ALL.find { |v| v.value == value }
end
new(value) click to toggle source
# File lib/flow_commerce/flow_api_v0_client.rb, line 20548
def initialize(value)
  @value = HttpClient::Preconditions.assert_class('value', value, String)
end
view_consumer_data() click to toggle source

Allows user to view consumers’ personal data.

# File lib/flow_commerce/flow_api_v0_client.rb, line 20573
def FlowBehavior.view_consumer_data
  @@_view_consumer_data ||= FlowBehavior.new('view_consumer_data')
end

Public Instance Methods

to_hash() click to toggle source
# File lib/flow_commerce/flow_api_v0_client.rb, line 20577
def to_hash
  value
end