BloqInstance#
qualtran.BloqInstance
View source on GitHub
|
A unique instance of a Bloq within a CompositeBloq.
qualtran.BloqInstance(
bloq, i
)
Attributes
bloqThe
Bloq.iAn arbitrary index to disambiguate this instance from other Bloqs of the same type within a
CompositeBloq.
Methods#
bloq_is
bloq_is(
t
) -> bool
Helper method that does isinstance(self.bloq, t).
This is also defined on DanglingT, so using this method on binst is equivalent
to:
>>> not isinstance(binst, DanglingT) and isinstance(binst.bloq, t)
__ne__
__ne__(
other
)
Check equality and either forward a NotImplemented or return the result negated.
__eq__
__eq__(
other
)
Method generated by attrs for class BloqInstance.
View source on GitHub