|
jInfer | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object cz.cuni.mff.ksi.jinfer.xsdimportsax.SAXHelper
public final class SAXHelper
Helper class for DOMHandler
, provides convenience methods used during parsing.
It is best NOT to use these methods outside this package.
Please read package info.
Method Summary | |
---|---|
static void |
finalizeElement(Element elem)
Finalizes the element, makes it immutable. |
static boolean |
isContainer(Element elem)
Finds out if parameter is only a temporary container with the name set by CONTAINER_NAME constant. |
static Map<String,Object> |
prepareAttributeMetadata(SAXDocumentElement el)
Prepare metadata of attribute tag stored in the parameter. |
static Map<String,Object> |
prepareElementMetadata(SAXDocumentElement el,
boolean isContainer)
Prepares the metadata for a rule by extracting information from el . |
static String |
prepareElementName(SAXDocumentElement el,
boolean isContainer)
Prepares the name for a rule by extracting data from el . |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Method Detail |
---|
public static Map<String,Object> prepareAttributeMetadata(SAXDocumentElement el)
el
- Instance of the wrapper class containing the attribute tag,
from which the metadata is extracted.
public static boolean isContainer(Element elem)
elem
- Instance to be examined.
elem
is a container, false otherwise.public static String prepareElementName(SAXDocumentElement el, boolean isContainer)
el
.
Resulting name is taken from attributes of the tag.
Attribute name has priority before attribute ref.
If it is a container, special internal value for the name is used.
el
- Instance wrapping the tag.isContainer
- Indicates if the name is prepared only for a container.
public static Map<String,Object> prepareElementMetadata(SAXDocumentElement el, boolean isContainer)
el
.
If it is not a container, IGGUtils.ATTR_FROM_SCHEMA
is added to metadata.
If el
has ref attribute specified, IGGUtils.METADATA_SENTINEL
is added to metadata.
el
- Instance wrapping the tag.isContainer
- Indicates if the metadata is prepared only for a container.
public static void finalizeElement(Element elem)
elem
- Element to finalize.
|
jInfer | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |