====== ResultManager ====== **//Inherited from//** [[class::domain::xmanager|XManager]], **//Inherited by//** NULL **//Friend class//** NULL **//Description//** ResultManager从XManager继承,是结果数据对象管理器,所有结果数据对象的创建、销毁、访问以及修改都通过调用它的通用接口完成。它的域识别码是Domain_Result,类型名是“DRESULT”。 **//Members//** * vector [[resultmanager#m_psteplist|m_pStepList]] * vector [[resultmanager#m_psrclist|m_pSrcList]] * XResultStep * [[resultmanager#m_puserrlts|m_pUserRlts]] * XManager * [[resultmanager#m_pcpmgr|m_pCpMgr]] * H5IO * [[resultmanager#m_ph5rlts|m_pH5Rlts]] * double [[resultmanager#m_maxdeformation|m_MaxDeformation]] * ResultSmoothMethod [[resultmanager#m_ismoothmethod|m_iSmoothMethod]] * ResultExtrapolateMethod [[resultmanager#m_iinterpolatemethod|m_iInterpolateMethod]] **//Public interface//** * [[resultmanager#resultmanager1|ResultManager]]() * virtual [[resultmanager#~resultmanager|~ResultManager]]() * void [[resultmanager#bindcomponentmanager|bindComponentManager]](XManager * mgr) * XResult * [[resultmanager#createresult|createResult]](TypeID rlt_type, const char * name = NULL, ulong id = 0) * virtual void [[resultmanager#additem|addItem]](XItem * obj) * XResultSubstep * [[resultmanager#createsubstep|createSubstep]]() * XResultStep * [[resultmanager#createstep|createStep]]() * XResultSubstep * [[resultmanager#checkoutsubstep|checkOutSubstep]](const XResultSubstep * ss) * XResult * [[resultmanager#getmateresult|getMateResult]](XResult * rlt, ResultLocType loc) * XResult * [[resultmanager#getresult|getResult]](ulong id) * XResult * [[resultmanager#getresult|getResult]](int stepIdx, int substepIdx, TypeID rType, int loc, const char * rName = NULL) * void [[resultmanager#addbasestep|addBaseStep]](XResultStep * step) * void [[resultmanager#bindresultiterator|bindResultIterator]](ItemIterator * iter) * void [[resultmanager#deleteresult|deleteResult]](XResult * pRlt) * void [[resultmanager#deletesubstep|deleteSubstep]](XResultSubstep * sub) * void [[resultmanager#deletestep|deleteStep]](XResultStep * step) * XResultStep * [[resultmanager#getbasestep|getBaseStep]](int index) * XResultStep * [[resultmanager#getuserstep|getUserStep]]() * bool [[resultmanager#findbasestep|findBaseStep]](XResult * rlt,ulong * sid,ulong * ssid) * int [[resultmanager#getbasestepcount|getBaseStepCount]]() * bool [[resultmanager#read|read]](H5IO * io, H5Obj * grp) * void [[resultmanager#write|write]](H5IO * io, H5Obj * grp) * ErrorCode [[resultmanager#read|read]](XBinaryIO * io) * void [[resultmanager#write|write]](XBinaryIO * io) * void [[resultmanager#clear|clear]]() * void [[resultmanager#resettensorresultonlocation|resetTensorResultOnLocation]](int loc) * void [[resultmanager#dumpresult|dumpResult]](XResult * chief, int cp = ALL_COMPONENT, bool bIncludeBeamShell = false) * void [[resultmanager#loadresult|loadResult]](XResult * chief, int cp = ALL_COMPONENT, bool bIncludeBeamShell = false) * void [[resultmanager#dumpresultwithlayers|dumpResultWithLayers]](XResult * chief) * DomainType [[resultmanager#getdomaintype|getDomainType]]() const * void [[resultmanager#serialize|serialize]](XBinaryIO * io, XItem * obj, bool bSave) * void [[resultmanager#opendumpfile|openDumpFile]](const char * raw) * void [[resultmanager#closedumpfile|closeDumpFile]]() * XResult * [[resultmanager#getdeformationdata|getDeformationData]](int main, int sub, const char * deformLabel = NULL) * void [[resultmanager#updatemaxdeformationbydisprlt|updateMaxDeformationByDispRlt]](ExtremeDeformInfo * edi = 0, XResult * dispRlt = NULL) * double [[resultmanager#getmaxdeformation|getMaxDeformation]]() const * void [[resultmanager#resetmaxdeformation|resetMaxDeformation]]() * ExtremeValue [[resultmanager#getcomponentmax|getComponentMax]](XResult * rlt, int cp, int cid = 0) const * ExtremeValue [[resultmanager#getcomponentmin|getComponentMin]](XResult * rlt, int cp, int cid = 0) const * const char * [[resultmanager#getresultcomponentname|getResultComponentName]](int rlt_type,int rlt_comp) * virtual const char * [[resultmanager#getsourcefile|getSourceFile]](XResult * rlt) * virtual const char * [[resultmanager#getsourcetype|getSourceType]](XResult * rlt) * int [[resultmanager#getsourcefilecount|getSourceFileCount]]() * void [[resultmanager#addsourcefile|addSourceFile]](const char * fname, const char * srcType) * ResultSmoothMethod [[resultmanager#getsmoothmethod|getSmoothMethod]]() const * ResultExtrapolateMethod [[resultmanager#getextrapolatemethod|getExtrapolateMethod]]() const * void [[resultmanager#setsmoothmethod|setSmoothMethod]](ResultSmoothMethod m) * void [[resultmanager#setextrapolatemethod|setExtrapolateMethod]](ResultExtrapolateMethod m) ---- {{anchor:m_psteplist}} **vector m_pStepList** 结果步数组 {{anchor:m_psrclist}} **vector m_pSrcList** 数据源文件数组 {{anchor:m_pcpmgr}} **XManager * m_pCpMgr** 结果分量对象管理器 {{anchor:m_ph5rlts}} **H5IO * m_pH5Rlts** 结果数据文件句柄 {{anchor:m_maxdeformation}} **double m_MaxDeformation** 结果最大变形 {{anchor:m_ismoothmethod}} **ResultSmoothMethod m_iSmoothMethod** 从单元节点结果计算节点结果的磨平方法 {{anchor:m_iinterpolatemethod}} **ResultExtrapolateMethod m_iInterpolateMethod** 从积分点结果计算单元节点结果的插值方法 ---- {{anchor:resultmanager1}} **ResultManager()** *function: 构造函数 *parameters: NULL *return value: 无 {{anchor:~resultmanager}} **virtual ~ResultManager()** *function: 析构函数 *parameters: NULL *return value: 无 {{anchor:bindcomponentmanager}} **void bindComponentManager(XManager * mgr)** *function: 绑定结果分量对象管理器 *parameters: - [i]XManager * mgr: 结果分量对象管理器 *return value: 无 {{anchor:createresult}} **XResult * createResult(TypeID rlt_type, const char * name = NULL, ulong id = 0)** *function: 创建结果对象 *parameters: - [i]TypeID rlt_type: 结果类型 - [i] const char * name = NULL: 结果名 - [i] ulong id = 0: 结果ID *return value: 结果对象 {{anchor:additem}} **virtual void addItem(XItem * obj)** *function: 基类函数的重新实现,添加对象 *parameters: - [i]XItem * obj: 结果对象 *return value: 无 {{anchor:createsubstep}} **XResultSubstep * createSubstep()** *function: 创建结果子步 *parameters: NULL *return value: 结果子步对象 {{anchor:createstep}} **XResultStep * createStep()** *function: 创建结果步 *parameters: NULL *return value: 结果步对象 {{anchor:checkoutsubstep}} **XResultSubstep * checkOutSubstep(const XResultSubstep * ss)** *function: 获取可以修改的结果子步对象 *parameters: - [i]const XResultSubstep * ss: 结果子步对象(不可修改) *return value: 可以修改的结果子步对象 {{anchor:getmateresult}} **XResult * getMateResult(XResult * rlt, ResultLocType loc)** *function: 获取指定位置的主结果 *parameters: - [i]XResult * rlt: 结果对象 - [i] ResultLocType loc: 位置 *return value: 指定位置的主结果对象 {{anchor:getresult}} **XResult * getResult(ulong id)** *function: 访问结果对象 *parameters: - [i]ulong id: 结果ID *return value: 结果对象 {{anchor:getresult}} **XResult * getResult(int stepIdx, int substepIdx, TypeID rType, int loc, const char * rName = NULL)** *function: 获取指定结果子步指定类型指定位置的主结果 *parameters: - [i]int stepIdx: 结果步序号 - [i] int substepIdx: 结果子步序号 - [i] TypeID rType: 结果类型 - [i] int loc: 结果位置 - [i] const char * rName = NULL: 结果名 *return value: 指定的结果对象,若不存在返回NULL {{anchor:addbasestep}} **void addBaseStep(XResultStep * step)** *function: 添加结果步 *parameters: - [i]XResultStep * step: 结果步对象 *return value: 无 {{anchor:bindresultiterator}} **void bindResultIterator(ItemIterator * iter)** *function: 绑定结果访问迭代器 *parameters: - [i]ItemIterator * iter: 结果访问迭代器 *return value: 无 {{anchor:deleteresult}} **void deleteResult(XResult * pRlt)** *function: 删除结果 *parameters: - [i]XResult * pRlt: 结果对象 *return value: 无 {{anchor:deletesubstep}} **void deleteSubstep(XResultSubstep * sub)** *function: 删除结果子步对象 *parameters: - [i]XResultSubstep * sub: 结果子步对象 *return value: 无 {{anchor:deletestep}} **void deleteStep(XResultStep * step)** *function: 删除结果步对象 *parameters: - [i]XResultStep * step: 结果步对象 *return value: 无 {{anchor:getbasestep}} **XResultStep * getBaseStep(int index)** *function: 获取给定序号的结果步对象 *parameters: - [i]int index: 结果步序号 *return value: 结果步对象 {{anchor:findbasestep}} **bool findBaseStep(XResult * rlt,ulong * sid,ulong * ssid)** *function: 获取结果对象所属的结果步序号和子步序号 *parameters: - [i]XResult * rlt: 结果对象 - [i]ulong * sid: 结果对象所属的结果步序号 - [i]ulong * ssid: 结果对象所属的结果子步序号 *return value: 成功获取返回true,否则返回false {{anchor:getbasestepcount}} **int getBaseStepCount()** *function: 获取结果步的数目 *parameters: NULL *return value: 结果步的数目 {{anchor:write}} **void write(XH5IO * io, H5Obj * grp)** *function: 将管理的所有对象数据写入到HDF5文件中 *parameters: - [i]XH5IO * io: HDF5文件句柄 - [i] H5Obj * grp: 对象管理器对应的HDF5节点 *return value: 无 {{anchor:read}} **bool read(XH5IO * io, H5Obj * grp)** *function: 从HDF5文件中读取对象数据到管理器中 *parameters: - [i]XH5IO * io: HDF5文件句柄 - [i] H5Obj * grp: 对象管理器对应的HDF5节点 *return value: 完整读取返回true,否则返回false {{anchor:read}} **ErrorCode read(XBinaryIO * io)** *function: 从二进制文件中读取对象数据到管理器中 *parameters: - [i]XBinaryIO * io: 二进制文件句柄 *return value: 成功读取返回Error_None, 否则返回相应错误码 {{anchor:write}} **void write(XBinaryIO * io)** *function: 将管理的所有对象数据写入到二进制文件中 *parameters: - [i]XBinaryIO * io: 二进制文件句柄 *return value: 无 {{anchor:clear}} **void clear()** *function: 清空结果与结果步对象 *parameters: NULL *return value: 无 {{anchor:resettensorresultonlocation}} **void resetTensorResultOnLocation(int loc)** *function: 重置指定位置的结果数据以及由其计算得到的结果数据(当修改插值方法或磨平方法时使用) *parameters: - [i]int loc: 结果位置 *return value: 无 {{anchor:dumpresult}} **void dumpResult(XResult * chief, int cp = ALL_COMPONENT, bool bIncludeBeamShell = false)** *function: 将结果数据倒出到缓存文件中 *parameters: - [i]XResult * chief: 主结果对象 - [i] int cp = ALL_COMPONENT: 结果分量 - [i] bool bIncludeBeamShell = false: 是否包含板壳、杆梁结果层 *return value: 无 {{anchor:loadresult}} **void loadResult(XResult * chief, int cp = ALL_COMPONENT, bool bIncludeBeamShell = false)** *function: 将结果数据从缓存文件中载入到内存中 *parameters: - [i]XResult * chief: 主结果对象 - [i] int cp = ALL_COMPONENT: 结果分量 - [i] bool bIncludeBeamShell = false: 是否包含板壳、杆梁结果层 *return value: 无 {{anchor:dumpresultwithlayers}} **void dumpResultWithLayers(XResult * chief)** *function: 将结果数据及其包含的层结果数据倒出到缓存文件中 *parameters: - [i]XResult * chief: 主结果对象 *return value: 无 {{anchor:serialize}} **void serialize(XBinaryIO * io, XItem * obj, bool bSave)** *function: 在undo、redo时从数据操作记录文件中序列化数据对象 *parameters: - [i]XBinaryIO * io: 二进制数据操作记录文件句柄 - [i] XItem * obj: 数据对象 - [i] bool bSave: 是否保存数据对象 *return value: 无 {{anchor:opendumpfile}} **void openDumpFile(const char * raw)** *function: 打开结果缓存文件 *parameters: - [i]const char * raw: 缓存文件路径 *return value: 无 {{anchor:closedumpfile}} **void closeDumpFile()** *function: 关闭结果缓存文件 *parameters: NULL *return value: 无 {{anchor:getdeformationdata}} **XResult * getDeformationData(int main, int sub, const char * deformLabel = NULL)** *function: 获取变形结果对象 *parameters: - [i]int main: 结果步序号 - [i] int sub: 结果子步序号 - [i] const char * deformLabel = NULL: 变形结果名 *return value: 变形结果对象 {{anchor:updatemaxdeformationbydisprlt}} **void updateMaxDeformationByDispRlt(ExtremeDeformInfo * edi = 0, XResult * dispRlt = NULL)** *function: 根据位移结果更新变形数据 *parameters: - [i]ExtremeDeformInfo * edi = 0: 极值记录 - [i] XResult * dispRlt = NULL: 位移结果对象 *return value: 无 {{anchor:getmaxdeformation}} **double getMaxDeformation() const** *function: 获取最大变形量(用于计算变形缩放系数) *parameters: NULL *return value: 最大变形量 {{anchor:resetmaxdeformation}} **void resetMaxDeformation()** *function: 重置最大变形量 *parameters: NULL *return value: 无 {{anchor:getcomponentmax}} **ExtremeValue getComponentMax(XResult * rlt, int cp, int cid = 0) const** *function: 获取结果对象的分量极大值 *parameters: - [i]XResult * rlt: 结果对象 - [i] int cp: 分量序号 - [i] int cid = 0: 局部坐标系ID *return value: 结果对象的分量极值 {{anchor:getcomponentmin}} **ExtremeValue getComponentMin(XResult * rlt, int cp, int cid = 0) const** *function: 获取结果对象的分量极小值 *parameters: - [i]XResult * rlt: 结果对象 - [i] int cp: 分量序号 - [i] int cid = 0: 局部坐标系ID *return value: 结果对象的分量极值 {{anchor:getresultcomponentname}} **const char * getResultComponentName(int rlt_type,int rlt_comp)** *function: 获取结果分量名 *parameters: - [i]int rlt_type: 结果类型 - [i]int rlt_comp: 分量序号 *return value: 结果分量名 {{anchor:getsourcefile}} **virtual const char * getSourceFile(XResult * rlt)** *function: 获取结果对象源文件路径 *parameters: - [i]XResult * rlt: 结果对象 *return value: 结果对象源文件路径 {{anchor:getsourcetype}} **virtual const char * getSourceType(XResult * rlt)** *function: 获取结果对象源文件类型 *parameters: - [i]XResult * rlt: 结果对象 *return value: 结果对象源文件类型 {{anchor:getsourcefilecount}} **int getSourceFileCount()** *function: 获取结果对象源文件个数 *parameters: NULL *return value: 结果对象源文件个数 {{anchor:addsourcefile}} **void addSourceFile(const char * fname, const char * srcType)** *function: 添加结果对象源文件; *parameters: - [i]const char * fname: 结果源文件路径 - [i] const char * srcType: 文件类型(接口类型) *return value: 无 {{anchor:getsmoothmethod}} **ResultSmoothMethod getSmoothMethod() const** *function: 获取结果数据磨平方法 *parameters: NULL *return value: 磨平方法 {{anchor:getextrapolatemethod}} **ResultExtrapolateMethod getExtrapolateMethod() const** *function: 获取结果数据插值方法 *parameters: NULL *return value: 结果数据插值方法 {{anchor:setsmoothmethod}} **void setSmoothMethod(ResultSmoothMethod m)** *function: 设置结果数据磨平方法 *parameters: - [i]ResultSmoothMethod m: 结果数据磨平方法 *return value: 无 {{anchor:setextrapolatemethod}} **void setExtrapolateMethod(ResultExtrapolateMethod m)** *function: 设置结果数据插值方法 *parameters: - [i]ResultExtrapolateMethod m: 结果数据插值方法 *return value: 无