Class ConnectorFilter

    • Field Detail

      • filterSet

        protected List<Filter> filterSet
        The set of filters used by And/Or filters
      • filtersLength

        protected int filtersLength
        The filters length
    • Constructor Detail

      • ConnectorFilter

        public ConnectorFilter​(int tlvId)
        The constructor. We wont initialize the ArrayList as it may not be used.
        Parameters:
        tlvId - The TLV identifier
      • ConnectorFilter

        public ConnectorFilter()
        The constructor. We wont initialize the ArrayList as it may not be used.
    • Method Detail

      • addFilter

        public void addFilter​(Filter filter)
                       throws DecoderException
        Add a new Filter to the list.
        Parameters:
        filter - The filter to add
        Throws:
        DecoderException - If the decoding failed
      • getFilterSet

        public List<Filter> getFilterSet()
        Get the list of filters stored in the composite filter
        Returns:
        And array of filters
      • computeLength

        public int computeLength()
        Compute the ConnectorFilter length Length(ConnectorFilter) = sum(filterSet.computeLength())
        Specified by:
        computeLength in class Filter
        Returns:
        The encoded length
      • encode

        public ByteBuffer encode​(ByteBuffer buffer)
                          throws EncoderException
        Encode the ConnectorFilter message to a PDU.
         ConnectorFilter :
         filter.encode() ... filter.encode()
         
        Specified by:
        encode in class Filter
        Parameters:
        buffer - The buffer where to put the PDU
        Returns:
        The PDU.
        Throws:
        EncoderException - If the encoding failed
      • toString

        public String toString()
        Return a string compliant with RFC 2254 representing a composite filter, one of AND, OR and NOT
        Overrides:
        toString in class Object
        Returns:
        The composite filter string