Class: Cadenya::Types::WidgetSpec
- Inherits:
-
Object
- Object
- Cadenya::Types::WidgetSpec
- Defined in:
- lib/cadenya/types.rb
Instance Attribute Summary collapse
-
#agent_id ⇒ Object
readonly
Returns the value of attribute agent_id.
-
#origin_allowlist ⇒ Object
readonly
Returns the value of attribute origin_allowlist.
-
#variation_id ⇒ Object
readonly
Returns the value of attribute variation_id.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(agent_id: nil, variation_id: nil, origin_allowlist: nil) ⇒ WidgetSpec
constructor
A new instance of WidgetSpec.
- #to_h ⇒ Object
Constructor Details
#initialize(agent_id: nil, variation_id: nil, origin_allowlist: nil) ⇒ WidgetSpec
Returns a new instance of WidgetSpec.
7469 7470 7471 7472 7473 |
# File 'lib/cadenya/types.rb', line 7469 def initialize(agent_id: nil, variation_id: nil, origin_allowlist: nil) @agent_id = agent_id @variation_id = variation_id @origin_allowlist = origin_allowlist end |
Instance Attribute Details
#agent_id ⇒ Object (readonly)
Returns the value of attribute agent_id.
7467 7468 7469 |
# File 'lib/cadenya/types.rb', line 7467 def agent_id @agent_id end |
#origin_allowlist ⇒ Object (readonly)
Returns the value of attribute origin_allowlist.
7467 7468 7469 |
# File 'lib/cadenya/types.rb', line 7467 def origin_allowlist @origin_allowlist end |
#variation_id ⇒ Object (readonly)
Returns the value of attribute variation_id.
7467 7468 7469 |
# File 'lib/cadenya/types.rb', line 7467 def variation_id @variation_id end |
Class Method Details
.from_json(data) ⇒ Object
7475 7476 7477 7478 7479 7480 7481 |
# File 'lib/cadenya/types.rb', line 7475 def self.from_json(data) new( agent_id: data["agentId"], variation_id: data["variationId"], origin_allowlist: data["originAllowlist"], ) end |