/** * Return the original values source, before we apply `missing`. */ private VS originalValuesSource() throws IOException { if (fieldContext() == null) { if (valueSourceType() == ValuesSourceType.NUMERIC) { return (VS) numericScript(); } if (valueSourceType() == ValuesSourceType.BYTES) { return (VS) bytesScript(); } throw new AggregationExecutionException("value source of type [" + valueSourceType().name() + "] is not supported by scripts"); } if (valueSourceType() == ValuesSourceType.NUMERIC) { return (VS) numericField(); } if (valueSourceType() == ValuesSourceType.GEOPOINT) { return (VS) geoPointField(); } // falling back to bytes values return (VS) bytesField(); }
/** * Return the original values source, before we apply `missing`. */ private VS originalValuesSource() throws IOException { if (fieldContext() == null) { if (valueSourceType() == ValuesSourceType.NUMERIC) { return (VS) numericScript(); } if (valueSourceType() == ValuesSourceType.BYTES) { return (VS) bytesScript(); } throw new AggregationExecutionException("value source of type [" + valueSourceType().name() + "] is not supported by scripts"); } if (valueSourceType() == ValuesSourceType.NUMERIC) { return (VS) numericField(); } if (valueSourceType() == ValuesSourceType.GEOPOINT) { return (VS) geoPointField(); } // falling back to bytes values return (VS) bytesField(); }
/** * Return the original values source, before we apply `missing`. */ private VS originalValuesSource() throws IOException { if (fieldContext() == null) { if (valueSourceType() == ValuesSourceType.NUMERIC) { return (VS) numericScript(); } if (valueSourceType() == ValuesSourceType.BYTES) { return (VS) bytesScript(); } throw new AggregationExecutionException("value source of type [" + valueSourceType().name() + "] is not supported by scripts"); } if (valueSourceType() == ValuesSourceType.NUMERIC) { return (VS) numericField(); } if (valueSourceType() == ValuesSourceType.GEOPOINT) { return (VS) geoPointField(); } // falling back to bytes values return (VS) bytesField(); }
/** * Return the original values source, before we apply `missing`. */ private VS originalValuesSource() throws IOException { if (fieldContext() == null) { if (valueSourceType() == ValuesSourceType.NUMERIC) { return (VS) numericScript(); } if (valueSourceType() == ValuesSourceType.BYTES) { return (VS) bytesScript(); } throw new AggregationExecutionException("value source of type [" + valueSourceType().name() + "] is not supported by scripts"); } if (valueSourceType() == ValuesSourceType.NUMERIC) { return (VS) numericField(); } if (valueSourceType() == ValuesSourceType.GEOPOINT) { return (VS) geoPointField(); } // falling back to bytes values return (VS) bytesField(); }