Tabnine Logo
InputFunction.<init>
Code IndexAdd Tabnine to your IDE (free)

How to use
io.prestosql.spi.function.InputFunction
constructor

Best Java code snippets using io.prestosql.spi.function.InputFunction.<init> (Showing top 20 results out of 315)

origin: io.prestosql/presto-main

@InputFunction
public static void input(BooleanDistinctState state, @SqlType(StandardTypes.BOOLEAN) boolean value)
{
  ApproximateCountDistinctAggregation.input(state, value, DEFAULT_STANDARD_ERROR);
}
origin: io.prestosql/presto-main

@InputFunction
public static void input(@AggregationState RegressionState state, @SqlType(StandardTypes.REAL) long dependentValue, @SqlType(StandardTypes.REAL) long independentValue)
{
  DoubleRegressionAggregation.input(state, intBitsToFloat((int) dependentValue), intBitsToFloat((int) independentValue));
}
origin: prestosql/presto

@InputFunction
public static void input(@AggregationState CovarianceState state, @SqlType(StandardTypes.REAL) long dependentValue, @SqlType(StandardTypes.REAL) long independentValue)
{
  DoubleCovarianceAggregation.input(state, intBitsToFloat((int) dependentValue), intBitsToFloat((int) independentValue));
}
origin: io.prestosql/presto-main

@InputFunction
public static void input(NullableDoubleState state, @SqlType(DOUBLE) double value)
{
  // noop this is only for annotation testing puproses
}
origin: prestosql/presto

@InputFunction
public static void doubleInput(@AggregationState CentralMomentsState state, @SqlType(StandardTypes.DOUBLE) double value)
{
  updateCentralMomentsState(state, value);
}
origin: io.prestosql/presto-main

@InputFunction
public static void add(@AggregationState DoubleHistogramAggregation.State state, @SqlType(StandardTypes.BIGINT) long buckets, @SqlType(StandardTypes.REAL) long value, @SqlType(StandardTypes.DOUBLE) double weight)
{
  DoubleHistogramAggregation.add(state, buckets, intBitsToFloat((int) value), weight);
}
origin: io.prestosql/presto-main

@InputFunction
public static void input(@AggregationState RegressionState state, @SqlType(StandardTypes.DOUBLE) double dependentValue, @SqlType(StandardTypes.DOUBLE) double independentValue)
{
  updateRegressionState(state, independentValue, dependentValue);
}
origin: io.prestosql/presto-main

@InputFunction
public static void add(@AggregationState State state, @SqlType(BIGINT) long buckets, @SqlType(DOUBLE) double value)
{
  add(state, buckets, value, 1);
}
origin: prestosql/presto

@InputFunction
public static void weightedInput(@AggregationState DigestAndPercentileArrayState state, @SqlType(StandardTypes.REAL) long value, @SqlType(StandardTypes.BIGINT) long weight, @SqlType("array(double)") Block percentilesArrayBlock)
{
  ApproximateLongPercentileArrayAggregations.weightedInput(state, floatToSortableInt(intBitsToFloat((int) value)), weight, percentilesArrayBlock);
}
origin: io.prestosql/presto-main

@InputFunction
public static void weightedInput(@AggregationState DigestAndPercentileState state, @SqlType(StandardTypes.REAL) long value, @SqlType(StandardTypes.BIGINT) long weight, @SqlType(StandardTypes.DOUBLE) double percentile, @SqlType(StandardTypes.DOUBLE) double accuracy)
{
  ApproximateLongPercentileAggregations.weightedInput(state, floatToSortableInt(intBitsToFloat((int) value)), weight, percentile, accuracy);
}
origin: io.prestosql/presto-main

@InputFunction
public static void input(
    @AggregationState NullableDoubleState state,
    @SqlType(DOUBLE) double value)
{
  // noop this is only for annotation testing puproses
}
origin: prestosql/presto

@InputFunction
public static void sum(NullableLongState state, @SqlType(INTERVAL_DAY_TO_SECOND) long value)
{
  state.setNull(false);
  state.setLong(BigintOperators.add(state.getLong(), value));
}
origin: prestosql/presto

@InputFunction
public static void input(@AggregationState DigestAndPercentileArrayState state, @SqlType(StandardTypes.DOUBLE) double value, @SqlType("array(double)") Block percentilesArrayBlock)
{
  ApproximateLongPercentileArrayAggregations.input(state, doubleToSortableLong(value), percentilesArrayBlock);
}
origin: io.prestosql/presto-main

@InputFunction
public static void input(@AggregationState DigestAndPercentileState state, @SqlType(StandardTypes.DOUBLE) double value, @SqlType(StandardTypes.DOUBLE) double percentile)
{
  ApproximateLongPercentileAggregations.input(state, doubleToSortableLong(value), percentile);
}
origin: io.prestosql/presto-main

@InputFunction
public static void input(@AggregationState HyperLogLogState state, @SqlType(StandardTypes.DOUBLE) double value)
{
  HyperLogLog hll = getOrCreateHyperLogLog(state);
  state.addMemoryUsage(-hll.estimatedInMemorySize());
  hll.add(Double.doubleToLongBits(value));
  state.addMemoryUsage(hll.estimatedInMemorySize());
}
origin: io.prestosql/presto-main

@InputFunction
public static void sum(@AggregationState NullableLongState state, @SqlType(StandardTypes.BIGINT) long value)
{
  state.setNull(false);
  state.setLong(BigintOperators.add(state.getLong(), value));
}
origin: io.prestosql/presto-main

@InputFunction
public static void weightedInput(@AggregationState DigestAndPercentileArrayState state, @SqlType(StandardTypes.DOUBLE) double value, @SqlType(StandardTypes.BIGINT) long weight, @SqlType("array(double)") Block percentilesArrayBlock)
{
  ApproximateLongPercentileArrayAggregations.weightedInput(state, doubleToSortableLong(value), weight, percentilesArrayBlock);
}
origin: io.prestosql/presto-main

@InputFunction
public static void add(@AggregationState State state, @SqlType(BIGINT) long buckets, @SqlType(DOUBLE) double value, @SqlType(DOUBLE) double weight)
{
  NumericHistogram histogram = state.get();
  if (histogram == null) {
    checkCondition(buckets >= 2, INVALID_FUNCTION_ARGUMENT, "numeric_histogram bucket count must be greater than one");
    histogram = new NumericHistogram(toIntExact(buckets), ENTRY_BUFFER_SIZE);
    state.set(histogram);
  }
  histogram.add(value, weight);
}
origin: prestosql/presto

@InputFunction
public static void add(@AggregationState State state, @SqlType(BIGINT) long buckets, @SqlType(DOUBLE) double value, @SqlType(DOUBLE) double weight)
{
  NumericHistogram histogram = state.get();
  if (histogram == null) {
    checkCondition(buckets >= 2, INVALID_FUNCTION_ARGUMENT, "numeric_histogram bucket count must be greater than one");
    histogram = new NumericHistogram(toIntExact(buckets), ENTRY_BUFFER_SIZE);
    state.set(histogram);
  }
  histogram.add(value, weight);
}
origin: io.prestosql/presto-main

@InputFunction
public static void input(@AggregationState NullableLongState state, @BlockPosition @NullablePosition @SqlType(StandardTypes.BIGINT) Block block, @BlockIndex int position)
{
  if (block.isNull(position)) {
    state.setLong(state.getLong() + 1);
  }
  state.setNull(false);
}
io.prestosql.spi.functionInputFunction<init>

Popular methods of InputFunction

    Popular in Java

    • Reactive rest calls using spring rest template
    • orElseThrow (Optional)
      Return the contained value, if present, otherwise throw an exception to be created by the provided s
    • addToBackStack (FragmentTransaction)
    • getContentResolver (Context)
    • GridBagLayout (java.awt)
      The GridBagLayout class is a flexible layout manager that aligns components vertically and horizonta
    • PrintStream (java.io)
      Fake signature of an existing Java class.
    • ByteBuffer (java.nio)
      A buffer for bytes. A byte buffer can be created in either one of the following ways: * #allocate
    • BoxLayout (javax.swing)
    • Table (org.hibernate.mapping)
      A relational table
    • Runner (org.openjdk.jmh.runner)
    • From CI to AI: The AI layer in your organization
    Tabnine Logo
    • Products

      Search for Java codeSearch for JavaScript code
    • IDE Plugins

      IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
    • Company

      About UsContact UsCareers
    • Resources

      FAQBlogTabnine AcademyTerms of usePrivacy policyJava Code IndexJavascript Code Index
    Get Tabnine for your IDE now