\doxysection{Connection.\+hpp}
\hypertarget{Connection_8hpp_source}{}\label{Connection_8hpp_source}\index{/home/chr/devel/PhD/Environment/pub/PCBEnv/pcbenv/cxx/Connection.hpp@{/home/chr/devel/PhD/Environment/pub/PCBEnv/pcbenv/cxx/Connection.hpp}}

\begin{DoxyCode}{0}
\DoxyCodeLine{00001\ \textcolor{preprocessor}{\#ifndef\ GYM\_PCB\_CONNECTION\_H}}
\DoxyCodeLine{00002\ \textcolor{preprocessor}{\#define\ GYM\_PCB\_CONNECTION\_H}}
\DoxyCodeLine{00003\ }
\DoxyCodeLine{00004\ \textcolor{preprocessor}{\#include\ "{}Py.hpp"{}}}
\DoxyCodeLine{00005\ \textcolor{preprocessor}{\#include\ "{}Defs.hpp"{}}}
\DoxyCodeLine{00006\ \textcolor{preprocessor}{\#include\ "{}Color.hpp"{}}}
\DoxyCodeLine{00007\ \textcolor{preprocessor}{\#include\ "{}Pin.hpp"{}}}
\DoxyCodeLine{00008\ }
\DoxyCodeLine{00009\ \textcolor{keyword}{class\ }\mbox{\hyperlink{classCloneEnv}{CloneEnv}};}
\DoxyCodeLine{00010\ \textcolor{keyword}{class\ }\mbox{\hyperlink{classComponent}{Component}};}
\DoxyCodeLine{00011\ \textcolor{keyword}{class\ }\mbox{\hyperlink{classNet}{Net}};}
\DoxyCodeLine{00012\ \textcolor{keyword}{class\ }\mbox{\hyperlink{classTrack}{Track}};}
\DoxyCodeLine{00013\ \textcolor{keyword}{class\ }\mbox{\hyperlink{classUniformGrid25}{UniformGrid25}};}
\DoxyCodeLine{00014\ \textcolor{keyword}{class\ }\mbox{\hyperlink{classNavGrid}{NavGrid}};}
\DoxyCodeLine{00015\ }
\DoxyCodeLine{00016\ \textcolor{keyword}{class\ }Connection}
\DoxyCodeLine{00017\ \{}
\DoxyCodeLine{00018\ \ \ \ \ \textcolor{keyword}{constexpr}\ \textcolor{keyword}{static}\ \textcolor{keyword}{const}\ \textcolor{keywordtype}{bool}\ EndpointsOnMaskedLayersOK\ =\ \textcolor{keyword}{true};}
\DoxyCodeLine{00019\ \textcolor{keyword}{public}:}
\DoxyCodeLine{00020\ \ \ \ \ Connection\ *clone(\mbox{\hyperlink{classCloneEnv}{CloneEnv}}\&)\ \textcolor{keyword}{const};}
\DoxyCodeLine{00021\ \ \ \ \ Connection(\mbox{\hyperlink{classNet}{Net}}\ *,\ \textcolor{keyword}{const}\ \mbox{\hyperlink{classPoint__25}{Point\_25}}\ \&source,\ \mbox{\hyperlink{classPin}{Pin}}\ *sourcePin,\ \textcolor{keyword}{const}\ \mbox{\hyperlink{classPoint__25}{Point\_25}}\ \&target,\ \mbox{\hyperlink{classPin}{Pin}}\ *targetPin);}
\DoxyCodeLine{00022\ \ \ \ \ Connection(\textcolor{keyword}{const}\ Connection\&,\ \textcolor{keyword}{const}\ \mbox{\hyperlink{classPoint__25}{Point\_25}}\ \&source,\ \textcolor{keyword}{const}\ \mbox{\hyperlink{classPoint__25}{Point\_25}}\ \&target);}
\DoxyCodeLine{00023\ \ \ \ \ \string~Connection();}
\DoxyCodeLine{00024\ }
\DoxyCodeLine{00025\ \ \ \ \ \textcolor{keywordtype}{void}\ setId(\textcolor{keywordtype}{int}\ \textcolor{keywordtype}{id})\ \{\ mId\ =\ id;\ \}}
\DoxyCodeLine{00026\ \ \ \ \ \textcolor{keywordtype}{int}\ id()\textcolor{keyword}{\ const\ }\{\ \textcolor{keywordflow}{return}\ mId;\ \}}
\DoxyCodeLine{00027\ \ \ \ \ std::string\ name()\ \textcolor{keyword}{const};}
\DoxyCodeLine{00028\ \ \ \ \ \textcolor{keywordtype}{bool}\ hasNet()\textcolor{keyword}{\ const\ }\{\ \textcolor{keywordflow}{return}\ !!mNet;\ \}}
\DoxyCodeLine{00029\ \ \ \ \ \mbox{\hyperlink{classNet}{Net}}\ *net()\textcolor{keyword}{\ const\ }\{\ \textcolor{keywordflow}{return}\ mNet;\ \}}
\DoxyCodeLine{00030\ }
\DoxyCodeLine{00031\ \ \ \ \ \textcolor{keyword}{const}\ \mbox{\hyperlink{classPoint__25}{Point\_25}}\&\ source()\textcolor{keyword}{\ const\ }\{\ \textcolor{keywordflow}{return}\ mSource;\ \}}
\DoxyCodeLine{00032\ \ \ \ \ \textcolor{keyword}{const}\ \mbox{\hyperlink{classPoint__25}{Point\_25}}\&\ target()\textcolor{keyword}{\ const\ }\{\ \textcolor{keywordflow}{return}\ mTarget;\ \}}
\DoxyCodeLine{00033\ \ \ \ \ \mbox{\hyperlink{classPin}{Pin}}\ *sourcePin()\textcolor{keyword}{\ const\ }\{\ \textcolor{keywordflow}{return}\ mSourcePin;\ \}}
\DoxyCodeLine{00034\ \ \ \ \ \mbox{\hyperlink{classPin}{Pin}}\ *targetPin()\textcolor{keyword}{\ const\ }\{\ \textcolor{keywordflow}{return}\ mTargetPin;\ \}}
\DoxyCodeLine{00035\ \ \ \ \ \mbox{\hyperlink{classPin}{Pin}}\ *otherPin(\textcolor{keyword}{const}\ \mbox{\hyperlink{classPin}{Pin}}\ *)\ \textcolor{keyword}{const};}
\DoxyCodeLine{00036\ }
\DoxyCodeLine{00037\ \ \ \ \ \mbox{\hyperlink{classComponent}{Component}}\ *sourceComponent()\textcolor{keyword}{\ const\ }\{\ \textcolor{keywordflow}{return}\ mSourcePin\ ?\ mSourcePin-\/>getParent()\ :\ 0;\ \}}
\DoxyCodeLine{00038\ \ \ \ \ \mbox{\hyperlink{classComponent}{Component}}\ *targetComponent()\textcolor{keyword}{\ const\ }\{\ \textcolor{keywordflow}{return}\ mTargetPin\ ?\ mTargetPin-\/>getParent()\ :\ 0;\ \}}
\DoxyCodeLine{00039\ }
\DoxyCodeLine{00040\ \ \ \ \ Vector\_2\ vector2()\textcolor{keyword}{\ const\ }\{\ \textcolor{keywordflow}{return}\ target().xy()\ -\/\ source().xy();\ \}}
\DoxyCodeLine{00041\ \ \ \ \ Segment\_2\ segment2()\textcolor{keyword}{\ const\ }\{\ \textcolor{keywordflow}{return}\ Segment\_2(source().xy(),\ target().xy());\ \}}
\DoxyCodeLine{00042\ }
\DoxyCodeLine{00043\ \ \ \ \ \textcolor{keywordtype}{void}\ detachSourcePin();}
\DoxyCodeLine{00044\ \ \ \ \ \textcolor{keywordtype}{void}\ detachTargetPin();}
\DoxyCodeLine{00045\ }
\DoxyCodeLine{00046\ \ \ \ \ \textcolor{keywordtype}{void}\ forceEndpointsToGrid(\textcolor{keyword}{const}\ \mbox{\hyperlink{classUniformGrid25}{UniformGrid25}}\&);}
\DoxyCodeLine{00047\ }
\DoxyCodeLine{00048\ \ \ \ \ \textcolor{keywordtype}{bool}\ hasTracks()\textcolor{keyword}{\ const\ }\{\ \textcolor{keywordflow}{return}\ !mTracks.empty();\ \}}
\DoxyCodeLine{00049\ \ \ \ \ uint\ numTracks()\textcolor{keyword}{\ const\ }\{\ \textcolor{keywordflow}{return}\ mTracks.size();\ \}}
\DoxyCodeLine{00050\ \ \ \ \ \textcolor{keyword}{const}\ std::vector<Track\ *>\&\ getTracks()\textcolor{keyword}{\ const\ }\{\ \textcolor{keywordflow}{return}\ mTracks;\ \}}
\DoxyCodeLine{00051\ \ \ \ \ \mbox{\hyperlink{classTrack}{Track}}\&\ getTrack(uint\ i)\textcolor{keyword}{\ const\ }\{\ \textcolor{keywordflow}{return}\ *mTracks.at(i);\ \}}
\DoxyCodeLine{00052\ \ \ \ \ \mbox{\hyperlink{classTrack}{Track}}\ *getTrackAt(\textcolor{keyword}{const}\ \mbox{\hyperlink{classPoint__25}{Point\_25}}\&)\ \textcolor{keyword}{const};}
\DoxyCodeLine{00053\ \ \ \ \ \mbox{\hyperlink{classTrack}{Track}}\ *newTrack(\textcolor{keyword}{const}\ \mbox{\hyperlink{classPoint__25}{Point\_25}}\ \&start);}
\DoxyCodeLine{00054\ \ \ \ \ \mbox{\hyperlink{classTrack}{Track}}\ *popTrack(uint\ index);}
\DoxyCodeLine{00055\ \ \ \ \ \textcolor{keywordtype}{void}\ clearTracks();}
\DoxyCodeLine{00056\ }
\DoxyCodeLine{00057\ \ \ \ \ \textcolor{keywordtype}{bool}\ isRouted()\textcolor{keyword}{\ const\ }\{\ \textcolor{keywordflow}{return}\ mIsRouted;\ \}}
\DoxyCodeLine{00058\ \ \ \ \ \textcolor{keywordtype}{bool}\ \_isRouted()\ \textcolor{keyword}{const};}
\DoxyCodeLine{00059\ \ \ \ \ \textcolor{keywordtype}{void}\ setRouted(\textcolor{keywordtype}{bool}\ b)\ \{\ mIsRouted\ =\ b;\ \}}
\DoxyCodeLine{00060\ \ \ \ \ \textcolor{keywordtype}{bool}\ checkRouted()\ \{\ setRouted(\_isRouted());\ \textcolor{keywordflow}{return}\ isRouted();\ \}}
\DoxyCodeLine{00061\ }
\DoxyCodeLine{00065\ \ \ \ \ \textcolor{keywordtype}{void}\ \mbox{\hyperlink{classConnection_a9a9a6074a3742bee55f86b7d180028d1}{forceRouted}}();}
\DoxyCodeLine{00066\ }
\DoxyCodeLine{00067\ \ \ \ \ \textcolor{keywordtype}{bool}\ isLocked()\textcolor{keyword}{\ const\ }\{\ \textcolor{keywordflow}{return}\ mLocked;\ \}}
\DoxyCodeLine{00068\ \ \ \ \ \textcolor{keywordtype}{void}\ setLocked(\textcolor{keywordtype}{bool}\ b)\ \{\ mLocked\ =\ b;\ \}}
\DoxyCodeLine{00069\ }
\DoxyCodeLine{00074\ \ \ \ \ \textcolor{keywordtype}{void}\ \mbox{\hyperlink{classConnection_a445528dee6edfbb5019c53cf03e1599f}{setTrack}}(\mbox{\hyperlink{classTrack}{Track}}\ *);}
\DoxyCodeLine{00075\ \ \ \ \ \textcolor{keywordtype}{void}\ \mbox{\hyperlink{classConnection_a445528dee6edfbb5019c53cf03e1599f}{setTrack}}(\mbox{\hyperlink{classTrack}{Track}}\&\&);}
\DoxyCodeLine{00076\ \ \ \ \ \textcolor{keywordtype}{void}\ \mbox{\hyperlink{classConnection_a445528dee6edfbb5019c53cf03e1599f}{setTrack}}(\textcolor{keyword}{const}\ \mbox{\hyperlink{classTrack}{Track}}\&);}
\DoxyCodeLine{00077\ }
\DoxyCodeLine{00082\ \ \ \ \ \textcolor{keywordtype}{void}\ \mbox{\hyperlink{classConnection_a0f9308f5e1c63e6dfb0e78e0b6d7cb5f}{appendTrack}}(\mbox{\hyperlink{classTrack}{Track}}\ *T);}
\DoxyCodeLine{00083\ \ \ \ \ \textcolor{keywordtype}{void}\ \mbox{\hyperlink{classConnection_a0f9308f5e1c63e6dfb0e78e0b6d7cb5f}{appendTrack}}(\textcolor{keyword}{const}\ \mbox{\hyperlink{classTrack}{Track}}\ \&T);}
\DoxyCodeLine{00084\ }
\DoxyCodeLine{00085\ \ \ \ \ \textcolor{keywordtype}{void}\ \mbox{\hyperlink{classConnection_aa18a1c0fb523565fd295d326c754cef6}{reverse}}();\ }
\DoxyCodeLine{00086\ }
\DoxyCodeLine{00094\ \ \ \ \ \textcolor{keywordtype}{void}\ \mbox{\hyperlink{classConnection_a910d28dd0e7645f4ffa2f26e32c32808}{makeDirectTrack45}}(Real\ minSquaredLen,\ uint\ viaLocation,\ \textcolor{keywordtype}{float}\ bendLocation);}
\DoxyCodeLine{00095\ \ \ \ \ \textcolor{keywordtype}{void}\ makeDirectTrack(Real\ minSquaredLen,\ uint\ viaLocation);}
\DoxyCodeLine{00096\ }
\DoxyCodeLine{00103\ \ \ \ \ \textcolor{keywordtype}{bool}\ \mbox{\hyperlink{classConnection_aff35eb50408d3ff4904a84478636ab42}{updateForRemovedLayers}}(uint\ removedZMin,\ uint\ removedZMax);}
\DoxyCodeLine{00104\ }
\DoxyCodeLine{00109\ \ \ \ \ std::vector<std::pair<Point\_25,\ Point\_25>>\ \mbox{\hyperlink{classConnection_a296a66b2a8e2a3818c84bbc1d22d24b9}{getRatsNest}}()\ \textcolor{keyword}{const};}
\DoxyCodeLine{00110\ }
\DoxyCodeLine{00111\ \ \ \ \ \textcolor{keywordtype}{bool}\ \mbox{\hyperlink{classConnection_a53f8bd5123d473f8b8bbddeb5f2f8a16}{arePinsOnNet}}(\textcolor{keyword}{const}\ \mbox{\hyperlink{classNet}{Net}}\ *)\ \textcolor{keyword}{const};\ }
\DoxyCodeLine{00112\ }
\DoxyCodeLine{00113\ \ \ \ \ Real\ clearance()\textcolor{keyword}{\ const\ }\{\ \textcolor{keywordflow}{return}\ mClearance;\ \}}
\DoxyCodeLine{00114\ \ \ \ \ Real\ defaultWidth()\textcolor{keyword}{\ const\ }\{\ \textcolor{keywordflow}{return}\ mWidth;\ \}}
\DoxyCodeLine{00115\ \ \ \ \ Real\ defaultViaDiameter()\textcolor{keyword}{\ const\ }\{\ \textcolor{keywordflow}{return}\ mViaDiameter;\ \}}
\DoxyCodeLine{00116\ \ \ \ \ Real\ defaultViaRadius()\textcolor{keyword}{\ const\ }\{\ \textcolor{keywordflow}{return}\ mViaDiameter\ *\ 0.5;\ \}}
\DoxyCodeLine{00117\ }
\DoxyCodeLine{00118\ \ \ \ \ \textcolor{keywordtype}{void}\ setClearance(Real\ c)\ \{\ mClearance\ =\ c;\ \}}
\DoxyCodeLine{00119\ \ \ \ \ \textcolor{keywordtype}{void}\ setDefaultWidth(\textcolor{keywordtype}{float}\ w)\ \{\ mWidth\ =\ w;\ \}}
\DoxyCodeLine{00120\ \ \ \ \ \textcolor{keywordtype}{void}\ setDefaultViaDiameter(Real\ d)\ \{\ mViaDiameter\ =\ d;\ \}}
\DoxyCodeLine{00121\ }
\DoxyCodeLine{00122\ \ \ \ \ \textcolor{keywordtype}{bool}\ canRouteOnLayer(uint\ n)\textcolor{keyword}{\ const\ }\{\ \textcolor{keywordflow}{return}\ mLayerMask\ \&\ (1\ <<\ n);\ \}}
\DoxyCodeLine{00123\ \ \ \ \ uint32\_t\ getLayerMask()\textcolor{keyword}{\ const\ }\{\ \textcolor{keywordflow}{return}\ mLayerMask;\ \}}
\DoxyCodeLine{00124\ }
\DoxyCodeLine{00125\ \ \ \ \ \textcolor{keywordtype}{void}\ setLayerMask(uint32\_t);}
\DoxyCodeLine{00126\ }
\DoxyCodeLine{00127\ \ \ \ \ \textcolor{keywordtype}{void}\ setParametersFrom(\textcolor{keyword}{const}\ Connection\&);}
\DoxyCodeLine{00128\ }
\DoxyCodeLine{00129\ \ \ \ \ \textcolor{keywordtype}{float}\ referenceLen()\textcolor{keyword}{\ const\ }\{\ \textcolor{keywordflow}{return}\ mReferenceLen;\ \}}
\DoxyCodeLine{00130\ \ \ \ \ \textcolor{keywordtype}{void}\ setReferenceLen(\textcolor{keywordtype}{float}\ v)\ \{\ assert(mReferenceLen\ ==\ 0.0f\ \&\&\ v\ >\ 0.0f);\ mReferenceLen\ =\ v;\ \}}
\DoxyCodeLine{00131\ }
\DoxyCodeLine{00132\ \ \ \ \ Bbox\_2\ tracksBbox()\ \textcolor{keyword}{const};}
\DoxyCodeLine{00133\ \ \ \ \ Bbox\_2\ bbox()\ \textcolor{keyword}{const};}
\DoxyCodeLine{00134\ \ \ \ \ Bbox\_2\ bboxAroundComps()\ \textcolor{keyword}{const};}
\DoxyCodeLine{00135\ }
\DoxyCodeLine{00136\ \ \ \ \ Real\ squared\_distance()\textcolor{keyword}{\ const\ }\{\ \textcolor{keywordflow}{return}\ CGAL::squared\_distance(mSource.xy(),\ mTarget.xy());\ \}}
\DoxyCodeLine{00137\ \ \ \ \ Real\ distance()\textcolor{keyword}{\ const\ }\{\ \textcolor{keywordflow}{return}\ std::sqrt(squared\_distance());\ \}}
\DoxyCodeLine{00138\ \ \ \ \ Real\ distance45()\textcolor{keyword}{\ const\ }\{\ \textcolor{keywordflow}{return}\ geo::distance45(mSource.xy(),\ mTarget.xy());\ \}}
\DoxyCodeLine{00139\ }
\DoxyCodeLine{00140\ \ \ \ \ \textcolor{keywordtype}{bool}\ \mbox{\hyperlink{classConnection_a8f68f01c92e6fec71500c7e13199c853}{isOrderedXMajor}}()\ \textcolor{keyword}{const};\ }
\DoxyCodeLine{00141\ }
\DoxyCodeLine{00142\ \ \ \ \ uint\ \mbox{\hyperlink{classConnection_a4a6970d8fbacbf56166eed5028726c62}{numNecessaryVias}}()\ \textcolor{keyword}{const};\ }
\DoxyCodeLine{00143\ }
\DoxyCodeLine{00144\ \ \ \ \ \textcolor{keyword}{template}<\textcolor{keyword}{class}\ Container>\ \textcolor{keyword}{static}\ \textcolor{keywordtype}{void}\ sort\_name(Container\&);}
\DoxyCodeLine{00145\ }
\DoxyCodeLine{00150\ \ \ \ \ \textcolor{keywordtype}{bool}\ \mbox{\hyperlink{classConnection_a95667648eeb64b1ff644a53da3d6c138}{intersects}}(\textcolor{keyword}{const}\ Connection\&)\ \textcolor{keyword}{const};}
\DoxyCodeLine{00151\ }
\DoxyCodeLine{00156\ \ \ \ \ \textcolor{keywordtype}{bool}\ \mbox{\hyperlink{classConnection_ae18ebec14ba0b4361780a2218ddbe359}{isRasterized\_allOrNone}}()\ \textcolor{keyword}{const};}
\DoxyCodeLine{00157\ }
\DoxyCodeLine{00161\ \ \ \ \ \textcolor{keywordtype}{bool}\ \mbox{\hyperlink{classConnection_ad7822648a263f19262cfb75c50e2920b}{checkRasterization}}(\textcolor{keyword}{const}\ \mbox{\hyperlink{classNavGrid}{NavGrid}}\&)\ \textcolor{keyword}{const};}
\DoxyCodeLine{00162\ }
\DoxyCodeLine{00163\ \ \ \ \ \textcolor{keywordtype}{void}\ \mbox{\hyperlink{classConnection_ab0cd0645d73c9e90e4a9f8981681b801}{setColor}}(\mbox{\hyperlink{classColor}{Color}}\ c)\ \{\ mColor\ =\ c;\ \}\ }
\DoxyCodeLine{00164\ \ \ \ \ \mbox{\hyperlink{classColor}{Color}}\ getColor()\ \textcolor{keyword}{const};}
\DoxyCodeLine{00165\ }
\DoxyCodeLine{00166\ \ \ \ \ std::string\ str()\ \textcolor{keyword}{const};}
\DoxyCodeLine{00167\ }
\DoxyCodeLine{00171\ \ \ \ \ PyObject\ *\mbox{\hyperlink{classConnection_a13eacaf0ce967aa7208cdcfe3b2fec8b}{getEndsPy}}()\ \textcolor{keyword}{const};}
\DoxyCodeLine{00175\ \ \ \ \ PyObject\ *\mbox{\hyperlink{classConnection_a4674636afbe95d07f73b6ef4a95206fb}{getTracksPy}}(\textcolor{keywordtype}{bool}\ asNumpy)\ \textcolor{keyword}{const};}
\DoxyCodeLine{00176\ \ \ \ \ PyObject\ *\mbox{\hyperlink{classConnection_a7b8f39f926b452d263c681ca9536e87d}{getPy}}(uint\ depth,\ \textcolor{keywordtype}{bool}\ asNumpy)\ \textcolor{keyword}{const};\ }
\DoxyCodeLine{00177\ \textcolor{keyword}{private}:}
\DoxyCodeLine{00178\ \ \ \ \ \mbox{\hyperlink{classPoint__25}{Point\_25}}\ mSource;}
\DoxyCodeLine{00179\ \ \ \ \ \mbox{\hyperlink{classPoint__25}{Point\_25}}\ mTarget;}
\DoxyCodeLine{00180\ \ \ \ \ \mbox{\hyperlink{classPin}{Pin}}\ *mSourcePin;}
\DoxyCodeLine{00181\ \ \ \ \ \mbox{\hyperlink{classPin}{Pin}}\ *mTargetPin;}
\DoxyCodeLine{00182\ \ \ \ \ \mbox{\hyperlink{classNet}{Net}}\ *\textcolor{keyword}{const}\ mNet;}
\DoxyCodeLine{00183\ \ \ \ \ std::vector<Track\ *>\ mTracks;}
\DoxyCodeLine{00184\ \ \ \ \ Real\ mClearance;}
\DoxyCodeLine{00185\ \ \ \ \ Real\ mWidth;}
\DoxyCodeLine{00186\ \ \ \ \ Real\ mViaDiameter;}
\DoxyCodeLine{00187\ \ \ \ \ uint32\_t\ mLayerMask\{0xffffffff\};}
\DoxyCodeLine{00188\ \ \ \ \ \textcolor{keywordtype}{int}\ mId\{-\/1\};}
\DoxyCodeLine{00189\ \ \ \ \ \textcolor{keywordtype}{bool}\ mIsRouted\{\textcolor{keyword}{false}\};}
\DoxyCodeLine{00190\ \ \ \ \ \textcolor{keywordtype}{bool}\ mLocked\{\textcolor{keyword}{false}\};}
\DoxyCodeLine{00191\ \ \ \ \ \textcolor{keywordtype}{float}\ mReferenceLen\{0.0f\};}
\DoxyCodeLine{00192\ \ \ \ \ Color\ mColor\{Color::TRANSPARENT\};}
\DoxyCodeLine{00193\ }
\DoxyCodeLine{00194\ \textcolor{keyword}{private}:}
\DoxyCodeLine{00195\ \ \ \ \ \textcolor{keywordtype}{void}\ mergeTrack(Track\ *);}
\DoxyCodeLine{00196\ \ \ \ \ \textcolor{keywordtype}{void}\ deleteEmptyTracks();}
\DoxyCodeLine{00197\ \ \ \ \ \textcolor{keywordtype}{void}\ updateEndpointForLayerMask(\textcolor{keywordtype}{bool}\ target);}
\DoxyCodeLine{00198\ \};}
\DoxyCodeLine{00199\ }
\DoxyCodeLine{00200\ \textcolor{keyword}{inline}\ \textcolor{keywordtype}{void}\ Connection::setParametersFrom(\textcolor{keyword}{const}\ \mbox{\hyperlink{classConnection}{Connection}}\ \&X)}
\DoxyCodeLine{00201\ \{}
\DoxyCodeLine{00202\ \ \ \ \ setClearance(X.clearance());}
\DoxyCodeLine{00203\ \ \ \ \ setDefaultWidth(X.defaultWidth());}
\DoxyCodeLine{00204\ \ \ \ \ setDefaultViaDiameter(X.defaultViaDiameter());}
\DoxyCodeLine{00205\ \ \ \ \ setLayerMask(X.getLayerMask());}
\DoxyCodeLine{00206\ \}}
\DoxyCodeLine{00207\ \textcolor{keyword}{inline}\ \mbox{\hyperlink{classPin}{Pin}}\ *Connection::otherPin(\textcolor{keyword}{const}\ \mbox{\hyperlink{classPin}{Pin}}\ *P)\textcolor{keyword}{\ const}}
\DoxyCodeLine{00208\ \textcolor{keyword}{}\{}
\DoxyCodeLine{00209\ \ \ \ \ assert(mSourcePin\ ==\ P\ ||\ mTargetPin\ ==\ P);}
\DoxyCodeLine{00210\ \ \ \ \ \textcolor{keywordflow}{return}\ (mSourcePin\ ==\ P)\ ?\ mTargetPin\ :\ mSourcePin;}
\DoxyCodeLine{00211\ \}}
\DoxyCodeLine{00212\ }
\DoxyCodeLine{00213\ \textcolor{keyword}{inline}\ \mbox{\hyperlink{classTrack}{Track}}\ *Connection::popTrack(uint\ index)}
\DoxyCodeLine{00214\ \{}
\DoxyCodeLine{00215\ \ \ \ \ setRouted(\textcolor{keyword}{false});}
\DoxyCodeLine{00216\ \ \ \ \ \textcolor{keyword}{const}\ \textcolor{keyword}{auto}\ T\ =\ mTracks.at(index);}
\DoxyCodeLine{00217\ \ \ \ \ mTracks.erase(mTracks.begin()\ +\ index);}
\DoxyCodeLine{00218\ \ \ \ \ \textcolor{keywordflow}{return}\ T;}
\DoxyCodeLine{00219\ \}}
\DoxyCodeLine{00220\ }
\DoxyCodeLine{00221\ \textcolor{keyword}{template}<\textcolor{keyword}{class}\ Container>\ \textcolor{keywordtype}{void}\ Connection::sort\_name(Container\ \&A)}
\DoxyCodeLine{00222\ \{}
\DoxyCodeLine{00223\ \ \ \ \ std::sort(A.begin(),}
\DoxyCodeLine{00224\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ A.end(),}
\DoxyCodeLine{00225\ \ \ \ \ \ \ \ \ \ \ \ \ \ \ [](\textcolor{keyword}{const}\ Connection\ *\textcolor{keyword}{const}\ L,\ \textcolor{keyword}{const}\ Connection\ *\textcolor{keyword}{const}\ R)\ -\/>\ \textcolor{keywordtype}{bool}\ \{\ return\ L-\/>name()\ <\ R-\/>name();\ \});}
\DoxyCodeLine{00226\ \}}
\DoxyCodeLine{00227\ }
\DoxyCodeLine{00228\ \textcolor{preprocessor}{\#endif\ }\textcolor{comment}{//\ GYM\_PCB\_CONNECTION\_H}}

\end{DoxyCode}
