l2280212 commented on code in PR #9665:
URL: https://github.com/apache/iotdb/pull/9665#discussion_r1173304057


##########
server/src/main/java/org/apache/iotdb/db/mpp/plan/statement/metadata/CountTimeSlotListStatement.java:
##########
@@ -0,0 +1,107 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF 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 org.apache.iotdb.db.mpp.plan.statement.metadata;
+
+import org.apache.iotdb.commons.exception.IllegalPathException;
+import org.apache.iotdb.commons.path.PartialPath;
+import org.apache.iotdb.db.mpp.plan.analyze.QueryType;
+import org.apache.iotdb.db.mpp.plan.statement.IConfigStatement;
+import org.apache.iotdb.db.mpp.plan.statement.Statement;
+import org.apache.iotdb.db.mpp.plan.statement.StatementVisitor;
+
+import java.util.ArrayList;
+import java.util.Collections;
+import java.util.List;
+
+public class CountTimeSlotListStatement extends Statement implements 
IConfigStatement {
+
+  private String database;
+
+  private String device;
+
+  private long regionId = -1;
+
+  private long startTime = -1;
+
+  private long endTime = -1;
+
+  public CountTimeSlotListStatement() {
+    super();
+  }
+
+  public void setDatabase(String database) {
+    this.database = database;
+  }
+
+  public String getDatabase() {
+    return database;
+  }
+
+  public long getStartTime() {
+    return startTime;
+  }
+
+  public void setStartTime(long startTime) {
+    this.startTime = startTime;
+  }
+
+  public long getEndTime() {
+    return endTime;
+  }
+
+  public void setEndTime(long endTime) {
+    this.endTime = endTime;
+  }
+
+  public void setDevice(String device) {
+    this.device = device;
+  }
+
+  public String getDevice() {
+    return this.device;
+  }
+
+  public void setRegionId(long regionId) {
+    this.regionId = regionId;
+  }
+
+  public long getRegionId() {
+    return this.regionId;
+  }
+
+  @Override
+  public <R, C> R accept(StatementVisitor<R, C> visitor, C context) {
+    return visitor.visitCountTimeSlotList(this, context);
+  }
+
+  @Override
+  public QueryType getQueryType() {
+    return QueryType.READ;
+  }
+
+  @Override
+  public List<PartialPath> getPaths() {
+    try {
+      return Collections.singletonList(new PartialPath(database));
+    } catch (IllegalPathException | NullPointerException e) {
+      return new ArrayList<>();
+    }

Review Comment:
   fix



##########
confignode/src/main/java/org/apache/iotdb/confignode/manager/IManager.java:
##########
@@ -629,9 +631,11 @@ TDataPartitionTableResp getOrCreateDataPartition(
 
   TGetRegionIdResp getRegionId(TGetRegionIdReq req);
 
-  TGetTimeSlotListResp getTimeSlotList(GetTimeSlotListPlan plan);
+  TGetTimeSlotListResp getTimeSlotList(TGetTimeSlotListReq req);
 
-  TGetSeriesSlotListResp getSeriesSlotList(GetSeriesSlotListPlan plan);
+  TCountTimeSlotListResp countTimeSlotList(TCountTimeSlotListReq req);
+
+  TGetSeriesSlotListResp getSeriesSlotList(TGetSeriesSlotListReq req);

Review Comment:
   added



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to