Currently narrow defines a StringArray for the String and str ArrayTypes. However, Arrow does not define a physical memory layout for string arrays, instead it defines the UTF8 (and UTF8 view) data types that are stored in the variable-size binary layout (and variable-size binary view layout).
I think it would be better if we remove StringArray and instead implement LogicalArrayType for String to map that to the corresponding physical memory layout.
Thinking ahead, when we add view layouts we need to add something to logical types to allow switching between "normal" and "view" layouts for types that can be mapped to both, or we use wrapper types with different LogicalArrayType implementations.
Currently
narrowdefines aStringArrayfor theStringandstrArrayTypes. However, Arrow does not define a physical memory layout for string arrays, instead it defines theUTF8(andUTF8 view) data types that are stored in the variable-size binary layout (and variable-size binary view layout).I think it would be better if we remove
StringArrayand instead implementLogicalArrayTypeforStringto map that to the corresponding physical memory layout.Thinking ahead, when we add view layouts we need to add something to logical types to allow switching between "normal" and "view" layouts for types that can be mapped to both, or we use wrapper types with different
LogicalArrayTypeimplementations.