private SchemaAndValue parseArray() {
            List<Object> result = new ArrayList<>();
            SchemaMerger elementSchema = new SchemaMerger();
            while (parser.hasNext()) {
                if (parser.canConsume(ARRAY_END_DELIMITER)) {
                    Schema listSchema;
                    if (elementSchema.hasCommonSchema()) {
                        listSchema = SchemaBuilder.array(elementSchema.schema()).schema();
                        result = alignListEntriesWithSchema(listSchema, result);
                    } else {
                        // Every value is null
                        listSchema = SchemaBuilder.arrayOfNull().build();
                    }
                    return new SchemaAndValue(listSchema, result);
                }

                if (parser.canConsume(COMMA_DELIMITER)) {
                    throw new DataException("Unable to parse an empty array element: " + parser.original());
                }
                SchemaAndValue element = parse(true);
                elementSchema.merge(element);
                result.add(element != null ? element.value() : null);

                int currentPosition = parser.mark();
                if (parser.canConsume(ARRAY_END_DELIMITER)) {
                    parser.rewindTo(currentPosition);
                } else if (!parser.canConsume(COMMA_DELIMITER)) {
                    throw new DataException("Array elements missing '" + COMMA_DELIMITER + "' delimiter");
                }
            }

            // Missing either a comma or an end delimiter
            if (COMMA_DELIMITER.equals(parser.previous())) {
                throw new DataException("Array is missing element after ',': " + parser.original());
            }
            throw new DataException("Array is missing terminating ']': " + parser.original());
        }
Convert the specified value with the desired floating point type.

@param value  the value to be converted; may not be null
@param schema the schema for the current value type; may not be null
@param error  any previous error that should be included in an exception message; may be null
@return the double value after conversion; never null
@throws DataException if the value could not be converted to a double
connect/api/src/main/java/org/apache/kafka/connect/data/Values.java