Make sync request using IP/UDP with request timeouts and retries.
Namespace:
SnmpSharpNetAssembly: SnmpSharpNet (in SnmpSharpNet.dll) Version: 0.5.0.0 (0.5.0.0)
Syntax
| C# | Visual Basic | Visual C++ |
public: array<unsigned char>^ Request( IPAddress^ peer, int port, array<unsigned char>^ buffer, int bufferLength, int timeout, int retries )
Parameters
- peer
- IPAddress
SNMP agent IP address
- port
- Int32
SNMP agent port number
- buffer
- array<
Byte
>[]()[]
Data to send to the agent
- bufferLength
- Int32
Data length in the buffer
- timeout
- Int32
Timeout in milliseconds
- retries
- Int32
Maximum number of retries. 0 = make a single request with no retry attempts
Return Value
Byte array returned by the agent. Null on error
Exceptions
| Exception | Condition |
|---|---|
| SnmpSharpNet..::.SnmpException | Thrown on request timed out. SnmpException.ErrorCode is set to SnmpException.RequestTimedOut constant. |