121 lines
5.0 KiB
TypeScript
121 lines
5.0 KiB
TypeScript
import { Vector3 } from 'three';
|
|
import { DuplicateRecordCloning } from '../Common/Status';
|
|
import { AlignLineGroupTable } from './AlignLine/AlignLineGroupTable';
|
|
import { BlockTableRecord } from './BlockTableRecord';
|
|
import { CADFiler } from './CADFiler';
|
|
import { CADObject } from './CADObject';
|
|
import { CameraSnapshootRecord } from './CameraSnapshoot/CameraSnapshootRecord';
|
|
import { DimStyleTable } from './DimStyle/DimStyleTable';
|
|
import { FontStyleTable } from './FontStyle/FontStyleTable';
|
|
import { GroupTable } from './GroupTable';
|
|
import { HistoricManage } from './HistoricManage';
|
|
import { IdMaping } from './IdMaping';
|
|
import { LayerTableRecord } from './LayerTableRecord';
|
|
import { AmbientLight } from './Lights/AmbientLight';
|
|
import { DirectionalLight } from './Lights/DirectionalLight';
|
|
import { HemisphereLight } from './Lights/HemisphereLight';
|
|
import { ObjectId } from './ObjectId';
|
|
import { OwnerContainer } from './OwnerContainer';
|
|
import { PhysicalMaterialRecord } from './PhysicalMaterialRecord';
|
|
import { ProcessingGroupTable } from './ProcessingGroup/ProcessingGroupTable';
|
|
import { BlockTable } from './Tables/BlockTable';
|
|
import { LayerTable } from './Tables/LayerTable';
|
|
import { MaterialTable } from './Tables/MaterialTable';
|
|
import { TextureTable } from './Tables/TextureTable';
|
|
import { TemplateTable } from './Template/TemplateTable';
|
|
import { WblockCloneFiler } from './WblockCloneFiler';
|
|
export declare class Database {
|
|
IsDefaultDatabase: boolean;
|
|
hm: HistoricManage;
|
|
BlockTable: BlockTable;
|
|
MaterialTable: MaterialTable;
|
|
TextureTable: TextureTable;
|
|
TemplateTable: TemplateTable;
|
|
GroupTable: GroupTable;
|
|
ProcessingGroupTable: ProcessingGroupTable;
|
|
AlignLineGroupTable: AlignLineGroupTable;
|
|
DimStyleTable: DimStyleTable;
|
|
LayerTable: LayerTable;
|
|
FontStyleTable: FontStyleTable;
|
|
ModelSpace: BlockTableRecord;
|
|
LayoutSpace: BlockTableRecord;
|
|
Lights: BlockTableRecord;
|
|
CameraSnapshoots: CameraSnapshootRecord[];
|
|
AmbientLight: AmbientLight;
|
|
SunLight: DirectionalLight;
|
|
HemisphereLight: HemisphereLight;
|
|
DefaultLayer: LayerTableRecord;
|
|
DefaultMaterial: PhysicalMaterialRecord;
|
|
/** 这是为UE设计器提供的拓展数据,WebCAD只负责保存,不使用它.
|
|
* 在存储吊顶模块时,存储了材质槽信息
|
|
*/
|
|
ExtendedData: any;
|
|
private idIndex;
|
|
private idMap;
|
|
/**
|
|
*
|
|
* @param [buildDefaultDrawing=false] 构建默认对象(标注 图层 材质 灯光)
|
|
* @param [IsDefaultDatabase=false] app图纸
|
|
* @param [disableHistoric=false] 禁止命令记录(撤销重做)
|
|
*/
|
|
constructor(buildDefaultDrawing?: boolean, IsDefaultDatabase?: boolean, disableHistoric?: boolean);
|
|
private InitDimStyle;
|
|
private InitLayer;
|
|
private InitMaterial;
|
|
private InitLight;
|
|
private InitFontStyle;
|
|
private SettingDefaultStyleAndMaterial;
|
|
Destroy(): void;
|
|
FileWrite(file?: CADFiler): CADFiler;
|
|
FileRead(file: CADFiler): this;
|
|
/**
|
|
* 注意:跨图纸拷贝(WblockCloneObjects) 同图纸拷贝(DeppCloneObjects)
|
|
*
|
|
* 单个数据库内克隆对象(objects),并将他们附加到指定的容器对象(owner).
|
|
* @param objects 被克隆的对象
|
|
* @param owner 克隆对象的容器
|
|
* @param idMap id映射 oldid->newid
|
|
* @param deferXlation 指示是否应该进行ID转换
|
|
* @returns 新克隆的对象列表
|
|
*/
|
|
DeepCloneObjects(objects: CADObject[], owner: OwnerContainer, idMap?: IdMaping, deferXlation?: boolean): CADObject[];
|
|
/**
|
|
* 清理拷贝后的实体空引用
|
|
*/
|
|
private ClearEmptyAssoc;
|
|
private DeepCloneObject;
|
|
/**
|
|
* 注意:跨图纸拷贝(WblockCloneObjects) 同图纸拷贝(DeppCloneObjects)
|
|
*
|
|
* 将来自不同数据库的对象列表拷贝到本数据库中.
|
|
* 当前支持使用HardId模式来硬关联某个对象,使该对象能够在WblockClone时一起被带过来.
|
|
* 当前不支持硬关联对象的Owner不是默认的容器.
|
|
* 如果需要这么做,请将该对象的Owner设置为Hard关联
|
|
* @param objects 对象不能属于本数据库
|
|
* @param owner 克隆对象的新容器
|
|
* @param idMap id映射
|
|
*/
|
|
WblockCloneObejcts(objects: CADObject[], owner: OwnerContainer, idMap: IdMaping, drc: DuplicateRecordCloning, filer?: WblockCloneFiler): CADObject[];
|
|
/**
|
|
* 克隆引用对象 WriteHardObjectId
|
|
*/
|
|
private WblockCloneReferenceObject;
|
|
private WblockCloneObject;
|
|
/**
|
|
* 为拷贝出来的对象分配id索引,并在数据库中注册
|
|
*/
|
|
private AllocationObjectId;
|
|
Insert(): void;
|
|
/**
|
|
* 写块
|
|
* @param outputDatabase 输出到指定的数据库
|
|
* @param objects
|
|
* @param basePoint
|
|
* @param cloning
|
|
*/
|
|
Wblock(outputDataBase: Database, objects: CADObject[], basePoint: Vector3, cloning: any): void;
|
|
AllocateId(): ObjectId;
|
|
GetObjectId(index: number, create?: boolean): ObjectId;
|
|
DeleteId(idIndex: number): void;
|
|
}
|
|
//# sourceMappingURL=Database.d.ts.map
|