File tree Expand file tree Collapse file tree 1 file changed +4
-4
lines changed
vector/src/main/codegen/templates Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -280,7 +280,10 @@ public StructVector getStruct() {
280280 <#if minor.class?starts_with(" Decimal ") || is_timestamp_tz(minor.class) || minor.class == " Duration " || minor.class == " FixedSizeBinary ">
281281 public ${name}Vector get${name}Vector() {
282282 if (${uncappedName}Vector == null) {
283- throw new IllegalArgumentException(" No $ {name } present . Provide ArrowType argument to create a new vector ");
283+ ${uncappedName}Vector = internalStruct.getChild(fieldName(MinorType.${name?upper_case}), ${name}Vector.class);
284+ if (${uncappedName}Vector == null) {
285+ throw new IllegalArgumentException(" No $ {name } present . Provide ArrowType argument to create a new vector ");
286+ }
284287 }
285288 return ${uncappedName}Vector;
286289 }
@@ -307,9 +310,6 @@ public StructVector getStruct() {
307310
308311 public ${name}Vector get${name}Vector(String name) {
309312 if (${uncappedName}Vector == null) {
310- ${uncappedName}Vector = internalStruct.getChild(fieldName(MinorType.${name?upper_case}), ${name}Vector.class);
311- if (${uncappedName}Vector == null) {
312- throw new IllegalArgumentException(" No $ {uncappedName } present . Provide ArrowType argument to create a new vector ");
313313 int vectorCount = internalStruct.size();
314314 ${uncappedName}Vector = addOrGet(name, MinorType.${name?upper_case}, ${name}Vector.class);
315315 if (internalStruct.size() > vectorCount) {
You can’t perform that action at this time.
0 commit comments