pub struct Undo<'a, T, U> { /* private fields */ }
Expand description

Wrapper around netlist, layout and L2N structures that allows undoing of operations.

Types

  • T: Underlying data structure.
  • U: Undo-operation.

Implementations

Return the number of undoable transactions.

Clear the undo buffer and make changes permanent.

Create a wrapper around a fused layout and netlist which allows to undo operations.

Undo the latest transaction. Does nothing if there’s no transaction left to be undone.

Create a wrapper which allows to undo operations performed on the LayoutEdit trait.

Undo the latest transaction. Does nothing if there’s no transaction left to be undone.

Create a wrapper which allows to undo operations performed on the NetlistEdit trait.

Undo the latest transaction. Does nothing if there’s no transaction left to be undone.

Create a wrapper which allows to undo operations performed on the HierarchyEdit trait.

Undo the latest transaction. Does nothing if there’s no transaction left to be undone.

Undoes all transactions.

Trait Implementations

The resulting type after dereferencing.

Dereferences the value.

Create a new empty data structure.

Create a new and empty cell template. A cell template can be be instantiated in other cells. Read more

Remove a cell and all the instances of it. Read more

Create a new instance of template_cell in parent_cell. Recursive instantiation is forbidden and might panic. Read more

Remove cell instance if it exists. Read more

Change the name of a cell instance. Read more

Change the name of a cell. Read more

Set a property of the top-level chip data structure..

Set a property of a cell.

Set a property of a cell instance.

Iterate over all shapes that are marked to belong to the specified net.

Iterate over all shapes that are part of the pin.

Get the net of a shape.

Get the pin that belongs to the shape (if any).

Create the link between a circuit pin and its shapes in the layout. Return the current pin. Read more

Set the net of a shape. Return the current net. Read more

Set the distance unit used in this layout in ‘pixels per micron’.

Create a new layer. Use set_layer_name() to define a name. Read more

Create a new layer with a specific ID. This is used to clone layer-stacks between layouts while preserving their IDs. Returns an Err when the ID already exists. Read more

Set the name of a layer or clear the layer name when passing None. This method should not change the ID of the layer. Returns the previous name of the layer. Read more

Insert a geometric shape into the parent cell.

Remove shape from the parent cell.

Replace the geometry of a shape.

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

Set a property of a shape.

Pin identifier type. Uniquely identifies a pin in the whole netlist.

Pin instance identifier type. Uniquely identifies a pin instance in the whole netlist. A pin instance is a pin of a circuit instance. Read more

Net identifier type. Uniquely identifies a net in the whole netlist.

Get the ID of the template pin of this pin instance.

Get the signal direction of the pin.

Get the name of the pin.

Find a pin by its name. Returns None if no such pin can be found. Read more

Get the ID of the parent circuit of this pin.

Get the ID of the circuit instance that holds this pin instance.

Get the ID of the parent circuit of this net.

Get the internal net attached to this pin.

Get the external net attached to this pin instance.

Get the net of the logical constant zero.

Get the net of the logical constant one.

Find a net by its name inside the parent circuit. Returns None if no such net can be found. Read more

Get the name of the net.

Call a function for each pin of the circuit.

Call a function for each pin instance of the circuit instance.

Call a function for net of the circuit.

Get the number of pins of a circuit.

Call a function for each pin connected to this net.

Call a function for each pin instance connected to this net.

Get the ID of a pin instance given the cell instance and the pin ID.

Get the net that is attached to this terminal.

Get a Vec with the IDs of all pins of this circuit.

Iterate over all pins of a circuit.

Get a Vec with the IDs of all pin instance of this circuit instance.

Iterate over all pin instances of a circuit.

Iterate over all external nets connected to the circuit instance. A net might appear more than once. Read more

Iterate over all external nets connected to the circuit instance. A net might appear more than once. Read more

Get a vector of all external nets connected to the circuit instance. A net might appear more than once. Read more

Get a Vec with all nets in this circuit.

Iterate over all defined nets inside a circuit.

Return the number of nets defined inside a cell.

Get the number of pins that are connected to this net.

Get the number of pin instances that are connected to this net.

Get the number of terminals that are connected to this net.

Get a Vec with all pin IDs connected to this net.

Iterate over all pins of a net.

Get a Vec with all pin instance IDs connected to this net.

Iterate over all pins of a net.

Call a function for each terminal connected to this net.

Get a Vec with all terminal IDs connected to this net.

Iterate over all terminals of a net.

Create a new pin in this cell. Also adds the pin to all instances of the cell. Read more

Remove the pin from this circuit and from all instances of this circuit.

Change the name of the pin, returns the old name. Read more

Create a net net that lives in the parent circuit.

Set a new name for the net. This might panic if the name already exists. Returns the old name. Read more

Delete the net if it exists and disconnect all connected terminals.

Connect a pin to a net. Returns the old connected net, if any. Read more

Connect a pin instance to a net. Returns the old connected net, if any. Read more

Disconnect the pin from any connected net. Returns the old connected net, if any. Read more

Disconnect the pin instance from any connected net. Returns the old connected net, if any. Read more

Connect a terminal to a net. Returns the old connected net, if any. Read more

Disconnect the terminal from any connected net. Returns the old connected net, if any. Read more

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.

Type for names of cells, instances, etc.

Cell/module identifier type.

Cell instance identifier type.

Find a cell by its name. Return the cell with the given name. Returns None if the cell does not exist. Read more

Find a cell instance by its name. Returns None if the name does not exist. Read more

Get the name of the cell.

Get the name of the cell instance.

Get the ID of the parent cell of this instance.

Get the ID of the template cell of this instance.

Call a function on each cell of the netlist.

Get a Vec of all cell IDs in this netlist.

Iterate over all cells.

Call a function on each instance in this cell.

Get a Vec of the IDs of all instances in this cell.

Iterate over all instances in a cell.

Call a function for each cell that is a child of this cell.

Get a Vec of each cell that is a child of this cell.

Iterate over all cells that are instantiated in this cell.

Count all cells that are dependencies of cell.

Call a function for each cell that directly depends on cell.

Get a Vec of each cell that directly depends on cell.

Iterate over each cell that directly depends on cell.

Count all cells that are directly dependent on cell, i.e. contain an instance of cell.

Iterate over all instances of this cell, i.e. instances that use this cell as a template. Read more

Get a Vec with all cell instances referencing this cell.

Iterate over all instances of this cell, i.e. instances that use this cell as a template. Read more

Count all instantiations of cell.

Get the number of cell instances inside the cell.

Get the number of cell templates.

Get a property of the top-level chip data structure.

Get a property of a cell.

Get a property of a cell instance.

Remove all child instances inside the cell.

Remove the cell instance and all cells which are then not used anymore.

Remove the cell and all other cells which are then not used anymore.

Check if the cell is a top level cell. This is done by checking that no other cells have an instance of this cell. Read more

Check if the cell is a leaf cell. This is done by checking that this cell contains no other cell instances. Read more

Iterate over all top level cells.

Iterate over all leaf cells, i.e. cells which contain no other cells.

Calls U::from(self).

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

Number type used for coordinates and distances.

Number type for areas. This is possibly another type then Coord for the following reasons: Read more

Layer identifier type.

Shape identifier type.

Get the distance unit used in this layout in ‘pixels per micron’.

Iterate over all defined layers.

Get the LayerInfo data structure for this layer.

Find layer index by the (index, data type) tuple.

Find layer index by the name.

Compute the bounding box of the shapes on one layer. The bounding box also includes all child cell instances. Read more

Compute the bounding box of the cell over all layers. The bounding box is not defined if the cell is empty. In this case return None. Read more

Iterate over the IDs of all shapes in the cell on a specific layer.

Call a function for each shape on this layer.

Access a shape by its ID.

Get the parent cell and the layer of a shape as a (cell, layer) tuple.

Call a function f for each shape of this cell and its sub cells. Along to the geometric shape f also gets a transformation as argument. The transformation describes the actual position of the geometric shape relative to the cell. Read more

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

Get a property of a shape.

Get a clone of the shape geometry.

Get the layer of a shape.

Create a layer or return an existing one.

Take all terminals that are connected to old_net and connect them to new_net instead. The old net is no longer used and removed. Read more

Replace the circuit instance with its contents. Remove the circuit instance afterwards. Does not purge nets nor unconnected instances. So there could be unconnected nets or unconnected instances. Read more

Flatten all instances of this circuit by replacing them with their content. Remove the circuit from the netlist afterwards. For top level circuits this is equivalent to removing them. Read more

Delete all unconnected nets in this circuit. Return number of purged nets. Read more

Delete all unconnected nets in all circuits. Return number of purged nets. Read more

Create names for all unnamed nets in the specified circuit. The names will consist of the prefix and an appended number. After calling this method, no net inside this circuit will be unnamed. Read more

Check if the net is either the constant LOW or HIGH.

Get all nets that are connected to the circuit instance.

Visit all circuit instances connected to this net. An instance is touched not more than once. Read more

Iterate over all circuit instances connected to this net. An instance is touched not more than once. Read more

Write the netlist in a human readable form.

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.