Package org.opennms.netmgt.icmp.jna
Class JnaIcmpMessenger
- java.lang.Object
-
- org.opennms.netmgt.icmp.jna.JnaIcmpMessenger
-
- All Implemented Interfaces:
PingReplyListener
,org.opennms.protocols.rt.Messenger<JnaPingRequest,JnaPingReply>
public class JnaIcmpMessenger extends Object implements org.opennms.protocols.rt.Messenger<JnaPingRequest,JnaPingReply>, PingReplyListener
- Author:
- brozow
-
-
Constructor Summary
Constructors Constructor Description JnaIcmpMessenger(int pingerId)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
isV4Available()
boolean
isV6Available()
void
onPingReply(InetAddress address, EchoPacket packet)
void
sendRequest(JnaPingRequest request)
void
setAllowFragmentation(boolean allow)
void
setTrafficClass(int tc)
void
start(org.opennms.protocols.rt.ReplyHandler<JnaPingReply> callback)
-
-
-
Method Detail
-
isV4Available
public boolean isV4Available()
-
isV6Available
public boolean isV6Available()
-
sendRequest
public void sendRequest(JnaPingRequest request)
- Specified by:
sendRequest
in interfaceorg.opennms.protocols.rt.Messenger<JnaPingRequest,JnaPingReply>
-
start
public void start(org.opennms.protocols.rt.ReplyHandler<JnaPingReply> callback)
- Specified by:
start
in interfaceorg.opennms.protocols.rt.Messenger<JnaPingRequest,JnaPingReply>
-
onPingReply
public void onPingReply(InetAddress address, EchoPacket packet)
- Specified by:
onPingReply
in interfacePingReplyListener
-
setTrafficClass
public void setTrafficClass(int tc) throws IOException
- Throws:
IOException
-
setAllowFragmentation
public void setAllowFragmentation(boolean allow) throws IOException
- Throws:
IOException
-
-