public class IndexBrowse extends Object
| Constructor and Description |
|---|
IndexBrowse()
Construct a new index browse.
|
IndexBrowse(Context context)
Create a new IndexBrowse object.
|
| Modifier and Type | Method and Description |
|---|---|
void |
clearDatabase()
delete all the existing browse tables
|
boolean |
delete() |
boolean |
execute() |
String |
getOutFile() |
int |
getStart() |
void |
indexItem(Item item)
Index the given item
|
void |
initBrowse()
index everything
|
String[] |
interpretField(String mfield,
String init)
Take a string representation of a metadata field, and return it as an array.
|
boolean |
isFileOut() |
boolean |
isVerbose() |
boolean |
itemRemoved(int itemID) |
boolean |
itemRemoved(Item item)
remove all the indices for the given item
|
static void |
main(String[] argv)
Creates Browse indexes, destroying the old ones.
|
boolean |
rebuild() |
void |
setDelete(boolean bool) |
void |
setExecute(boolean bool) |
void |
setFileOut(boolean bool) |
void |
setOutFile(String file) |
void |
setRebuild(boolean bool) |
void |
setStart(int start) |
void |
setStdOut(boolean bool) |
void |
setVerbose(boolean verbose) |
boolean |
toStdOut() |
public IndexBrowse()
throws SQLException,
BrowseException
new IndexBrowse(context);
with your desired context (when using with the application)SQLExceptionBrowseExceptionpublic IndexBrowse(Context context) throws SQLException, BrowseException
context - SQLExceptionBrowseExceptionpublic boolean isVerbose()
public void setVerbose(boolean verbose)
verbose - The verbose to set.public boolean rebuild()
public void setRebuild(boolean bool)
bool - whether to rebuild the database or notpublic boolean delete()
public void setDelete(boolean bool)
bool - whetehr to delete the database or notpublic void setStart(int start)
start - the index to start working up frompublic int getStart()
public void setExecute(boolean bool)
bool - whether to execute the database commands or notpublic boolean execute()
public void setFileOut(boolean bool)
bool - whether to use an output filepublic boolean isFileOut()
public void setStdOut(boolean bool)
bool - whether to write to standard outpublic boolean toStdOut()
public void setOutFile(String file)
file - the name of the output filepublic String getOutFile()
public void indexItem(Item item) throws BrowseException
item - the item to indexBrowseExceptionpublic boolean itemRemoved(Item item) throws BrowseException
item - the item to be removedBrowseExceptionpublic boolean itemRemoved(int itemID)
throws BrowseException
BrowseExceptionpublic static void main(String[] argv) throws SQLException, BrowseException, org.apache.commons.cli.ParseException
argv - Command-line argumentsSQLExceptionBrowseExceptionorg.apache.commons.cli.ParseExceptionpublic void clearDatabase()
throws BrowseException
BrowseExceptionpublic void initBrowse()
throws SQLException,
BrowseException
SQLExceptionBrowseExceptionpublic String[] interpretField(String mfield, String init) throws IOException
mfield - the string representation of the metadatainit - the default value of the array elementsIOExceptionCopyright © 2015 DuraSpace. All Rights Reserved.