KiCad PCB EDA Suite
PNS::FIXED_TAIL Class Reference

#include <pns_line_placer.h>

Classes

struct  FIX_POINT
 
struct  STAGE
 

Public Member Functions

 FIXED_TAIL (int aLineCount=1)
 
 ~FIXED_TAIL ()
 
void Clear ()
 
void AddStage (VECTOR2I aStart, int aLayer, bool placingVias, DIRECTION_45 direction, NODE *aNode)
 
bool PopStage (STAGE &aStage)
 
int StageCount () const
 

Private Attributes

std::vector< STAGEm_stages
 

Detailed Description

Definition at line 45 of file pns_line_placer.h.

Constructor & Destructor Documentation

◆ FIXED_TAIL()

PNS::FIXED_TAIL::FIXED_TAIL ( int  aLineCount = 1)

Definition at line 1443 of file pns_line_placer.cpp.

1444 {
1445 
1446 }

◆ ~FIXED_TAIL()

PNS::FIXED_TAIL::~FIXED_TAIL ( )

Definition at line 1448 of file pns_line_placer.cpp.

1449 {
1450 
1451 }

Member Function Documentation

◆ AddStage()

void PNS::FIXED_TAIL::AddStage ( VECTOR2I  aStart,
int  aLayer,
bool  placingVias,
DIRECTION_45  direction,
NODE aNode 
)

Definition at line 1458 of file pns_line_placer.cpp.

1459 {
1460  STAGE st;
1461  FIX_POINT pt;
1462 
1463  pt.p = aStart;
1464  pt.layer = aLayer;
1465  pt.direction = direction;
1466  pt.placingVias = placingVias;
1467 
1468  st.pts.push_back(pt);
1469  st.commit = aNode;
1470 
1471  m_stages.push_back( st );
1472 }
std::vector< STAGE > m_stages

References PNS::FIXED_TAIL::STAGE::commit, PNS::FIXED_TAIL::FIX_POINT::direction, PNS::FIXED_TAIL::FIX_POINT::layer, m_stages, PNS::FIXED_TAIL::FIX_POINT::p, PNS::FIXED_TAIL::FIX_POINT::placingVias, and PNS::FIXED_TAIL::STAGE::pts.

Referenced by PNS::LINE_PLACER::FixRoute(), and PNS::LINE_PLACER::Start().

◆ Clear()

void PNS::FIXED_TAIL::Clear ( )

Definition at line 1453 of file pns_line_placer.cpp.

1454 {
1455  m_stages.clear();
1456 }
std::vector< STAGE > m_stages

References m_stages.

Referenced by PNS::LINE_PLACER::Start().

◆ PopStage()

bool PNS::FIXED_TAIL::PopStage ( FIXED_TAIL::STAGE aStage)

Definition at line 1474 of file pns_line_placer.cpp.

1475 {
1476  if( !m_stages.size() )
1477  return false;
1478 
1479 
1480  aStage = m_stages.back();
1481 
1482  if( m_stages.size() > 1 )
1483  m_stages.pop_back();
1484 
1485  return true;
1486 }
std::vector< STAGE > m_stages

References m_stages.

Referenced by PNS::LINE_PLACER::UnfixRoute().

◆ StageCount()

int PNS::FIXED_TAIL::StageCount ( ) const

Definition at line 1489 of file pns_line_placer.cpp.

1490 {
1491  return m_stages.size();
1492 }
std::vector< STAGE > m_stages

References m_stages.

Referenced by PNS::LINE_PLACER::HasPlacedAnything().

Member Data Documentation

◆ m_stages

std::vector<STAGE> PNS::FIXED_TAIL::m_stages
private

Definition at line 70 of file pns_line_placer.h.

Referenced by AddStage(), Clear(), PopStage(), and StageCount().


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