org.fcrepo.server.search
Interface FieldSearch

All Known Implementing Classes:
FieldSearchSQLImpl, FieldSearchSQLModule

public interface FieldSearch

Provides a simple field-based search service across all objects in the repository.

Key object metadata and dublin core fields are searchable from via implementations of this interface.

Key fields include:

pid, label, state, ownerId, cDate, mDate, dcmDate

Dublin core fields include:

title, creator, subject, description, publisher, contributor, date, format, identifier, source, language, relation, coverage, rights

Author:
Chris Wilper

Method Summary
 boolean delete(String pid)
          Remove an object from the search indexes.
 FieldSearchResult findObjects(String[] resultFields, int maxResults, FieldSearchQuery query)
          Search across specific fields and return the desired fields.
 FieldSearchResult resumeFindObjects(String sessionToken)
          Resume an in-progress search across specific fields and return the desired fields.
 void update(DOReader reader)
          Update the search indexes with information from the provided DOReader.
 

Method Detail

update

void update(DOReader reader)
            throws ServerException
Update the search indexes with information from the provided DOReader.

Parameters:
reader - the DOReader containing all the field information for the object
Throws:
ServerException - if anything went wrong

delete

boolean delete(String pid)
               throws ServerException
Remove an object from the search indexes.

Parameters:
pid - the unique id of the object whose info should be removed
Returns:
true if object successfully removed; false otherwise.
Throws:
ServerException - if anything went wrong

findObjects

FieldSearchResult findObjects(String[] resultFields,
                              int maxResults,
                              FieldSearchQuery query)
                              throws ServerException
Search across specific fields and return the desired fields.

Parameters:
resultFields - the desired fields
maxResults - the maximum number of results the client wants
query - the query
Returns:
FieldSearchResult the results
Throws:
ServerException - if anything went wrong

resumeFindObjects

FieldSearchResult resumeFindObjects(String sessionToken)
                                    throws ServerException
Resume an in-progress search across specific fields and return the desired fields.

Parameters:
sessionToken - the token of the session in which the remaining results can be found
Returns:
FieldSearchResult the results
Throws:
ServerException - if anything went wrong


Copyright © 2012 DuraSpace. All Rights Reserved.