Class AsOfDateNeighbourValuePostProcessor<OutputType>

  • Type Parameters:
    OutputType - the output type
    All Implemented Interfaces:
    com.quartetfs.biz.pivot.postprocessing.IAggregatedMeasureAware, com.quartetfs.biz.pivot.postprocessing.IPostProcessor<OutputType>, com.quartetfs.fwk.types.IExtendedPluginValue, Serializable

    @QuartetExtendedPluginValue(intf=com.quartetfs.biz.pivot.postprocessing.IPostProcessor.class,
                                key="AsOfDateNeighbourValuePostProcessor")
    public class AsOfDateNeighbourValuePostProcessor<OutputType>
    extends com.quartetfs.biz.pivot.postprocessing.impl.NeighborValuePostProcessor<OutputType>
    Extension of the NeighborValuePostProcessor which uses an IDayToDayDifference context value to select the AsOfDate to shift to. If the context value has not been set the standard NeighborValuePostProcessor behaviour is used.

    Note: this post-processor assumes the time hierarchy provided is a slicing hierarchy with one level.
    Author:
    ActiveViam
    See Also:
    Serialized Form
    • Nested Class Summary

      • Nested classes/interfaces inherited from class com.quartetfs.biz.pivot.postprocessing.impl.NeighborValuePostProcessor

        com.quartetfs.biz.pivot.postprocessing.impl.NeighborValuePostProcessor.NeighborValuePrefetcher
    • Field Summary

      Fields 
      Modifier and Type Field Description
      static String PLUGIN_KEY  
      static String USE_D2D_PROPERTY  
      protected boolean useD2D  
      • Fields inherited from class com.quartetfs.biz.pivot.postprocessing.impl.NeighborValuePostProcessor

        DIRECTION_PROPERTY, isPrevious, STREAM_MEASURE_PROPERTY, streamMeasureName, TIME_HIERARCHY_PROPERTY, timeHierarchy, timeHierarchyIdx
      • Fields inherited from class com.quartetfs.biz.pivot.postprocessing.impl.AAdvancedPostProcessor

        aggregatedMeasureName, ANALYSIS_LEVELS_PROPERTY, analysisLevelsToExpand, continuousQueryHandlerKeys, derivedContextDependencies, evaluator, EVALUATOR, explicitContextDependencies, logger, measuresProvider, name, OUTPUT_TYPE, outputType, pivot, prefetchers, PRINT_TIMINGS, printTimings, properties, underlyingMeasures
      • Fields inherited from interface com.quartetfs.biz.pivot.postprocessing.IPostProcessor

        CONTINUOUS_QUERY_HANDLER_KEYS, IS_PARTITIONED_ON_RANGE_LEVELS_PROPERTY, SEPARATOR, UNDERLYING_MEASURES
    • Constructor Summary

      Constructors 
      Constructor Description
      AsOfDateNeighbourValuePostProcessor​(String name, com.quartetfs.biz.pivot.cube.hierarchy.measures.IPostProcessorCreationContext creationContext)  
    • Method Summary

      All Methods Static Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      static Function<com.activeviam.desc.build.ICanStartBuildingMeasures,​com.activeviam.desc.build.IHasAtLeastOneMeasure> getPostProcessorDescription​(String measureName, String underlyingMeasure, String direction, boolean useD2D, String hierarchy, String formatter, String folder)  
      void init​(Properties properties)  
      static com.activeviam.copper.api.CopperMeasure measure​(String underlyingMeasure, String hierarchy)
      This PP will take change the date of the metric.
      static com.activeviam.copper.api.CopperMeasure measure​(String underlyingMeasure, String direction, boolean useD2D, String hierarchy)
      This PP will take change the date of the metric.
      com.quartetfs.biz.pivot.cube.hierarchy.axis.IAxisMember retrieveNeighbor​(com.quartetfs.biz.pivot.ILocation location, boolean isPrevious)  
      • Methods inherited from class com.quartetfs.biz.pivot.postprocessing.impl.NeighborValuePostProcessor

        compute, computeNeighborLocation, findNext, findPrevious, getType, hardExpandLocation, searchAmongNext, searchAmongNext, searchAmongPrevious, searchAmongPrevious, tryGoDownToLevelAndFindFirst, tryGoDownToLevelAndFindLast
      • Methods inherited from class com.quartetfs.biz.pivot.postprocessing.impl.AAdvancedPostProcessor

        addContextDependency, checkInterruption, checkOutputType, computeNamePath, computeOutputType, createEvaluator, expandResult, getActivePivot, getContext, getContextDependencies, getContinuousQueryHandlerKeys, getCurrentMeasure, getDatastoreVersion, getDerivedContextDependencies, getExpansionProcedure, getGenericOutputType, getMeasuresProvider, getName, getOutputType, getOutputTypeFromGenericClassParameter, getOutputTypeFromProperties, getPrefetchers, getProperties, getQueryCache, getTypeFromClass, handleCircularDependency, handleNotSupportedAnalysisLevels, handleUnknownUnderlyingMeasure, hideEvaluator, initializeContinuousQueryHandlerKeys, initializeUnderlyingMeasures, removeAnalysisLevelsFromFilter, restrictLocationAnalysisLevels, retrieveAnalysisLevelsToExpand, retrieveNamedPrefetchAggregatesWithAnalysisLevels, retrievePrefetchAggregates, retrievePrefetchAggregatesWithAnalysisLevels, setAggregatedMeasureName, supportsAnalysisLevels, toString
      • Methods inherited from interface com.quartetfs.biz.pivot.postprocessing.IPostProcessor

        setPartitioningLevels
    • Constructor Detail

      • AsOfDateNeighbourValuePostProcessor

        public AsOfDateNeighbourValuePostProcessor​(String name,
                                                   com.quartetfs.biz.pivot.cube.hierarchy.measures.IPostProcessorCreationContext creationContext)
    • Method Detail

      • getPostProcessorDescription

        public static Function<com.activeviam.desc.build.ICanStartBuildingMeasures,​com.activeviam.desc.build.IHasAtLeastOneMeasure> getPostProcessorDescription​(String measureName,
                                                                                                                                                                      String underlyingMeasure,
                                                                                                                                                                      String direction,
                                                                                                                                                                      boolean useD2D,
                                                                                                                                                                      String hierarchy,
                                                                                                                                                                      String formatter,
                                                                                                                                                                      String folder)
      • measure

        public static com.activeviam.copper.api.CopperMeasure measure​(String underlyingMeasure,
                                                                      String hierarchy)
        This PP will take change the date of the metric. If DayToDayDifference is expressed it will use it, or else it will slice over the hierarchy
        Parameters:
        underlyingMeasure - The measure to change
        hierarchy - The date hierarchy
        Returns:
        The measure at the specified date
      • measure

        public static com.activeviam.copper.api.CopperMeasure measure​(String underlyingMeasure,
                                                                      String direction,
                                                                      boolean useD2D,
                                                                      String hierarchy)
        This PP will take change the date of the metric.

        Note: for reverse-sorted date hierarchy, "next" is previous date, and "previous" is next date.

        Parameters:
        underlyingMeasure - The measure to change
        direction - "next" or "previous"
        useD2D - flag to specify whether the day-to-day measure is used
        hierarchy - The date hierarchy
        Returns:
        The measure at the specified date
      • init

        public void init​(Properties properties)
                  throws com.quartetfs.fwk.QuartetException
        Specified by:
        init in interface com.quartetfs.biz.pivot.postprocessing.IPostProcessor<OutputType>
        Overrides:
        init in class com.quartetfs.biz.pivot.postprocessing.impl.NeighborValuePostProcessor<OutputType>
        Throws:
        com.quartetfs.fwk.QuartetException
      • retrieveNeighbor

        public com.quartetfs.biz.pivot.cube.hierarchy.axis.IAxisMember retrieveNeighbor​(com.quartetfs.biz.pivot.ILocation location,
                                                                                        boolean isPrevious)
        Overrides:
        retrieveNeighbor in class com.quartetfs.biz.pivot.postprocessing.impl.NeighborValuePostProcessor<OutputType>