|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.languagecomputer.client.WebClient
com.languagecomputer.client.BatchWebClient
public class BatchWebClient
WebClient For batch processing Files.
| Field Summary |
|---|
| Fields inherited from class com.languagecomputer.client.WebClient |
|---|
ANNOTATION_META_SERVICE, ATTRIBUTE_SERVICE, COREFERENCE_SERVICE, DOCUMENT_SERVICE, ENTITY_SERVICE, EVENT_SERVICE, INDEX_SERVICE, SPATIAL_SERVICE, TEMPORAL_SERVICE |
| Constructor Summary | |
|---|---|
BatchWebClient(String host,
List<String> services)
Creates a new BatchWebClient with the services
located on the given host. |
|
| Method Summary | |
|---|---|
protected static List<String> |
getFiles(String path)
Recursively constructs a list of all files within a directory. |
String |
getHost(String service)
Returns the default host (localhost). |
static void |
main(String[] args)
Client driver, called from command line. |
protected Document |
process(String file)
Processes the given file as either a URL or
File. |
void |
runBatch(List<String> filesToProcess)
Runs the given files through the chosen services. |
void |
setIndexPath(String indexPath)
Sets the index path for the IndexService. |
| Methods inherited from class com.languagecomputer.client.WebClient |
|---|
getAnnotationMetaService, getAttributeService, getConnectTimeout, getCoreferenceService, getDocumentService, getEntityService, getEventService, getIndexService, getPort, getReceiveTimeout, getSpatialService, getTemporalService, getURL, print, setSessionID |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public BatchWebClient(String host,
List<String> services)
BatchWebClient with the services
located on the given host.
| Method Detail |
|---|
public static void main(String[] args)
throws Exception
args - Command line arguments.
Exception - In case of service call failure.protected static List<String> getFiles(String path)
public String getHost(String service)
getHost in class WebClientpublic void setIndexPath(String indexPath)
IndexService.
public void runBatch(List<String> filesToProcess)
throws Exception
Exception
protected Document process(String file)
throws IOException
URL or
File.
IOException
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||