From dc786ebc4c87fd17e334cd43aaf5172f2a8121da Mon Sep 17 00:00:00 2001 From: Gian Merlino Date: Tue, 24 Apr 2018 11:42:16 -0700 Subject: [PATCH] SQL: Remove some unused code. (#5690) --- .../aggregation/DimensionExpression.java | 5 -- .../aggregation/PostAggregatorFactory.java | 57 ------------------- 2 files changed, 62 deletions(-) delete mode 100644 sql/src/main/java/io/druid/sql/calcite/aggregation/PostAggregatorFactory.java diff --git a/sql/src/main/java/io/druid/sql/calcite/aggregation/DimensionExpression.java b/sql/src/main/java/io/druid/sql/calcite/aggregation/DimensionExpression.java index d5da02d37b7..c4131d7d97f 100644 --- a/sql/src/main/java/io/druid/sql/calcite/aggregation/DimensionExpression.java +++ b/sql/src/main/java/io/druid/sql/calcite/aggregation/DimensionExpression.java @@ -59,11 +59,6 @@ public class DimensionExpression return expression; } - public ValueType getOutputType() - { - return outputType; - } - public DimensionSpec toDimensionSpec() { if (expression.isSimpleExtraction()) { diff --git a/sql/src/main/java/io/druid/sql/calcite/aggregation/PostAggregatorFactory.java b/sql/src/main/java/io/druid/sql/calcite/aggregation/PostAggregatorFactory.java deleted file mode 100644 index a7c2b654fd3..00000000000 --- a/sql/src/main/java/io/druid/sql/calcite/aggregation/PostAggregatorFactory.java +++ /dev/null @@ -1,57 +0,0 @@ -/* - * Licensed to Metamarkets Group Inc. (Metamarkets) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. Metamarkets licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, - * software distributed under the License is distributed on an - * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - * KIND, either express or implied. See the License for the - * specific language governing permissions and limitations - * under the License. - */ - -package io.druid.sql.calcite.aggregation; - -import io.druid.query.aggregation.PostAggregator; - -/** - * Can create PostAggregators with specific output names. - */ -public abstract class PostAggregatorFactory -{ - public abstract PostAggregator factorize(String outputName); - - @Override - public boolean equals(Object o) - { - if (this == o) { - return true; - } - if (o == null || getClass() != o.getClass()) { - return false; - } - - PostAggregatorFactory that = (PostAggregatorFactory) o; - - return factorize(null).equals(that.factorize(null)); - } - - @Override - public int hashCode() - { - return factorize(null).hashCode(); - } - - @Override - public String toString() - { - return factorize(null).toString(); - } -}