Interface StatisticQuery

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

public interface StatisticQuery extends OsidCompendiumQuery

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

  • Method Details

    • matchMeterId

      void matchMeterId(Id meterId, boolean match)
      Sets a meter Id .
      Parameters:
      meterId - a meter Id
      match - true for a positive match, false for a negative match
      Throws:
      NullArgumentException - meterId is null
      Compliance:
      mandatory - This method must be implemented.
    • clearMeterIdTerms

      void clearMeterIdTerms()
      Clears the meter Id query term.
      Compliance:
      mandatory - This method must be implemented.
    • supportsMeterQuery

      boolean supportsMeterQuery()
      Tests if a meter query is available.
      Returns:
      true if a meter query is available, false otherwise
      Compliance:
      mandatory - This method must be implemented.
    • getMeterQuery

      MeterQuery getMeterQuery()
      Gets the query for a meter.
      Returns:
      the meter query
      Throws:
      UnimplementedException - supportsMeterQuery() is false
      Compliance:
      optional - This method must be implemented if {@code supportsMeterQuery()} is {@code true} .
    • clearMeterTerms

      void clearMeterTerms()
      Clears the meter query terms.
      Compliance:
      mandatory - This method must be implemented.
    • matchMeteredObjectId

      void matchMeteredObjectId(Id objectId, boolean match)
      Sets an object Id .
      Parameters:
      objectId - an object Id
      match - true for a positive match, false for a negative match
      Throws:
      NullArgumentException - objectId is null
      Compliance:
      mandatory - This method must be implemented.
    • clearMeteredObjectIdTerms

      void clearMeteredObjectIdTerms()
      Clears the object query terms.
      Compliance:
      mandatory - This method must be implemented.
    • setTimeRange

      void setTimeRange(DateTime start, DateTime end)
      Sets the time for the statistics to generate.
      Parameters:
      start - the start time
      end - the end time
      Throws:
      NullArgumentException - start or end is null
      Compliance:
      mandatory - This method must be implemented.
    • matchSum

      void matchSum(BigDecimal low, BigDecimal high, boolean match)
      Matches statistics with the sum between the given range inclusive.
      Parameters:
      low - the low end of the range
      high - the high end of the range
      match - true for a positive match, false for a negative match
      Throws:
      InvalidArgumentException - the low is greater than the high
      Compliance:
      mandatory - This method must be implemented.
    • clearSumTerms

      void clearSumTerms()
      Clears the sum query terms.
      Compliance:
      mandatory - This method must be implemented.
    • matchMinimumSum

      void matchMinimumSum(BigDecimal value, boolean match)
      Matches statistics with the minimum sum value inclusive.
      Parameters:
      value - the low end of the range
      match - true for a positive match, false for a negative match
      Compliance:
      mandatory - This method must be implemented.
    • clearMinimumSumTerms

      void clearMinimumSumTerms()
      Clears the minimum sum query terms.
      Compliance:
      mandatory - This method must be implemented.
    • matchMean

      void matchMean(BigDecimal low, BigDecimal high, boolean match)
      Matches statistics with the mean between the given range inclusive.
      Parameters:
      low - the low end of the range
      high - the high end of the range
      match - true for a positive match, false for a negative match
      Throws:
      InvalidArgumentException - the low is greater than the high
      Compliance:
      mandatory - This method must be implemented.
    • clearMeanTerms

      void clearMeanTerms()
      Clears the mean query terms.
      Compliance:
      mandatory - This method must be implemented.
    • matchMinimumMean

      void matchMinimumMean(BigDecimal value, boolean match)
      Matches statistics with the minimum mean value inclusive.
      Parameters:
      value - the low end of the range
      match - true for a positive match, false for a negative match
      Compliance:
      mandatory - This method must be implemented.
    • clearMinimumMeanTerms

      void clearMinimumMeanTerms()
      Clears the minimum mean query terms.
      Compliance:
      mandatory - This method must be implemented.
    • matchMedian

      void matchMedian(BigDecimal low, BigDecimal high, boolean match)
      Matches statistics with the median between the given range inclusive.
      Parameters:
      low - the low end of the range
      high - the high end of the range
      match - true for a positive match, false for a negative match
      Throws:
      InvalidArgumentException - the low is greater than the high
      Compliance:
      mandatory - This method must be implemented.
    • clearMedianTerms

      void clearMedianTerms()
      Clears the median query terms.
      Compliance:
      mandatory - This method must be implemented.
    • matchMinimumMedian

      void matchMinimumMedian(BigDecimal value, boolean match)
      Matches statistics with the minimum median value inclusive.
      Parameters:
      value - the low end of the range
      match - true for a positive match, false for a negative match
      Compliance:
      mandatory - This method must be implemented.
    • clearMinimumMedianTerms

      void clearMinimumMedianTerms()
      Clears the minimum median query terms.
      Compliance:
      mandatory - This method must be implemented.
    • matchMode

      void matchMode(BigDecimal low, BigDecimal high, boolean match)
      Matches statistics with the mode between the given range inclusive.
      Parameters:
      low - the low end of the range
      high - the high end of the range
      match - true for a positive match, false for a negative match
      Throws:
      InvalidArgumentException - the low is greater than the high
      Compliance:
      mandatory - This method must be implemented.
    • clearModeTerms

      void clearModeTerms()
      Clears the mode query terms.
      Compliance:
      mandatory - This method must be implemented.
    • matchMinimumMode

      void matchMinimumMode(BigDecimal value, boolean match)
      Matches statistics with the minimum mode value inclusive.
      Parameters:
      value - the low end of the range
      match - true for a positive match, false for a negative match
      Compliance:
      mandatory - This method must be implemented.
    • clearMinimumModeTerms

      void clearMinimumModeTerms()
      Clears the minimum mode query terms.
      Compliance:
      mandatory - This method must be implemented.
    • matchStandardDeviation

      void matchStandardDeviation(BigDecimal low, BigDecimal high, boolean match)
      Matches statistics with the standard deviation between the given range inclusive.
      Parameters:
      low - the low end of the range
      high - the high end of the range
      match - true for a positive match, false for a negative match
      Throws:
      InvalidArgumentException - the low is greater than the high
      Compliance:
      mandatory - This method must be implemented.
    • clearStandardDeviationTerms

      void clearStandardDeviationTerms()
      Clears the standard deviation query terms.
      Compliance:
      mandatory - This method must be implemented.
    • matchMinimumStandardDeviation

      void matchMinimumStandardDeviation(BigDecimal value, boolean match)
      Matches statistics with the minimum standard deviation value inclusive.
      Parameters:
      value - the low end of the range
      match - true for a positive match, false for a negative match
      Compliance:
      mandatory - This method must be implemented.
    • clearMinimumStandardDeviationTerms

      void clearMinimumStandardDeviationTerms()
      Clears the minimum standard deviation query terms.
      Compliance:
      mandatory - This method must be implemented.
    • matchRMS

      void matchRMS(BigDecimal low, BigDecimal high, boolean match)
      Matches statistics with the root mean square between the given range inclusive.
      Parameters:
      low - the low end of the range
      high - the high end of the range
      match - true for a positive match, false for a negative match
      Throws:
      InvalidArgumentException - the low is greater than the high
      Compliance:
      mandatory - This method must be implemented.
    • clearRMSTerms

      void clearRMSTerms()
      Clears the rms query terms.
      Compliance:
      mandatory - This method must be implemented.
    • matchMinimumRMS

      void matchMinimumRMS(BigDecimal value, boolean match)
      Matches statistics with the minimum rms value inclusive.
      Parameters:
      value - the low end of the range
      match - true for a positive match, false for a negative match
      Compliance:
      mandatory - This method must be implemented.
    • clearMinimumRMSTerms

      void clearMinimumRMSTerms()
      Clears the minimum rms query terms.
      Compliance:
      mandatory - This method must be implemented.
    • matchDelta

      void matchDelta(BigDecimal low, BigDecimal high, boolean match)
      Matches statistics with the delta between the given range inclusive.
      Parameters:
      low - the low end of the range
      high - the high end of the range
      match - true for a positive match, false for a negative match
      Throws:
      InvalidArgumentException - the low is greater than the high
      Compliance:
      mandatory - This method must be implemented.
    • clearDeltaTerms

      void clearDeltaTerms()
      Clears the delta query terms.
      Compliance:
      mandatory - This method must be implemented.
    • matchMinimumDelta

      void matchMinimumDelta(BigDecimal value, boolean match)
      Matches statistics with the minimum delta value inclusive.
      Parameters:
      value - the low end of the range
      match - true for a positive match, false for a negative match
      Compliance:
      mandatory - This method must be implemented.
    • clearMinimumDeltaTerms

      void clearMinimumDeltaTerms()
      Clears the minimum delta query terms.
      Compliance:
      mandatory - This method must be implemented.
    • matchPercentChange

      void matchPercentChange(BigDecimal low, BigDecimal high, boolean match)
      Matches statistics with the percentage change between the given range inclusive.
      Parameters:
      low - the low end of the range
      high - the high end of the range
      match - true for a positive match, false for a negative match
      Throws:
      InvalidArgumentException - the low is greater than the high
      Compliance:
      mandatory - This method must be implemented.
    • clearPercentChangeTerms

      void clearPercentChangeTerms()
      Clears the delta query terms.
      Compliance:
      mandatory - This method must be implemented.
    • matchMinimumPercentChange

      void matchMinimumPercentChange(BigDecimal value, boolean match)
      Matches statistics with the minimum percentage change value inclusive.
      Parameters:
      value - the low end of the range
      match - true for a positive match, false for a negative match
      Compliance:
      mandatory - This method must be implemented.
    • clearMinimumPercentChangeTerms

      void clearMinimumPercentChangeTerms()
      Clears the minimum percentage change query terms.
      Compliance:
      mandatory - This method must be implemented.
    • matchAverageRate

      void matchAverageRate(BigDecimal low, BigDecimal high, boolean match)
      Matches statistics with the average rate between the given range inclusive.
      Parameters:
      low - the low end of the range
      high - the high end of the range
      match - true for a positive match, false for a negative match
      Throws:
      InvalidArgumentException - the low is greater than the high
      Compliance:
      mandatory - This method must be implemented.
    • clearAverageRateTerms

      void clearAverageRateTerms()
      Clears the average rate query terms.
      Compliance:
      mandatory - This method must be implemented.
    • getStatisticQueryRecord

      StatisticQueryRecord getStatisticQueryRecord(Type statisticRecordType) throws OperationFailedException
      Gets the statistic query record corresponding to the given Statistic record Type . Multiple retrievals produce a nested OR term.
      Parameters:
      statisticRecordType - a statistic record type
      Returns:
      the statistic query record
      Throws:
      NullArgumentException - statisticRecordType is null
      OperationFailedException - unable to complete request
      UnsupportedException - hasRecordType(statisticRecordType) is false
      Compliance:
      mandatory - This method must be implemented.