public class SnmpClientFixture extends Object implements SnmpClient
Constructor and Description |
---|
SnmpClientFixture()
Constructor.
|
Modifier and Type | Method and Description |
---|---|
static SnmpResponse |
copy(SnmpRequest request)
Helper method to copy a request into a response (used for fixtures/testing).
|
void |
sendRequest(SnmpRequest request)
Main entry point for sending requests to a SNMP server.
|
void |
sendTrap(SnmpTrapRequest trap)
Main entry point for sending traps to a SNMP receiver.
|
void |
setErrorType(SnmpRequest.ErrorType errorType) |
void |
setRemoteAddress(IpAddress remoteAddress) |
void |
stop()
Shutdown the client and underlying engine.
|
public static SnmpResponse copy(SnmpRequest request)
request
- original SNMP requestpublic void setErrorType(SnmpRequest.ErrorType errorType)
public void setRemoteAddress(IpAddress remoteAddress)
public void stop()
SnmpClient
stop
in interface SnmpClient
public void sendTrap(SnmpTrapRequest trap)
SnmpClient
sendTrap
in interface SnmpClient
trap
- SNMP trappublic void sendRequest(SnmpRequest request)
SnmpClient
sendRequest
in interface SnmpClient
request
- SNMP request (all required fields must be setup properly)Copyright © 2016. All Rights Reserved.