Class: DatadogAPIClient::V1::MonitorDeviceID

Inherits:
Object
  • Object
show all
Includes:
BaseEnumModel
Defined in:
lib/datadog_api_client/v1/models/monitor_device_id.rb,
lib/datadog_api_client/v1/models/monitor_device_id.rb

Overview

ID of the device the Synthetics monitor is running on. Same as SyntheticsDeviceID.

Constant Summary collapse

LAPTOP_LARGE =
"laptop_large".freeze
TABLET =
"tablet".freeze
MOBILE_SMALL =
"mobile_small".freeze
CHROME_LAPTOP_LARGE =
"chrome.laptop_large".freeze
CHROME_TABLET =
"chrome.tablet".freeze
CHROME_MOBILE_SMALL =
"chrome.mobile_small".freeze
FIREFOX_LAPTOP_LARGE =
"firefox.laptop_large".freeze
FIREFOX_TABLET =
"firefox.tablet".freeze
FIREFOX_MOBILE_SMALL =
"firefox.mobile_small".freeze

Class Method Summary collapse

Instance Method Summary collapse

Methods included from BaseEnumModel

included

Class Method Details

.build_from_hash(value) ⇒ String

Builds the enum from string

Parameters:

  • The (String)

    enum value in the form of the string

Returns:

  • (String)

    The enum value



34
35
36
# File 'lib/datadog_api_client/v1/models/monitor_device_id.rb', line 34

def self.build_from_hash(value)
  new.build_from_hash(value)
end

Instance Method Details

#build_from_hash(value) ⇒ String

Builds the enum from string

Parameters:

  • The (String)

    enum value in the form of the string

Returns:

  • (String)

    The enum value



41
42
43
44
# File 'lib/datadog_api_client/v1/models/monitor_device_id.rb', line 41

def build_from_hash(value)
  constantValues = MonitorDeviceID.constants.select { |c| MonitorDeviceID::const_get(c) == value }
  constantValues.empty? ? DatadogAPIClient::V1::UnparsedObject.new(value) : value
end