pub struct PortDef<W> {
    pub name: Id,
    pub width: W,
    pub direction: Direction,
    pub attributes: Attributes,
}
Expand description

Definition of a port parameterized by a width type. Ports on Primitives can be parameteris and use Width. Ports on Components cannot be parameterized and therefore use u64.

Fields

name: Id

The name of the port.

width: W

The width of the port. .

direction: Direction

The direction of the port. Only allowed to be Direction::Input or Direction::Output.

attributes: Attributes

Attributes attached to this port definition

Implementations

Given a map from names of parameters to their values, attempt to resolve this definition. Errors if there is no binding for a required parameter binding.

Trait Implementations

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

Formats the value using the given formatter. Read more

Performs the conversion.

Performs the conversion.

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Returns the argument unchanged.

Calls U::from(self).

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

The resulting type after obtaining ownership.

Creates owned data from borrowed data, usually by cloning. Read more

🔬 This is a nightly-only experimental API. (toowned_clone_into)

Uses borrowed data to replace owned data, usually by cloning. Read more

The type returned in the event of a conversion error.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.