dxf-json 0.0.8 → 0.0.10
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.github/workflows/npm-publish.yml +1 -1
- package/dist/bundle.js +2 -0
- package/dist/bundle.js.LICENSE.txt +5 -0
- package/dist/consts/block.d.ts +10 -0
- package/dist/consts/block.js +22 -0
- package/dist/consts/block.js.map +1 -0
- package/dist/consts/color.d.ts +5 -0
- package/dist/consts/color.js +10 -0
- package/dist/consts/color.js.map +1 -0
- package/dist/consts/config.d.ts +2 -0
- package/dist/consts/config.js +6 -0
- package/dist/consts/config.js.map +1 -0
- package/dist/consts/dimension.d.ts +61 -0
- package/dist/consts/dimension.js +74 -0
- package/dist/consts/dimension.js.map +1 -0
- package/dist/consts/hatch.d.ts +44 -0
- package/dist/consts/hatch.js +57 -0
- package/dist/consts/hatch.js.map +1 -0
- package/dist/consts/header.d.ts +9 -0
- package/dist/consts/header.js +13 -0
- package/dist/consts/header.js.map +1 -0
- package/dist/consts/index.d.ts +9 -0
- package/dist/consts/index.js +26 -0
- package/dist/consts/index.js.map +1 -0
- package/dist/consts/lineweight.d.ts +5 -0
- package/dist/consts/lineweight.js +10 -0
- package/dist/consts/lineweight.js.map +1 -0
- package/dist/consts/measurement.d.ts +4 -0
- package/dist/consts/measurement.js +9 -0
- package/dist/consts/measurement.js.map +1 -0
- package/dist/consts/obscuredLineTypes.d.ts +21 -0
- package/dist/consts/obscuredLineTypes.js +26 -0
- package/dist/consts/obscuredLineTypes.js.map +1 -0
- package/dist/consts/scene.d.ts +2 -0
- package/dist/consts/scene.js +6 -0
- package/dist/consts/scene.js.map +1 -0
- package/dist/consts/viewport.d.ts +56 -0
- package/dist/consts/viewport.js +67 -0
- package/dist/consts/viewport.js.map +1 -0
- package/dist/index.d.ts +2 -0
- package/dist/index.js +9 -0
- package/dist/index.js.map +1 -0
- package/dist/parser/AutoCadColorIndex.d.ts +8 -0
- package/dist/parser/AutoCadColorIndex.js +267 -0
- package/dist/parser/AutoCadColorIndex.js.map +1 -0
- package/dist/parser/DxfArrayScanner.d.ts +38 -0
- package/dist/parser/DxfArrayScanner.js +159 -0
- package/dist/parser/DxfArrayScanner.js.map +1 -0
- package/dist/parser/DxfParser.d.ts +11 -0
- package/dist/parser/DxfParser.js +108 -0
- package/dist/parser/DxfParser.js.map +1 -0
- package/dist/parser/ParseHelpers.d.ts +21 -0
- package/dist/parser/ParseHelpers.js +129 -0
- package/dist/parser/ParseHelpers.js.map +1 -0
- package/dist/parser/blocks/blocks.test.d.ts +1 -0
- package/dist/parser/blocks/blocks.test.js +86 -0
- package/dist/parser/blocks/blocks.test.js.map +1 -0
- package/dist/parser/blocks/index.d.ts +4 -0
- package/dist/parser/blocks/index.js +83 -0
- package/dist/parser/blocks/index.js.map +1 -0
- package/dist/parser/blocks/types.d.ts +14 -0
- package/dist/parser/blocks/types.js +3 -0
- package/dist/parser/blocks/types.js.map +1 -0
- package/dist/parser/entities/3dface.js +106 -0
- package/dist/parser/entities/3dface.js.map +1 -0
- package/dist/parser/entities/arc/index.d.ts +2 -0
- package/dist/parser/entities/arc/index.js +19 -0
- package/dist/parser/entities/arc/index.js.map +1 -0
- package/dist/parser/entities/arc/parser.d.ts +7 -0
- package/dist/parser/entities/arc/parser.js +63 -0
- package/dist/parser/entities/arc/parser.js.map +1 -0
- package/dist/parser/entities/arc/types.d.ts +12 -0
- package/dist/parser/entities/arc/types.js +3 -0
- package/dist/parser/entities/arc/types.js.map +1 -0
- package/dist/parser/entities/attdef/consts.d.ts +11 -0
- package/dist/parser/entities/attdef/consts.js +17 -0
- package/dist/parser/entities/attdef/consts.js.map +1 -0
- package/dist/parser/entities/attdef/index.d.ts +3 -0
- package/dist/parser/entities/attdef/index.js +20 -0
- package/dist/parser/entities/attdef/index.js.map +1 -0
- package/dist/parser/entities/attdef/parser.d.ts +8 -0
- package/dist/parser/entities/attdef/parser.js +108 -0
- package/dist/parser/entities/attdef/parser.js.map +1 -0
- package/dist/parser/entities/attdef/types.d.ts +17 -0
- package/dist/parser/entities/attdef/types.js +3 -0
- package/dist/parser/entities/attdef/types.js.map +1 -0
- package/dist/parser/entities/attribute/consts.d.ts +6 -0
- package/dist/parser/entities/attribute/consts.js +11 -0
- package/dist/parser/entities/attribute/consts.js.map +1 -0
- package/dist/parser/entities/attribute/index.d.ts +3 -0
- package/dist/parser/entities/attribute/index.js +20 -0
- package/dist/parser/entities/attribute/index.js.map +1 -0
- package/dist/parser/entities/attribute/parser.d.ts +8 -0
- package/dist/parser/entities/attribute/parser.js +185 -0
- package/dist/parser/entities/attribute/parser.js.map +1 -0
- package/dist/parser/entities/attribute/types.d.ts +30 -0
- package/dist/parser/entities/attribute/types.js +3 -0
- package/dist/parser/entities/attribute/types.js.map +1 -0
- package/dist/parser/entities/circle/index.d.ts +2 -0
- package/dist/parser/entities/circle/index.js +19 -0
- package/dist/parser/entities/circle/index.js.map +1 -0
- package/dist/parser/entities/circle/parser.d.ts +8 -0
- package/dist/parser/entities/circle/parser.js +50 -0
- package/dist/parser/entities/circle/parser.js.map +1 -0
- package/dist/parser/entities/circle/types.d.ts +10 -0
- package/dist/parser/entities/circle/types.js +3 -0
- package/dist/parser/entities/circle/types.js.map +1 -0
- package/dist/parser/entities/dimension/common.d.ts +6 -0
- package/dist/parser/entities/dimension/common.js +122 -0
- package/dist/parser/entities/dimension/common.js.map +1 -0
- package/dist/parser/entities/dimension/index.d.ts +6 -0
- package/dist/parser/entities/dimension/index.js +21 -0
- package/dist/parser/entities/dimension/index.js.map +1 -0
- package/dist/parser/entities/dimension/types.d.ts +48 -0
- package/dist/parser/entities/dimension/types.js +3 -0
- package/dist/parser/entities/dimension/types.js.map +1 -0
- package/dist/parser/entities/ellipse/index.d.ts +2 -0
- package/dist/parser/entities/ellipse/index.js +19 -0
- package/dist/parser/entities/ellipse/index.js.map +1 -0
- package/dist/parser/entities/ellipse/parser.d.ts +7 -0
- package/dist/parser/entities/ellipse/parser.js +59 -0
- package/dist/parser/entities/ellipse/parser.js.map +1 -0
- package/dist/parser/entities/ellipse/types.d.ts +12 -0
- package/dist/parser/entities/ellipse/types.js +3 -0
- package/dist/parser/entities/ellipse/types.js.map +1 -0
- package/dist/parser/entities/entities.test.d.ts +1 -0
- package/dist/parser/entities/entities.test.js +81 -0
- package/dist/parser/entities/entities.test.js.map +1 -0
- package/dist/parser/entities/hatch/boundaryPathData/edge.d.ts +6 -0
- package/dist/parser/entities/hatch/boundaryPathData/edge.js +178 -0
- package/dist/parser/entities/hatch/boundaryPathData/edge.js.map +1 -0
- package/dist/parser/entities/hatch/boundaryPathData/index.d.ts +5 -0
- package/dist/parser/entities/hatch/boundaryPathData/index.js +23 -0
- package/dist/parser/entities/hatch/boundaryPathData/index.js.map +1 -0
- package/dist/parser/entities/hatch/boundaryPathData/polyline.d.ts +2 -0
- package/dist/parser/entities/hatch/boundaryPathData/polyline.js +41 -0
- package/dist/parser/entities/hatch/boundaryPathData/polyline.js.map +1 -0
- package/dist/parser/entities/hatch/boundaryPathData/shared.d.ts +2 -0
- package/dist/parser/entities/hatch/boundaryPathData/shared.js +19 -0
- package/dist/parser/entities/hatch/boundaryPathData/shared.js.map +1 -0
- package/dist/parser/entities/hatch/index.d.ts +8 -0
- package/dist/parser/entities/hatch/index.js +183 -0
- package/dist/parser/entities/hatch/index.js.map +1 -0
- package/dist/parser/entities/hatch/patternData.d.ts +3 -0
- package/dist/parser/entities/hatch/patternData.js +54 -0
- package/dist/parser/entities/hatch/patternData.js.map +1 -0
- package/dist/parser/entities/hatch/types/boundaryPath.d.ts +59 -0
- package/dist/parser/entities/hatch/types/boundaryPath.js +3 -0
- package/dist/parser/entities/hatch/types/boundaryPath.js.map +1 -0
- package/dist/parser/entities/hatch/types/definitionLine.d.ts +8 -0
- package/dist/parser/entities/hatch/types/definitionLine.js +3 -0
- package/dist/parser/entities/hatch/types/definitionLine.js.map +1 -0
- package/dist/parser/entities/hatch/types/hatch.d.ts +38 -0
- package/dist/parser/entities/hatch/types/hatch.js +3 -0
- package/dist/parser/entities/hatch/types/hatch.js.map +1 -0
- package/dist/parser/entities/hatch/types/index.d.ts +3 -0
- package/dist/parser/entities/hatch/types/index.js +20 -0
- package/dist/parser/entities/hatch/types/index.js.map +1 -0
- package/dist/parser/entities/index.d.ts +8 -0
- package/dist/parser/entities/index.js +81 -0
- package/dist/parser/entities/index.js.map +1 -0
- package/dist/parser/entities/insert/index.d.ts +2 -0
- package/dist/parser/entities/insert/index.js +19 -0
- package/dist/parser/entities/insert/index.js.map +1 -0
- package/dist/parser/entities/insert/parser.d.ts +8 -0
- package/dist/parser/entities/insert/parser.js +97 -0
- package/dist/parser/entities/insert/parser.js.map +1 -0
- package/dist/parser/entities/insert/types.d.ts +18 -0
- package/dist/parser/entities/insert/types.js +3 -0
- package/dist/parser/entities/insert/types.js.map +1 -0
- package/dist/parser/entities/leader/consts.d.ts +6 -0
- package/dist/parser/entities/leader/consts.js +11 -0
- package/dist/parser/entities/leader/consts.js.map +1 -0
- package/dist/parser/entities/leader/index.d.ts +3 -0
- package/dist/parser/entities/leader/index.js +20 -0
- package/dist/parser/entities/leader/index.js.map +1 -0
- package/dist/parser/entities/leader/parser.d.ts +8 -0
- package/dist/parser/entities/leader/parser.js +110 -0
- package/dist/parser/entities/leader/parser.js.map +1 -0
- package/dist/parser/entities/leader/types.d.ts +23 -0
- package/dist/parser/entities/leader/types.js +3 -0
- package/dist/parser/entities/leader/types.js.map +1 -0
- package/dist/parser/entities/line/index.d.ts +2 -0
- package/dist/parser/entities/line/index.js +19 -0
- package/dist/parser/entities/line/index.js.map +1 -0
- package/dist/parser/entities/line/parser.d.ts +8 -0
- package/dist/parser/entities/line/parser.js +50 -0
- package/dist/parser/entities/line/parser.js.map +1 -0
- package/dist/parser/entities/line/types.d.ts +10 -0
- package/dist/parser/entities/line/types.js +3 -0
- package/dist/parser/entities/line/types.js.map +1 -0
- package/dist/parser/entities/lwpolyline/consts.d.ts +4 -0
- package/dist/parser/entities/lwpolyline/consts.js +9 -0
- package/dist/parser/entities/lwpolyline/consts.js.map +1 -0
- package/dist/parser/entities/lwpolyline/index.d.ts +3 -0
- package/dist/parser/entities/lwpolyline/index.js +20 -0
- package/dist/parser/entities/lwpolyline/index.js.map +1 -0
- package/dist/parser/entities/lwpolyline/parser.d.ts +7 -0
- package/dist/parser/entities/lwpolyline/parser.js +105 -0
- package/dist/parser/entities/lwpolyline/parser.js.map +1 -0
- package/dist/parser/entities/lwpolyline/types.d.ts +19 -0
- package/dist/parser/entities/lwpolyline/types.js +3 -0
- package/dist/parser/entities/lwpolyline/types.js.map +1 -0
- package/dist/parser/entities/mtext/consts.d.ts +5 -0
- package/dist/parser/entities/mtext/consts.js +10 -0
- package/dist/parser/entities/mtext/consts.js.map +1 -0
- package/dist/parser/entities/mtext/index.d.ts +3 -0
- package/dist/parser/entities/mtext/index.js +20 -0
- package/dist/parser/entities/mtext/index.js.map +1 -0
- package/dist/parser/entities/mtext/parser.d.ts +10 -0
- package/dist/parser/entities/mtext/parser.js +188 -0
- package/dist/parser/entities/mtext/parser.js.map +1 -0
- package/dist/parser/entities/mtext/types.d.ts +33 -0
- package/dist/parser/entities/mtext/types.js +3 -0
- package/dist/parser/entities/mtext/types.js.map +1 -0
- package/dist/parser/entities/point/index.d.ts +2 -0
- package/dist/parser/entities/point/index.js +19 -0
- package/dist/parser/entities/point/index.js.map +1 -0
- package/dist/parser/entities/point/parser.d.ts +6 -0
- package/dist/parser/entities/point/parser.js +54 -0
- package/dist/parser/entities/point/parser.js.map +1 -0
- package/dist/parser/entities/point/types.d.ts +9 -0
- package/dist/parser/entities/point/types.js +3 -0
- package/dist/parser/entities/point/types.js.map +1 -0
- package/dist/parser/entities/polyline/consts.d.ts +16 -0
- package/dist/parser/entities/polyline/consts.js +22 -0
- package/dist/parser/entities/polyline/consts.js.map +1 -0
- package/dist/parser/entities/polyline/index.d.ts +3 -0
- package/dist/parser/entities/polyline/index.js +20 -0
- package/dist/parser/entities/polyline/index.js.map +1 -0
- package/dist/parser/entities/polyline/parser.d.ts +7 -0
- package/dist/parser/entities/polyline/parser.js +118 -0
- package/dist/parser/entities/polyline/parser.js.map +1 -0
- package/dist/parser/entities/polyline/types.d.ts +19 -0
- package/dist/parser/entities/polyline/types.js +3 -0
- package/dist/parser/entities/polyline/types.js.map +1 -0
- package/dist/parser/entities/section/index.d.ts +2 -0
- package/dist/parser/entities/section/index.js +19 -0
- package/dist/parser/entities/section/index.js.map +1 -0
- package/dist/parser/entities/section/parser.d.ts +7 -0
- package/dist/parser/entities/section/parser.js +97 -0
- package/dist/parser/entities/section/parser.js.map +1 -0
- package/dist/parser/entities/section/types.d.ts +19 -0
- package/dist/parser/entities/section/types.js +3 -0
- package/dist/parser/entities/section/types.js.map +1 -0
- package/dist/parser/entities/shared.d.ts +35 -0
- package/dist/parser/entities/shared.js +136 -0
- package/dist/parser/entities/shared.js.map +1 -0
- package/dist/parser/entities/solid/index.d.ts +2 -0
- package/dist/parser/entities/solid/index.js +19 -0
- package/dist/parser/entities/solid/index.js.map +1 -0
- package/dist/parser/entities/solid/parser.d.ts +8 -0
- package/dist/parser/entities/solid/parser.js +48 -0
- package/dist/parser/entities/solid/parser.js.map +1 -0
- package/dist/parser/entities/solid/types.d.ts +9 -0
- package/dist/parser/entities/solid/types.js +3 -0
- package/dist/parser/entities/solid/types.js.map +1 -0
- package/dist/parser/entities/spline/consts.d.ts +8 -0
- package/dist/parser/entities/spline/consts.js +13 -0
- package/dist/parser/entities/spline/consts.js.map +1 -0
- package/dist/parser/entities/spline/index.d.ts +3 -0
- package/dist/parser/entities/spline/index.js +20 -0
- package/dist/parser/entities/spline/index.js.map +1 -0
- package/dist/parser/entities/spline/parser.d.ts +8 -0
- package/dist/parser/entities/spline/parser.js +113 -0
- package/dist/parser/entities/spline/parser.js.map +1 -0
- package/dist/parser/entities/spline/types.d.ts +21 -0
- package/dist/parser/entities/spline/types.js +3 -0
- package/dist/parser/entities/spline/types.js.map +1 -0
- package/dist/parser/entities/text/consts.d.ts +19 -0
- package/dist/parser/entities/text/consts.js +26 -0
- package/dist/parser/entities/text/consts.js.map +1 -0
- package/dist/parser/entities/text/index.d.ts +3 -0
- package/dist/parser/entities/text/index.js +20 -0
- package/dist/parser/entities/text/index.js.map +1 -0
- package/dist/parser/entities/text/parser.d.ts +26 -0
- package/dist/parser/entities/text/parser.js +112 -0
- package/dist/parser/entities/text/parser.js.map +1 -0
- package/dist/parser/entities/text/types.d.ts +20 -0
- package/dist/parser/entities/text/types.js +3 -0
- package/dist/parser/entities/text/types.js.map +1 -0
- package/dist/parser/entities/vertex/consts.d.ts +10 -0
- package/dist/parser/entities/vertex/consts.js +15 -0
- package/dist/parser/entities/vertex/consts.js.map +1 -0
- package/dist/parser/entities/vertex/index.d.ts +3 -0
- package/dist/parser/entities/vertex/index.js +20 -0
- package/dist/parser/entities/vertex/index.js.map +1 -0
- package/dist/parser/entities/vertex/parser.d.ts +8 -0
- package/dist/parser/entities/vertex/parser.js +86 -0
- package/dist/parser/entities/vertex/parser.js.map +1 -0
- package/dist/parser/entities/vertex/types.d.ts +16 -0
- package/dist/parser/entities/vertex/types.js +3 -0
- package/dist/parser/entities/vertex/types.js.map +1 -0
- package/dist/parser/entities/viewport/index.d.ts +5 -0
- package/dist/parser/entities/viewport/index.js +195 -0
- package/dist/parser/entities/viewport/index.js.map +1 -0
- package/dist/parser/entities/viewport/types.d.ts +51 -0
- package/dist/parser/entities/viewport/types.js +3 -0
- package/dist/parser/entities/viewport/types.js.map +1 -0
- package/dist/parser/filterDummyBlocks.d.ts +2 -0
- package/dist/parser/filterDummyBlocks.js +37 -0
- package/dist/parser/filterDummyBlocks.js.map +1 -0
- package/dist/parser/header/index.d.ts +3 -0
- package/dist/parser/header/index.js +32 -0
- package/dist/parser/header/index.js.map +1 -0
- package/dist/parser/objects/common.d.ts +8 -0
- package/dist/parser/objects/common.js +51 -0
- package/dist/parser/objects/common.js.map +1 -0
- package/dist/parser/objects/dictionary.d.ts +20 -0
- package/dist/parser/objects/dictionary.js +50 -0
- package/dist/parser/objects/dictionary.js.map +1 -0
- package/dist/parser/objects/index.d.ts +6 -0
- package/dist/parser/objects/index.js +43 -0
- package/dist/parser/objects/index.js.map +1 -0
- package/dist/parser/objects/layout.d.ts +30 -0
- package/dist/parser/objects/layout.js +110 -0
- package/dist/parser/objects/layout.js.map +1 -0
- package/dist/parser/objects/plotSettings.d.ts +64 -0
- package/dist/parser/objects/plotSettings.js +198 -0
- package/dist/parser/objects/plotSettings.js.map +1 -0
- package/dist/parser/objects/treefy.d.ts +2 -0
- package/dist/parser/objects/treefy.js +37 -0
- package/dist/parser/objects/treefy.js.map +1 -0
- package/dist/parser/objects/types.d.ts +15 -0
- package/dist/parser/objects/types.js +3 -0
- package/dist/parser/objects/types.js.map +1 -0
- package/dist/parser/shared/index.d.ts +7 -0
- package/dist/parser/shared/index.js +22 -0
- package/dist/parser/shared/index.js.map +1 -0
- package/dist/parser/shared/parsePoint.d.ts +7 -0
- package/dist/parser/shared/parsePoint.js +33 -0
- package/dist/parser/shared/parsePoint.js.map +1 -0
- package/dist/parser/shared/parserGenerator.d.ts +15 -0
- package/dist/parser/shared/parserGenerator.js +114 -0
- package/dist/parser/shared/parserGenerator.js.map +1 -0
- package/dist/parser/shared/parserGenerator.test.d.ts +1 -0
- package/dist/parser/shared/parserGenerator.test.js +153 -0
- package/dist/parser/shared/parserGenerator.test.js.map +1 -0
- package/dist/parser/shared/xdata/index.d.ts +3 -0
- package/dist/parser/shared/xdata/index.js +20 -0
- package/dist/parser/shared/xdata/index.js.map +1 -0
- package/dist/parser/shared/xdata/interpreter.d.ts +20 -0
- package/dist/parser/shared/xdata/interpreter.js +43 -0
- package/dist/parser/shared/xdata/interpreter.js.map +1 -0
- package/dist/parser/shared/xdata/interpreter.test.d.ts +1 -0
- package/dist/parser/shared/xdata/interpreter.test.js +83 -0
- package/dist/parser/shared/xdata/interpreter.test.js.map +1 -0
- package/dist/parser/shared/xdata/parser.d.ts +6 -0
- package/dist/parser/shared/xdata/parser.js +133 -0
- package/dist/parser/shared/xdata/parser.js.map +1 -0
- package/dist/parser/shared/xdata/parser.test.d.ts +1 -0
- package/dist/parser/shared/xdata/parser.test.js +64 -0
- package/dist/parser/shared/xdata/parser.test.js.map +1 -0
- package/dist/parser/shared/xdata/types.d.ts +9 -0
- package/dist/parser/shared/xdata/types.js +3 -0
- package/dist/parser/shared/xdata/types.js.map +1 -0
- package/dist/parser/tables/blockRecord/index.d.ts +2 -0
- package/dist/parser/tables/blockRecord/index.js +19 -0
- package/dist/parser/tables/blockRecord/index.js.map +1 -0
- package/dist/parser/tables/blockRecord/parser.d.ts +1 -0
- package/dist/parser/tables/blockRecord/parser.js +45 -0
- package/dist/parser/tables/blockRecord/parser.js.map +1 -0
- package/dist/parser/tables/blockRecord/types.d.ts +10 -0
- package/dist/parser/tables/blockRecord/types.js +3 -0
- package/dist/parser/tables/blockRecord/types.js.map +1 -0
- package/dist/parser/tables/dimStyle/consts.d.ts +2 -0
- package/dist/parser/tables/dimStyle/consts.js +424 -0
- package/dist/parser/tables/dimStyle/consts.js.map +1 -0
- package/dist/parser/tables/dimStyle/index.d.ts +3 -0
- package/dist/parser/tables/dimStyle/index.js +20 -0
- package/dist/parser/tables/dimStyle/index.js.map +1 -0
- package/dist/parser/tables/dimStyle/parser.d.ts +1 -0
- package/dist/parser/tables/dimStyle/parser.js +35 -0
- package/dist/parser/tables/dimStyle/parser.js.map +1 -0
- package/dist/parser/tables/dimStyle/types.d.ts +83 -0
- package/dist/parser/tables/dimStyle/types.js +3 -0
- package/dist/parser/tables/dimStyle/types.js.map +1 -0
- package/dist/parser/tables/index.d.ts +2 -0
- package/dist/parser/tables/index.js +19 -0
- package/dist/parser/tables/index.js.map +1 -0
- package/dist/parser/tables/layer/index.d.ts +2 -0
- package/dist/parser/tables/layer/index.js +19 -0
- package/dist/parser/tables/layer/index.js.map +1 -0
- package/dist/parser/tables/layer/parser.d.ts +1 -0
- package/dist/parser/tables/layer/parser.js +55 -0
- package/dist/parser/tables/layer/parser.js.map +1 -0
- package/dist/parser/tables/layer/types.d.ts +13 -0
- package/dist/parser/tables/layer/types.js +3 -0
- package/dist/parser/tables/layer/types.js.map +1 -0
- package/dist/parser/tables/ltype/consts.d.ts +6 -0
- package/dist/parser/tables/ltype/consts.js +11 -0
- package/dist/parser/tables/ltype/consts.js.map +1 -0
- package/dist/parser/tables/ltype/index.d.ts +3 -0
- package/dist/parser/tables/ltype/index.js +20 -0
- package/dist/parser/tables/ltype/index.js.map +1 -0
- package/dist/parser/tables/ltype/parser.d.ts +1 -0
- package/dist/parser/tables/ltype/parser.js +105 -0
- package/dist/parser/tables/ltype/parser.js.map +1 -0
- package/dist/parser/tables/ltype/types.d.ts +21 -0
- package/dist/parser/tables/ltype/types.js +3 -0
- package/dist/parser/tables/ltype/types.js.map +1 -0
- package/dist/parser/tables/parser.d.ts +2 -0
- package/dist/parser/tables/parser.js +90 -0
- package/dist/parser/tables/parser.js.map +1 -0
- package/dist/parser/tables/shared.d.ts +2 -0
- package/dist/parser/tables/shared.js +32 -0
- package/dist/parser/tables/shared.js.map +1 -0
- package/dist/parser/tables/style/index.d.ts +2 -0
- package/dist/parser/tables/style/index.js +19 -0
- package/dist/parser/tables/style/index.js.map +1 -0
- package/dist/parser/tables/style/parser.d.ts +1 -0
- package/dist/parser/tables/style/parser.js +68 -0
- package/dist/parser/tables/style/parser.js.map +1 -0
- package/dist/parser/tables/style/types.d.ts +14 -0
- package/dist/parser/tables/style/types.js +3 -0
- package/dist/parser/tables/style/types.js.map +1 -0
- package/dist/parser/tables/types.d.ts +14 -0
- package/dist/parser/tables/types.js +3 -0
- package/dist/parser/tables/types.js.map +1 -0
- package/dist/parser/tables/vport/index.d.ts +2 -0
- package/dist/parser/tables/vport/index.js +19 -0
- package/dist/parser/tables/vport/index.js.map +1 -0
- package/dist/parser/tables/vport/parser.d.ts +1 -0
- package/dist/parser/tables/vport/parser.js +201 -0
- package/dist/parser/tables/vport/parser.js.map +1 -0
- package/dist/parser/tables/vport/types.d.ts +43 -0
- package/dist/parser/tables/vport/types.js +3 -0
- package/dist/parser/tables/vport/types.js.map +1 -0
- package/dist/parser/types.d.ts +29 -0
- package/dist/parser/types.js +3 -0
- package/dist/parser/types.js.map +1 -0
- package/dist/types/color.d.ts +3 -0
- package/dist/types/color.js +3 -0
- package/dist/types/color.js.map +1 -0
- package/dist/types/dxfHeader.d.ts +16 -0
- package/dist/types/dxfHeader.js +3 -0
- package/dist/types/dxfHeader.js.map +1 -0
- package/dist/types/entity.d.ts +6 -0
- package/dist/types/entity.js +3 -0
- package/dist/types/entity.js.map +1 -0
- package/dist/types/index.d.ts +24 -0
- package/dist/types/index.js +20 -0
- package/dist/types/index.js.map +1 -0
- package/dist/utils/binarySearch.d.ts +1 -0
- package/dist/utils/binarySearch.js +23 -0
- package/dist/utils/binarySearch.js.map +1 -0
- package/dist/utils/disjointSet.d.ts +6 -0
- package/dist/utils/disjointSet.js +52 -0
- package/dist/utils/disjointSet.js.map +1 -0
- package/dist/utils/flooding.d.ts +8 -0
- package/dist/utils/flooding.js +26 -0
- package/dist/utils/flooding.js.map +1 -0
- package/dist/utils/functional.d.ts +17 -0
- package/dist/utils/functional.js +111 -0
- package/dist/utils/functional.js.map +1 -0
- package/dist/utils/graph.d.ts +19 -0
- package/dist/utils/graph.js +47 -0
- package/dist/utils/graph.js.map +1 -0
- package/dist/utils/index.d.ts +30 -0
- package/dist/utils/index.js +106 -0
- package/dist/utils/index.js.map +1 -0
- package/dist/utils/queue.d.ts +19 -0
- package/dist/utils/queue.js +71 -0
- package/dist/utils/queue.js.map +1 -0
- package/dist/utils/triangle.d.ts +2 -0
- package/dist/utils/triangle.js +19 -0
- package/dist/utils/triangle.js.map +1 -0
- package/package.json +2 -2
- package/src/parser/DxfParser.ts +2 -1
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.SmoothType = exports.PolylineFlag = void 0;
|
|
4
|
+
var PolylineFlag;
|
|
5
|
+
(function (PolylineFlag) {
|
|
6
|
+
PolylineFlag[PolylineFlag["CLOSED_POLYLINE"] = 1] = "CLOSED_POLYLINE";
|
|
7
|
+
PolylineFlag[PolylineFlag["CURVE_FIT"] = 2] = "CURVE_FIT";
|
|
8
|
+
PolylineFlag[PolylineFlag["SPLINE_FIT"] = 4] = "SPLINE_FIT";
|
|
9
|
+
PolylineFlag[PolylineFlag["POLYLINE_3D"] = 8] = "POLYLINE_3D";
|
|
10
|
+
PolylineFlag[PolylineFlag["POLYGON_3D"] = 16] = "POLYGON_3D";
|
|
11
|
+
PolylineFlag[PolylineFlag["CLOSED_POLYGON"] = 32] = "CLOSED_POLYGON";
|
|
12
|
+
PolylineFlag[PolylineFlag["POLYFACE"] = 64] = "POLYFACE";
|
|
13
|
+
PolylineFlag[PolylineFlag["CONTINUOUS"] = 128] = "CONTINUOUS";
|
|
14
|
+
})(PolylineFlag || (exports.PolylineFlag = PolylineFlag = {}));
|
|
15
|
+
var SmoothType;
|
|
16
|
+
(function (SmoothType) {
|
|
17
|
+
SmoothType[SmoothType["NONE"] = 0] = "NONE";
|
|
18
|
+
SmoothType[SmoothType["QUADRATIC"] = 5] = "QUADRATIC";
|
|
19
|
+
SmoothType[SmoothType["CUBIC"] = 6] = "CUBIC";
|
|
20
|
+
SmoothType[SmoothType["BEZIER"] = 8] = "BEZIER";
|
|
21
|
+
})(SmoothType || (exports.SmoothType = SmoothType = {}));
|
|
22
|
+
//# sourceMappingURL=consts.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"consts.js","sourceRoot":"","sources":["../../../../src/parser/entities/polyline/consts.ts"],"names":[],"mappings":";;;AAAA,IAAY,YASX;AATD,WAAY,YAAY;IACpB,qEAAmB,CAAA;IACnB,yDAAa,CAAA;IACb,2DAAc,CAAA;IACd,6DAAe,CAAA;IACf,4DAAe,CAAA;IACf,oEAAmB,CAAA;IACnB,wDAAa,CAAA;IACb,6DAAgB,CAAA;AACpB,CAAC,EATW,YAAY,4BAAZ,YAAY,QASvB;AAED,IAAY,UAKX;AALD,WAAY,UAAU;IAClB,2CAAQ,CAAA;IACR,qDAAa,CAAA;IACb,6CAAS,CAAA;IACT,+CAAU,CAAA;AACd,CAAC,EALW,UAAU,0BAAV,UAAU,QAKrB"}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
+
};
|
|
16
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
+
__exportStar(require("./types"), exports);
|
|
18
|
+
__exportStar(require("./consts"), exports);
|
|
19
|
+
__exportStar(require("./parser"), exports);
|
|
20
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/parser/entities/polyline/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,0CAAwB;AACxB,2CAAyB;AACzB,2CAAyB"}
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import type DxfArrayScanner from '../../DxfArrayScanner';
|
|
2
|
+
import type { ScannerGroup } from '../../DxfArrayScanner';
|
|
3
|
+
export declare class PolylineParser {
|
|
4
|
+
static ForEntityName: string;
|
|
5
|
+
private parser;
|
|
6
|
+
parseEntity(scanner: DxfArrayScanner, curr: ScannerGroup): any;
|
|
7
|
+
}
|
|
@@ -0,0 +1,118 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.PolylineParser = void 0;
|
|
4
|
+
const shared_1 = require("../../shared");
|
|
5
|
+
const parserGenerator_1 = require("../../shared/parserGenerator");
|
|
6
|
+
const shared_2 = require("../shared");
|
|
7
|
+
const vertex_1 = require("../vertex");
|
|
8
|
+
const DefaultPolylineEntity = {
|
|
9
|
+
thickness: 0,
|
|
10
|
+
flag: 0,
|
|
11
|
+
startWidth: 0,
|
|
12
|
+
endWidth: 0,
|
|
13
|
+
meshMVertexCount: 0,
|
|
14
|
+
meshNVertexCount: 0,
|
|
15
|
+
surfaceMDensity: 0,
|
|
16
|
+
surfaceNDensity: 0,
|
|
17
|
+
smoothType: 0,
|
|
18
|
+
extrusionDirection: { x: 0, y: 0, z: 1 },
|
|
19
|
+
vertices: [],
|
|
20
|
+
};
|
|
21
|
+
const PolylineParserSnippets = [
|
|
22
|
+
{
|
|
23
|
+
code: 0,
|
|
24
|
+
name: 'vertices',
|
|
25
|
+
isMultiple: true,
|
|
26
|
+
parser(curr, scanner) {
|
|
27
|
+
// Polyline 정의부 이후 바로 다음에 이것들이 나옴
|
|
28
|
+
if (!(0, shared_1.isMatched)(curr, 0, 'VERTEX')) {
|
|
29
|
+
return parserGenerator_1.Abort;
|
|
30
|
+
}
|
|
31
|
+
curr = scanner.next();
|
|
32
|
+
return new vertex_1.VertexParser().parseEntity(scanner, curr);
|
|
33
|
+
},
|
|
34
|
+
},
|
|
35
|
+
{
|
|
36
|
+
code: 210,
|
|
37
|
+
name: 'extrusionDirection',
|
|
38
|
+
parser: parserGenerator_1.PointParser,
|
|
39
|
+
},
|
|
40
|
+
{
|
|
41
|
+
code: 75,
|
|
42
|
+
name: 'smoothType',
|
|
43
|
+
parser: parserGenerator_1.Identity,
|
|
44
|
+
},
|
|
45
|
+
{
|
|
46
|
+
code: 74,
|
|
47
|
+
name: 'surfaceNDensity',
|
|
48
|
+
parser: parserGenerator_1.Identity,
|
|
49
|
+
},
|
|
50
|
+
{
|
|
51
|
+
code: 73,
|
|
52
|
+
name: 'surfaceMDensity',
|
|
53
|
+
parser: parserGenerator_1.Identity,
|
|
54
|
+
},
|
|
55
|
+
{
|
|
56
|
+
code: 72,
|
|
57
|
+
name: 'meshNVertexCount',
|
|
58
|
+
parser: parserGenerator_1.Identity,
|
|
59
|
+
},
|
|
60
|
+
{
|
|
61
|
+
code: 71,
|
|
62
|
+
name: 'meshMVertexCount',
|
|
63
|
+
parser: parserGenerator_1.Identity,
|
|
64
|
+
},
|
|
65
|
+
{
|
|
66
|
+
code: 41,
|
|
67
|
+
name: 'endWidth',
|
|
68
|
+
parser: parserGenerator_1.Identity,
|
|
69
|
+
},
|
|
70
|
+
{
|
|
71
|
+
code: 40,
|
|
72
|
+
name: 'startWidth',
|
|
73
|
+
parser: parserGenerator_1.Identity,
|
|
74
|
+
},
|
|
75
|
+
{
|
|
76
|
+
code: 70,
|
|
77
|
+
name: 'flag',
|
|
78
|
+
parser: parserGenerator_1.Identity,
|
|
79
|
+
},
|
|
80
|
+
{
|
|
81
|
+
code: 39,
|
|
82
|
+
name: 'thickness',
|
|
83
|
+
parser: parserGenerator_1.Identity,
|
|
84
|
+
},
|
|
85
|
+
{
|
|
86
|
+
code: 30,
|
|
87
|
+
name: 'elevation',
|
|
88
|
+
parser: parserGenerator_1.Identity,
|
|
89
|
+
},
|
|
90
|
+
{
|
|
91
|
+
code: 20, // dummy point, always 0
|
|
92
|
+
},
|
|
93
|
+
{
|
|
94
|
+
code: 10, // dummy point, always 0
|
|
95
|
+
},
|
|
96
|
+
{
|
|
97
|
+
code: 66, // obsolete, ignore
|
|
98
|
+
},
|
|
99
|
+
{
|
|
100
|
+
code: 100,
|
|
101
|
+
name: 'subclassMarker',
|
|
102
|
+
parser: parserGenerator_1.Identity,
|
|
103
|
+
},
|
|
104
|
+
...shared_2.CommonEntitySnippets,
|
|
105
|
+
];
|
|
106
|
+
class PolylineParser {
|
|
107
|
+
constructor() {
|
|
108
|
+
this.parser = (0, parserGenerator_1.createParser)(PolylineParserSnippets, DefaultPolylineEntity);
|
|
109
|
+
}
|
|
110
|
+
parseEntity(scanner, curr) {
|
|
111
|
+
const entity = {};
|
|
112
|
+
this.parser(curr, scanner, entity);
|
|
113
|
+
return entity;
|
|
114
|
+
}
|
|
115
|
+
}
|
|
116
|
+
exports.PolylineParser = PolylineParser;
|
|
117
|
+
PolylineParser.ForEntityName = 'POLYLINE';
|
|
118
|
+
//# sourceMappingURL=parser.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"parser.js","sourceRoot":"","sources":["../../../../src/parser/entities/polyline/parser.ts"],"names":[],"mappings":"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"}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import type { Point3D } from '../../../types';
|
|
2
|
+
import { CommonDxfEntity } from '../shared';
|
|
3
|
+
import { VertexEntity } from '../vertex/types';
|
|
4
|
+
import type { SmoothType } from './consts';
|
|
5
|
+
export interface PolylineEntity extends CommonDxfEntity {
|
|
6
|
+
type: 'POLYLINE';
|
|
7
|
+
subclassMarker: 'AcDb2dPolyline | AcDb3dPolyline';
|
|
8
|
+
thickness: number;
|
|
9
|
+
flag: number;
|
|
10
|
+
startWidth: number;
|
|
11
|
+
endWidth: number;
|
|
12
|
+
meshMVertexCount: number;
|
|
13
|
+
meshNVertexCount: number;
|
|
14
|
+
surfaceMDensity: number;
|
|
15
|
+
surfaceNDensity: number;
|
|
16
|
+
smoothType: SmoothType;
|
|
17
|
+
extrusionDirection: Point3D;
|
|
18
|
+
vertices: VertexEntity[];
|
|
19
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"types.js","sourceRoot":"","sources":["../../../../src/parser/entities/polyline/types.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
+
};
|
|
16
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
+
__exportStar(require("./types"), exports);
|
|
18
|
+
__exportStar(require("./parser"), exports);
|
|
19
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/parser/entities/section/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,0CAAwB;AACxB,2CAAyB"}
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import type DxfArrayScanner from '../../DxfArrayScanner';
|
|
2
|
+
import type { ScannerGroup } from '../../DxfArrayScanner';
|
|
3
|
+
export declare class SectionEntityParser {
|
|
4
|
+
static ForEntityName: string;
|
|
5
|
+
private parser;
|
|
6
|
+
parseEntity(scanner: DxfArrayScanner, curr: ScannerGroup): any;
|
|
7
|
+
}
|
|
@@ -0,0 +1,97 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.SectionEntityParser = void 0;
|
|
4
|
+
const parserGenerator_1 = require("../../shared/parserGenerator");
|
|
5
|
+
const shared_1 = require("../shared");
|
|
6
|
+
const DefaultSectionEntity = {
|
|
7
|
+
vertices: [],
|
|
8
|
+
backLineVertices: [],
|
|
9
|
+
};
|
|
10
|
+
const SectionEntityParserSnippets = [
|
|
11
|
+
{
|
|
12
|
+
code: 360,
|
|
13
|
+
name: 'geometrySettingHardId',
|
|
14
|
+
parser: parserGenerator_1.Identity,
|
|
15
|
+
},
|
|
16
|
+
{
|
|
17
|
+
code: 12,
|
|
18
|
+
name: 'backLineVertices',
|
|
19
|
+
isMultiple: true,
|
|
20
|
+
parser: parserGenerator_1.PointParser,
|
|
21
|
+
},
|
|
22
|
+
{
|
|
23
|
+
code: 93,
|
|
24
|
+
name: 'numberOfBackLineVertices',
|
|
25
|
+
parser: parserGenerator_1.Identity,
|
|
26
|
+
},
|
|
27
|
+
{
|
|
28
|
+
code: 11,
|
|
29
|
+
name: 'vertices',
|
|
30
|
+
isMultiple: true,
|
|
31
|
+
parser: parserGenerator_1.PointParser,
|
|
32
|
+
},
|
|
33
|
+
{
|
|
34
|
+
code: 92,
|
|
35
|
+
name: 'verticesCount',
|
|
36
|
+
parser: parserGenerator_1.Identity,
|
|
37
|
+
},
|
|
38
|
+
{
|
|
39
|
+
code: [63, 411],
|
|
40
|
+
name: 'indicatorColor',
|
|
41
|
+
parser: parserGenerator_1.Identity,
|
|
42
|
+
},
|
|
43
|
+
{
|
|
44
|
+
code: 70,
|
|
45
|
+
name: 'indicatorTransparency',
|
|
46
|
+
parser: parserGenerator_1.Identity,
|
|
47
|
+
},
|
|
48
|
+
{
|
|
49
|
+
code: 41,
|
|
50
|
+
name: 'bottomHeight',
|
|
51
|
+
parser: parserGenerator_1.Identity,
|
|
52
|
+
},
|
|
53
|
+
{
|
|
54
|
+
code: 40,
|
|
55
|
+
name: 'topHeight',
|
|
56
|
+
parser: parserGenerator_1.Identity,
|
|
57
|
+
},
|
|
58
|
+
{
|
|
59
|
+
code: 10,
|
|
60
|
+
name: 'verticalDirection',
|
|
61
|
+
parser: parserGenerator_1.PointParser,
|
|
62
|
+
},
|
|
63
|
+
{
|
|
64
|
+
code: 1,
|
|
65
|
+
name: 'name',
|
|
66
|
+
parser: parserGenerator_1.Identity,
|
|
67
|
+
},
|
|
68
|
+
{
|
|
69
|
+
code: 91,
|
|
70
|
+
name: 'flag',
|
|
71
|
+
parser: parserGenerator_1.Identity,
|
|
72
|
+
},
|
|
73
|
+
{
|
|
74
|
+
code: 90,
|
|
75
|
+
name: 'state',
|
|
76
|
+
parser: parserGenerator_1.Identity,
|
|
77
|
+
},
|
|
78
|
+
{
|
|
79
|
+
code: 100,
|
|
80
|
+
name: 'subclassMarker',
|
|
81
|
+
parser: parserGenerator_1.Identity,
|
|
82
|
+
},
|
|
83
|
+
...shared_1.CommonEntitySnippets,
|
|
84
|
+
];
|
|
85
|
+
class SectionEntityParser {
|
|
86
|
+
constructor() {
|
|
87
|
+
this.parser = (0, parserGenerator_1.createParser)(SectionEntityParserSnippets, DefaultSectionEntity);
|
|
88
|
+
}
|
|
89
|
+
parseEntity(scanner, curr) {
|
|
90
|
+
const entity = {};
|
|
91
|
+
this.parser(curr, scanner, entity);
|
|
92
|
+
return entity;
|
|
93
|
+
}
|
|
94
|
+
}
|
|
95
|
+
exports.SectionEntityParser = SectionEntityParser;
|
|
96
|
+
SectionEntityParser.ForEntityName = 'SECTION';
|
|
97
|
+
//# sourceMappingURL=parser.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"parser.js","sourceRoot":"","sources":["../../../../src/parser/entities/section/parser.ts"],"names":[],"mappings":";;;AAAA,kEAKsC;AACtC,sCAAiD;AAIjD,MAAM,oBAAoB,GAAG;IACzB,QAAQ,EAAE,EAAE;IACZ,gBAAgB,EAAE,EAAE;CACvB,CAAC;AAEF,MAAM,2BAA2B,GAAuB;IACpD;QACI,IAAI,EAAE,GAAG;QACT,IAAI,EAAE,uBAAuB;QAC7B,MAAM,EAAE,0BAAQ;KACnB;IACD;QACI,IAAI,EAAE,EAAE;QACR,IAAI,EAAE,kBAAkB;QACxB,UAAU,EAAE,IAAI;QAChB,MAAM,EAAE,6BAAW;KACtB;IACD;QACI,IAAI,EAAE,EAAE;QACR,IAAI,EAAE,0BAA0B;QAChC,MAAM,EAAE,0BAAQ;KACnB;IACD;QACI,IAAI,EAAE,EAAE;QACR,IAAI,EAAE,UAAU;QAChB,UAAU,EAAE,IAAI;QAChB,MAAM,EAAE,6BAAW;KACtB;IACD;QACI,IAAI,EAAE,EAAE;QACR,IAAI,EAAE,eAAe;QACrB,MAAM,EAAE,0BAAQ;KACnB;IACD;QACI,IAAI,EAAE,CAAC,EAAE,EAAE,GAAG,CAAC;QACf,IAAI,EAAE,gBAAgB;QACtB,MAAM,EAAE,0BAAQ;KACnB;IACD;QACI,IAAI,EAAE,EAAE;QACR,IAAI,EAAE,uBAAuB;QAC7B,MAAM,EAAE,0BAAQ;KACnB;IACD;QACI,IAAI,EAAE,EAAE;QACR,IAAI,EAAE,cAAc;QACpB,MAAM,EAAE,0BAAQ;KACnB;IACD;QACI,IAAI,EAAE,EAAE;QACR,IAAI,EAAE,WAAW;QACjB,MAAM,EAAE,0BAAQ;KACnB;IACD;QACI,IAAI,EAAE,EAAE;QACR,IAAI,EAAE,mBAAmB;QACzB,MAAM,EAAE,6BAAW;KACtB;IACD;QACI,IAAI,EAAE,CAAC;QACP,IAAI,EAAE,MAAM;QACZ,MAAM,EAAE,0BAAQ;KACnB;IACD;QACI,IAAI,EAAE,EAAE;QACR,IAAI,EAAE,MAAM;QACZ,MAAM,EAAE,0BAAQ;KACnB;IACD;QACI,IAAI,EAAE,EAAE;QACR,IAAI,EAAE,OAAO;QACb,MAAM,EAAE,0BAAQ;KACnB;IACD;QACI,IAAI,EAAE,GAAG;QACT,IAAI,EAAE,gBAAgB;QACtB,MAAM,EAAE,0BAAQ;KACnB;IACD,GAAG,6BAAoB;CAC1B,CAAC;AAEF,MAAa,mBAAmB;IAAhC;QAEY,WAAM,GAAG,IAAA,8BAAY,EACzB,2BAA2B,EAC3B,oBAAoB,CACvB,CAAC;IAON,CAAC;IALG,WAAW,CAAC,OAAwB,EAAE,IAAkB;QACpD,MAAM,MAAM,GAAG,EAAS,CAAC;QACzB,IAAI,CAAC,MAAM,CAAC,IAAI,EAAE,OAAO,EAAE,MAAM,CAAC,CAAC;QACnC,OAAO,MAAM,CAAC;IAClB,CAAC;;AAXL,kDAYC;AAXU,iCAAa,GAAG,SAAS,AAAZ,CAAa"}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import type { Point3D } from '../../../types';
|
|
2
|
+
import type { CommonDxfEntity } from '../shared';
|
|
3
|
+
export interface SectionEntity extends CommonDxfEntity {
|
|
4
|
+
type: 'SECTION';
|
|
5
|
+
subclassMarker: 'AcDbSection';
|
|
6
|
+
state: number;
|
|
7
|
+
flag: number;
|
|
8
|
+
name: string;
|
|
9
|
+
verticalDirection: Point3D;
|
|
10
|
+
topHeight: number;
|
|
11
|
+
bottomHeight: number;
|
|
12
|
+
indicatorTransparency: number;
|
|
13
|
+
indicatorColor: number;
|
|
14
|
+
numberOfVertices: number;
|
|
15
|
+
vertices: Point3D[];
|
|
16
|
+
numberOfBackLineVertices: number;
|
|
17
|
+
backLineVertices: Point3D[];
|
|
18
|
+
geometrySettingHardId: string;
|
|
19
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"types.js","sourceRoot":"","sources":["../../../../src/parser/entities/section/types.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
import type { ColorIndex, ColorInstance } from '../../types';
|
|
2
|
+
import DxfArrayScanner, { ScannerGroup } from '../DxfArrayScanner';
|
|
3
|
+
import { DXFParserSnippet } from '../shared/parserGenerator';
|
|
4
|
+
import { XData } from '../shared/xdata';
|
|
5
|
+
export interface CommonDxfEntity {
|
|
6
|
+
type: string;
|
|
7
|
+
handle: string;
|
|
8
|
+
ownerBlockRecordSoftId?: string;
|
|
9
|
+
isInPaperSpace?: boolean;
|
|
10
|
+
layer: string;
|
|
11
|
+
lineType?: string;
|
|
12
|
+
materialObjectHardId?: string;
|
|
13
|
+
colorIndex?: ColorIndex;
|
|
14
|
+
lineweight?: number;
|
|
15
|
+
lineTypeScale?: number;
|
|
16
|
+
isVisible?: boolean;
|
|
17
|
+
proxyByte?: number;
|
|
18
|
+
proxyEntity?: string;
|
|
19
|
+
color?: ColorInstance;
|
|
20
|
+
colorName?: string;
|
|
21
|
+
transparency?: number;
|
|
22
|
+
plotStyleHardId?: string;
|
|
23
|
+
shadowMode?: ShadowMode;
|
|
24
|
+
xdata?: XData;
|
|
25
|
+
ownerdictionaryHardId?: string | number | boolean;
|
|
26
|
+
ownerDictionarySoftId?: string | number | boolean;
|
|
27
|
+
}
|
|
28
|
+
export declare enum ShadowMode {
|
|
29
|
+
CAST_AND_RECEIVE = 0,
|
|
30
|
+
CAST = 1,
|
|
31
|
+
RECEIVE = 2,
|
|
32
|
+
IGNORE = 3
|
|
33
|
+
}
|
|
34
|
+
export declare const CommonEntitySnippets: DXFParserSnippet[];
|
|
35
|
+
export declare function skipApplicationGroups(curr: ScannerGroup, scanner: DxfArrayScanner): void;
|
|
@@ -0,0 +1,136 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.skipApplicationGroups = exports.CommonEntitySnippets = exports.ShadowMode = void 0;
|
|
4
|
+
const ParseHelpers_1 = require("../ParseHelpers");
|
|
5
|
+
const shared_1 = require("../shared");
|
|
6
|
+
const parserGenerator_1 = require("../shared/parserGenerator");
|
|
7
|
+
const xdata_1 = require("../shared/xdata");
|
|
8
|
+
var ShadowMode;
|
|
9
|
+
(function (ShadowMode) {
|
|
10
|
+
ShadowMode[ShadowMode["CAST_AND_RECEIVE"] = 0] = "CAST_AND_RECEIVE";
|
|
11
|
+
ShadowMode[ShadowMode["CAST"] = 1] = "CAST";
|
|
12
|
+
ShadowMode[ShadowMode["RECEIVE"] = 2] = "RECEIVE";
|
|
13
|
+
ShadowMode[ShadowMode["IGNORE"] = 3] = "IGNORE";
|
|
14
|
+
})(ShadowMode || (exports.ShadowMode = ShadowMode = {}));
|
|
15
|
+
// 이게 top에 와야함. 우선순위가 더 높다.
|
|
16
|
+
exports.CommonEntitySnippets = [
|
|
17
|
+
...xdata_1.XDataParserSnippets,
|
|
18
|
+
{
|
|
19
|
+
code: 284,
|
|
20
|
+
name: 'shadowMode',
|
|
21
|
+
parser: parserGenerator_1.Identity,
|
|
22
|
+
},
|
|
23
|
+
{
|
|
24
|
+
code: 390,
|
|
25
|
+
name: 'plotStyleHardId',
|
|
26
|
+
parser: parserGenerator_1.Identity,
|
|
27
|
+
},
|
|
28
|
+
{
|
|
29
|
+
code: 440,
|
|
30
|
+
name: 'transparency',
|
|
31
|
+
parser: parserGenerator_1.Identity,
|
|
32
|
+
},
|
|
33
|
+
{
|
|
34
|
+
code: 430,
|
|
35
|
+
name: 'colorName',
|
|
36
|
+
parser: parserGenerator_1.Identity,
|
|
37
|
+
},
|
|
38
|
+
{
|
|
39
|
+
code: 420,
|
|
40
|
+
name: 'color',
|
|
41
|
+
parser: parserGenerator_1.Identity,
|
|
42
|
+
},
|
|
43
|
+
{
|
|
44
|
+
code: 310,
|
|
45
|
+
name: 'proxyEntity',
|
|
46
|
+
parser: parserGenerator_1.Identity,
|
|
47
|
+
},
|
|
48
|
+
{
|
|
49
|
+
code: 92,
|
|
50
|
+
name: 'proxyByte',
|
|
51
|
+
parser: parserGenerator_1.Identity,
|
|
52
|
+
},
|
|
53
|
+
{
|
|
54
|
+
code: 60,
|
|
55
|
+
name: 'isVisible',
|
|
56
|
+
parser: parserGenerator_1.ToBoolean,
|
|
57
|
+
},
|
|
58
|
+
{
|
|
59
|
+
code: 48,
|
|
60
|
+
name: 'lineTypeScale',
|
|
61
|
+
parser: parserGenerator_1.Identity,
|
|
62
|
+
},
|
|
63
|
+
{
|
|
64
|
+
code: 370,
|
|
65
|
+
name: 'lineweight',
|
|
66
|
+
parser: parserGenerator_1.Identity,
|
|
67
|
+
},
|
|
68
|
+
{
|
|
69
|
+
code: 62,
|
|
70
|
+
name: 'colorIndex',
|
|
71
|
+
parser(curr, scanner, entity) {
|
|
72
|
+
const colorIndex = curr.value;
|
|
73
|
+
entity.color = (0, ParseHelpers_1.getAcadColor)(Math.abs(colorIndex));
|
|
74
|
+
return colorIndex;
|
|
75
|
+
},
|
|
76
|
+
},
|
|
77
|
+
{
|
|
78
|
+
code: 347,
|
|
79
|
+
name: 'materialObjectHardId',
|
|
80
|
+
parser: parserGenerator_1.Identity,
|
|
81
|
+
},
|
|
82
|
+
{
|
|
83
|
+
code: 6,
|
|
84
|
+
name: 'lineType',
|
|
85
|
+
parser: parserGenerator_1.Identity,
|
|
86
|
+
},
|
|
87
|
+
{
|
|
88
|
+
code: 8,
|
|
89
|
+
name: 'layer',
|
|
90
|
+
parser: parserGenerator_1.Identity,
|
|
91
|
+
},
|
|
92
|
+
{
|
|
93
|
+
code: 410,
|
|
94
|
+
name: 'layoutTabName',
|
|
95
|
+
parser: parserGenerator_1.Identity,
|
|
96
|
+
},
|
|
97
|
+
{
|
|
98
|
+
code: 67,
|
|
99
|
+
name: 'isInPaperSpace',
|
|
100
|
+
parser: parserGenerator_1.ToBoolean,
|
|
101
|
+
},
|
|
102
|
+
{
|
|
103
|
+
code: 100, // AcDbEntity를 소모시키기 위함
|
|
104
|
+
},
|
|
105
|
+
{
|
|
106
|
+
code: 330,
|
|
107
|
+
name: 'ownerBlockRecordSoftId',
|
|
108
|
+
parser: parserGenerator_1.Identity,
|
|
109
|
+
},
|
|
110
|
+
{
|
|
111
|
+
code: 102, // {ACAD_XDICTIONARY
|
|
112
|
+
parser: skipApplicationGroups,
|
|
113
|
+
},
|
|
114
|
+
{
|
|
115
|
+
code: 102, // {ACAD_REACTORS
|
|
116
|
+
parser: skipApplicationGroups,
|
|
117
|
+
},
|
|
118
|
+
{
|
|
119
|
+
code: 102, // {application_name
|
|
120
|
+
parser: skipApplicationGroups,
|
|
121
|
+
},
|
|
122
|
+
{
|
|
123
|
+
code: 5,
|
|
124
|
+
name: 'handle',
|
|
125
|
+
parser: parserGenerator_1.Identity,
|
|
126
|
+
},
|
|
127
|
+
];
|
|
128
|
+
function skipApplicationGroups(curr, scanner) {
|
|
129
|
+
curr = scanner.next();
|
|
130
|
+
while (!(0, shared_1.isMatched)(curr, 102) && !(0, shared_1.isMatched)(curr, 0, 'EOF')) {
|
|
131
|
+
curr = scanner.next();
|
|
132
|
+
}
|
|
133
|
+
// } 까지 소비
|
|
134
|
+
}
|
|
135
|
+
exports.skipApplicationGroups = skipApplicationGroups;
|
|
136
|
+
//# sourceMappingURL=shared.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"shared.js","sourceRoot":"","sources":["../../../src/parser/entities/shared.ts"],"names":[],"mappings":"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"}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
+
};
|
|
16
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
+
__exportStar(require("./types"), exports);
|
|
18
|
+
__exportStar(require("./parser"), exports);
|
|
19
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/parser/entities/solid/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,0CAAwB;AACxB,2CAAyB"}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import type DxfArrayScanner from '../../DxfArrayScanner';
|
|
2
|
+
import type { ScannerGroup } from '../../DxfArrayScanner';
|
|
3
|
+
import type { SolidEntity } from './types';
|
|
4
|
+
export declare class SolidEntityParser {
|
|
5
|
+
static ForEntityName: string;
|
|
6
|
+
private parser;
|
|
7
|
+
parseEntity(scanner: DxfArrayScanner, curr: ScannerGroup): SolidEntity;
|
|
8
|
+
}
|
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.SolidEntityParser = void 0;
|
|
4
|
+
const utils_1 = require("../../../utils");
|
|
5
|
+
const shared_1 = require("../shared");
|
|
6
|
+
const parserGenerator_1 = require("../../shared/parserGenerator");
|
|
7
|
+
const DefaultSolidEntity = {
|
|
8
|
+
points: [],
|
|
9
|
+
thickness: 0,
|
|
10
|
+
extrusionDirection: { x: 0, y: 0, z: 1 },
|
|
11
|
+
};
|
|
12
|
+
const SolidEntityParserSnippets = [
|
|
13
|
+
{
|
|
14
|
+
code: 210,
|
|
15
|
+
name: 'extrusionDirection',
|
|
16
|
+
parser: parserGenerator_1.PointParser,
|
|
17
|
+
},
|
|
18
|
+
{
|
|
19
|
+
code: 39,
|
|
20
|
+
name: 'thickness',
|
|
21
|
+
parser: parserGenerator_1.Identity,
|
|
22
|
+
},
|
|
23
|
+
{
|
|
24
|
+
code: [...(0, utils_1.generateIntegers)(10, 14)],
|
|
25
|
+
name: 'points',
|
|
26
|
+
isMultiple: true,
|
|
27
|
+
parser: parserGenerator_1.PointParser,
|
|
28
|
+
},
|
|
29
|
+
{
|
|
30
|
+
code: 100,
|
|
31
|
+
name: 'subclassMarker',
|
|
32
|
+
parser: parserGenerator_1.Identity,
|
|
33
|
+
},
|
|
34
|
+
...shared_1.CommonEntitySnippets,
|
|
35
|
+
];
|
|
36
|
+
class SolidEntityParser {
|
|
37
|
+
constructor() {
|
|
38
|
+
this.parser = (0, parserGenerator_1.createParser)(SolidEntityParserSnippets, DefaultSolidEntity);
|
|
39
|
+
}
|
|
40
|
+
parseEntity(scanner, curr) {
|
|
41
|
+
const entity = {};
|
|
42
|
+
this.parser(curr, scanner, entity);
|
|
43
|
+
return entity;
|
|
44
|
+
}
|
|
45
|
+
}
|
|
46
|
+
exports.SolidEntityParser = SolidEntityParser;
|
|
47
|
+
SolidEntityParser.ForEntityName = 'SOLID';
|
|
48
|
+
//# sourceMappingURL=parser.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"parser.js","sourceRoot":"","sources":["../../../../src/parser/entities/solid/parser.ts"],"names":[],"mappings":";;;AAEA,0CAAkD;AAClD,sCAAiD;AACjD,kEAKsC;AAGtC,MAAM,kBAAkB,GAAG;IACvB,MAAM,EAAE,EAAE;IACV,SAAS,EAAE,CAAC;IACZ,kBAAkB,EAAE,EAAE,CAAC,EAAE,CAAC,EAAE,CAAC,EAAE,CAAC,EAAE,CAAC,EAAE,CAAC,EAAE;CAC3C,CAAC;AAEF,MAAM,yBAAyB,GAAuB;IAClD;QACI,IAAI,EAAE,GAAG;QACT,IAAI,EAAE,oBAAoB;QAC1B,MAAM,EAAE,6BAAW;KACtB;IACD;QACI,IAAI,EAAE,EAAE;QACR,IAAI,EAAE,WAAW;QACjB,MAAM,EAAE,0BAAQ;KACnB;IACD;QACI,IAAI,EAAE,CAAC,GAAG,IAAA,wBAAgB,EAAC,EAAE,EAAE,EAAE,CAAC,CAAC;QACnC,IAAI,EAAE,QAAQ;QACd,UAAU,EAAE,IAAI;QAChB,MAAM,EAAE,6BAAW;KACtB;IACD;QACI,IAAI,EAAE,GAAG;QACT,IAAI,EAAE,gBAAgB;QACtB,MAAM,EAAE,0BAAQ;KACnB;IACD,GAAG,6BAAoB;CAC1B,CAAC;AAEF,MAAa,iBAAiB;IAA9B;QAEY,WAAM,GAAG,IAAA,8BAAY,EACzB,yBAAyB,EACzB,kBAAkB,CACrB,CAAC;IAON,CAAC;IALG,WAAW,CAAC,OAAwB,EAAE,IAAkB;QACpD,MAAM,MAAM,GAAG,EAAS,CAAC;QACzB,IAAI,CAAC,MAAM,CAAC,IAAI,EAAE,OAAO,EAAE,MAAM,CAAC,CAAC;QACnC,OAAO,MAAqB,CAAC;IACjC,CAAC;;AAXL,8CAYC;AAXU,+BAAa,GAAG,OAAO,AAAV,CAAW"}
|