public final class EDLXmlUtils extends Object
Modifier and Type | Field and Description |
---|---|
static String |
DATA_E |
static String |
DOCID_E |
static String |
EDL_E |
static String |
EDLCONTENT_E |
static String |
TYPE_E |
static String |
VALIDATION_E |
static String |
VERSION_E |
Modifier and Type | Method and Description |
---|---|
static void |
addErrorsAndMessagesToDocument(Document doc,
List errors,
List messages,
Map<String,String> fieldErrors)
Adds the specified errors and messages to the <documentState> element of the
given EDL doc
|
static void |
addGlobalErrorMessage(Document dom,
String errorMessage) |
static Element |
createChildElement(Element parentElement,
String elementName) |
static Element |
createFieldDataElement(Element parentVersionElement,
MatchingParam matchingParam) |
static Element |
createTextElementOnParent(Element parent,
String childElementName,
String text) |
static Element |
getChildElement(Node parent,
String name)
Returns a node child with the specified tag name of the specified parent node,
or null if no such child node is found.
|
static String |
getChildElementTextValue(Node parent,
String name)
Returns the text value of a child element with the given name, of the given parent element,
or null if the child does not exist or does not have a child text node
|
static Element |
getDataFromEDLDocument(Element edlContent,
boolean create) |
static DocumentBuilder |
getDocumentBuilder()
Returns a valid DocumentBuilder
|
static Element |
getDocumentStateElement(Document dom) |
static Element |
getEDLContent(Document displayDoc,
boolean create) |
static Element |
getOrCreateChildElement(Element parent,
String name,
boolean create)
Returns, and creates if absent, a child element
|
static Element |
getVersionFromData(Element dataElement,
Integer versionCount) |
public static final String EDL_E
public static final String EDLCONTENT_E
public static final String DATA_E
public static final String TYPE_E
public static final String VALIDATION_E
public static final String VERSION_E
public static final String DOCID_E
public static DocumentBuilder getDocumentBuilder()
public static Element createFieldDataElement(Element parentVersionElement, MatchingParam matchingParam)
public static Element createChildElement(Element parentElement, String elementName)
public static Element getDocumentStateElement(Document dom)
public static void addGlobalErrorMessage(Document dom, String errorMessage)
public static Element createTextElementOnParent(Element parent, String childElementName, String text)
public static Element getVersionFromData(Element dataElement, Integer versionCount)
public static Element getDataFromEDLDocument(Element edlContent, boolean create)
public static Element getEDLContent(Document displayDoc, boolean create)
public static Element getOrCreateChildElement(Element parent, String name, boolean create)
parent
- the parent elementname
- the name of the child element to create and/or returnpublic static Element getChildElement(Node parent, String name)
parent
- the parent nodename
- the name of the child nodepublic static String getChildElementTextValue(Node parent, String name)
parent
- parent elementname
- name of child elementpublic static void addErrorsAndMessagesToDocument(Document doc, List errors, List messages, Map<String,String> fieldErrors)
doc
- the EDL docerrors
- the list of error Stringsmessages
- the list of message StringsCopyright © 2005-2015 The Kuali Foundation. All Rights Reserved.