|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.dspace.browse.IndexBrowse
public class IndexBrowse
Tool to create Browse indexes. This class is used from the command line to create and destroy the browse indices from configuration, and also from within the application to add and remove content from those tables. To see a full definition of the usage of this class just run it without any arguments, and you will get the help message.
| Constructor Summary | |
|---|---|
IndexBrowse()
Construct a new index browse. |
|
IndexBrowse(Context context)
Create a new IndexBrowse object. |
|
| Method Summary | |
|---|---|
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 |
itemAdded(Item item)
Deprecated. |
boolean |
itemChanged(Item item)
Deprecated. |
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()
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public IndexBrowse()
throws SQLException,
BrowseException
new IndexBrowse(context);
with your desired context (when using with the application)
SQLException
BrowseException
public IndexBrowse(Context context)
throws SQLException,
BrowseException
context -
SQLException
BrowseException| Method Detail |
|---|
public 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 index
BrowseException
public boolean itemAdded(Item item)
throws BrowseException
item -
BrowseException
public boolean itemChanged(Item item)
throws BrowseException
item -
BrowseException
public boolean itemRemoved(Item item)
throws BrowseException
item - the item to be removed
BrowseException
public boolean itemRemoved(int itemID)
throws BrowseException
BrowseException
public static void main(String[] argv)
throws SQLException,
BrowseException,
org.apache.commons.cli.ParseException
argv - Command-line arguments
SQLException
BrowseException
org.apache.commons.cli.ParseException
public void clearDatabase()
throws BrowseException
BrowseException
public void initBrowse()
throws SQLException,
BrowseException
SQLException
BrowseException
public String[] interpretField(String mfield,
String init)
throws IOException
mfield - the string representation of the metadatainit - the default value of the array elements
IOException
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||