oaVectorName
模块: oapy._oa._base
导入: from oapy._oa import _base
概览
oaVectorName 在 oapy 中可用,可通过 _base 模块访问。
本页汇总 oaVectorName 当前在 oapy 中可用的 Python 接口。
详细说明
The oaVectorName utility class holds a name for a database object that consists of a base name with an index range。 These names can be hierarchical。 The index range may be high to low or low to high, and may have an optional step value。 If the step value is greater than 1, then a step value of n means that the vector only includes every nth bit after the starting bit。 In conjunction with the oaNameSpace objects, this class facilitates mapping names from one namespace to another。 See the Name Mapping Section in the Programmers Guide for more information about mapping names between different namespaces。 An example of an oaVectorName in the oaVerilog namespace is test[3:0] , where the base portion of this name is test , and start index is 3, the stop index is 0, and the implied step value is 1。
构造函数
_base.oaVectorName()
obj = _base.oaVectorName()
_base.oaVectorName(nSpace, in, start, stop, step=1)
obj = _base.oaVectorName(nSpace, in, start, stop, step=1)
_base.oaVectorName(nSpace, in)
obj = _base.oaVectorName(nSpace, in)
_base.oaVectorName(in, start, stop, step=1)
obj = _base.oaVectorName(in, start, stop, step=1)
_base.oaVectorName(in)
obj = _base.oaVectorName(in)
方法总览
| 状态 | Python 调用 |
|---|---|
| ✅ | obj.init(nSpace, in, baseOnly=false) |
| ✅ | obj.get(nSpace, out) |
| ✅ | obj.get(out) |
| ✅ | obj.getBaseName(nSpace, out) |
| ✅ | obj.getBaseName(out) |
| ✅ | obj.getBaseName(out) |
| ✅ | obj.getBitName(nSpace, bit, out) |
| ✅ | obj.getNumBits() |
| ✅ | obj.getStart() |
| ✅ | obj.getStop() |
| ✅ | obj.getStep() |
| ✅ | obj.setStart(val) |
| ✅ | obj.setStop(val) |
| ✅ | obj.setStep(val) |
| ✅ | obj.operator=(name) |
| ✅ | obj.operator==(name) |
| ✅ | obj.operator!=(name) |
方法说明
obj.init(nSpace, in, baseOnly=false)
绑定状态: 已绑定
Python 调用: obj.init(nSpace, in, baseOnly=false)
This function allows reuse of the oaVectorName object in order to improve application performance and capacity。 This function initializes the name by clearing any previously stored name data, then re-initializing its value to the string specified by in, evaluating the string in the specified namespace。 The optional boolean argument baseOnly indicates if the input name is interpreted as the base portion of the vector name or as the entire name -- for example, with nSpace set to the oaVerilog namespace, baseOnly equal to true, and in specified as "abc[0:7:1]"。
参数
nSpace: The oaNameSpace in which to evaluate the string。in: The input string, which may specify the base name only (if baseOnly is true) or the entire name (if baseOnly is false)。baseOnly: A boolean value that indicates if the input string is an entire vector name or only the base portion。
异常
oacInvalidNameLength。oacInvalidNameSyntax。oacInvalidVectorValue。
Python 示例
from oapy._oa import _base
# assume obj is a oaVectorName
obj.init(nSpace, in, baseOnly=false)
obj.get(nSpace, out)
绑定状态: 已绑定
Python 调用: obj.get(nSpace, out)
This function returns this vector name, mapped into the oaNative nameSpace。
参数
out: The string in which to output the mapped name。
Python 示例
from oapy._oa import _base
# assume obj is a oaVectorName
obj.get(nSpace, out)
obj.get(out)
绑定状态: 已绑定
Python 调用: obj.get(out)
This function returns the vector name, mapped into the specified oaNameSpace 。 An oacVectorNameInvalid exception is thrown if the specified nameSpace does not support vectorNames。 For information on the names supported in each nameSpace, see Details of OpenAccess Name Spaces 。
参数
nSpace: The oaNameSpace in which to map this name。out: The string in which to output the mapped name。
异常
oacVectorNameInvalid。
Python 示例
from oapy._oa import _base
# assume obj is a oaVectorName
obj.get(out)
obj.getBaseName(nSpace, out)
绑定状态: 已绑定
Python 调用: obj.getBaseName(nSpace, out)
This function returns the base portion of this name。
参数
out: The scalar name in which to output the mapped name。
Python 示例
from oapy._oa import _base
# assume obj is a oaVectorName
obj.getBaseName(nSpace, out)
obj.getBaseName(out)
绑定状态: 已绑定
Python 调用: obj.getBaseName(out)
This function returns the base portion of this name, mapped into the oaNative nameSpace。
参数
out: The string in which to output the mapped name。
Python 示例
from oapy._oa import _base
# assume obj is a oaVectorName
obj.getBaseName(out)
obj.getBaseName(out)
绑定状态: 已绑定
Python 调用: obj.getBaseName(out)
This function returns the base portion of this name, mapped into the specified oaNameSpace 。
参数
nSpace: The oaNameSpace in which to map the base portion of this name。out: The string in which to output the mapped name。
Python 示例
from oapy._oa import _base
# assume obj is a oaVectorName
obj.getBaseName(out)
obj.getBitName(nSpace, bit, out)
绑定状态: 已绑定
Python 调用: obj.getBitName(nSpace, bit, out)
This function returns the bit value of this vector name, mapped into the specified oaNameSpace 。
参数
nSpace: The oaNameSpace in which to map the bit value of this name。bit: The bit value of this vector name。out: The string to which to output the mapped name。
异常
oacBitNotInRangeForName。
Python 示例
from oapy._oa import _base
# assume obj is a oaVectorName
obj.getBitName(nSpace, bit, out)
obj.getNumBits()
绑定状态: 已绑定
Python 调用: obj.getNumBits()
This function returns the number of bits this vector name represents。
Python 示例
from oapy._oa import _base
# assume obj is a oaVectorName
obj.getNumBits()
obj.getStart()
绑定状态: 已绑定
Python 调用: obj.getStart()
This function returns the start index for this oaVectorName。
Python 示例
from oapy._oa import _base
# assume obj is a oaVectorName
obj.getStart()
obj.getStop()
绑定状态: 已绑定
Python 调用: obj.getStop()
This function returns the stop index of this oaVectorName。
Python 示例
from oapy._oa import _base
# assume obj is a oaVectorName
obj.getStop()
obj.getStep()
绑定状态: 已绑定
Python 调用: obj.getStep()
This function returns the step value for this oaVectorName。
Python 示例
from oapy._oa import _base
# assume obj is a oaVectorName
obj.getStep()
obj.setStart(val)
绑定状态: 已绑定
Python 调用: obj.setStart(val)
This function sets the start index for this vector name to the specified value。
参数
val: The start value。
Python 示例
from oapy._oa import _base
# assume obj is a oaVectorName
obj.setStart(val)
obj.setStop(val)
绑定状态: 已绑定
Python 调用: obj.setStop(val)
This function sets the stop index for this vector name to the specified value。
参数
val: The stop value。
Python 示例
from oapy._oa import _base
# assume obj is a oaVectorName
obj.setStop(val)
obj.setStep(val)
绑定状态: 已绑定
Python 调用: obj.setStep(val)
This function sets the step value for this vector name to the specified value。
参数
val: The step value。
Python 示例
from oapy._oa import _base
# assume obj is a oaVectorName
obj.setStep(val)
obj.operator=(name)
绑定状态: 已绑定
Python 调用: obj.operator=(name)
Python 示例
from oapy._oa import _base
# assume obj is a oaVectorName
obj.operator=(name)
obj.operator==(name)
绑定状态: 已绑定
Python 调用: obj.operator==(name)
Python 示例
from oapy._oa import _base
# assume obj is a oaVectorName
obj.operator==(name)
obj.operator!=(name)
绑定状态: 已绑定
Python 调用: obj.operator!=(name)
Python 示例
from oapy._oa import _base
# assume obj is a oaVectorName
obj.operator!=(name)