Interface ItemQuery

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

public interface ItemQuery extends OsidObjectQuery

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

  • Method Details

    • matchStockId

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

      void clearStockIdTerms()
      Clears the stock Id terms.
      Compliance:
      mandatory - This method must be implemented.
    • supportsStockQuery

      boolean supportsStockQuery()
      Tests if a StockQuery is available.
      Returns:
      true if a stock query is available, false otherwise
      Compliance:
      mandatory - This method must be implemented.
    • getStockQuery

      StockQuery getStockQuery()
      Gets the query for a stocjk. Multiple retrievals produce a nested OR term.
      Returns:
      the stock query
      Throws:
      UnimplementedException - supportsStockQuery() is false
      Compliance:
      optional - This method must be implemented if {@code supportsStockQuery()} is {@code true} .
    • matchAnyStock

      void matchAnyStock(boolean match)
      Matches items that have any stock.
      Parameters:
      match - true to match items with any stock, false to match items with no stock
      Compliance:
      mandatory - This method must be implemented.
    • clearStockTerms

      void clearStockTerms()
      Clears the stock terms.
      Compliance:
      mandatory - This method must be implemented.
    • matchPropertyTag

      void matchPropertyTag(String property, Type stringMatchType, boolean match)
      Matches a property identification number.
      Parameters:
      property - a property number
      stringMatchType - a string match type
      match - true if a positive match, false for a negative match
      Throws:
      NullArgumentException - property or stringMatchType is null
      UnsupportedException - supportsStringMatchType(stringMatchType) is false
      Compliance:
      mandatory - This method must be implemented.
    • matchAnyPropertyTag

      void matchAnyPropertyTag(boolean match)
      Matches items that have any property tag.
      Parameters:
      match - true to match items with any property tag, false to match items with no property tag
      Compliance:
      mandatory - This method must be implemented.
    • clearPropertyTagTerms

      void clearPropertyTagTerms()
      Clears the property tag terms.
      Compliance:
      mandatory - This method must be implemented.
    • matchSerialNumber

      void matchSerialNumber(String serial, Type stringMatchType, boolean match)
      Matches a serial number.
      Parameters:
      serial - a serial number
      stringMatchType - a string match type
      match - true if a positive match, false for a negative match
      Throws:
      NullArgumentException - serial or stringMatchType is null
      UnsupportedException - supportsStringMatchType(stringMatchType) is false
      Compliance:
      mandatory - This method must be implemented.
    • matchAnySerialNumber

      void matchAnySerialNumber(boolean match)
      Matches items that have any serial number.
      Parameters:
      match - true to match items with any serial number, false to match items with no serial number
      Compliance:
      mandatory - This method must be implemented.
    • clearSerialNumberTerms

      void clearSerialNumberTerms()
      Clears the serial number terms.
      Compliance:
      mandatory - This method must be implemented.
    • matchLocationDescription

      void matchLocationDescription(String location, Type stringMatchType, boolean match)
      Matches a location description.
      Parameters:
      location - a location string
      stringMatchType - a string match type
      match - true if a positive match, false for a negative match
      Throws:
      NullArgumentException - location or stringMatchType is null
      UnsupportedException - supportsStringMatchType(stringMatchType) is false
      Compliance:
      mandatory - This method must be implemented.
    • matchAnyLocationDescription

      void matchAnyLocationDescription(boolean match)
      Matches items that have any location description.
      Parameters:
      match - true to match items with any location string, false to match items with no location string
      Compliance:
      mandatory - This method must be implemented.
    • clearLocationDescriptionTerms

      void clearLocationDescriptionTerms()
      Clears the location description terms.
      Compliance:
      mandatory - This method must be implemented.
    • matchLocationId

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

      void clearLocationIdTerms()
      Clears the location Id terms.
      Compliance:
      mandatory - This method must be implemented.
    • supportsLocationQuery

      boolean supportsLocationQuery()
      Tests if a LocationQuery is available.
      Returns:
      true if a location query is available, false otherwise
      Compliance:
      mandatory - This method must be implemented.
    • getLocationQuery

      LocationQuery getLocationQuery()
      Gets the query for a location. Multiple retrievals produce a nested OR term.
      Returns:
      the location query
      Throws:
      UnimplementedException - supportsLocationQuery() is false
      Compliance:
      optional - This method must be implemented if {@code supportsLocationQuery()} is {@code true} .
    • matchAnyLocation

      void matchAnyLocation(boolean match)
      Matches items that have any location.
      Parameters:
      match - true to match items with any location, false to match items with no location
      Compliance:
      mandatory - This method must be implemented.
    • clearLocationTerms

      void clearLocationTerms()
      Clears the location terms.
      Compliance:
      mandatory - This method must be implemented.
    • matchItemId

      void matchItemId(Id itemId, boolean match)
      Sets the item Id for this query to match items part of the given item.
      Parameters:
      itemId - the item Id
      match - true for a positive match, false for a negative match
      Throws:
      NullArgumentException - itemId is null
      Compliance:
      mandatory - This method must be implemented.
    • clearItemIdTerms

      void clearItemIdTerms()
      Clears the item Id terms.
      Compliance:
      mandatory - This method must be implemented.
    • supportsItemQuery

      boolean supportsItemQuery()
      Tests if an ItemQuery is available.
      Returns:
      true if an item query is available, false otherwise
      Compliance:
      mandatory - This method must be implemented.
    • getItemQuery

      ItemQuery getItemQuery()
      Gets the query for an item. Multiple retrievals produce a nested OR term.
      Returns:
      the item query
      Throws:
      UnimplementedException - supportsItemQuery() is false
      Compliance:
      optional - This method must be implemented if {@code supportsItemQuery()} is {@code true} .
    • matchAnyItem

      void matchAnyItem(boolean match)
      Matches items that have any item.
      Parameters:
      match - true to match items part of any item, false to match items psrt of no item
      Compliance:
      mandatory - This method must be implemented.
    • clearItemTerms

      void clearItemTerms()
      Clears the item terms.
      Compliance:
      mandatory - This method must be implemented.
    • matchWarehouseId

      void matchWarehouseId(Id warehouseId, boolean match)
      Sets the warehouse Id for this query to match items assigned to warehouses.
      Parameters:
      warehouseId - the warehouse Id
      match - true for a positive match, false for a negative match
      Throws:
      NullArgumentException - warehouseId is null
      Compliance:
      mandatory - This method must be implemented.
    • clearWarehouseIdTerms

      void clearWarehouseIdTerms()
      Clears the warehouse Id terms.
      Compliance:
      mandatory - This method must be implemented.
    • supportsWarehouseQuery

      boolean supportsWarehouseQuery()
      Tests if a WarehouseQuery is available.
      Returns:
      true if a warehouse query is available, false otherwise
      Compliance:
      mandatory - This method must be implemented.
    • getWarehouseQuery

      WarehouseQuery getWarehouseQuery()
      Gets the query for a warehouse. Multiple retrievals produce a nested OR term.
      Returns:
      the warehouse query
      Throws:
      UnimplementedException - supportsWarehouseQuery() is false
      Compliance:
      optional - This method must be implemented if {@code supportsWarehouseQuery()} is {@code true} .
    • clearWarehouseTerms

      void clearWarehouseTerms()
      Clears the warehouse terms.
      Compliance:
      mandatory - This method must be implemented.
    • getItemQueryRecord

      ItemQueryRecord getItemQueryRecord(Type itemRecordType) throws OperationFailedException
      Gets the item query record corresponding to the given Item record Type .Multiple record retrievals produce a nested OR term.
      Parameters:
      itemRecordType - an item record type
      Returns:
      the item query record
      Throws:
      NullArgumentException - itemRecordType is null
      OperationFailedException - unable to complete request
      UnsupportedException - hasRecordType(itemRecordType) is false
      Compliance:
      mandatory - This method must be implemented.