Interface BudgetEntryQuery

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

public interface BudgetEntryQuery extends OsidRelationshipQuery

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

  • Method Details

    • matchBudgetId

      void matchBudgetId(Id budgetId, boolean match)
      Sets the budget Id for this query.
      Parameters:
      budgetId - a budget Id
      match - true if a positive match, false for a negative match
      Throws:
      NullArgumentException - budgetId is null
      Compliance:
      mandatory - This method must be implemented.
    • clearBudgetIdTerms

      void clearBudgetIdTerms()
      Clears the budget Id terms.
      Compliance:
      mandatory - This method must be implemented.
    • supportsBudgetQuery

      boolean supportsBudgetQuery()
      Tests if a BudgetQuery is available.
      Returns:
      true if a budget query is available, false otherwise
      Compliance:
      mandatory - This method must be implemented.
    • getBudgetQuery

      BudgetQuery getBudgetQuery()
      Gets the query for a budget. Multiple retrievals produce a nested OR term.
      Returns:
      the payer query
      Throws:
      UnimplementedException - the budget query
      Compliance:
      optional - This method must be implemented if {@code supportsBudgetQuery()} is {@code true} .
    • clearBudgetTerms

      void clearBudgetTerms()
      Clears the budget terms.
      Compliance:
      mandatory - This method must be implemented.
    • matchAccountId

      void matchAccountId(Id accountId, boolean match)
      Sets the account Id for this query.
      Parameters:
      accountId - an account Id
      match - true if a positive match, false for a negative match
      Throws:
      NullArgumentException - accountId is null
      Compliance:
      mandatory - This method must be implemented.
    • clearAccountIdTerms

      void clearAccountIdTerms()
      Clears the account Id terms.
      Compliance:
      mandatory - This method must be implemented.
    • supportsAccountQuery

      boolean supportsAccountQuery()
      Tests if an AccountQuery is available.
      Returns:
      true if an account query is available, false otherwise
      Compliance:
      mandatory - This method must be implemented.
    • getAccountQuery

      AccountQuery getAccountQuery()
      Gets the query for an account. Multiple retrievals produce a nested OR term.
      Returns:
      the account query
      Throws:
      UnimplementedException - supportsAccountQuery() is false
      Compliance:
      optional - This method must be implemented if {@code supportsAccountQuery()} is {@code true} .
    • matchAnyAccount

      void matchAnyAccount(boolean match)
      Matches entries that have any account set.
      Parameters:
      match - true to match entries with any account, false to match entries with no account
      Compliance:
      mandatory - This method must be implemented.
    • clearAccountTerms

      void clearAccountTerms()
      Clears the account terms.
      Compliance:
      mandatory - This method must be implemented.
    • matchAmount

      void matchAmount(Currency low, Currency high, boolean match)
      Matches the amount between the given range inclusive.
      Parameters:
      low - start of range
      high - end of range
      match - true for a positive match, false for a negative match
      Throws:
      InvalidArgumentException - low is greater than high
      NullArgumentException - low or high is null
      Compliance:
      mandatory - This method must be implemented.
    • matchAnyAmount

      void matchAnyAmount(boolean match)
      Matches entries that have any amount set.
      Parameters:
      match - true to match entries with any amount, false to match entries with no amount
      Compliance:
      mandatory - This method must be implemented.
    • clearAmountTerms

      void clearAmountTerms()
      Clears the amount terms.
      Compliance:
      mandatory - This method must be implemented.
    • matchDebit

      void matchDebit(boolean match)
      Matches entries that have debit amounts.
      Parameters:
      match - true to match entries with a debit amount, false to match entries with a credit amount
      Compliance:
      mandatory - This method must be implemented.
    • clearDebitTerms

      void clearDebitTerms()
      Clears the debit terms.
      Compliance:
      mandatory - This method must be implemented.
    • matchBusinessId

      void matchBusinessId(Id businessId, boolean match)
      Sets the business Id for this query to match budget entries assigned to businesses.
      Parameters:
      businessId - the business Id
      match - true for a positive match, false for a negative match
      Throws:
      NullArgumentException - businessId is null
      Compliance:
      mandatory - This method must be implemented.
    • clearBusinessIdTerms

      void clearBusinessIdTerms()
      Clears the business Id terms.
      Compliance:
      mandatory - This method must be implemented.
    • supportsBusinessQuery

      boolean supportsBusinessQuery()
      Tests if a BusinessQuery is available.
      Returns:
      true if a business query is available, false otherwise
      Compliance:
      mandatory - This method must be implemented.
    • getBusinessQuery

      BusinessQuery getBusinessQuery()
      Gets the query for a business. Multiple retrievals produce a nested OR term.
      Returns:
      the business query
      Throws:
      UnimplementedException - supportsBusinessQuery() is false
      Compliance:
      optional - This method must be implemented if {@code supportsBusinessQuery()} is {@code true} .
    • clearBusinessTerms

      void clearBusinessTerms()
      Clears the business terms.
      Compliance:
      mandatory - This method must be implemented.
    • getBudgetEntryQueryRecord

      BudgetEntryQueryRecord getBudgetEntryQueryRecord(Type budgetEntryRecordType) throws OperationFailedException
      Gets the budget entry query record corresponding to the given BudgetEntry record Type . Multiple record retrievals produce a nested OR term.
      Parameters:
      budgetEntryRecordType - a budget entry record type
      Returns:
      the budget entry query record
      Throws:
      NullArgumentException - budgetEntryRecordType is null
      OperationFailedException - unable to complete request
      UnsupportedException - hasRecordType(budgetEntryRecordType) is false
      Compliance:
      mandatory - This method must be implemented.