WebCAD-Lib-TS API 文档 - v1.0.0
    Preparing search index...

    Interface ParsedLine

    解析后的脚本行

    interface ParsedLine {
        lineNumber: number;
        type:
            | "set"
            | "label"
            | "command"
            | "goto"
            | "if"
            | "repeat"
            | "endrepeat"
            | "empty"
            | "comment";
        raw: string;
        content: string;
        labelName?: string;
        varName?: string;
        varValue?: string;
        gotoTarget?: string;
        condition?: string;
        repeatCount?: number;
    }
    Index

    Properties

    lineNumber: number

    行号(原始脚本中的位置)

    type:
        | "set"
        | "label"
        | "command"
        | "goto"
        | "if"
        | "repeat"
        | "endrepeat"
        | "empty"
        | "comment"

    行类型

    raw: string

    原始内容

    content: string

    处理后的内容(变量替换、表达式计算后)

    labelName?: string

    标签名(仅 label 类型)

    varName?: string

    变量名(仅 set 类型)

    varValue?: string

    变量值(仅 set 类型)

    gotoTarget?: string

    跳转目标(仅 goto/if 类型)

    condition?: string

    条件表达式(仅 if 类型)

    repeatCount?: number

    循环次数(仅 repeat 类型)