Class: Nonnative::Server
- Inherits:
-
Thread
- Object
- Thread
- Nonnative::Server
- Defined in:
- lib/nonnative/server.rb
Instance Attribute Summary collapse
-
#port ⇒ Object
readonly
Returns the value of attribute port.
Instance Method Summary collapse
-
#initialize(port) ⇒ Server
constructor
A new instance of Server.
- #perform_start ⇒ Object
- #perform_stop ⇒ Object
- #start ⇒ Object
- #stop ⇒ Object
Constructor Details
#initialize(port) ⇒ Server
Returns a new instance of Server.
5 6 7 8 9 10 11 12 |
# File 'lib/nonnative/server.rb', line 5 def initialize(port) @port = port self.abort_on_exception = true super do perform_start end end |
Instance Attribute Details
#port ⇒ Object (readonly)
Returns the value of attribute port.
23 24 25 |
# File 'lib/nonnative/server.rb', line 23 def port @port end |
Instance Method Details
#perform_start ⇒ Object
25 |
# File 'lib/nonnative/server.rb', line 25 def perform_start; end |
#perform_stop ⇒ Object
27 |
# File 'lib/nonnative/server.rb', line 27 def perform_stop; end |
#start ⇒ Object
14 15 16 |
# File 'lib/nonnative/server.rb', line 14 def start object_id end |
#stop ⇒ Object
18 19 20 21 |
# File 'lib/nonnative/server.rb', line 18 def stop perform_stop object_id end |