isomatch
Classes | Public Member Functions | Friends | List of all members
WireId Class Reference

#include <wireId.h>

Classes

class  CircIterator
 
class  NoSuchConnection
 
struct  PinConnection
 

Public Member Functions

 WireId (size_t id, const std::string &name, WireManager *manager)
 
 ~WireId ()
 
bool operator== (const WireId &oth) const
 
bool operator== (WireId &oth)
 
bool operator!= (const WireId &oth) const
 Id-based equality. More...
 
bool operator!= (WireId &oth)
 Id-based equality. More...
 
bool operator< (const WireId &oth) const
 
bool operator< (WireId &oth)
 
void connect (CircuitTree *circ)
 
void connect (const PinConnection &pin)
 
void connect (IOPin *pin, WireId *other)
 
void disconnect (CircuitTree *circ)
 Disconnect the given CircuitTree More...
 
void disconnect (IOPin *pin)
 Disconnect the given IOPin More...
 
const std::vector< CircuitTree * > & connectedCirc ()
 
const std::vector< PinConnection > & connectedPins ()
 
size_t connectedCount ()
 
CircIterator adjacent_begin ()
 
CircIterator adjacent_end ()
 
std::vector< CircuitTree * > connected ()
 
const std::string & name ()
 
const std::string & name () const
 
std::string uniqueName ()
 

Friends

struct std::hash< WireId >
 
struct std::hash< WireId *>
 
struct HashWirePtr
 

Constructor & Destructor Documentation

◆ WireId()

WireId::WireId ( size_t  id,
const std::string &  name,
WireManager manager 
)

Basic constructor

Parameters
idId of the wire
nameConvenience name for the wire
managerthe WireManager used to create this wire

◆ ~WireId()

WireId::~WireId ( )

Member Function Documentation

◆ adjacent_begin()

WireId::CircIterator WireId::adjacent_begin ( )

Get an iterator to the first adjacent circuit. Adjacent circuits are the circuits directly connected to this wire. Groups connected to this wire are considered (instead of considering the actual leaf the wire is connected to inside this group).

NOTE: the behaviour of this iterator is undefined when the parent WireId is altered during the iteration. This includes connecting more gates, merging this wire, …

◆ adjacent_end()

WireId::CircIterator WireId::adjacent_end ( )

Get a past-the-end iterator to adjacent circuits for this group. See adjacent_begin.

◆ connect() [1/3]

void WireId::connect ( CircuitTree circ)

Connect a circuit to this wire. Should be handled by circuit classes silently.

◆ connect() [2/3]

void WireId::connect ( const PinConnection pin)

Connect a pin to this wire.

◆ connect() [3/3]

void WireId::connect ( IOPin pin,
WireId other 
)

Connect a pin to this wire, creating a PinConnection on the fly.

◆ connected()

std::vector< CircuitTree * > WireId::connected ( )

Get the list of circuits connected to that wire, possibly through other wires. Must perform a DFS through connected wires and create the list on-the-fly, which might be a bit slow for heavy use.

◆ connectedCirc()

const std::vector< CircuitTree * > & WireId::connectedCirc ( )

Get the list of circuits connected to that wire. Fast.

◆ connectedCount()

size_t WireId::connectedCount ( )
inline

Get the number of direct connections to this wire.

◆ connectedPins()

const std::vector< WireId::PinConnection > & WireId::connectedPins ( )

Get the list of wires connected to that wire. Fast.

◆ disconnect() [1/2]

void WireId::disconnect ( CircuitTree circ)

Disconnect the given CircuitTree

◆ disconnect() [2/2]

void WireId::disconnect ( IOPin pin)

Disconnect the given IOPin

◆ name() [1/2]

const std::string& WireId::name ( )
inline

Get the name of this wire

◆ name() [2/2]

const std::string& WireId::name ( ) const
inline

Get the name of this wire (const version)

◆ operator!=() [1/2]

bool WireId::operator!= ( const WireId oth) const

Id-based equality.

◆ operator!=() [2/2]

bool WireId::operator!= ( WireId oth)

Id-based equality.

◆ operator<() [1/2]

bool WireId::operator< ( const WireId oth) const

Id-based comparaison

◆ operator<() [2/2]

bool WireId::operator< ( WireId oth)

Id-based comparaison

◆ operator==() [1/2]

bool WireId::operator== ( const WireId oth) const

Id-based equality

◆ operator==() [2/2]

bool WireId::operator== ( WireId oth)

Id-based equality

◆ uniqueName()

std::string WireId::uniqueName ( )

Get this wire's display unique name

Friends And Related Function Documentation

◆ HashWirePtr

friend struct HashWirePtr
friend

◆ std::hash< WireId *>

friend struct std::hash< WireId * >
friend

◆ std::hash< WireId >

friend struct std::hash< WireId >
friend

Member Data Documentation

◆ chain

WireId* WireId::chain

◆ end

Inner* WireId::end

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