首页 / design / oaInst

oaInst

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

概览

oaInstoapy 中可用,可通过 _design 模块访问。

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

详细说明

The oaInst class is an abstract base class for block domain instances。 An instance represents the inclusion of one design as a part of the contents of another。 The design containing the instance is the parent design and the design that is included is the master of the instance。 oaInst objects are always in the block domain。 Thus they are contained in an oaBlock object。 An oaInst may have one or more equivalent module instances in the module hierarchy and will have an equivalent oaOccInst in the occurrence hierarchy。 You can use instances to create hierarchical designs。 The master of an instance can contain instances of other masters。 This hierarchy can continue for as many levels as needed to express a complete design。 You can use instances to represent complex pin figures。 These are often used in schematics where a shape more complicated than a polygon is wanted。 All instances have names。 These names can be assigned by the creator。 For scalar inst, instance names can be automatically assigned by the database。 Instances always have an oaInstHeader , which contains the attributes that are constant for all instances of a given master。 Instances of Pcells include a set of parameters values used to tailor the Pcell for each specific instance。 A Pcell instance can be created with a subset of the parameters defined in the superMaster。 Any parameters not specified will become default parameters, which will track changes in the superMaster's parameter value。 When a parameter is specified during creation or any subsequence calls to setParam(), this parameter will not be classified as a default parameter even though its value is equal to the default value in the superMaster。 The superMaster of pcell Instances will be bound when they are created so that OpenAccess can verify the parameters supplied。 If the binding fails, an oacParamsSuppliedForNonPCellInstMaster exception will be thrown。 The oaInst class can be observed by deriving from oaObserver

方法总览

状态 Python 调用
obj.getLibName(libName)
obj.getCellName(cellName)
obj.getViewName(viewName)
obj.getLibName(ns, libName)
obj.getCellName(ns, cellName)
obj.getViewName(ns, viewName)
obj.getHeader()
obj.getName(name)
obj.getName(ns, name)
obj.getParams(params)
obj.getNumBits()
obj.getPlacementStatus()
obj.getPriority()
obj.getSource()
obj.getUsage()
obj.getCluster()
obj.isImplicit()
obj.usesTermPositions()
obj.findParam(name, param)
_design.oaInst.setMaster(master)
_design.oaInst.setMaster(libName, cellName, viewName)
obj.setParams(params)
obj.setPlacementStatus(status)
obj.setPriority(priority)
obj.setSource(source)
obj.setUsage(usage)
obj.addToCluster(cluster)
obj.removeFromCluster()
obj.scalarize()
obj.getOccInst()
obj.getInstTerms(filterFlags=oacInstTermIterNotImplicit)
obj.getAssignments()
obj.getBlockagesOwnedBy()
obj.getOccInsts(top)
_design.oaInst.find(block, name)

方法说明

obj.getLibName(libName)

绑定状态: 已绑定

Python 调用: obj.getLibName(libName)

This function returns the library name in the given namespace for the master design referenced by this instance。

参数

  • ns: The namespace for the library name。
  • libName: The library name for the master design。

Python 示例

from oapy._oa import _design

# assume obj is a oaInst
obj.getLibName(libName)

obj.getCellName(cellName)

绑定状态: 已绑定

Python 调用: obj.getCellName(cellName)

This function returns the cell name in the given namespace for the master design referenced by this instance。

参数

  • ns: The namespace for the name。
  • cellName: The cell name for the master design。

Python 示例

from oapy._oa import _design

# assume obj is a oaInst
obj.getCellName(cellName)

obj.getViewName(viewName)

绑定状态: 已绑定

Python 调用: obj.getViewName(viewName)

This function returns the view name in the given namespace for the master design referenced by this instance。

参数

  • ns: The namespace for the name。
  • viewName: The view name for the master design。

Python 示例

from oapy._oa import _design

# assume obj is a oaInst
obj.getViewName(viewName)

obj.getLibName(ns, libName)

绑定状态: 已绑定

Python 调用: obj.getLibName(ns, libName)

This function returns the library name for the master design referenced by this instance。

参数

  • libName: The library name for the master design。

Python 示例

from oapy._oa import _design

# assume obj is a oaInst
obj.getLibName(ns, libName)

obj.getCellName(ns, cellName)

绑定状态: 已绑定

Python 调用: obj.getCellName(ns, cellName)

This function returns the cell name for the master design referenced by this instance。

参数

  • cellName: The cell name for the master design。

Python 示例

from oapy._oa import _design

# assume obj is a oaInst
obj.getCellName(ns, cellName)

obj.getViewName(ns, viewName)

绑定状态: 已绑定

Python 调用: obj.getViewName(ns, viewName)

This function returns the view name for the master design referenced by this instance。

参数

  • viewName: The view name for the master design。

Python 示例

from oapy._oa import _design

# assume obj is a oaInst
obj.getViewName(ns, viewName)

obj.getHeader()

绑定状态: 已绑定

Python 调用: obj.getHeader()

This function returns the instHeader associated with this instance。 The instHeader is a collection of the attributes that are common to all instances of a particular master。 For Pcell instances, this function returns the subheader。 从 oaRef 重新实现。

返回

  • The pointer to the instance header。

Python 示例

from oapy._oa import _design

# assume obj is a oaInst
obj.getHeader()

obj.getName(name)

绑定状态: 已绑定

Python 调用: obj.getName(name)

This function fills out name with the name of this instance。 The name is mapped according to the specified nameSpace。 在 oaArrayInst 中重新实现。

参数

  • ns: The nameSpace used to map the name。
  • name: The returned instance name。

Python 示例

from oapy._oa import _design

# assume obj is a oaInst
obj.getName(name)

obj.getName(ns, name)

绑定状态: 已绑定

Python 调用: obj.getName(ns, name)

This function fills out name with the name of this instance。

参数

  • name: The returned instance name。

Python 示例

from oapy._oa import _design

# assume obj is a oaInst
obj.getName(ns, name)

obj.getParams(params)

绑定状态: 已绑定

Python 调用: obj.getParams(params)

This function fills out params with the parameters of this instance。 Only Pcell instances have parameters。 This call only returns parameters that were specified during creation or through calls to setParams() 。 If invoked on an inst that is not a Pcell or if no parameter is specified for the instance, the returned params paramArray will have a numParams of zero。

Python 示例

from oapy._oa import _design

# assume obj is a oaInst
obj.getParams(params)

obj.getNumBits()

绑定状态: 已绑定

Python 调用: obj.getNumBits()

This function returns the number of bits of this instance。 This function always returns '1' for scalar and array instances。 The function can return '1' or more for vector instances。

Python 示例

from oapy._oa import _design

# assume obj is a oaInst
obj.getNumBits()

obj.getPlacementStatus()

绑定状态: 已绑定

Python 调用: obj.getPlacementStatus()

This function returns the placement status for this instance。

Python 示例

from oapy._oa import _design

# assume obj is a oaInst
obj.getPlacementStatus()

obj.getPriority()

绑定状态: 已绑定

Python 调用: obj.getPriority()

This function returns the placement priority for this instance。

Python 示例

from oapy._oa import _design

# assume obj is a oaInst
obj.getPriority()

obj.getSource()

绑定状态: 已绑定

Python 调用: obj.getSource()

This function returns the source for this instance。 This is used to indicate where the instance was created。

Python 示例

from oapy._oa import _design

# assume obj is a oaInst
obj.getSource()

obj.getUsage()

绑定状态: 已绑定

Python 调用: obj.getUsage()

This function returns a bit mask that indicates certain special reasons that instances can be used in a design。 The defined bits are: oacInstUsageFeedthru this instance simply connects its inputs to its outputs oacInstUsageSpare this instance is a spare that is not currently used in the design's function oacInstUsageJTag this instance is part of the JTAG test structures added to the design These bits may be or'ed together in the value returned。

Python 示例

from oapy._oa import _design

# assume obj is a oaInst
obj.getUsage()

obj.getCluster()

绑定状态: 已绑定

Python 调用: obj.getCluster()

This function returns a pointer to the cluster of which this instance is a member。 If the instance is not in a cluster, NULL is returned。

Python 示例

from oapy._oa import _design

# assume obj is a oaInst
obj.getCluster()

obj.isImplicit()

绑定状态: 已绑定

Python 调用: obj.isImplicit()

This function returns a boolean value that indicates if this instance is implicit, having been automatically created as a result of the creation of a vectorInst。

Python 示例

from oapy._oa import _design

# assume obj is a oaInst
obj.isImplicit()

obj.usesTermPositions()

绑定状态: 已绑定

Python 调用: obj.usesTermPositions()

This function returns a boolean indicating how connections to this instance have been made。 If the instTerms associated with this instance connect to terminal positions, this function returns 'true'。 Otherwise, this function returns 'false'。 Note that if the collection of instTerms for this instance is empty, this function will also return 'false'。

Python 示例

from oapy._oa import _design

# assume obj is a oaInst
obj.usesTermPositions()

obj.findParam(name, param)

绑定状态: 已绑定

Python 调用: obj.findParam(name, param)

This function searches the parameter list of this instance for a parameter with the specified name。 If found, it fills out param with the appropriate attributes and returns true。 Otherwise, the function returns false。 Only Pcell instances have parameters。

参数

  • name: The parameter name to find。
  • param: The parameter class to fill out if the parameter is found。

Python 示例

from oapy._oa import _design

# assume obj is a oaInst
obj.findParam(name, param)

_design.oaInst.setMaster(master)

绑定状态: 已绑定

Python 调用: _design.oaInst.setMaster(master)

This function sets the master of this instance。 This version sets the master to the design specified by the specified library, cell, and view names and does not force the master to open。 Note: If the target master is in memory or if it has an oaInstHeader that is a superHeader, then OpenAccess performs some conversions between parameters and properties。 If the target master is not in memory and does not have an oaInstHeader that is a superHeader, then no conversions between parameters and properties are performed。 In this case, if the current header is a subHeader, all the subHeader's non-default parameters are converted to properties。 Refer to Remastering Instances in the "Support for Pcells" section of the Programmers Guide for more information。

参数

  • libName: The library name for the new instance master。
  • cellName: The cell name for the new instance master。
  • viewName: The view name for the new instance master。

异常

  • oacCannotSetMasterImplicitInst
  • oacInstMustBeInUniqueOccHier

Python 示例

from oapy._oa import _design

_design.oaInst.setMaster(master)

_design.oaInst.setMaster(libName, cellName, viewName)

绑定状态: 已绑定

Python 调用: _design.oaInst.setMaster(libName, cellName, viewName)

This function sets the master of this instance。 This version sets the master to the specified design。 Note: If the current master or the target master is a Pcell, OpenAccess performs some conversions between parameters and properties。 Refer to Remastering Instances in the "Support for Pcells" section of the Programmers Guide for more information。

参数

  • master: The pointer to the new instance master。

异常

  • oacInvalidSuperMaster
  • oacCannotSetMasterImplicitInst
  • oacInstMustBeInUniqueOccHier

Python 示例

from oapy._oa import _design

_design.oaInst.setMaster(libName, cellName, viewName)

obj.setParams(params)

绑定状态: 已绑定

Python 调用: obj.setParams(params)

This function sets the parameters of this instance to the specified list。 If this instance already has parameters attached to it, the existing parameters are replaced。 The oaParamArray can be any subset of the master's oaParamArray definition。 Any parameter omitted becomes a default parameter and gets its value from the superMaster。 If a parameter included in the params array is not defined in the master's oaParamArray definition (whose name and type is not found in the master's definition), an oacInvalidDataTypeForParam exception is thrown。

参数

  • params: The array of parameters to apply to the instance。

异常

  • oacInvalidDataTypeForParam
  • oacInvalidPcellMaster
  • oacPcellMasterNotBound
  • oacCannotSetParamsImplicitInst
  • oacInstMustBeInUniqueOccHier

Python 示例

from oapy._oa import _design

# assume obj is a oaInst
obj.setParams(params)

obj.setPlacementStatus(status)

绑定状态: 已绑定

Python 调用: obj.setPlacementStatus(status)

This function sets the placement status of this instance to the specified value。

参数

  • status: The new placement status for the instance。

异常

  • oacCannotSetPlacementStatusImplicitInst

Python 示例

from oapy._oa import _design

# assume obj is a oaInst
obj.setPlacementStatus(status)

obj.setPriority(priority)

绑定状态: 已绑定

Python 调用: obj.setPriority(priority)

This function sets the priority for this instance to the specified value。 The priority is used during placement。

异常

  • oacCannotSetPriorityImplicitInst

Python 示例

from oapy._oa import _design

# assume obj is a oaInst
obj.setPriority(priority)

obj.setSource(source)

绑定状态: 已绑定

Python 调用: obj.setSource(source)

This function sets the source for this instance to the specified value。 The source is used to indicate where the instance was created。

异常

  • oacCannotSetSourceImplicitInst

Python 示例

from oapy._oa import _design

# assume obj is a oaInst
obj.setSource(source)

obj.setUsage(usage)

绑定状态: 已绑定

Python 调用: obj.setUsage(usage)

This function sets a bit mask that indicates certain special reasons for instances to be created in a design。 See oaInst::getUsage for details。

异常

  • oacCannotSetUsageImplicitInst

Python 示例

from oapy._oa import _design

# assume obj is a oaInst
obj.setUsage(usage)

obj.addToCluster(cluster)

绑定状态: 已绑定

Python 调用: obj.addToCluster(cluster)

This function adds this instance to the specified cluster。

异常

  • oacClusterAndInstNotSameBlock
  • oacInstAlreadyInCluster

Python 示例

from oapy._oa import _design

# assume obj is a oaInst
obj.addToCluster(cluster)

obj.removeFromCluster()

绑定状态: 已绑定

Python 调用: obj.removeFromCluster()

This function removes this instance from the cluster with which it is associated。 If this instance is not associated with a cluster, this function does nothing。

Python 示例

from oapy._oa import _design

# assume obj is a oaInst
obj.removeFromCluster()

obj.scalarize()

绑定状态: 已绑定

Python 调用: obj.scalarize()

This function insures that the bitInsts associated with this instance have been promoted to the explicit state so that they can support implementation data。 If this instance is a multibit instance, this function insures that all constituent bitInsts are promoted to the explicit state。 The multibit instance is then demoted to the implicit state so that no implementation data can be associated with it。 When an instance is demoted to the implicit state, associated implementation data is removed from it。 When an instance is scalarized, all of its connections are also scalarized。 Each bit of any multi-bit connection associated with the instance is promoted to the explicit state and is available for editing。

Python 示例

from oapy._oa import _design

# assume obj is a oaInst
obj.scalarize()

obj.getOccInst()

绑定状态: 已绑定

Python 调用: obj.getOccInst()

This function returns the occurrence instance that is the reflection of this block instance in the context of the top occurrence of the design that contains the instance。

Python 示例

from oapy._oa import _design

# assume obj is a oaInst
obj.getOccInst()

obj.getInstTerms(filterFlags=oacInstTermIterNotImplicit)

绑定状态: 已绑定

Python 调用: obj.getInstTerms(filterFlags=oacInstTermIterNotImplicit)

This function returns a collection of instTerms associated with this instance。

参数

  • filterFlags: Specifies what the collection contains。 The bits flags are defined as follows:。

Python 示例

from oapy._oa import _design

# assume obj is a oaInst
obj.getInstTerms(filterFlags=oacInstTermIterNotImplicit)

obj.getAssignments()

绑定状态: 已绑定

Python 调用: obj.getAssignments()

This function returns a collection of assignments in this instance。

Python 示例

from oapy._oa import _design

# assume obj is a oaInst
obj.getAssignments()

obj.getBlockagesOwnedBy()

绑定状态: 已绑定

Python 调用: obj.getBlockagesOwnedBy()

This function returns a collection of blockages owned by this instance。

Python 示例

from oapy._oa import _design

# assume obj is a oaInst
obj.getBlockagesOwnedBy()

obj.getOccInsts(top)

绑定状态: 已绑定

Python 调用: obj.getOccInsts(top)

This function returns a collection of the occInsts that are occurrences of this instance in the occurrence hierarchy identified by top。 The top occurrence does not have to be in the same design as the given instance。

参数

  • top: the top occurrence。

Python 示例

from oapy._oa import _design

# assume obj is a oaInst
obj.getOccInsts(top)

_design.oaInst.find(block, name)

绑定状态: 已绑定

Python 调用: _design.oaInst.find(block, name)

This function searches the specified block for an instance with the specified name。 If found, the instance is returned。 Otherwise, NULL is returned。

参数

  • block: The block to search。
  • name: The instance name to find。

返回

  • A pointer to the instance, if found; otherwise, NULL。

Python 示例

from oapy._oa import _design

_design.oaInst.find(block, name)