paul-rogers commented on a change in pull request #1633: DRILL-7024: Refactor 
ColumnWriter to simplify type-conversion shim
URL: https://github.com/apache/drill/pull/1633#discussion_r254569369
 
 

 ##########
 File path: 
exec/java-exec/src/main/java/org/apache/drill/exec/physical/rowSet/impl/ColumnState.java
 ##########
 @@ -47,19 +48,19 @@
    * Column metadata is hosted on the writer.
    */
 
-  public static class PrimitiveColumnState extends ColumnState implements 
ColumnWriterListener {
+  public static class PrimitiveColumnState extends ColumnState implements 
AbstractScalarWriterImpl.ColumnWriterListener {
 
     public PrimitiveColumnState(LoaderInternals loader,
         AbstractObjectWriter colWriter,
         VectorState vectorState) {
       super(loader, colWriter, vectorState);
-      ScalarWriter scalarWriter;
+      WriterEvents scalarWriter;
       if (colWriter.type() == ObjectType.ARRAY) {
-        scalarWriter = writer.array().scalar();
+        scalarWriter = writer.array().entry().events();
       } else {
-        scalarWriter = writer.scalar();
+        scalarWriter = writer.events();
       }
-      scalarWriter.bindListener(this);
+      ((AbstractScalarWriterImpl) scalarWriter).bindListener(this);
 
 Review comment:
   Refactored a bit more to avoid the cast.

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
[email protected]


With regards,
Apache Git Services

Reply via email to