Class: Netdisco::XDP
- Inherits:
-
Object
- Object
- Netdisco::XDP
- Includes:
- NameMap
- Defined in:
- lib/netdisco/method/xdp.rb
Instance Attribute Summary collapse
-
#mib ⇒ Object
readonly
类对象方法属性.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(host) ⇒ XDP
constructor
对象实例化入口函数.
-
#poll ⇒ Object
轮询设备邻居关系.
Methods included from NameMap
Constructor Details
Instance Attribute Details
#mib ⇒ Object (readonly)
类对象方法属性
9 10 11 |
# File 'lib/netdisco/method/xdp.rb', line 9 def mib @mib end |
Class Method Details
.peers(host) ⇒ Array(Netdisco::Peer)
类属性方法
22 23 24 |
# File 'lib/netdisco/method/xdp.rb', line 22 def self.peers(host) new(host).poll end |
Instance Method Details
#poll ⇒ Object
轮询设备邻居关系
27 28 29 30 31 32 |
# File 'lib/netdisco/method/xdp.rb', line 27 def poll @mib = @snmp.hashwalk self.class::MIB make_peers rescue SNMP::NoResponse [] end |