OSID Logo
OSID Specifications
filing package
Version 3.1.0
Interfaceosid.filing.DirectoryQuery
Implementsosid.OsidCatalogQuery
osid.filing.DirectoryEntryQuery
Used Byosid.filing.DirectoryEntryQuery
osid.filing.DirectoryQuerySession
osid.filing.DirectorySearchSession
Description

This is the query for searching directories. Each method match request produces an AND term while multiple invocations of a method produces a nested OR.

An example to find directories whose name is "Library".

DirectoryQuery query = session.getDirectoryQuery();
query.matchName("Library", wordStringMatchType, true);

DirectoryList list = session.getDirectoriesByQuery(query);
                
MethodmatchFileName
Description

Matches directories that contain the specified file name.

Parametersstringname a file name
osid.type.TypestringMatchType the string match type
booleanmatch true for a positive match, false for a negative match
ErrorsINVALID_ARGUMENT name not of stringMatchType
NULL_ARGUMENT name or stringMatchType is null
UNSUPPORTED supportsStringMatchType(stringMatchType) is false
Compliancemandatory This method must be implemented.
MethodclearFileNameTerms
Description

Clears all file name terms.

Compliancemandatory This method must be implemented.
MethodsupportsFileQuery
Description

Tests if a FileQuery is available.

Returnboolean true if a file query is available, false otherwise
Compliancemandatory This method must be implemented.
MethodgetFileQuery
Description

Gets the query for a file contained within the directory.

Parametersbooleanmatch true for a positive match, false for a negative match
Returnosid.filing.FileQuery the directory query
ErrorsUNIMPLEMENTED supportsFileQuery() is false
Complianceoptional This method must be implemented if supportsFileQuery() is true.
MethodmatchAnyFile
Description

Matches directories with any file.

Parametersbooleanmatch true to match directories with any file,, false to match directories with no file.
Compliancemandatory This method must be implemented.
MethodclearFileTerms
Description

Clears all file terms.

Compliancemandatory This method must be implemented.
MethodgetDirectoryQueryRecord
Description

Gets the directory query record corresponding to the given Directory record Type. Multiple record retrievals produce a nested boolean OR term.

Parametersosid.type.TypedirectoryRecordType a directory record type
Returnosid.filing.records.DirectoryQueryRecord the directory query record
ErrorsNULL_ARGUMENT directoryRecordType is null
OPERATION_FAILED unable to complete request
UNSUPPORTED hasRecordType(directoryRecordType) is false
Compliancemandatory This method must be implemented.