Logo Search packages:      
Sourcecode: ktechlab version File versions  Download package

PinList Pin::localConnectedPins (  )  const

This function returns the pins that are directly connected to this pins: either at the ends of connected wires, or via switches.

Definition at line 40 of file pin.cpp.

Referenced by CircuitDocument::getPartition(), Circuit::recursivePinAdd(), and CircuitDocument::recursivePinAdd().

{
//    kdDebug() << k_funcinfo << "Input wires: "<<m_inputWireList.size()<<"   Output wires: " << m_outputWireList.size() << "   Switch connected: " << m_switchConnectedPins.size() << endl;
      
      PinList pins;
      
      WireList::const_iterator end = m_inputWireList.end();
      for ( WireList::const_iterator it = m_inputWireList.begin(); it != end; ++it )
      {
            if (*it)
                  pins << (*it)->startPin();
      }
      
      end = m_outputWireList.end();
      for ( WireList::const_iterator it = m_outputWireList.begin(); it != end; ++it )
      {
            if (*it)
                  pins << (*it)->endPin();
      }
      
      pins += m_switchConnectedPins;
      
      return pins;
}


Generated by  Doxygen 1.6.0   Back to index