Class: Netconf::Transport
- Inherits:
-
Object
- Object
- Netconf::Transport
- Defined in:
- lib/sloe/common.rb
Instance Attribute Summary collapse
-
#logging ⇒ Object
Returns the value of attribute logging.
Instance Method Summary collapse
-
#initialize(&block) ⇒ Transport
constructor
A new instance of Transport.
Constructor Details
#initialize(&block) ⇒ Transport
Returns a new instance of Transport.
47 48 49 50 51 52 53 54 55 56 57 58 59 |
# File 'lib/sloe/common.rb', line 47 def initialize(&block) @state = :NETCONF_CLOSED @os_type = @args[:os_type] || Netconf::DEFAULT_OS_TYPE @rpc = Netconf::RPC::Executor.new(self, @os_type, self.logging) @rpc_message_id = 1 if block_given? open(&block = nil) # do not pass this block to open() yield self close end end |
Instance Attribute Details
#logging ⇒ Object
Returns the value of attribute logging.
45 46 47 |
# File 'lib/sloe/common.rb', line 45 def logging @logging end |