import { Maybe } from '@terascope/types';

/**
 * The Vector Type, this will change how the data is stored and read
 *
 * @todo add IP and IP_RANGE support
*/
export enum VectorType {
    /**
     * Currently this operates like String
     * but I imagine will be expanding it.
     * But will need to add format options
    */
    Date = 'Date',
    String = 'String',
    Int = 'Int',
    Float = 'Float',
    BigInt = 'BigInt',
    Boolean = 'Boolean',
    GeoPoint = 'GeoPoint',
    GeoJSON = 'GeoJSON',
    IP = 'IP',
    IP_RANGE = 'IP_RANGE',
    Object = 'Object',
    /**
     * Arbitrary data can be stored with this. Not recommended for use.
    */
    Any = 'Any',
    /**
     * The list type is used for fields marked as Arrays
     * where each item in the Vector is a child element
    */
    List = 'List',
}

/**
 * A data type agnostic in-memory representation of the data
 * for a Vector and potential indices.
 * This should be generated by the builder.
*/
export type Data<T> = Readonly<{
    readonly values: readonly Maybe<T>[];
}>;

import { Maybe } from '@terascope/types';

/**
 * The Vector Type, this will change how the data is stored and read
*/
export enum VectorType {
    /**
     * Currently this operates like String
     * but I imagine will be expanding it.
     * But will need to add format options
    */
    Date = 'Date',
    String = 'String',
    Int = 'Int',
    Float = 'Float',
    BigInt = 'BigInt',
    Boolean = 'Boolean',
    GeoPoint = 'GeoPoint',
    GeoJSON = 'GeoJSON',
    /** @todo */
    Object = 'Object',
    /**
     * Arbitrary data can be stored with this
    */
    Any = 'Any',
    /**
     * The list type is used for fields marked as Arrays
     * where each item in the Vector is a child element
    */
    List = 'List',
}

/**
 * A data type agnostic in-memory representation of the data
 * for a Vector and potential indices.
 * This should be generated by the builder.
*/
export type Data<T> = Readonly<{
    readonly values: readonly Maybe<T>[];
}>;

--- 
+++ 
@@ -2,6 +2,8 @@
 
 /**
  * The Vector Type, this will change how the data is stored and read
+ *
+ * @todo add IP and IP_RANGE support
 */
 export enum VectorType {
     /**
@@ -17,10 +19,11 @@
     Boolean = 'Boolean',
     GeoPoint = 'GeoPoint',
     GeoJSON = 'GeoJSON',
-    /** @todo */
+    IP = 'IP',
+    IP_RANGE = 'IP_RANGE',
     Object = 'Object',
     /**
-     * Arbitrary data can be stored with this
+     * Arbitrary data can be stored with this. Not recommended for use.
     */
     Any = 'Any',
     /**
Add todo for IP and IP_RANGE vectors
