public class XmlDataManager extends BasicDataManager implements DataManager
Modifier and Type | Field and Description |
---|---|
(package private) java.lang.String |
encoding |
(package private) java.lang.String |
fileName |
(package private) java.lang.String |
header |
static java.lang.String |
OUTPUT_FILE |
static java.lang.String |
XML_ENCODING |
static java.lang.String |
XML_HEADER_VALUE |
cacher, currentCacheBlock, currentDataNodes, eventEngine, mergeable, root, rootLock, schema, updateable
Constructor and Description |
---|
XmlDataManager(java.lang.String filename) |
Modifier and Type | Method and Description |
---|---|
void |
addSchema(java.lang.String name,
java.lang.String[] childValues,
java.lang.String[] attributes) |
void |
buildSchemas()
Builds the schemas from a database.
|
boolean |
checkDataNode(java.lang.String schema)
verifies that the data is ready to be inserted.
|
void |
close()
close should be called when you are done with the DataManager
|
boolean |
commit(java.lang.String schema)
commits the row of data corresponding to the schema, so the next time addData is called it will be in a new row.
|
boolean |
flush()
writes the current data to the Database and clears out all the data.
|
java.lang.String |
getEncoding() |
java.lang.String |
getFileName() |
java.lang.String |
getHeader() |
XmlDataWriter |
getNewDataWriter() |
boolean |
importSchemas(java.lang.String file) |
void |
setEncoding(java.lang.String encoding) |
void |
setFileName(java.lang.String fileName) |
void |
setHeader(java.lang.String header) |
addData, addData, addData, addDataAssertion, addDataAssertion, addEventListener, addEventListener, addEventListenerWithPriority, addSchemalessEventListener, addSchemalessEventListenerWithPriority, cacheContent, cacheContent, cacheContent, cacheContext, cacheScrapeableFile, cacheScrapeableFile, catData, catData, clearAllData, clearData, connectTree, enablePageAndContextCaching, generateUID, getCacheReaderWriter, getColumns, getCurrentDataNode, getDatabaseSchema, getNewDataNode, getRoot, getSchema, hashData, hashData, hasSchema, removeEventListener, removeSchemalessEventListener, rollback, setDatabaseSchema, setMergeEnabled, setUpdateEnabled, write
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
addData, addData, addData, addEventListener, addEventListenerWithPriority, clearAllData, clearData, getColumns, getCurrentDataNode, getDatabaseSchema, getNewDataNode, getRoot, getSchema, hasSchema, setDatabaseSchema
java.lang.String fileName
java.lang.String encoding
java.lang.String header
public static final java.lang.String OUTPUT_FILE
public static final java.lang.String XML_ENCODING
public static final java.lang.String XML_HEADER_VALUE
@NotNull public XmlDataWriter getNewDataWriter()
getNewDataWriter
in class BasicDataManager
public void addSchema(java.lang.String name, @Nullable java.lang.String[] childValues, @Nullable java.lang.String[] attributes)
public java.lang.String getFileName()
public void setFileName(java.lang.String fileName)
public java.lang.String getEncoding()
public void setEncoding(java.lang.String encoding)
public java.lang.String getHeader()
public void setHeader(java.lang.String header)
public void close()
DataManager
close
in interface DataManager
close
in class BasicDataManager
public void buildSchemas()
DataManager
buildSchemas
in interface DataManager
buildSchemas
in class BasicDataManager
public boolean flush()
DataManager
flush
in interface DataManager
flush
in class BasicDataManager
public boolean commit(java.lang.String schema)
BasicDataManager
commit
in interface DataManager
commit
in class BasicDataManager
schema
- The name of the schema for which to commit datapublic boolean checkDataNode(java.lang.String schema)
BasicDataManager
checkDataNode
in interface DataManager
checkDataNode
in class BasicDataManager
schema
- The name of the schema for which to check the current nodepublic boolean importSchemas(java.lang.String file)
importSchemas
in class BasicDataManager