public class SQLDumpExport extends AbstractExportTool
Modifier and Type | Class and Description |
---|---|
class |
SQLDumpExport.XTM2toSQL |
Modifier and Type | Field and Description |
---|---|
protected int |
associationCount |
protected int |
dataCount |
static int |
I_ASSOCIATION |
static int |
I_DATA |
static int |
I_MEMBER |
static int |
I_SUBJECTIDENTIFIER |
static int |
I_TOPIC |
static int |
I_TOPICTYPE |
static int |
I_VARIANT |
static int |
I_VARIANTSCOPE |
private static int |
idcounter |
protected int |
memberCount |
protected int |
subjectIdentifierCount |
protected int |
topicCount |
protected int |
topicTypeCount |
protected int |
variantCount |
protected int |
variantScopeCount |
protected int |
writeLimit |
Constructor and Description |
---|
SQLDumpExport() |
Modifier and Type | Method and Description |
---|---|
void |
appendFile(java.io.OutputStream out,
java.io.File in) |
void |
appendFile(java.io.OutputStream out,
java.io.InputStream in) |
void |
closeStream(int count,
java.io.PrintStream out) |
void |
closeStreams(java.io.PrintStream[] out) |
void |
convertXTM2ToSQL(java.io.InputStream in,
java.io.PrintStream outs,
TopicMapLogger logger) |
void |
disableForeignKeys(java.io.PrintStream out) |
void |
enableForeignKeys(java.io.PrintStream out) |
void |
execute(Wandora admin,
Context context)
Runs the tool.
|
java.lang.String |
getDescription()
AdminToolManager views tool descriptions while user browses available
tools and build user customizable GUI elements such as Tools menu.
|
java.lang.String |
getName()
Tools name represent the tool in UI unless the tool has been given
explicitly another GUI name.
|
static void |
main(java.lang.String[] args) |
protected static java.lang.String |
makeID(java.lang.String prefix) |
boolean |
requiresRefresh()
If any visible topic has been changed during tool execution GUI is
automatically refreshed.
|
java.lang.String |
sqlEscape(java.lang.String s) |
void |
writeAssociation(java.lang.String associationid,
java.lang.String typeid,
java.io.PrintStream out) |
void |
writeAssociation(java.lang.String associationid,
java.lang.String typeid,
java.io.PrintStream[] out) |
void |
writeData(java.lang.String topicid,
java.lang.String typeid,
java.lang.String versionid,
java.lang.String data,
java.io.PrintStream out) |
void |
writeData(java.lang.String topicid,
java.lang.String typeid,
java.lang.String versionid,
java.lang.String data,
java.io.PrintStream[] out) |
void |
writeMember(java.lang.String associationid,
java.lang.String playerid,
java.lang.String roleid,
java.io.PrintStream out) |
void |
writeMember(java.lang.String associationid,
java.lang.String playerid,
java.lang.String roleid,
java.io.PrintStream[] out) |
void |
writeSubjectIdentifier(java.lang.String topicid,
java.lang.String si,
java.io.PrintStream out) |
void |
writeSubjectIdentifier(java.lang.String topicid,
java.lang.String si,
java.io.PrintStream[] out) |
void |
writeTopic(java.lang.String topicid,
java.lang.String baseName,
Locator subjectLocator,
java.io.PrintStream out) |
void |
writeTopic(java.lang.String topicid,
java.lang.String baseName,
Locator subjectLocator,
java.io.PrintStream[] out) |
void |
writeTopic(java.lang.String topicid,
java.lang.String baseName,
java.lang.String subjectLocator,
java.io.PrintStream out) |
void |
writeTopic(java.lang.String topicid,
java.lang.String baseName,
java.lang.String subjectLocator,
java.io.PrintStream[] out) |
void |
writeTopicType(java.lang.String topicid,
java.lang.String typeid,
java.io.PrintStream out) |
void |
writeTopicType(java.lang.String topicid,
java.lang.String typeid,
java.io.PrintStream[] out) |
void |
writeVariant(java.lang.String variantid,
java.lang.String topicid,
java.lang.String value,
java.io.PrintStream out) |
void |
writeVariant(java.lang.String variantid,
java.lang.String topicid,
java.lang.String value,
java.io.PrintStream[] out) |
void |
writeVariantScope(java.lang.String variantid,
java.lang.String topicid,
java.io.PrintStream out) |
void |
writeVariantScope(java.lang.String variantid,
java.lang.String topicid,
java.io.PrintStream[] out) |
getIcon, getType, makeTopicMapWith, makeTopicMapWith
addUndoMarker, addUndoMarker, allowMultipleInvocations, clearAllThreads, clearThreads, clearThreads, clearToolLock, clearToolLock, clearToolLocks, configure, execute, execute, forceStop, forceStop, getContext, getCurrentLogger, getDefaultLogger, getHistory, getLastLogger, getState, getThreads, getThreads, getToolMenuItem, getToolMenuItem, getTopicName, hlog, initialize, interruptAllThreads, interruptThreads, interruptThreads, isConfigurable, isRunning, isRunning, lockLog, log, log, log, log, run, runInOwnThread, setContext, setDefaultLogger, setLogTitle, setProgress, setProgressMax, setState, setToolLogger, singleLog, singleLog, singleLog, solveContextTopicMap, solveNameForTopicMap, writeOptions
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
configure, execute, execute, getContext, getToolMenuItem, hlog, initialize, isConfigurable, isRunning, log, log, log, log, setContext, setToolLogger, writeOptions
forceStop, getHistory, getState, lockLog, setLogTitle, setProgress, setProgressMax, setState
public static final int I_TOPIC
public static final int I_ASSOCIATION
public static final int I_MEMBER
public static final int I_SUBJECTIDENTIFIER
public static final int I_TOPICTYPE
public static final int I_DATA
public static final int I_VARIANT
public static final int I_VARIANTSCOPE
private static int idcounter
protected int writeLimit
protected int topicCount
protected int topicTypeCount
protected int associationCount
protected int memberCount
protected int subjectIdentifierCount
protected int dataCount
protected int variantScopeCount
protected int variantCount
public java.lang.String getName()
AbstractWandoraTool
getName
in interface WandoraTool
getName
in class AbstractWandoraTool
public java.lang.String getDescription()
AbstractWandoraTool
getDescription
in interface WandoraTool
getDescription
in class AbstractWandoraTool
public boolean requiresRefresh()
AbstractWandoraTool
If any visible topic has been changed during tool execution GUI is automatically refreshed. If tool doesn't change topics but GUI still requires refresh, tool should override this method and return true.
For example tools that alter the GUI but change no topics should return true.
requiresRefresh
in interface WandoraTool
requiresRefresh
in class AbstractWandoraTool
protected static java.lang.String makeID(java.lang.String prefix)
public void execute(Wandora admin, Context context) throws TopicMapException
WandoraTool
TopicMapException
public void appendFile(java.io.OutputStream out, java.io.File in) throws java.io.IOException
java.io.IOException
public void appendFile(java.io.OutputStream out, java.io.InputStream in) throws java.io.IOException
java.io.IOException
public java.lang.String sqlEscape(java.lang.String s)
public void disableForeignKeys(java.io.PrintStream out) throws java.io.IOException
java.io.IOException
public void enableForeignKeys(java.io.PrintStream out) throws java.io.IOException
java.io.IOException
public void closeStream(int count, java.io.PrintStream out) throws java.io.IOException
java.io.IOException
public void closeStreams(java.io.PrintStream[] out) throws java.io.IOException
java.io.IOException
public void writeTopic(java.lang.String topicid, java.lang.String baseName, Locator subjectLocator, java.io.PrintStream[] out) throws java.io.IOException
java.io.IOException
public void writeTopic(java.lang.String topicid, java.lang.String baseName, java.lang.String subjectLocator, java.io.PrintStream[] out) throws java.io.IOException
java.io.IOException
public void writeTopic(java.lang.String topicid, java.lang.String baseName, Locator subjectLocator, java.io.PrintStream out) throws java.io.IOException
java.io.IOException
public void writeTopic(java.lang.String topicid, java.lang.String baseName, java.lang.String subjectLocator, java.io.PrintStream out) throws java.io.IOException
java.io.IOException
public void writeTopicType(java.lang.String topicid, java.lang.String typeid, java.io.PrintStream[] out) throws java.io.IOException
java.io.IOException
public void writeTopicType(java.lang.String topicid, java.lang.String typeid, java.io.PrintStream out) throws java.io.IOException
java.io.IOException
public void writeAssociation(java.lang.String associationid, java.lang.String typeid, java.io.PrintStream[] out) throws java.io.IOException
java.io.IOException
public void writeAssociation(java.lang.String associationid, java.lang.String typeid, java.io.PrintStream out) throws java.io.IOException
java.io.IOException
public void writeMember(java.lang.String associationid, java.lang.String playerid, java.lang.String roleid, java.io.PrintStream[] out) throws java.io.IOException
java.io.IOException
public void writeMember(java.lang.String associationid, java.lang.String playerid, java.lang.String roleid, java.io.PrintStream out) throws java.io.IOException
java.io.IOException
public void writeSubjectIdentifier(java.lang.String topicid, java.lang.String si, java.io.PrintStream[] out) throws java.io.IOException
java.io.IOException
public void writeSubjectIdentifier(java.lang.String topicid, java.lang.String si, java.io.PrintStream out) throws java.io.IOException
java.io.IOException
public void writeData(java.lang.String topicid, java.lang.String typeid, java.lang.String versionid, java.lang.String data, java.io.PrintStream[] out) throws java.io.IOException
java.io.IOException
public void writeData(java.lang.String topicid, java.lang.String typeid, java.lang.String versionid, java.lang.String data, java.io.PrintStream out) throws java.io.IOException
java.io.IOException
public void writeVariantScope(java.lang.String variantid, java.lang.String topicid, java.io.PrintStream[] out) throws java.io.IOException
java.io.IOException
public void writeVariantScope(java.lang.String variantid, java.lang.String topicid, java.io.PrintStream out) throws java.io.IOException
java.io.IOException
public void writeVariant(java.lang.String variantid, java.lang.String topicid, java.lang.String value, java.io.PrintStream[] out) throws java.io.IOException
java.io.IOException
public void writeVariant(java.lang.String variantid, java.lang.String topicid, java.lang.String value, java.io.PrintStream out) throws java.io.IOException
java.io.IOException
public void convertXTM2ToSQL(java.io.InputStream in, java.io.PrintStream outs, TopicMapLogger logger)
public static void main(java.lang.String[] args) throws java.lang.Exception
java.lang.Exception
Copyright 2004-2015 Wandora Team