Class: Bane::CommandLineConfiguration::LinearPortMappedBehaviorConfiguration
- Inherits:
-
Object
- Object
- Bane::CommandLineConfiguration::LinearPortMappedBehaviorConfiguration
- Defined in:
- lib/bane/command_line_configuration.rb
Instance Method Summary collapse
-
#initialize(port, behaviors, host) ⇒ LinearPortMappedBehaviorConfiguration
constructor
A new instance of LinearPortMappedBehaviorConfiguration.
- #servers ⇒ Object
Constructor Details
#initialize(port, behaviors, host) ⇒ LinearPortMappedBehaviorConfiguration
Returns a new instance of LinearPortMappedBehaviorConfiguration.
70 71 72 73 74 |
# File 'lib/bane/command_line_configuration.rb', line 70 def initialize(port, behaviors, host) @starting_port = port @behaviors = behaviors @host = host end |
Instance Method Details
#servers ⇒ Object
76 77 78 79 80 81 82 |
# File 'lib/bane/command_line_configuration.rb', line 76 def servers configurations = [] @behaviors.each_with_index do |behavior, index| configurations << BehaviorServer.new(@starting_port + index, behavior.new, @host) end configurations end |