Class SnmpRequest

    • Field Detail

      • DEFAULT_CONTEXT

        public static final org.snmp4j.smi.OctetString DEFAULT_CONTEXT
      • processingUserObjects

        protected Map<Object,Object> processingUserObjects
    • Constructor Detail

      • SnmpRequest

        public SnmpRequest​(org.snmp4j.CommandResponderEvent<?> request,
                           CoexistenceInfo cinfo)
    • Method Detail

      • nextTransactionID

        public static int nextTransactionID​()
      • getMaxRepetitions

        public int getMaxRepetitions​()
      • getNonRepeaters

        public int getNonRepeaters​()
      • size

        public int size​()
        Description copied from interface: Request
        Gets the number of sub-requests in this request. For GETBULK requests this number may increase over time.
        Returns:
        a positive integer (greater or equal to zero).
      • setRequestEvent

        public void setRequestEvent​(org.snmp4j.CommandResponderEvent<?> source)
      • assignErrorStatus2Response

        protected void assignErrorStatus2Response​()
      • is2PC

        protected boolean is2PC​()
      • getContext

        public org.snmp4j.smi.OctetString getContext​()
        Description copied from interface: Request
        Gets the context of the request.
        Returns:
        an OctetString instance.
      • getViewName

        public org.snmp4j.smi.OctetString getViewName​()
      • setViewName

        public void setViewName​(org.snmp4j.smi.OctetString viewName)
      • getSecurityLevel

        public int getSecurityLevel​()
      • getSecurityModel

        public int getSecurityModel​()
      • getSecurityName

        public org.snmp4j.smi.OctetString getSecurityName​()
      • getViewType

        public int getViewType​()
      • getViewType

        public static int getViewType​(int pduType)
        Returns the VACM view type for the supplied PDU type.
        Parameters:
        pduType - a PDU type.
        Returns:
        the corresponding VACM view type.
      • addRepeaterSubRequest

        protected void addRepeaterSubRequest​()
      • getMessageProcessingModel

        public int getMessageProcessingModel​()
      • getRepeaterCount

        public int getRepeaterCount​()
      • isPhaseComplete

        public boolean isPhaseComplete​()
        Description copied from interface: Request
        Checks whether the current phase is complete.
        Returns:
        true if all required processing has been finished for the current request phase. For single phase request types this method returns the same result as Request.isComplete().
      • getProcessingUserObject

        public Object getProcessingUserObject​(Object key)
        Description copied from interface: Request
        Gets the processing user object for the specified key. By default there is no such object associated with a request, but ManagedObjects may put their own objects into the request (for example to avoid unnecessary updates on behalf of the same request).
        Parameters:
        key - an Object.
        Returns:
        the associated Object or null if their exists no such association.
      • setProcessingUserObject

        public Object setProcessingUserObject​(Object key,
                                              Object value)
        Description copied from interface: Request
        Sets an user object association.
        Parameters:
        key - a key Object.
        value - a value Object associated with key.
        Returns:
        the previous value associated with key or null if no such association existed.