@lcap/asl
Version:
NetEase Application Specific Language
58 lines (57 loc) • 1.19 kB
TypeScript
import { Vertex, Enum, LEVEL_ENUM, ActionOptions } from '..';
/**
* 枚举项
*/
export declare class EnumItem extends Vertex {
/**
* 概念类型
*/
readonly level: LEVEL_ENUM;
/**
* Id
*/
readonly id: string;
/**
* 值
*/
readonly value: string;
/**
* 名称
*/
readonly label: string;
/**
* 枚举 Id
*/
readonly enumId: string;
/**
* 父级引用
*/
root: Enum;
/**
* @param source 需要合并的部分参数
*/
constructor(source?: Partial<EnumItem>);
/**
* 添加枚举项
*/
create(none?: void, actionOptions?: ActionOptions): Promise<this>;
/**
* 删除枚举项
*/
delete(none?: void, actionOptions?: ActionOptions): Promise<void>;
/**
* 修改枚举项
*/
update(none?: void, actionOptions?: ActionOptions, then?: () => Promise<any>): Promise<this>;
/**
* 设置枚举项值
* @param value
*/
setValue(value: string): Promise<void>;
/**
* 设置枚举项标题
* @param value
*/
setLabel(label: string): Promise<void>;
}
export default EnumItem;