T - The type of SchemaObjectpublic abstract class AbstractSchemaParser<T extends SchemaObject> extends Object
| Modifier and Type | Field and Description |
|---|---|
protected OpenLdapSchemaParser |
fastParser
The fast schemaObject parser
|
protected static org.slf4j.Logger |
LOG
The LoggerFactory used by this class
|
| Modifier | Constructor and Description |
|---|---|
protected |
AbstractSchemaParser(Class<T> schemaObjectType,
org.apache.directory.api.i18n.I18n errorCodeOnNull,
org.apache.directory.api.i18n.I18n errorCodeOnParseExceptionWithPosition,
org.apache.directory.api.i18n.I18n errorCodeOnParseException)
Instantiates a new abstract schema parser.
|
| Modifier and Type | Method and Description |
|---|---|
Map<String,OpenLdapObjectIdentifierMacro> |
getObjectIdentifiers()
Get the defined macros.
|
boolean |
isQuirksMode()
Checks if quirks mode is enabled.
|
abstract T |
parse(String schemaDescription)
Parse a SchemaObject description and returns back an instance of SchemaObject.
|
void |
setQuirksMode(boolean enabled)
Sets the quirks mode.
|
protected void |
updateSchemaName(SchemaObject schemaObject)
Update the schemaName for the given SchemaObject, accordingly to the X-SCHEMA parameter.
|
protected static final org.slf4j.Logger LOG
protected OpenLdapSchemaParser fastParser
protected AbstractSchemaParser(Class<T> schemaObjectType, org.apache.directory.api.i18n.I18n errorCodeOnNull, org.apache.directory.api.i18n.I18n errorCodeOnParseExceptionWithPosition, org.apache.directory.api.i18n.I18n errorCodeOnParseException)
schemaObjectType - The Schema object typeerrorCodeOnNull - error code used when schema element is nullerrorCodeOnParseExceptionWithPosition - error code used on parse error when position is knownerrorCodeOnParseException - error code used on parse error when position is unknownpublic void setQuirksMode(boolean enabled)
enabled - the new quirks modepublic boolean isQuirksMode()
public abstract T parse(String schemaDescription) throws ParseException
schemaDescription - The SchemaObject descriptionParseException - If the parsing failedprotected void updateSchemaName(SchemaObject schemaObject)
schemaObject - the schema object where the name should be updatedpublic Map<String,OpenLdapObjectIdentifierMacro> getObjectIdentifiers()
Copyright © 2003–2022 The Apache Software Foundation. All rights reserved.