WillAyd commented on code in PR #1998:
URL: https://github.com/apache/arrow-adbc/pull/1998#discussion_r1671417752


##########
c/driver/postgresql/copy/writer.h:
##########
@@ -92,13 +92,20 @@ class PostgresCopyFieldWriter {
  public:
   virtual ~PostgresCopyFieldWriter() {}
 
-  void Init(struct ArrowArrayView* array_view) { array_view_ = array_view; };
+  template <class T, typename... Params>
+  static std::unique_ptr<T> Create(struct ArrowArrayView* array_view, 
Params&&... args) {

Review Comment:
   I think would have to make the Init method public to do that - do you think 
that is better?
   
   ```cpp
   ../driver/postgresql/copy/writer.h:564:15: error: ‘virtual void 
adbcpq::PostgresCopyFieldWriter::Init(ArrowArrayView*)’ is protected within 
this context
     564 |   writer->Init(array_view);
         |   ~~~~~~~~~~~~^~~~~~~~~~~~
   ../driver/postgresql/copy/writer.h:100:16: note: declared protected here
     100 |   virtual void Init(struct ArrowArrayView* array_view) { array_view_ 
= array_view; };
   ```



-- 
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