org.dspace.browse |
Provides classes and mehtods for browsing Items in DSpace by whatever
is specified in the configuration. The standard method by which you
would perform a browse is as follows:
- Create a BrowserScope object. This object holds all of the parameters
of your browse request
- Pass the BrowserScope object into the BrowseEngine object.
This object should be invoked through either the browse() method or the browseMini() method
- The BrowseEngine will pass back a BrowseInfo object which contains all the relevant details of your request
Browses only return archived Items; other Items (eg, those
in the workflow system) are ignored.
Using the Browse API
An example use of the Browse API is shown below:
// Create or obtain a context object
Context context = new Context();
// Create a BrowseScope object within the context
BrowserScope scope = new BrowserScope(context);
// The browse is limited to the test collection
Collection test = Collection.find(context, someID);
scope.setBrowseContainer(test);
// Set the focus
scope.setFocus("Test Title");
// A maximum of 30 items will be returned
scope.setResultsPerPage(30);
// set ordering to DESC
scope.setOrder("DESC");
// now execute the browse
BrowseEngine be = new BrowseEngine();
BrowseInfo results = be.browse(scope);
In this case, the results might be Items with titles like:
Tehran, City of the Ages
Ten Little Indians
Tenchi Universe
Tension
Tennessee Williams
Test Title (the focus)
Thematic Alignment
Thesis and Antithesis
...
Browse Indexes
The Browse API uses database tables to index Items based on the supplied
configuration. When an Item is added to DSpace, modified or removed via the
Content Management API, the
indexes are automatically updated.
To rebuild the database tables for the browse (on configuration change), or
to re-index just the contents of the existing tables, use the following
commands from IndexBrowse:
A complete rebuild of the database and the indices:
[dspace]/dsrun org.dspace.browse.IndexBrowse -f -r
A complete re-index of the archive contents:
[dspace]/dsrun org.dspace.browse.IndexBrowse -i
|
Java Source File Name | Type | Comment |
BrowseConsumer.java | Class | Class for updating browse system from content events.
Prototype: only Item events recognized.
XXX FIXME NOTE: The Browse Consumer is INCOMPLETE because the
deletion of an Item CANNOT be implemented as an event consumer:
When an Item is deleted, the browse tables must be updated
immediately, within the same transaction, to maintain referential
consistency. |
BrowseCreateDAO.java | Interface | Interface for any class wishing to provide a browse storage later. |
BrowseCreateDAOOracle.java | Class | This class implements the BrowseCreateDAO interface for the Oracle database
as associated with the default DSpace installation. |
BrowseCreateDAOPostgres.java | Class | This class implements the BrowseCreateDAO interface for the PostgreSQL database
as associated with the default DSpace installation. |
BrowseDAO.java | Interface | Interface for any class wishing to interact with the Browse storage layer for
Read Only operations. |
BrowseDAOFactory.java | Class | |
BrowseDAOOracle.java | Class | This class is the Oracle driver class for reading information from the Browse
tables. |
BrowseDAOPostgres.java | Class | This class is the PostgreSQL driver class for reading information from the
Browse tables. |
BrowseDAOUtils.java | Interface | Utility class for retrieving the size of the columns to be used in the browse tables,
and applying truncation to the strings that will be inserted into the tables.
Can be configured in dspace.cfg, with the following entries:
webui.browse.value_columns.max
- the maximum number of characters in 'value' columns
(0 is unlimited)
webui.browse.sort_columns.max
- the maximum number of characters in 'sort' columns
(0 is unlimited)
webui.browse.value_columns.omission_mark
- a string to append to truncated values that will be entered into
the value columns (ie. |
BrowseDAOUtilsDefault.java | Class | Utility class for retrieving the size of the columns to be used in the browse tables,
and applying truncation to the strings that will be inserted into the tables.
Can be configured in dspace.cfg, with the following entries:
webui.browse.value_columns.max
- the maximum number of characters in 'value' columns
(0 is unlimited)
webui.browse.sort_columns.max
- the maximum number of characters in 'sort' columns
(0 is unlimited)
webui.browse.value_columns.omission_mark
- a string to append to truncated values that will be entered into
the value columns (ie. |
BrowseDAOUtilsOracle.java | Class | Utility class for retrieving the size of the columns to be used in the browse tables,
and applying truncation to the strings that will be inserted into the tables.
Can be configured in dspace.cfg, with the following entries:
webui.browse.value_columns.max
- the maximum number of characters in 'value' columns
(0 is unlimited)
webui.browse.sort_columns.max
- the maximum number of characters in 'sort' columns
(0 is unlimited)
webui.browse.value_columns.omission_mark
- a string to append to truncated values that will be entered into
the value columns (ie. |
BrowseDAOUtilsPostgres.java | Class | Utility class for retrieving the size of the columns to be used in the browse tables,
and applying truncation to the strings that will be inserted into the tables.
Can be configured in dspace.cfg, with the following entries:
webui.browse.value_columns.max
- the maximum number of characters in 'value' columns
(0 is unlimited)
webui.browse.sort_columns.max
- the maximum number of characters in 'sort' columns
(0 is unlimited)
webui.browse.value_columns.omission_mark
- a string to append to truncated values that will be entered into
the value columns (ie. |
BrowseEngine.java | Class | This class does most of the actual grunt work of preparing a browse
result. |
BrowseException.java | Class | |
BrowseIndex.java | Class | This class holds all the information about a specifically configured
BrowseIndex. |
BrowseInfo.java | Class | The results of a Browse, including all the contextual information about
the query, as well as the results and associated information to create
pagable navigation. |
BrowseItem.java | Class | Entity class to represent an item that is being used to generate Browse
results. |
BrowseItemDAO.java | Interface | |
BrowseItemDAOOracle.java | Class | |
BrowseItemDAOPostgres.java | Class | |
BrowseOutput.java | Class | Utility class to provide a wrapper for the various output possibilities from
the IndexBrowse class. |
BrowserScope.java | Class | A class which represents the initial request to the browse system. |
CrossLinks.java | Class | Class to represent the configuration of the cross-linking between browse
pages (for example, between the author name in one full listing to the
author's list of publications). |
IndexBrowse.java | Class | Tool to create Browse indexes. |
ItemCountDAO.java | Interface | |
ItemCountDAOFactory.java | Class | |
ItemCountDAOOracle.java | Class | |
ItemCountDAOPostgres.java | Class | |
ItemCounter.java | Class | This class provides a standard interface to all item counting
operations for communities and collections. |
ItemCountException.java | Class | |
ItemListConfig.java | Class | |
LocaleOrderingFilter.java | Class | Makes a sort string that is Locale dependent. |