You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@doris.apache.org by GitBox <gi...@apache.org> on 2019/09/23 02:28:45 UTC

[GitHub] [incubator-doris] imay commented on a change in pull request #1835: add default value column iterator #1834

imay commented on a change in pull request #1835: add default value column iterator #1834
URL: https://github.com/apache/incubator-doris/pull/1835#discussion_r326934566
 
 

 ##########
 File path: be/src/olap/rowset/segment_v2/column_reader.h
 ##########
 @@ -188,5 +191,39 @@ class FileColumnIterator : public ColumnIterator {
     rowid_t _current_rowid = 0;
 };
 
+// This iterator is used to read default value column
+class DefaultValueColumnIterator : public ColumnIterator {
+public:
+    DefaultValueColumnIterator(const TabletColumn& tablet_column)
+        : _tablet_column(tablet_column) { }
+
+    ~DefaultValueColumnIterator() { }
+
+    Status init() override;
+
+    Status seek_to_first() override {
+        _current_rowid = 0;
+        return Status::OK();
+    }
+
+    Status seek_to_ordinal(rowid_t ord_idx) override {
+        _current_rowid = ord_idx;
+        return Status::OK();
+    }
+
+    Status next_batch(size_t* n, ColumnBlock* dst) override;
+
+    rowid_t get_current_ordinal() const override { return _current_rowid; }
+
+private:
+    const TabletColumn& _tablet_column;
 
 Review comment:
   Get what this class needs, It's better not to depends TabletColumn.

----------------------------------------------------------------
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.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@doris.apache.org
For additional commands, e-mail: commits-help@doris.apache.org