Struct libreda_db::reference_access::CellInstRef

source ·
pub struct CellInstRef<'a, H: HierarchyBase + ?Sized> { /* private fields */ }
Expand description

Default implementation for CellInstRef. This is just a wrapper around a netlist and a cell ID.

Implementations§

source§

impl<'a, H: HierarchyBase> CellInstRef<'a, H>

source

pub fn base(&self) -> &H

Access the base structure.

source

pub fn id(&self) -> H::CellInstId

Get the ID of this cell instance.

source

pub fn name(&self) -> Option<H::NameType>

Get the name of the cell instance.

source

pub fn qname(&self, separator: &str) -> String

Get a qualified name for this instance.

source

pub fn parent(&self) -> CellRef<'a, H>

Get the parent cell of this instance.

source

pub fn template(&self) -> CellRef<'a, H>

Get the template cell of this instance.

source

pub fn parent_id(&self) -> H::CellId

Get the ID of the parent cell of this instance.

source

pub fn template_id(&self) -> H::CellId

Get the ID of the template cell of this instance.

source§

impl<'a, L: LayoutBase> CellInstRef<'a, L>

source

pub fn get_transform(&self) -> SimpleTransform<L::Coord>

Get the geometric transform that describes the location of a cell instance relative to its parent.

source§

impl<'a, N: NetlistBase> CellInstRef<'a, N>

source

pub fn each_pin_instance_id(&self) -> impl Iterator<Item = N::PinInstId> + '_

Iterate over the IDs of all pins of this cell.

source

pub fn each_pin_instance(&self) -> impl Iterator<Item = PinInstRef<'a, N>> + '_

Iterate over all pins of this cell.

source

pub fn each_net(&self) -> impl Iterator<Item = NetRef<'a, N>> + '_

Iterate over all nets are connected to this instance. A net might appear more than once.

source

pub fn pin_instance(&self, pin: &N::PinId) -> PinInstRef<'a, N>

Get the pin instance which matches the given pin template.

source

pub fn pin_instance_by_name(&self, name: &str) -> Option<PinInstRef<'a, N>>

Find a pin instance by its name.

Trait Implementations§

source§

impl<'a, H: HierarchyBase> Debug for CellInstRef<'a, H>

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<'a, H: HierarchyBase> PartialEq for CellInstRef<'a, H>

source§

fn eq(&self, other: &Self) -> bool

This method tests for self and other values to be equal, and is used by ==.
1.0.0 · source§

fn ne(&self, other: &Rhs) -> bool

This method tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
source§

impl<'a, H: HierarchyBase> Eq for CellInstRef<'a, H>

Auto Trait Implementations§

§

impl<'a, H> Freeze for CellInstRef<'a, H>
where <H as HierarchyIds>::CellInstId: Freeze, H: ?Sized,

§

impl<'a, H> RefUnwindSafe for CellInstRef<'a, H>

§

impl<'a, H> Send for CellInstRef<'a, H>
where <H as HierarchyIds>::CellInstId: Send, H: Sync + ?Sized,

§

impl<'a, H> Sync for CellInstRef<'a, H>
where <H as HierarchyIds>::CellInstId: Sync, H: Sync + ?Sized,

§

impl<'a, H> Unpin for CellInstRef<'a, H>
where <H as HierarchyIds>::CellInstId: Unpin, H: ?Sized,

§

impl<'a, H> UnwindSafe for CellInstRef<'a, H>

Blanket Implementations§

source§

impl<T> Any for T
where T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> Borrow<T> for T
where T: ?Sized,

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
source§

impl<T> From<T> for T

source§

fn from(t: T) -> T

Returns the argument unchanged.

source§

impl<T, U> Into<U> for T
where U: From<T>,

source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

source§

impl<T> IntoEither for T

source§

fn into_either(self, into_left: bool) -> Either<Self, Self>

Converts self into a Left variant of Either<Self, Self> if into_left is true. Converts self into a Right variant of Either<Self, Self> otherwise. Read more
source§

fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
where F: FnOnce(&Self) -> bool,

Converts self into a Left variant of Either<Self, Self> if into_left(&self) returns true. Converts self into a Right variant of Either<Self, Self> otherwise. Read more
source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

§

type Error = Infallible

The type returned in the event of a conversion error.
source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.