Class: Cadenya::Types::ObjectiveConfigSnapshot
- Inherits:
-
Object
- Object
- Cadenya::Types::ObjectiveConfigSnapshot
- Defined in:
- lib/cadenya/types.rb
Instance Attribute Summary collapse
-
#agent ⇒ Object
readonly
Returns the value of attribute agent.
-
#agent_schedule ⇒ Object
readonly
Returns the value of attribute agent_schedule.
-
#agent_variation ⇒ Object
readonly
Returns the value of attribute agent_variation.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(agent: nil, agent_variation: nil, agent_schedule: nil) ⇒ ObjectiveConfigSnapshot
constructor
A new instance of ObjectiveConfigSnapshot.
- #to_h ⇒ Object
Constructor Details
#initialize(agent: nil, agent_variation: nil, agent_schedule: nil) ⇒ ObjectiveConfigSnapshot
Returns a new instance of ObjectiveConfigSnapshot.
3566 3567 3568 3569 3570 |
# File 'lib/cadenya/types.rb', line 3566 def initialize(agent: nil, agent_variation: nil, agent_schedule: nil) @agent = agent @agent_variation = agent_variation @agent_schedule = agent_schedule end |
Instance Attribute Details
#agent ⇒ Object (readonly)
Returns the value of attribute agent.
3564 3565 3566 |
# File 'lib/cadenya/types.rb', line 3564 def agent @agent end |
#agent_schedule ⇒ Object (readonly)
Returns the value of attribute agent_schedule.
3564 3565 3566 |
# File 'lib/cadenya/types.rb', line 3564 def agent_schedule @agent_schedule end |
#agent_variation ⇒ Object (readonly)
Returns the value of attribute agent_variation.
3564 3565 3566 |
# File 'lib/cadenya/types.rb', line 3564 def agent_variation @agent_variation end |
Class Method Details
.from_json(data) ⇒ Object
3572 3573 3574 3575 3576 3577 3578 |
# File 'lib/cadenya/types.rb', line 3572 def self.from_json(data) new( agent: data["agent"].nil? ? nil : Types::Agent.from_json(data["agent"]), agent_variation: data["agentVariation"].nil? ? nil : Types::AgentVariation.from_json(data["agentVariation"]), agent_schedule: data["agentSchedule"].nil? ? nil : Types::AgentSchedule.from_json(data["agentSchedule"]), ) end |