首页 / cms / oaChangeMgr

oaChangeMgr

模块: oapy._oa._cms 导入: from oapy._oa import _cms

概览

oaChangeMgroapy 中可用,可通过 _cms 模块访问。

本页汇总 oaChangeMgr 当前在 oapy 中可用的 Python 接口。

详细说明

OpenAccess provides a foundation for an approach to sharing design data that enables fine-grained collaboration between multiple processes operating on the same design。 OpenAccess defines a plug-in based infrastructure that allows software developers to provide plug-ins that support incremental data exchange between cooperating applications。 The complete infrastructure is called the OpenAccess change management system (CMS) 。 Applications access CMS functionality through public functions on the oaChangeMgr class。 The oaChangeMgr functions let applications initialize change tracking plug-ins, initialize export plug-ins, begin and end change tracking, and export the tracked changes。 A function is also provided to discard all accumulated changes。 The oaChangeMgr class supports multiple protocols for the various plug-ins。 Note that there is one and only one oaChangeMgr instance in any given process。 This class can be observed by deriving from oaObserver

方法总览

状态 Python 调用
obj.initTracking(pluginName)
obj.initExport(pluginName)
obj.getTrackingProtocols(out)
obj.getExportProtocols(out)
obj.setTrackingProtocol(in)
obj.setExportProtocol(in)
obj.beginTracking(nameIn)
obj.endTracking()
obj.exportFull(changeSetName)
obj.exportIncr(changeSetName)
obj.findChangeSet(nameIn)
obj.discardAllChangeSets()
obj.beginChangeSet()
obj.endChangeSet()
obj.discardChangeSet(changeSetName)
_cms.oaChangeMgr.get()

方法说明

obj.initTracking(pluginName)

绑定状态: 已绑定

Python 调用: obj.initTracking(pluginName)

This function loads and initializes the specified tracking plug-in。 OpenAccess obtains the protocol array supported by the plug-in and verifies that the protocols in the array have the same pluginName as the plug-in that returns them。 This function does not implicitly begin a change set。

参数

  • pluginName: The name of the tracking plug-in to initialize。

异常

  • oacCMInvalidPlugInProtocol

Python 示例

from oapy._oa import _cms

# assume obj is a oaChangeMgr
obj.initTracking(pluginName)

obj.initExport(pluginName)

绑定状态: 已绑定

Python 调用: obj.initExport(pluginName)

This function loads and initializes the specified export plug-in。 OpenAccess obtains the protocol array supported by the plug-in and verifies that the protocols in the array have the same pluginName as the plug-in that returns them。 This function does not implicitly end a change set。

参数

  • pluginName: The name of the export plug-in to initialize。

异常

  • oacCMInvalidPlugInProtocol

Python 示例

from oapy._oa import _cms

# assume obj is a oaChangeMgr
obj.initExport(pluginName)

obj.getTrackingProtocols(out)

绑定状态: 已绑定

Python 调用: obj.getTrackingProtocols(out)

This function retrieves the set of protocols supported by the tracking plug-in and places them in the out protocol array。

参数

  • out: The returned array of tracking protocols。

Python 示例

from oapy._oa import _cms

# assume obj is a oaChangeMgr
obj.getTrackingProtocols(out)

obj.getExportProtocols(out)

绑定状态: 已绑定

Python 调用: obj.getExportProtocols(out)

This function retrieves the set of protocols supported by the export plug-in and places them in the out protocol array。

参数

  • out: The returned array of export protocols。

Python 示例

from oapy._oa import _cms

# assume obj is a oaChangeMgr
obj.getExportProtocols(out)

obj.setTrackingProtocol(in)

绑定状态: 已绑定

Python 调用: obj.setTrackingProtocol(in)

This function sets the protocol to be used by the tracking plug-in。 It must match one of the protocols in the protocol array returned by getTrackingProtocols() 。

参数

  • in: The protocol to set on the tracking plug in。

异常

  • oacCMProtocolCannotBeSet: The protocol has unset attributes that must be set before continuing。
  • oacCMProtocolArrayMatchNotFound: The specified protocol does not correspond to a protocol from the array of tracking protocols。

Python 示例

from oapy._oa import _cms

# assume obj is a oaChangeMgr
obj.setTrackingProtocol(in)

obj.setExportProtocol(in)

绑定状态: 已绑定

Python 调用: obj.setExportProtocol(in)

This function sets the protocol to be used by the export plug-in。 It must match one of the protocols in the protocol array returned by getExportProtocols() 。

参数

  • in: The protocol to set on the export plug in。

异常

  • oacCMProtocolCannotBeSet: The protocol has unset attributes that must be set before continuing。
  • oacCMProtocolArrayMatchNotFound: The specified protocol does not correspond to a protocol from the array of export protocols。

Python 示例

from oapy._oa import _cms

# assume obj is a oaChangeMgr
obj.setExportProtocol(in)

obj.beginTracking(nameIn)

绑定状态: 已绑定

Python 调用: obj.beginTracking(nameIn)

This function begins tracking changes by beginning a change set, which is given the specified nameIn。 The name cannot be the name of an existing change set。 From this point on, changes to design representations due to non-const OpenAccess API calls are recorded as change records in the specified change set。 Change sets cannot be nested。 A call to beginTracking() on a specified change set must be followed by a call to endTracking() before another call to beginTracking() can start tracking on a new change set。

参数

  • nameIn: The name for the new change set。

异常

  • oacCMTrackingNotInitialized
  • oacCMChangeSetIsActive

Python 示例

from oapy._oa import _cms

# assume obj is a oaChangeMgr
obj.beginTracking(nameIn)

obj.endTracking()

绑定状态: 已绑定

Python 调用: obj.endTracking()

This function ends tracking by ending the currently active change set。

异常

  • oacCMTrackingNotInitialized
  • oacCMChangeSetNotSet

Python 示例

from oapy._oa import _cms

# assume obj is a oaChangeMgr
obj.endTracking()

obj.exportFull(changeSetName)

绑定状态: 已绑定

Python 调用: obj.exportFull(changeSetName)

This function exports the full named change set using the currently selected export plug-in and export protocol。 A full export of a change set outputs all change records of a change set。 This function requires that tracking has been stopped and the change set has ended。 A full export can be called more than once for the same named change set。 You can reset the protocol between calls to full export。 Refer to the exportIncr function if you want to export change sets in incremental chunks。 Incremental export and full export do not interact with each other。

参数

  • changeSetName: Name of the change set to export。

异常

  • oacCMExportNotInitialized
  • oacCMChangeSetNotFound
  • oacCMChangeSetIsActive
  • oacCMProtocolHasNotBeenSet

Python 示例

from oapy._oa import _cms

# assume obj is a oaChangeMgr
obj.exportFull(changeSetName)

obj.exportIncr(changeSetName)

绑定状态: 已绑定

Python 调用: obj.exportIncr(changeSetName)

This function exports the named change set from the last exportIncr() call using the currently selected export plug-in and export protocol。 If this is the first exportIncr() call, the change set is exported from the start of the change set。 Exporting a change set incrementally emits only new change records that have not previously been exported, then marks those records as exported。 This allows the change set to be emitted in chunks。 Incremental export should be called one last time after tracking has been stopped in order to emit the final set of changes。 Incremental export and full export do not interact with each other。

参数

  • changeSetName: Name of the change set to export。

异常

  • oacCMExportNotInitialized
  • oacCMChangeSetNotFound
  • oacCMProtocolHasNotBeenSet

Python 示例

from oapy._oa import _cms

# assume obj is a oaChangeMgr
obj.exportIncr(changeSetName)

obj.findChangeSet(nameIn)

绑定状态: 已绑定

Python 调用: obj.findChangeSet(nameIn)

This function finds the named change set in the change manager's current set of changes。

参数

  • nameIn: Name of the change set to find。

Python 示例

from oapy._oa import _cms

# assume obj is a oaChangeMgr
obj.findChangeSet(nameIn)

obj.discardAllChangeSets()

绑定状态: 已绑定

Python 调用: obj.discardAllChangeSets()

This function deletes all change sets known to the oaChangeMgr class。

Python 示例

from oapy._oa import _cms

# assume obj is a oaChangeMgr
obj.discardAllChangeSets()

obj.beginChangeSet()

绑定状态: 已绑定

Python 调用: obj.beginChangeSet()

This function returns a constant iterator that points to the first reference object managed by this change set。

Python 示例

from oapy._oa import _cms

# assume obj is a oaChangeMgr
obj.beginChangeSet()

obj.endChangeSet()

绑定状态: 已绑定

Python 调用: obj.endChangeSet()

This function returns a constant iterator that points to the last reference object managed by this change set。

Python 示例

from oapy._oa import _cms

# assume obj is a oaChangeMgr
obj.endChangeSet()

obj.discardChangeSet(changeSetName)

绑定状态: 已绑定

Python 调用: obj.discardChangeSet(changeSetName)

Python 示例

from oapy._oa import _cms

# assume obj is a oaChangeMgr
obj.discardChangeSet(changeSetName)

_cms.oaChangeMgr.get()

绑定状态: 已绑定

Python 调用: _cms.oaChangeMgr.get()

This static function gets the pointer to the singleton oaChangeMgr object。

Python 示例

from oapy._oa import _cms

_cms.oaChangeMgr.get()