/// <summary> /// Initializes a new instance of the <see cref="SnmpDatagram"/> class. /// </summary> /// <param name="snmpHeader">The SNMP header.</param> /// <param name="snmpPDU">The SNMP pdu.</param> public SnmpDatagram(SnmpHeader snmpHeader, SnmpPDU snmpPDU) { Header = snmpHeader; PDU = snmpPDU; }
/// <summary> /// Initializes a new instance of the <see cref="SnmpDatagram"/> class. /// </summary> /// <param name="pduType">Type of the pdu.</param> /// <param name="snmpVersion">The SNMP version.</param> /// <param name="community">The community.</param> /// <param name="requestId">The request identifier.</param> /// <param name="errorStatus">The error status.</param> /// <param name="errorIndex">Index of the error.</param> /// <param name="varBinds">The variable binds.</param> public SnmpDatagram(PduType pduType, SnmpVersion snmpVersion, string community, int requestId, SnmpErrorStatus errorStatus, int errorIndex, VarBind[] varBinds) { Header = new SnmpHeader(snmpVersion, community); PDU = new SnmpPDU(pduType, requestId, errorStatus, errorIndex, varBinds); }