import { FIELD_ORIGIN } from '../../../common/constants' ; import { IField , AbstractField } from './field' ; import { IVectorSource } from '../sources/vector_source' ; export class InlineField < T extends IVectorSource > extends AbstractField implements IField { private readonly _source : T ; private readonly _dataType : string ; constructor ( { fieldName , source , origin , dataType , } ) { super ( { fieldName , origin } ) ; this . _source = source ; this . _dataType = dataType ; } supportsFieldMetaFromEs ( ) { return false ; } supportsFieldMetaFromLocalData ( ) { return true ; } getSource ( ) { return this . _source ; } async getLabel ( ) { return this . getName ( ) ; } async getDataType ( ) { return this . _dataType ; } }