You are viewing a plain text version of this content. The canonical link for it is here.
Posted to github@arrow.apache.org by GitBox <gi...@apache.org> on 2020/12/13 14:28:07 UTC

[GitHub] [arrow] Ulimo commented on a change in pull request #8902: ARROW-10719: [C#] ArrowStreamWriter doesn't write schema metadata

Ulimo commented on a change in pull request #8902:
URL: https://github.com/apache/arrow/pull/8902#discussion_r541936265



##########
File path: csharp/src/Apache.Arrow/Field.cs
##########
@@ -34,6 +35,22 @@ public partial class Field
 
         public Field(string name, IArrowType dataType, bool nullable,
             IEnumerable<KeyValuePair<string, string>> metadata = default)
+            : this(name, dataType, nullable)
+        {
+            Metadata = metadata?.ToDictionary(kv => kv.Key, kv => kv.Value);
+
+        }
+
+        internal Field(string name, IArrowType dataType, bool nullable,
+            IReadOnlyDictionary<string, string> metadata, bool copyCollections)

Review comment:
       Is copyCollections not in the private constructor with if(copyCollections) only to not have the extra if statement?
   
   Otherwise it could be nice to have the internal constructor work in both cases and the Debug.Assert could be skipped?




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