|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.exist.client.InteractiveClient
Command-line client based on the XML:DB API.
| Nested Class Summary | |
static class |
InteractiveClient.ProgressObserver
|
| Field Summary | |
protected static int[] |
colSizes
|
protected java.util.TreeSet |
completitions
|
protected static java.lang.String |
configuration
|
static java.lang.String |
CONFIGURATION
|
protected Collection |
current
|
protected static java.util.Properties |
defaultProps
|
protected static java.lang.String |
driver
|
static java.lang.String |
DRIVER
|
protected static java.lang.String |
EDIT_CMD
|
protected static java.lang.String |
ENCODING
|
protected int |
filesCount
number of files of a recursive store |
protected ClientFrame |
frame
|
protected java.io.File |
historyFile
|
protected int |
maxResults
|
protected java.util.HashMap |
namespaceMappings
|
protected int |
nextInSet
|
protected static int |
PARALLEL_THREADS
|
protected static java.lang.String |
PASS
|
static java.lang.String |
PASSWORD
|
protected java.lang.String |
path
|
protected java.util.Properties |
properties
|
protected java.util.LinkedList |
queryHistory
|
protected java.io.File |
queryHistoryFile
|
protected boolean |
quiet
|
protected boolean |
recurseDirs
default recursive, maybe override by client.properties |
protected java.lang.String[] |
resources
|
protected ResourceSet |
result
|
protected boolean |
startGUI
|
protected long |
totalLength
total length of a recursive store |
protected java.io.Writer |
traceWriter
|
static java.lang.String |
URI
|
protected static java.lang.String |
URI_DEFAULT
|
static java.lang.String |
USER
|
protected static java.lang.String |
USER_DEFAULT
|
protected boolean |
verbose
|
| Constructor Summary | |
InteractiveClient()
|
|
| Method Summary | |
protected void |
addToHistory(java.lang.String query)
|
protected void |
connect()
Register XML:DB driver and retrieve root collection. |
protected void |
displayHelp()
Display help on commands |
protected Collection |
getCollection()
Returns the current collection. |
protected Collection |
getCollection(java.lang.String path)
|
protected CommandlineOptions |
getCommandlineOptions(java.lang.String[] args,
java.util.Properties props)
Parse command line options, store into dedicated object |
static java.lang.String |
getExceptionMessage(java.lang.Throwable e)
|
protected void |
getResources()
Get list of resources contained in collection. |
static void |
main(java.lang.String[] args)
The main program for the InteractiveClient class. |
protected void |
more(java.lang.String str)
Display document on screen, by 24 lines. |
protected boolean |
parse(java.io.File[] files,
org.exist.client.UploadDialog upload)
Method called by the store Dialog |
protected boolean |
parse(java.lang.String fileName)
stores given Resource |
void |
printNotice()
|
protected boolean |
process(java.lang.String line)
In interactive mode, process a line entered by the user. |
void |
readlineInputLoop(java.lang.String home)
|
protected void |
readQueryHistory()
|
protected void |
reloadCollection()
|
protected Resource |
retrieve(java.lang.String resource)
|
protected Resource |
retrieve(java.lang.String resource,
java.lang.String indent)
|
void |
run(java.lang.String[] args)
Main processing method for the InteractiveClient object |
protected void |
setProperties()
|
protected void |
shutdown(boolean force)
|
protected void |
writeQueryHistory()
|
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
public static final java.lang.String USER
public static final java.lang.String PASSWORD
public static final java.lang.String URI
public static final java.lang.String CONFIGURATION
public static final java.lang.String DRIVER
protected static java.lang.String EDIT_CMD
protected static java.lang.String ENCODING
protected static java.lang.String PASS
protected static java.lang.String URI_DEFAULT
protected static java.lang.String USER_DEFAULT
protected static int PARALLEL_THREADS
protected static java.util.Properties defaultProps
protected static final int[] colSizes
protected static java.lang.String driver
protected static java.lang.String configuration
protected java.util.TreeSet completitions
protected java.util.LinkedList queryHistory
protected java.io.File queryHistoryFile
protected java.io.File historyFile
protected Collection current
protected int nextInSet
protected int maxResults
protected java.lang.String path
protected java.util.Properties properties
protected java.lang.String[] resources
protected ResourceSet result
protected java.util.HashMap namespaceMappings
protected int filesCount
protected long totalLength
protected boolean quiet
protected boolean verbose
protected boolean recurseDirs
protected boolean startGUI
protected java.io.Writer traceWriter
protected ClientFrame frame
| Constructor Detail |
public InteractiveClient()
| Method Detail |
protected void displayHelp()
public static void main(java.lang.String[] args)
args - The command line arguments
protected void connect()
throws java.lang.Exception
java.lang.Exception - Description of the Exceptionprotected Collection getCollection()
protected void reloadCollection()
throws XMLDBException
XMLDBException
protected void setProperties()
throws XMLDBException
XMLDBException
protected void getResources()
throws XMLDBException
XMLDBException - Description of the Exceptionprotected void more(java.lang.String str)
str - string containing the document.protected boolean process(java.lang.String line)
line - the line entered
protected final Resource retrieve(java.lang.String resource)
throws XMLDBException
XMLDBException
protected final Resource retrieve(java.lang.String resource,
java.lang.String indent)
throws XMLDBException
XMLDBException
protected boolean parse(java.lang.String fileName)
throws XMLDBException
fileName - simple file or directory
XMLDBException
protected boolean parse(java.io.File[] files,
org.exist.client.UploadDialog upload)
throws XMLDBException
files - : selectedupload - : GUI object
XMLDBException
protected Collection getCollection(java.lang.String path)
throws XMLDBException
XMLDBException
protected CommandlineOptions getCommandlineOptions(java.lang.String[] args,
java.util.Properties props)
args - Argumentsprops - Client configuration
public void run(java.lang.String[] args)
throws java.lang.Exception
args - arguments from main()
java.lang.Exceptionpublic static final java.lang.String getExceptionMessage(java.lang.Throwable e)
protected void readQueryHistory()
protected void addToHistory(java.lang.String query)
protected void writeQueryHistory()
public void readlineInputLoop(java.lang.String home)
protected final void shutdown(boolean force)
public void printNotice()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||