public abstract class ConfigElementLoader
extends Object
Modifier and Type | Field and Description |
---|---|
static String |
ALIAS_ELEMENT
Alias element.
|
static String |
ALLOW_ATTRIBUTE
Allow attribute.
|
static String |
CACHED_ATTRIBUTE
Cached attribute.
|
static String |
CLASS_DEF_ENTITY
ClassDef entity element.
|
static String |
CLASS_DEF_REFERENCE
ClassDef reference.
|
static String |
CLASS_LIB_ENTITY
ClassLib entity element.
|
static String |
CLASS_LIB_REFERENCE
ClassLib reference.
|
static String |
DECRYPT_ATTRIBUTE
Decrypt attribute.
|
static String |
DECRYPT_KEY_ELEMENT
Decrypt key element.
|
static String |
DEF_ATTRIBUTE
Def attribute.
|
static String |
DENY_ATTRIBUTE
Deny attribute.
|
static String |
ENV_ATTRIBUTE
Env attribute.
|
static String |
EQ_ATTRIBUTE
Eq attribute.
|
static String |
EXTENDS_ATTRIBUTE
Extends attribute.
|
static String |
FROM_ATTRIBUTE
From attribute.
|
static String |
HIDDEN_ATTRIBUTE
Hidden attribute.
|
static String |
IMPLEMENTS_ELEMENT
Implements element.
|
static String |
LOCATION_ATTRIBUTE
Location attribute.
|
static String |
LOCATION_ELEMENT
Location element.
|
static String |
MEMBER_ATTRIBUTE
Member attribute.
|
static String |
MULTIPLE_ATTRIBUTE
Multiple allowed attribute.
|
static String |
OPTIONAL_ATTRIBUTE
Optional attribute.
|
static String |
OVERRIDES_ATTRIBUTE
Overrides attribute.
|
static String |
PACKAGE_ATTRIBUTE
Package attribute.
|
static String |
PROPERTIES_DEF_ENTITY
PropertiesDef entity element.
|
static String |
PROPERTIES_ELEMENT
Properties element.
|
static String |
PROPERTY_ATTRIBUTE
Property attribute.
|
static String |
PROPERTY_DEF_ENTITY
PropertyDef entity element.
|
static String |
PROPERTY_ELEMENT
Property element.
|
static String |
REQUIRED_ATTRIBUTE
Required attribute.
|
static String |
ROLE_ATTRIBUTE
Role attribute.
|
static String |
SECURITY_ATTRIBUTE
Security attribute.
|
static String |
SERVICE_ELEMENT
Service element.
|
static String |
STAMP_ATTRIBUTE
Stamp attribute.
|
static String |
SUPERSEDE_ATTRIBUTE
Supersede attribute.
|
static String |
SYSTEM_ATTRIBUTE
System attribute.
|
static String |
VALIDATED_ATTRIBUTE
Validated attribute.
|
static String |
VALUE_ATTRIBUTE
Value attribute.
|
static String |
VALUE_ELEMENT
Value element.
|
static String |
VERIFY_ATTRIBUTE
Verify attribute.
|
static String |
VERIFY_KEY_ELEMENT
Verify key element.
|
Constructor and Description |
---|
ConfigElementLoader() |
Modifier and Type | Method and Description |
---|---|
protected Config |
getConfig()
Gets the config.
|
protected URL |
getContextURL()
Gets the URL for the current context.
|
protected DocumentLoader |
getDocumentLoader()
Gets the document loader.
|
protected DocumentElement |
getElement()
Gets the XML element.
|
protected Entity |
getEntity(String key,
String prefix)
Gets an entity registered to the owner.
|
protected Optional<? extends Entity> |
getEntity(String key,
String prefix,
boolean optional)
Gets an entity registered to the owner.
|
protected Optional<String> |
getLang()
Gets the information texts language.
|
protected Logger |
getLogger()
Gets the logger.
|
protected abstract void |
process()
Processes the entry XML informations.
|
protected void |
putEntity(Entity entity)
Registers an entity to the owner XML document.
|
protected void |
putEntity(Entity entity,
boolean supersede)
Registers an entity to the owner XML document.
|
protected void |
putEntity(String key,
Entity entity)
Registers an entity to the owner XML document.
|
protected void |
removeEntity(String key,
String prefix)
Removes an entity.
|
protected void |
updateTexts()
Updates information texts.
|
public static final String ALIAS_ELEMENT
public static final String ALLOW_ATTRIBUTE
public static final String CACHED_ATTRIBUTE
public static final String CLASS_DEF_ENTITY
public static final String CLASS_DEF_REFERENCE
public static final String CLASS_LIB_ENTITY
public static final String CLASS_LIB_REFERENCE
public static final String DECRYPT_ATTRIBUTE
public static final String DECRYPT_KEY_ELEMENT
public static final String DEF_ATTRIBUTE
public static final String DENY_ATTRIBUTE
public static final String ENV_ATTRIBUTE
public static final String EQ_ATTRIBUTE
public static final String EXTENDS_ATTRIBUTE
public static final String FROM_ATTRIBUTE
public static final String HIDDEN_ATTRIBUTE
public static final String IMPLEMENTS_ELEMENT
public static final String LOCATION_ATTRIBUTE
public static final String LOCATION_ELEMENT
public static final String MEMBER_ATTRIBUTE
public static final String MULTIPLE_ATTRIBUTE
public static final String OPTIONAL_ATTRIBUTE
public static final String OVERRIDES_ATTRIBUTE
public static final String PACKAGE_ATTRIBUTE
public static final String PROPERTIES_DEF_ENTITY
public static final String PROPERTIES_ELEMENT
public static final String PROPERTY_ATTRIBUTE
public static final String PROPERTY_DEF_ENTITY
public static final String PROPERTY_ELEMENT
public static final String REQUIRED_ATTRIBUTE
public static final String ROLE_ATTRIBUTE
public static final String SECURITY_ATTRIBUTE
public static final String SERVICE_ELEMENT
public static final String STAMP_ATTRIBUTE
public static final String SUPERSEDE_ATTRIBUTE
public static final String SYSTEM_ATTRIBUTE
public static final String VALIDATED_ATTRIBUTE
public static final String VALUE_ATTRIBUTE
public static final String VALUE_ELEMENT
public static final String VERIFY_ATTRIBUTE
public static final String VERIFY_KEY_ELEMENT
@Nonnull @CheckReturnValue protected final Config getConfig()
@Nonnull @CheckReturnValue protected final URL getContextURL()
@Nonnull @CheckReturnValue protected final DocumentLoader getDocumentLoader()
@Nonnull @CheckReturnValue protected final DocumentElement getElement()
@Nonnull @CheckReturnValue protected final Entity getEntity(@Nonnull String key, @Nonnull String prefix) throws ValidationException
Produces a warning if the entity is not present.
key
- The entity key.prefix
- The prefix associated with the entity class.ValidationException
- When appropriate.@Nonnull @CheckReturnValue protected final Optional<? extends Entity> getEntity(@Nonnull String key, @Nonnull String prefix, boolean optional) throws ValidationException
key
- The entity name.prefix
- The prefix associated with the entity class.optional
- True if the entity is optional.ValidationException
- When appropriate.@Nonnull @CheckReturnValue protected Optional<String> getLang()
@Nonnull @CheckReturnValue protected final Logger getLogger()
protected abstract void process() throws ValidationException
ValidationException
- When appropriate.protected final void putEntity(@Nonnull Entity entity)
entity
- The entity to be registered.protected final void putEntity(@Nonnull Entity entity, boolean supersede)
entity
- The entity to be registered.supersede
- Allows supersede by name.protected final void putEntity(@Nonnull String key, @Nonnull Entity entity)
key
- The key for the registration.entity
- The entity to be registered.protected final void removeEntity(@Nonnull String key, @Nonnull String prefix)
key
- The entity definition key.prefix
- The key prefix for the entity.protected void updateTexts()
Copyright © 2003-2019 Serge Brisson. All Rights Reserved.