|
IMSEVimse 1.0 Draft |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--se.kth.cid.xml.XmlLoaderHelper
This class contains utility functions for loading and saving XML components.
Constructor Summary | |
protected |
XmlLoaderHelper()
Constructing an XmlLoaderHelper is not allowed. |
Method Summary | |
static XmlElement |
buildDataTags(String[] tags)
Builds a DataTags element. |
static XmlElement |
buildDataTagStyles(String[] tags)
Builds a DataTagStyles element. |
static XmlElement |
getSubElement(XmlElement el,
String elname)
|
static String |
loadAttribute(XmlElement el,
String attname,
String def)
|
static String |
loadAttribute(XmlElement el,
String attname,
String def,
boolean emptyAllowed)
|
static boolean |
loadBoolean(XmlElement el,
String attr,
String def)
Loads a boolean attribute. |
static int |
loadPositiveInteger(XmlElement el,
String attr,
String def,
boolean allowInf)
Loads a positive integer attribute. |
static XmlElement |
maybeGetSubElement(XmlElement el,
String elname)
|
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
protected XmlLoaderHelper()
Method Detail |
public static String loadAttribute(XmlElement el, String attname, String def) throws XmlStructureException
public static String loadAttribute(XmlElement el, String attname, String def, boolean emptyAllowed) throws XmlStructureException
public static XmlElement getSubElement(XmlElement el, String elname) throws XmlStructureException
public static XmlElement maybeGetSubElement(XmlElement el, String elname) throws XmlStructureException
public static boolean loadBoolean(XmlElement el, String attr, String def) throws XmlStructureException
el
- the element to load from.attr
- the name of the attribute containing a boolean.XmlStructureException
- if the attribute was invalid.public static int loadPositiveInteger(XmlElement el, String attr, String def, boolean allowInf) throws XmlStructureException
el
- the element to load from.attr
- the name of the attribute containing a positive integer.XmlStructureException
- if the attribute was invalid.public static XmlElement buildDataTags(String[] tags) throws XmlElementException
tags
- the DataTags wanted in the element.public static XmlElement buildDataTagStyles(String[] tags) throws XmlElementException
tags
- the DataTagStyles wanted in the element.
|
IMSEVimse 1.0 Draft |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |