|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object edu.sdsc.inca.util.XmlWrapper edu.sdsc.inca.util.SuiteWrapper
public class SuiteWrapper
Convenience object for accessing suite documents and persisting changes to them.
Field Summary |
---|
Fields inherited from class edu.sdsc.inca.util.XmlWrapper |
---|
CDATA_PATTERN, ELEMENT_CLOSE_PATTERN, PASSWORD_MACRO_VALUE_PATTERN, PROCESSING_INSTRUCTION_PATTERN, XML_COMMENT_PATTERN, XML_NAME_PATTERN, XML_NODE_PATTERN |
Constructor Summary | |
---|---|
SuiteWrapper()
Create a new SuiteWrapper object containing a blank suite. |
|
SuiteWrapper(java.lang.String filename)
Create a new SuiteWrapper object from a suite XML file. |
|
SuiteWrapper(edu.sdsc.inca.dataModel.suite.SuiteDocument suiteDoc)
Create a new SuiteWrapper object from an XML Beans class instance. |
Method Summary | |
---|---|
void |
appendSeriesConfig(edu.sdsc.inca.dataModel.util.SeriesConfig seriesConfig)
Append a new series config to the existing suite. |
void |
changeAction(java.lang.String action)
Change the action in all series configs found in the suite document. |
void |
copySuiteAttributes(edu.sdsc.inca.dataModel.suite.SuiteDocument suiteDoc)
Copy the top level suite attributes: name, guid, and description to supplied suite document. |
edu.sdsc.inca.dataModel.suite.SuiteDocument |
diff(edu.sdsc.inca.dataModel.suite.SuiteDocument suiteDoc)
Compare the existing suite against the passed in suite and return the differences as adds and deletes. |
edu.sdsc.inca.dataModel.util.SeriesConfig |
getSeriesConfig(int index)
Return a series config from the suite. |
int |
getSeriesConfigCount()
Return the number of series config objects contained in the suite document. |
int[] |
getSeriesConfigCountByPattern(java.lang.String[] nicknamePatterns,
java.lang.String[] namePatterns)
Count the number of series configs that match the provided patterns. |
edu.sdsc.inca.dataModel.util.SeriesConfig[] |
getSeriesConfigs()
Return all series configs in the suite as an array. |
edu.sdsc.inca.dataModel.suite.SuiteDocument |
getSuiteDocument()
Return the root element of the suite document. |
void |
save(java.io.File saveTo)
Save the suite to the specified file |
Methods inherited from class edu.sdsc.inca.util.XmlWrapper |
---|
configEqual, cryptSensitive, escape, getPrettyPrintOptions, main, prettyPrint, read, save, unescape, validate |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public SuiteWrapper()
public SuiteWrapper(edu.sdsc.inca.dataModel.suite.SuiteDocument suiteDoc) throws org.apache.xmlbeans.XmlException
suiteDoc
- An instance of SuiteDocument, a class generated
org.apache.xmlbeans.XmlException
public SuiteWrapper(java.lang.String filename) throws java.io.IOException, org.apache.xmlbeans.XmlException
filename
- Path to a file containing suite XML.
java.io.IOException
org.apache.xmlbeans.XmlException
Method Detail |
---|
public void appendSeriesConfig(edu.sdsc.inca.dataModel.util.SeriesConfig seriesConfig)
seriesConfig
- A new series config object to be added to the end
of the existing suite.public void changeAction(java.lang.String action)
action
- The action to use in all series configs.public void copySuiteAttributes(edu.sdsc.inca.dataModel.suite.SuiteDocument suiteDoc)
suiteDoc
- A suite that where the top level suite attributes will be
copied topublic edu.sdsc.inca.dataModel.suite.SuiteDocument diff(edu.sdsc.inca.dataModel.suite.SuiteDocument suiteDoc) throws org.apache.xmlbeans.XmlException
suiteDoc
- Another suite document to compare to the object's suite
document.
org.apache.xmlbeans.XmlException
public edu.sdsc.inca.dataModel.util.SeriesConfig getSeriesConfig(int index)
index
- The index of the series config to return.
public edu.sdsc.inca.dataModel.util.SeriesConfig[] getSeriesConfigs()
public int getSeriesConfigCount()
public int[] getSeriesConfigCountByPattern(java.lang.String[] nicknamePatterns, java.lang.String[] namePatterns)
nicknamePatterns
- Patterns that should be matched against the
series nicknamenamePatterns
- Patterns that should be matched against the
series reporter name
public edu.sdsc.inca.dataModel.suite.SuiteDocument getSuiteDocument()
public void save(java.io.File saveTo) throws java.io.IOException
saveTo
- The file to save the suite to.
java.io.IOException
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |