跳到主要内容
版本:v10.0

M3D / M3D / Reader / SectionFactory

Class: SectionFactory

M3D.Reader.SectionFactory

Memberof

SView.Reader

Description

剖切工具类

Author

nihy

Date

2022-1-20

Version

1.0

Hierarchy

Table of contents

Constructors

Methods

Constructors

constructor

new SectionFactory(): SectionFactory

Returns

SectionFactory

Inherited from

MObjectFactory.constructor

Methods

createMObject

createMObject<T>(arg): T

Type parameters

Name
T

Parameters

NameTypeDescription
argT泛型

Returns

T

Description

创建对象

Inherited from

MObjectFactory.createMObject


fromJson

fromJson(sectionPlaneObj, scene, version?): SectionPlane

Parameters

NameTypeDescription
sectionPlaneObjany剖切面对象
sceneScene场景对象
version?string版本

Returns

SectionPlane

Static

Description

根据剖切JSON数据生成剖切对象


getMaxObjectId

getMaxObjectId(sectionJsonArray): number

Parameters

NameTypeDescription
sectionJsonArrayany剖切json数组

Returns

number

获取剖切ID的最大值

Static

Description

获取最大objectId


toJsonSectionPlane

toJsonSectionPlane(sectionPlane): string

Parameters

NameTypeDescription
sectionPlaneSectionPlane剖切面对象

Returns

string

剖切JSON数据

Static

Description

根据剖切对象生成剖切JSON数据