Skip navigation links

Oracle Virtual Directory Java API Reference
11g Release 1 (11.1.1)

E10688-03


com.octetstring.vde.syntax
Class Syntax

java.lang.Object
  extended by com.octetstring.vde.syntax.Syntax

Direct Known Subclasses:
BinarySyntax, DirectoryString, IA5String, IntegerSyntax, TelephoneNumberSyntax

public abstract class Syntax
extends java.lang.Object

Values persisted in the directory have an associated syntax. Classes implementing this interface can be used as values for appropriate attributes.


Constructor Summary
Syntax()
           

 

Method Summary
abstract  int compareTo(Syntax val)
          Compares the value in this syntax with the value in another syntax object.
abstract  boolean endsWith(Syntax val)
          Checks to see if the passed value is at the end of this value.
abstract  byte[] getValue()
          Get a byte array representation of this value.
abstract  int indexOf(Syntax val)
          Find the first occurance of the passed syntax within this syntax.
abstract  java.lang.String normalize()
          Perform necessary steps to create an indexable String representation of this value.
abstract  Syntax reverse()
          Returns the reverse of this string.
abstract  void setValue(byte[] value)
          Set this value to the passed byte array according to appropriate rules.
abstract  void setValue(byte[] value, int hashCode)
          Set this value to the passed bye array according to appropriate rules.
abstract  boolean startsWith(Syntax val)
          Determines if the specified value is at the beginning of this value.
abstract  void validate()
          Determines if this value is in accordance to the syntax rules (if any)

 

Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

 

Constructor Detail

Syntax

public Syntax()

Method Detail

compareTo

public abstract int compareTo(Syntax val)
Compares the value in this syntax with the value in another syntax object. Returns an int less than 0 if this value is less, 0 if equal, or a value greater than 0 if this value is greater.
Parameters:
val - a Syntax value
Returns:
an int value

endsWith

public abstract boolean endsWith(Syntax val)
Checks to see if the passed value is at the end of this value. Returns true if so, false if not, or if such a comparison is inappropriate (with an int, for example).
Parameters:
val - a Syntax value
Returns:
a boolean value

getValue

public abstract byte[] getValue()
Get a byte array representation of this value. This method allows the value to be sent as an octet string value via LDAP.
Returns:
a byte[] value

indexOf

public abstract int indexOf(Syntax val)
Find the first occurance of the passed syntax within this syntax.
Parameters:
val - a Syntax value
Returns:
an int value

normalize

public abstract java.lang.String normalize()
Perform necessary steps to create an indexable String representation of this value.
Returns:
a String value

reverse

public abstract Syntax reverse()
Returns the reverse of this string. Useful for substring final indexes.
Returns:
a Syntax value

setValue

public abstract void setValue(byte[] value)
Set this value to the passed byte array according to appropriate rules.
Parameters:
value - a byte[] value

setValue

public abstract void setValue(byte[] value,
                              int hashCode)
Set this value to the passed bye array according to appropriate rules. This version of the method also takes a hashCode to save computation time when it is already known.
Parameters:
value - a byte[] value
hashCode - an int value

startsWith

public abstract boolean startsWith(Syntax val)
Determines if the specified value is at the beginning of this value. Returns true if it is, false if not or if the comparison is inappropirate.
Parameters:
val - a Syntax value
Returns:
a boolean value

validate

public abstract void validate()
                       throws com.octetstring.vde.syntax.InvalidSyntaxException
Determines if this value is in accordance to the syntax rules (if any)
Throws:
com.octetstring.vde.syntax.InvalidSyntaxException

Skip navigation links

Oracle Virtual Directory Java API Reference
11g Release 1 (11.1.1)

E10688-03


Copyright © 2000-2010 Oracle and/or its affiliates. All Rights Reserved.