Class CountFromClassStep

  • All Implemented Interfaces:
    ExecutionStep, ExecutionStepInternal

    public class CountFromClassStep
    extends AbstractExecutionStep
    Returns the number of records contained in a class (including subTypes) Executes a count(*) on a class and returns a single record that contains that value (with a specific alias).
    Author:
    Luigi Dell'Aquila (luigi.dellaquila - at - gmail.com)
    • Constructor Detail

      • CountFromClassStep

        public CountFromClassStep​(Identifier targetClass,
                                  String alias,
                                  CommandContext ctx,
                                  boolean profilingEnabled)
        Parameters:
        targetClass - An identifier containing the name of the class to count
        alias - the name of the property returned in the result-set
        ctx - the query context
        profilingEnabled - true to enable the profiling of the execution (for SQL PROFILE)
    • Method Detail

      • reset

        public void reset()
      • prettyPrint

        public String prettyPrint​(int depth,
                                  int indent)
      • getCost

        public long getCost()
        Description copied from interface: ExecutionStep
        returns the absolute cost (in nanoseconds) of the execution of this step
        Returns:
        the absolute cost (in nanoseconds) of the execution of this step, -1 if not calculated