import { Compile } from './base-compile'; import { ArrayAST, LiteralAST, ReferencesAST, StringAST } from '../type'; /** * literal parse, include string, integer, array, map, bool data structure * @require {method} getReferences */ export declare class LiteralCompiler extends Compile { /** * Evaluate literals, mainly including four data structures: string, integer, array, map * @param literal {object} Defined in the velocity.yy file, type describes the data type, * value property is the literal value description * @return js variable */ getLiteral(literal: LiteralAST | ReferencesAST): any; /** * Evaluate strings, for double-quoted strings, variable replacement needs to be done */ getString(literal: StringAST): string; /** * Evaluate array literals, e.g. [1, 2] => [1,2], [1..5] => [1,2,3,4,5] * @param literal {object} Description object of array literal, divided into two types: * normal array and range array */ getArray(literal: ArrayAST): unknown[]; }