org.apache.directory.shared.ldap.codec.search
Class Filter

java.lang.Object
  extended by org.apache.directory.shared.ldap.codec.search.Filter
Direct Known Subclasses:
AttributeValueAssertionFilter, ConnectorFilter, ExtensibleMatchFilter, PresentFilter, SubstringFilter

public abstract class Filter
extends Object

An abstract Asn1Object used to store the filter. A filter is seen as a tree with a root. This class does nothing, it's just the root of all the different filters.

Author:
Apache Directory Project

Field Summary
protected  Filter parent
          The parent Filter
protected  int parentTlvId
          The parent TLV id
 
Constructor Summary
Filter()
          The constructor.
Filter(int tlvId)
          The constructor.
 
Method Summary
abstract  int computeLength()
          Compute the Filter length
abstract  ByteBuffer encode(ByteBuffer buffer)
          Encode the Filter message to a PDU.
 Filter getParent()
          Get the parent
 int getParentTlvId()
          Get the parent
 int getTlvId()
           
 void setParent(Filter parent, int parentTlvId)
          Set the parent
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

parentTlvId

protected int parentTlvId
The parent TLV id


parent

protected Filter parent
The parent Filter

Constructor Detail

Filter

public Filter(int tlvId)
The constructor.


Filter

public Filter()
The constructor.

Method Detail

getParent

public Filter getParent()
Get the parent

Returns:
Returns the parent.

getParentTlvId

public int getParentTlvId()
Get the parent

Returns:
Returns the parent.

setParent

public void setParent(Filter parent,
                      int parentTlvId)
Set the parent

Parameters:
parent - The parent to set.

getTlvId

public int getTlvId()

computeLength

public abstract int computeLength()
Compute the Filter length


encode

public abstract ByteBuffer encode(ByteBuffer buffer)
                           throws EncoderException
Encode the Filter message to a PDU.

Parameters:
buffer - The buffer where to put the PDU
Returns:
The PDU.
Throws:
EncoderException


Copyright © 2003-2011 The Apache Software Foundation. All Rights Reserved.