Sha256: f91c20690cc5f4565c82359e946d2aa07e55b8084b12938958a93f4095e1a608

Contents?: true

Size: 459 Bytes

Versions: 2

Compression:

Stored size: 459 Bytes

Contents

module SPNet
class CommandOutPort < OutPort

  def initialize hashed_args = {}
    hashed_args.merge!(:matching_port_class => CommandInPort)
    super(hashed_args)
  end
  
  def list_commands
    rvs = []
    @links.each do |link|
      rvs.push link.list_commands
    end
    return rvs
  end

  def exec_command command, data = nil
    rvs = []
    @links.each do |link|
      rvs.push link.exec_command(command, data)
    end
    return rvs
  end

end
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
spnet-0.1.4 lib/spnet/ports/command_out_port.rb
spnet-0.1.3 lib/spnet/ports/command_out_port.rb