Interface DirectionQuery

All Superinterfaces:
Extensible, OsidBrowsableQuery, OsidExtensibleQuery, OsidIdentifiableQuery, OsidObjectQuery, OsidQuery, OsidSubjugateableQuery, Suppliable

public interface DirectionQuery extends OsidObjectQuery, OsidSubjugateableQuery

This is the query for searching directions. Each method match specifies an AND term while multiple invocations of the same method produce a nested OR .

  • Method Details

    • matchRecipeId

      void matchRecipeId(Id recipeId, boolean match)
      Sets the recipe Id for this query.
      Parameters:
      recipeId - the recipe Id
      match - true for a positive match, false for a negative match
      Throws:
      NullArgumentException - recipeId is null
      Compliance:
      mandatory - This method must be implemented.
    • clearRecipeIdTerms

      void clearRecipeIdTerms()
      Clears the recipe Id query terms.
      Compliance:
      mandatory - This method must be implemented.
    • supportsRecipeQuery

      boolean supportsRecipeQuery()
      Tests if a RecipeQuery is available.
      Returns:
      true if a recipe query is available, false otherwise
      Compliance:
      mandatory - This method must be implemented.
    • getRecipeQuery

      RecipeQuery getRecipeQuery()
      Gets the query for a recipe. Multiple retrievals produce a nested OR term.
      Returns:
      the recipe query
      Throws:
      UnimplementedException - supportsRecipeQuery() is false
      Compliance:
      optional - This method must be implemented if {@code supportsRecipeQuery()} is {@code true} .
    • clearRecipeTerms

      void clearRecipeTerms()
      Clears the recipe query terms.
      Compliance:
      mandatory - This method must be implemented.
    • matchProcedureId

      void matchProcedureId(Id procedureId, boolean match)
      Sets the procedure Id for this query.
      Parameters:
      procedureId - the procedure Id
      match - true for a positive match, false for a negative match
      Throws:
      NullArgumentException - procedureId is null
      Compliance:
      mandatory - This method must be implemented.
    • clearProcedureIdTerms

      void clearProcedureIdTerms()
      Clears the procedure Id query terms.
      Compliance:
      mandatory - This method must be implemented.
    • supportsProcedureQuery

      boolean supportsProcedureQuery()
      Tests if a ProcedureQuery is available.
      Returns:
      true if a procedure query is available, false otherwise
      Compliance:
      mandatory - This method must be implemented.
    • getProcedureQuery

      ProcedureQuery getProcedureQuery()
      Gets the query for a procedure. Multiple retrievals produce a nested OR term.
      Returns:
      the procedure query
      Throws:
      UnimplementedException - supportsProcedureQuery() is false
      Compliance:
      optional - This method must be implemented if {@code supportsProcedureQuery()} is {@code true} .
    • matchAnyProcedure

      void matchAnyProcedure(boolean match)
      Matches directions with any procedure.
      Parameters:
      match - true to match directions with any procedure, false to match directions with no procedures
      Compliance:
      mandatory - This method must be implemented.
    • clearProcedureTerms

      void clearProcedureTerms()
      Clears the procedure query terms.
      Compliance:
      mandatory - This method must be implemented.
    • matchIngredientId

      void matchIngredientId(Id ingredientId, boolean match)
      Sets the ingredient Id .
      Parameters:
      ingredientId - the ingredient Id
      match - true for a positive match, false for a negative match
      Throws:
      NullArgumentException - ingredientId is null
      Compliance:
      mandatory - This method must be implemented.
    • clearIngredientIdTerms

      void clearIngredientIdTerms()
      Clears the ingredient Id query terms.
      Compliance:
      mandatory - This method must be implemented.
    • supportsIngredientQuery

      boolean supportsIngredientQuery()
      Tests if an IngredientkQuery is available.
      Returns:
      true if an ingredient query is available, false otherwise
      Compliance:
      mandatory - This method must be implemented.
    • getIngredientQuery

      IngredientQuery getIngredientQuery()
      Gets the query for an ingredient. Multiple retrievals produce a nested OR term.
      Returns:
      the ingredient query
      Throws:
      UnimplementedException - supportsIngredientItemQuery() is false
      Compliance:
      optional - This method must be implemented if {@code supportsIngredientQuery()} is {@code true} .
    • matchAnyIngredient

      void matchAnyIngredient(boolean match)
      Matches directions with any ingredient.
      Parameters:
      match - true to match directions with any ingredient, false to match directions with no ingredients
      Compliance:
      mandatory - This method must be implemented.
    • clearIngredientTerms

      void clearIngredientTerms()
      Clears the ingredient query terms.
      Compliance:
      mandatory - This method must be implemented.
    • matchEstimatedDuration

      void matchEstimatedDuration(Duration start, Duration end, boolean match)
      Matches directions with an estimated duration between the given range inclusive.
      Parameters:
      start - starting duration
      end - ending duration
      match - true for a positive match, false for a negative match
      Throws:
      InvalidArgumentException - start is greater than end
      NullArgumentException - start or end is null
      Compliance:
      mandatory - This method must be implemented.
    • matchAnyEstimatedDuration

      void matchAnyEstimatedDuration(boolean match)
      Matches directions with any estimated duration.
      Parameters:
      match - true to match directions with any estimated duration, false to match directions with no estimated duration
      Compliance:
      mandatory - This method must be implemented.
    • clearEstimatedDurationTerms

      void clearEstimatedDurationTerms()
      Clears the duration query terms.
      Compliance:
      mandatory - This method must be implemented.
    • matchAssetId

      void matchAssetId(Id assetId, boolean match)
      Sets the asset Id for this query.
      Parameters:
      assetId - the asset Id
      match - true for a positive match, false for a negative match
      Throws:
      NullArgumentException - assetId is null
      Compliance:
      mandatory - This method must be implemented.
    • clearAssetIdTerms

      void clearAssetIdTerms()
      Clears the asset Id query terms.
      Compliance:
      mandatory - This method must be implemented.
    • supportsAssetQuery

      boolean supportsAssetQuery()
      Tests if an AssetQuery is available.
      Returns:
      true if an asset query is available, false otherwise
      Compliance:
      mandatory - This method must be implemented.
    • getAssetQuery

      AssetQuery getAssetQuery()
      Gets the query for an asset. Multiple retrievals produce a nested OR term.
      Returns:
      the asset query
      Throws:
      UnimplementedException - supportsAssetQuery() is false
      Compliance:
      optional - This method must be implemented if {@code supportsAssetQuery()} is {@code true} .
    • matchAnyAsset

      void matchAnyAsset(boolean match)
      Matches directions with any asset.
      Parameters:
      match - true to match directions with any asset, false to match directions with no assets
      Compliance:
      mandatory - This method must be implemented.
    • clearAssetTerms

      void clearAssetTerms()
      Clears the asset query terms.
      Compliance:
      mandatory - This method must be implemented.
    • matchCookbookId

      void matchCookbookId(Id cookbookId, boolean match)
      Sets the award Id for this query to match directions assigned to cookbooks.
      Parameters:
      cookbookId - a cookbook Id
      match - true for a positive match, false for a negative match
      Throws:
      NullArgumentException - cookbookId is null
      Compliance:
      mandatory - This method must be implemented.
    • clearCookbookIdTerms

      void clearCookbookIdTerms()
      Clears the cookbook Id terms.
      Compliance:
      mandatory - This method must be implemented.
    • supportsCookbookQuery

      boolean supportsCookbookQuery()
      Tests if a CookbookQuery is available.
      Returns:
      true if a cookbook query is available, false otherwise
      Compliance:
      mandatory - This method must be implemented.
    • getCookbookQuery

      CookbookQuery getCookbookQuery()
      Gets the query for a cookbook. Multiple retrievals produce a nested OR term.
      Returns:
      the cookbook query
      Throws:
      UnimplementedException - supportsCookbookQuery() is false
      Compliance:
      optional - This method must be implemented if {@code supportsCookbookQuery()} is {@code true} .
    • clearCookbookTerms

      void clearCookbookTerms()
      Clears the cookbook query terms.
      Compliance:
      mandatory - This method must be implemented.
    • getDirectionQueryRecord

      DirectionQueryRecord getDirectionQueryRecord(Type directionRecordType) throws OperationFailedException, PermissionDeniedException
      Gets the direction query record corresponding to the given Direction record Type . Multiple record retrievals produce a nested OR term.
      Parameters:
      directionRecordType - a direction record type
      Returns:
      the direction query record
      Throws:
      NullArgumentException - directionRecordType is null
      OperationFailedException - unable to complete request
      PermissionDeniedException - authorization failure occurred
      UnsupportedException - hasRecordType(directionRecordType) is false
      Compliance:
      mandatory - This method must be implemented.