LOG.warn("member name is null or empty.");
continue;
}
Field memberField = fieldSchema.getField(memberName);
Schema memberSchema = memberField.schema();
Type memberType = memberSchema.getType();
CassandraSubColumn cassandraColumn = new CassandraSubColumn();
cassandraColumn.setField(memberField);
cassandraColumn.setValue(hColumn);
if (memberType.equals(Type.UNION)){
HColumn<ByteBuffer, ByteBuffer> hc = getUnionTypeColumn(memberField.name()
+ CassandraStore.UNION_COL_SUFIX, this.hSuperColumn.getColumns().toArray());
Integer unionIndex = getUnionIndex(memberField.name(),hc);
cassandraColumn.setUnionType(unionIndex);
}
record.put(record.getSchema().getField(memberName).pos(), cassandraColumn.getValue());
}
}
}
break;
case UNION:
int schemaPos = this.getUnionType();
Schema unioSchema = fieldSchema.getTypes().get(schemaPos);
Type unionType = unioSchema.getType();
value = getSuperValue(field, unioSchema, unionType);
break;
default:
Object memberValue = null;
// Using for UnionIndex of Union type field get value. UnionIndex always Integer.