import { toJSONCompatibleValue as toJSONCompatValue , isNil } from '@terascope/utils' ; import { Vector , VectorOptions } from '../Vector' ; import { VectorType , DataBuckets , SerializeOptions } from '../interfaces' ; export class AnyVector extends Vector < any > { getComparableValue = undefined ; constructor ( data , options ) { super ( VectorType . Any , data , options ) ; } toJSONCompatibleValue ( value , options ? ) { const nilValue = options ?. useNullForUndefined ? null : undefined ; if ( isNil ( value ) ) return nilValue ; return toJSONCompatValue ( value ) ; } }