Class: Bcome::Orchestrator::DirectCommand::Group

Inherits:
Object
  • Object
show all
Includes:
ValidateAndSet
Defined in:
lib/orchestrator/direct_command/group.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods included from ValidateAndSet

#validate_and_set

Constructor Details

#initialize(json) ⇒ Group

Returns a new instance of Group.



8
9
10
# File 'lib/orchestrator/direct_command/group.rb', line 8

def initialize(json)
  validate_and_set(json)
end

Instance Attribute Details

#commandsObject (readonly)

Returns the value of attribute commands.



6
7
8
# File 'lib/orchestrator/direct_command/group.rb', line 6

def commands
  @commands
end

#descriptionObject (readonly)

Returns the value of attribute description.



6
7
8
# File 'lib/orchestrator/direct_command/group.rb', line 6

def description
  @description
end

#direct_command_set_identifierObject (readonly)

Returns the value of attribute direct_command_set_identifier.



6
7
8
# File 'lib/orchestrator/direct_command/group.rb', line 6

def direct_command_set_identifier
  @direct_command_set_identifier
end

Instance Method Details

#command_instancesObject



12
13
14
# File 'lib/orchestrator/direct_command/group.rb', line 12

def command_instances
  @command_instances ||= commands.collect{|raw_command| ::Bcome::Orchestrator::DirectCommand::Instance.new(raw_command)}
end

#json_attributesObject



16
17
18
# File 'lib/orchestrator/direct_command/group.rb', line 16

def json_attributes
  [:direct_command_set_identifier, :commands, :description]
end