class Rox::Core::DeviceProperties
Attributes
rox_options[R]
Public Class Methods
new(sdk_settings, rox_options)
click to toggle source
# File lib/rox/core/client/device_properties.rb, line 9 def initialize(sdk_settings, rox_options) @sdk_settings = sdk_settings @rox_options = rox_options end
Public Instance Methods
all_properties()
click to toggle source
# File lib/rox/core/client/device_properties.rb, line 18 def all_properties { PropertyType::PACKAGE_NAME.name => @rox_options.version, PropertyType::VERSION_NAME.name => @rox_options.version, PropertyType::LIB_VERSION.name => lib_version, PropertyType::ROLLOUT_BUILD.name => '50', PropertyType::API_VERSION.name => Build::API_VERSION, PropertyType::APP_VERSION.name => @rox_options.version, PropertyType::APP_RELEASE.name => @rox_options.version, PropertyType::DISTINCT_ID.name => distinct_id, PropertyType::APP_KEY.name => @sdk_settings.api_key, PropertyType::PLATFORM.name => Build::PLATFORM } end
distinct_id()
click to toggle source
# File lib/rox/core/client/device_properties.rb, line 46 def distinct_id 'stam' end
get(property)
click to toggle source
# File lib/rox/core/client/device_properties.rb, line 14 def get(property) all_properties[property.name] end
lib_version()
click to toggle source
# File lib/rox/core/client/device_properties.rb, line 38 def lib_version '1.0.0' end
rollout_environment()
click to toggle source
# File lib/rox/core/client/device_properties.rb, line 33 def rollout_environment env = ENV['ROLLOUT_MODE'] %w[QA LOCAL].include?(env) ? env : 'PRODUCTION' end
rollout_key()
click to toggle source
# File lib/rox/core/client/device_properties.rb, line 42 def rollout_key all_properties[PropertyType::APP_KEY.name] end