Ophidian
 All Classes Namespaces Functions
Public Member Functions | List of all members
ophidian::netlist::netlist Class Reference

Netlist class. More...

#include <netlist.h>

Public Member Functions

void cell_preallocate (std::size_t qnt)
 
void pin_preallocate (std::size_t qnt)
 
void net_preallocate (std::size_t qnt)
 
 netlist (standard_cell::standard_cells *std_cells)
 Constructor. More...
 
void register_cell_property (entity_system::property *property)
 Registers cell property. More...
 
void register_pin_property (entity_system::property *property)
 Registers pin property. More...
 
void register_net_property (entity_system::property *property)
 Registers net property. More...
 
void module_name (std::string name)
 
std::string module_name () const
 
const
standard_cell::standard_cells
std_cells () const
 Standard cells getter. More...
 
entity_system::entity cell_find (std::string name) const
 Finds cell. More...
 
entity_system::entity cell_insert (std::string name, std::string type)
 Inserts a new cell. More...
 
void cell_remove (entity_system::entity cell)
 Removes a cell. More...
 
std::size_t cell_count () const
 Returns the number of cells. More...
 
std::string cell_name (entity_system::entity cell) const
 Cell name getter. More...
 
const std::vector
< entity_system::entity > & 
cell_pins (entity_system::entity cell) const
 Cell pins getter. More...
 
entity_system::entity cell_std_cell (entity_system::entity cell) const
 Cell type getter. More...
 
bool cell_std_cell (entity_system::entity cell, std::string type)
 Cell type setter. More...
 
bool cell_std_cell (entity_system::entity cell, entity_system::entity std_cell)
 Cell type setter. More...
 
const
entity_system::entity_system
cell_system () const
 Cell system getter. More...
 
const cellscells_properties () const
 Cell properties getter. More...
 
entity_system::entity pin_insert (entity_system::entity cell, std::string name)
 Inserts a new pin. More...
 
std::size_t pin_count () const
 Returns the number of pins. More...
 
std::string pin_name (entity_system::entity pin) const
 Pin name getter. More...
 
entity_system::entity pin_owner (entity_system::entity pin) const
 Pin owner getter. More...
 
entity_system::entity pin_net (entity_system::entity pin) const
 Pin net getter. More...
 
entity_system::entity pin_std_cell (entity_system::entity pin) const
 Pin type getter. More...
 
entity_system::entity pin_by_name (std::string name) const
 Finds pin. More...
 
const
entity_system::entity_system
pin_system () const
 Pin system getter. More...
 
const pinspins_properties () const
 Pin properties getter. More...
 
entity_system::entity net_insert (std::string name)
 Inserts a new net. More...
 
entity_system::entity net_insert (std::string name, std::size_t pin_count)
 Inserts a new net. More...
 
void net_remove (entity_system::entity net)
 Removes a net. More...
 
std::size_t net_count () const
 Returns the number of nets. More...
 
std::string net_name (entity_system::entity net) const
 Net name getter. More...
 
const std::vector
< entity_system::entity > & 
net_pins (entity_system::entity net) const
 Net pins getter. More...
 
std::pair< std::vector
< std::string >
::const_iterator, std::vector
< std::string >
::const_iterator > 
net_names () const
 Net names iterator. More...
 
const
entity_system::entity_system
net_system () const
 Net system getter. More...
 
entity_system::entity net_by_name (std::string name) const
 Finds net. More...
 
const netsnets_properties () const
 Net properties getter. More...
 
void connect (entity_system::entity net, entity_system::entity pin)
 Connects a pin to a net. More...
 
void disconnect (entity_system::entity pin)
 Disconnects a pin from its net. More...
 
entity_system::entity PI_insert (std::string name)
 Inserts a new primary input. More...
 
void PI_remove (entity_system::entity PI)
 Removes a primary input. More...
 
std::size_t PI_count () const
 Returns the number of primary inputs. More...
 
std::vector
< entity_system::entity >
::const_iterator 
PI_begin () const
 Primary input begin iterator. More...
 
std::vector
< entity_system::entity >
::const_iterator 
PI_end () const
 Primary input end iterator. More...
 
entity_system::entity PO_insert (std::string name)
 Inserts a new primary output. More...
 
void PO_remove (entity_system::entity PO)
 Removes a primary output. More...
 
std::size_t PO_count () const
 Returns the number of primary outputs. More...
 
std::vector
< entity_system::entity >
::const_iterator 
PO_begin () const
 Primary output begin iterator. More...
 
std::vector
< entity_system::entity >
::const_iterator 
PO_end () const
 Primary output end iterator. More...
 

Detailed Description

This class provides the basic netlist interface, such as cells, pins and nets manipulation.

Constructor & Destructor Documentation

ophidian::netlist::netlist::netlist ( standard_cell::standard_cells std_cells)

Netlist constructor. Creates the entity systems for cells, pins and nets.

Parameters
std_cellsStandard cells object.

Member Function Documentation

std::size_t ophidian::netlist::netlist::cell_count ( ) const
inline

Returns the number of cells created in the cells system.

Returns
Number of cells.
entity_system::entity ophidian::netlist::netlist::cell_find ( std::string  name) const

Finds a cell by its name.

Parameters
nameCell name.
Returns
Entity representing the found cell.
entity_system::entity ophidian::netlist::netlist::cell_insert ( std::string  name,
std::string  type 
)

Inserts a new cell in the netlist. A cell has a name and type associated to it.

Parameters
nameName of the cell, used to identify it.
typeStandard cell type of the cell.
Returns
The created cell.
std::string ophidian::netlist::netlist::cell_name ( entity_system::entity  cell) const
inline

Returns the name of a cell.

Parameters
cellCell to get the name.
Returns
Name of the cell.
const std::vector<entity_system::entity>& ophidian::netlist::netlist::cell_pins ( entity_system::entity  cell) const
inline

Returns the pins of a cell.

Parameters
cellCell to get the pins.
Returns
Vector containing all pins of the cell.
void ophidian::netlist::netlist::cell_remove ( entity_system::entity  cell)

Removes an existing cell from the netlist.

Parameters
cellCell to be removed.
entity_system::entity ophidian::netlist::netlist::cell_std_cell ( entity_system::entity  cell) const
inline

Returns the standard cell type of a cell.

Parameters
cellCell to get the type.
Returns
Entity representing the standard cell type of the cell.
bool ophidian::netlist::netlist::cell_std_cell ( entity_system::entity  cell,
std::string  type 
)

Sets the standard cell type of a cell. The number of pins of the current cell type and the new one must match.

Parameters
cellCell to set the type.
typeName of the type to set for the cell.
Returns
bool variable describing if it was possible to set the type of the cell.
bool ophidian::netlist::netlist::cell_std_cell ( entity_system::entity  cell,
entity_system::entity  std_cell 
)

Sets the standard cell type of a cell. The number of pins of the current cell type and the new one must match.

Parameters
cellCell to set the type.
typeEntity of the type to set for the cell.
Returns
bool variable describing if it was possible to set the type of the cell.
const entity_system::entity_system& ophidian::netlist::netlist::cell_system ( ) const
inline

Returns the cells entity system.

Returns
Constant reference to the cells entity system.
const cells& ophidian::netlist::netlist::cells_properties ( ) const
inline

Returns the cells properties object.

Returns
Constant reference to the object containing the cells properties.
void ophidian::netlist::netlist::connect ( entity_system::entity  net,
entity_system::entity  pin 
)

Connects a pin to a net. This method changes the pins property of the net to contain the new pin and the net property of the pin.

Parameters
netNet to be connnected.
pinPin to be connected.
void ophidian::netlist::netlist::disconnect ( entity_system::entity  pin)

Disconnects a pin from its net. This method removes the pin from the net pins property and leaves the pin without a net.

Parameters
pinPin to be disconnected.
entity_system::entity ophidian::netlist::netlist::net_by_name ( std::string  name) const
inline

Finds a net by its name.

Parameters
nameNet name.
Returns
Entity representing the found net.
std::size_t ophidian::netlist::netlist::net_count ( ) const
inline

Returns the number of nets created in the pins system.

Returns
Number of pins.
entity_system::entity ophidian::netlist::netlist::net_insert ( std::string  name)

Inserts a new net in the netlist. A net has a name associated to it.

Parameters
nameName of the net, used to identify it.
Returns
The created net.
entity_system::entity ophidian::netlist::netlist::net_insert ( std::string  name,
std::size_t  pin_count 
)

Inserts a new net in the netlist. A net has a name associated to it.

Parameters
nameName of the net, used to identify it.
pin_countNumber of pins the net will connect
Returns
The created net.
std::string ophidian::netlist::netlist::net_name ( entity_system::entity  net) const
inline

Returns the name of a net.

Parameters
netNet to get the name.
Returns
Name of the net.
std::pair<std::vector<std::string>::const_iterator, std::vector<std::string>::const_iterator> ophidian::netlist::netlist::net_names ( ) const
inline

Returns the beginning and end iterators of the net names property.

Returns
Pair of iterators pointing to the begin and end of the net names property.
const std::vector<entity_system::entity>& ophidian::netlist::netlist::net_pins ( entity_system::entity  net) const
inline

Returns the pins of a net.

Parameters
netNet to get the pins.
Returns
Vector containing all pins of the net.
void ophidian::netlist::netlist::net_remove ( entity_system::entity  net)

Removes an existing net from the netlist.

Parameters
netNet to be removed.
const entity_system::entity_system& ophidian::netlist::netlist::net_system ( ) const
inline

Returns the nets entity system.

Returns
Constant reference to the nets entity system.
const nets& ophidian::netlist::netlist::nets_properties ( ) const
inline

Returns the nets properties object.

Returns
Constant reference to the object containing the nets properties.
std::vector<entity_system::entity>::const_iterator ophidian::netlist::netlist::PI_begin ( ) const
inline

Returns an iterator pointing to the beginning of the primary inputs in the netlist.

Returns
Constant iterator pointing to the beginning of the primary inputs.
std::size_t ophidian::netlist::netlist::PI_count ( ) const
inline

Returns the number of primary inputs created in the netlist.

Returns
Number of primary inputs.
std::vector<entity_system::entity>::const_iterator ophidian::netlist::netlist::PI_end ( ) const
inline

Returns an iterator pointing to the end of the primary inputs in the netlist.

Returns
Constant iterator pointing to the end of the primary inputs.
entity_system::entity ophidian::netlist::netlist::PI_insert ( std::string  name)

Inserts a new primary input in the netlist. A primary input is a pin without an owner.

Parameters
nameName of the primary input, used to identify it.
Returns
The created primary input.
void ophidian::netlist::netlist::PI_remove ( entity_system::entity  PI)

Removes an existing primary input from the netlist.

Parameters
PIPrimary input to be removed.
entity_system::entity ophidian::netlist::netlist::pin_by_name ( std::string  name) const
inline

Finds a pin by its name.

Parameters
namePin name.
Returns
Entity representing the found pin.
std::size_t ophidian::netlist::netlist::pin_count ( ) const
inline

Returns the number of pins created in the pins system.

Returns
Number of pins.
entity_system::entity ophidian::netlist::netlist::pin_insert ( entity_system::entity  cell,
std::string  name 
)

Inserts a new pin in the netlist. A pin has a name and owner associated to it.

Parameters
cellCell owner of the pin.
nameName of the pin, used to identify it.
Returns
The created pin.
std::string ophidian::netlist::netlist::pin_name ( entity_system::entity  pin) const
inline

Returns the name of a pin.

Parameters
pinPin to get the name.
Returns
Name of the pin.
entity_system::entity ophidian::netlist::netlist::pin_net ( entity_system::entity  pin) const
inline

Returns the net of a pin.

Parameters
pinPin to get the net.
Returns
Entity describing the net of the pin.
entity_system::entity ophidian::netlist::netlist::pin_owner ( entity_system::entity  pin) const
inline

Returns the owner of a pin.

Parameters
pinPin to get the owner.
Returns
Entity describing the cell owning the pin.
entity_system::entity ophidian::netlist::netlist::pin_std_cell ( entity_system::entity  pin) const
inline

Returns the standard cell type of a pin.

Parameters
pinPin to get the type.
Returns
Entity describing the standard cell type of a pin.
const entity_system::entity_system& ophidian::netlist::netlist::pin_system ( ) const
inline

Returns the pins entity system.

Returns
Constant reference to the pins entity system.
const pins& ophidian::netlist::netlist::pins_properties ( ) const
inline

Returns the pins properties object.

Returns
Constant reference to the object containing the pins properties.
std::vector<entity_system::entity>::const_iterator ophidian::netlist::netlist::PO_begin ( ) const
inline

Returns an iterator pointing to the beginning of the primary outputs in the netlist.

Returns
Constant iterator pointing to the beginning of the primary outputs.
std::size_t ophidian::netlist::netlist::PO_count ( ) const
inline

Returns the number of primary outputs created in the netlist.

Returns
Number of primary outputs.
std::vector<entity_system::entity>::const_iterator ophidian::netlist::netlist::PO_end ( ) const
inline

Returns an iterator pointing to the end of the primary outputs in the netlist.

Returns
Constant iterator pointing to the end of the primary outputs.
entity_system::entity ophidian::netlist::netlist::PO_insert ( std::string  name)

Inserts a new primary output in the netlist. A primary input is a pin without an owner.

Parameters
nameName of the primary output, used to identify it.
Returns
The created primary output.
void ophidian::netlist::netlist::PO_remove ( entity_system::entity  PO)

Removes an existing primary output from the netlist.

Parameters
POPrimary output to be removed.
void ophidian::netlist::netlist::register_cell_property ( entity_system::property property)

Registers a property to the cells entity system.

Parameters
propertyProperty to be registered.
void ophidian::netlist::netlist::register_net_property ( entity_system::property property)

Registers a property to the nets entity system.

Parameters
propertyProperty to be registered.
void ophidian::netlist::netlist::register_pin_property ( entity_system::property property)

Registers a property to the pins entity system.

Parameters
propertyProperty to be registered.
const standard_cell::standard_cells& ophidian::netlist::netlist::std_cells ( ) const
inline

Returns the standard cells object.

Returns
Constant reference to the standard cells object.

The documentation for this class was generated from the following files: