org.apache.directory.api.ldap.aci
Class ACIItemParser

java.lang.Object
  extended by org.apache.directory.api.ldap.aci.ACIItemParser

public class ACIItemParser
extends Object

A reusable wrapper around the antlr generated parser for an ACIItem as defined by X.501. This class enables the reuse of the antlr parser/lexer pair without having to recreate them every time.

Author:
Apache Directory Project

Constructor Summary
ACIItemParser(org.apache.directory.api.ldap.model.schema.normalizers.NameComponentNormalizer normalizer, org.apache.directory.api.ldap.model.schema.SchemaManager schemaManager)
          Creates a normalizing ACIItem parser.
ACIItemParser(org.apache.directory.api.ldap.model.schema.SchemaManager schemaManager)
          Creates a ACIItem parser.
 
Method Summary
 boolean isNormizing()
          Tests to see if this parser is normalizing.
 ACIItem parse(String spec)
          Parses an ACIItem without exhausting the parser.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ACIItemParser

public ACIItemParser(org.apache.directory.api.ldap.model.schema.SchemaManager schemaManager)
Creates a ACIItem parser.

Parameters:
schemaManager - the schema manager

ACIItemParser

public ACIItemParser(org.apache.directory.api.ldap.model.schema.normalizers.NameComponentNormalizer normalizer,
                     org.apache.directory.api.ldap.model.schema.SchemaManager schemaManager)
Creates a normalizing ACIItem parser.

Parameters:
normalizer - the normalizer
schemaManager - the schema manager
Method Detail

parse

public ACIItem parse(String spec)
              throws ParseException
Parses an ACIItem without exhausting the parser.

Parameters:
spec - the specification to be parsed
Returns:
the specification bean
Throws:
ParseException - if there are any recognition errors (bad syntax)

isNormizing

public boolean isNormizing()
Tests to see if this parser is normalizing.

Returns:
true if it normalizes false otherwise


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