OSID Logo
OSID Specifications
filing package
Version 3.1.0
Interfaceosid.filing.DirectorySearchResults
Implementsosid.OsidSearchResults
Used Byosid.filing.DirectorySearchSession
Description

This interface provides a means to capture results of a search. This example gets a result set from a keyword match.

An example to find directories whose path contains "System" from a resulting search of directories whose name is "Library", sorted by the path name.

DirectoryQuery query = session.getDirectoryQuery();
query.addNameMatch("Library", wordStringMatchType, true);
DirectorySearch search = session.getDirectorySearch();
DirectorySearchResults results = session.getDirectoriesBySearch(query, search);

query = session.getDirectoryQuery();
query.addNameMatch("System", wordStringMatchType, true);
search = session.getDirectorySearch();
search.searchWithinDirectoryResults(results);
DirectorySearchOrder order = session.getDirectorySearchOrder();
order.orderByPath();
search.orderDirectoryResults(order);

results = session.getDirectoriesBySearch(query, search);
DirectoryList directories = results.getDirectories();
                
MethodgetDirectories
Description

Gets the directory list resulting from a search.

Returnosid.filing.DirectoryList the directory list
ErrorsILLEGAL_STATE list already retrieved
Compliancemandatory This method must be implemented.
MethodgetDirectoryQueryInspector
Description

Gets the inspector for the query to examine the terms used in the search.

Returnosid.filing.DirectoryQueryInspector the query inspector
Compliancemandatory This method must be implemented.
MethodgetDirectorySearchResultsRecord
Description

Gets the directory search results record corresponding to the given directory search record Type .This method is used to retrieve an object implementing the requested record.

Parametersosid.type.TypedirectorySearchRecordType a directory search record type
Returnosid.filing.records.DirectorySearchResultsRecord the directory search results record
ErrorsNULL_ARGUMENT directorySearchRecordType is null
OPERATION_FAILED unable to complete request
UNSUPPORTED hasRecordType(directorySearchRecordType) is false
Compliancemandatory This method must be implemented.