KiCad PCB EDA Suite
EPAD Struct Reference

Eagle thru hol pad. More...

#include <eagle_parser.h>

Public Types

enum  {
  SQUARE, ROUND, OCTAGON, LONG,
  OFFSET
}
 

Public Member Functions

 EPAD (wxXmlNode *aPad)
 

Public Attributes

wxString name
 
ECOORD x
 
ECOORD y
 
ECOORD drill
 
opt_ecoord diameter
 
opt_int shape
 
opt_erot rot
 
opt_bool stop
 
opt_bool thermals
 
opt_bool first
 

Detailed Description

Eagle thru hol pad.

Definition at line 678 of file eagle_parser.h.

Member Enumeration Documentation

anonymous enum
Enumerator
SQUARE 
ROUND 
OCTAGON 
LONG 
OFFSET 

Definition at line 687 of file eagle_parser.h.

687  {
688  SQUARE,
689  ROUND,
690  OCTAGON,
691  LONG,
692  OFFSET,
693  };

Constructor & Destructor Documentation

EPAD::EPAD ( wxXmlNode *  aPad)

Definition at line 624 of file eagle_parser.cpp.

References LONG, name, OCTAGON, OFFSET, ROUND, and SQUARE.

625 {
626  /*
627  <!ELEMENT pad EMPTY>
628  <!ATTLIST pad
629  name %String; #REQUIRED
630  x %Coord; #REQUIRED
631  y %Coord; #REQUIRED
632  drill %Dimension; #REQUIRED
633  diameter %Dimension; "0"
634  shape %PadShape; "round"
635  rot %Rotation; "R0"
636  stop %Bool; "yes"
637  thermals %Bool; "yes"
638  first %Bool; "no"
639  >
640  */
641 
642  // #REQUIRED says DTD, throw exception if not found
643  name = parseRequiredAttribute<wxString>( aPad, "name" );
644  x = parseRequiredAttribute<ECOORD>( aPad, "x" );
645  y = parseRequiredAttribute<ECOORD>( aPad, "y" );
646  drill = parseRequiredAttribute<ECOORD>( aPad, "drill" );
647 
648  // Optional attributes
649  diameter = parseOptionalAttribute<ECOORD>( aPad, "diameter" );
650 
651  opt_wxString s = parseOptionalAttribute<wxString>( aPad, "shape" );
652 
653  // (square | round | octagon | long | offset)
654  if( s == "square" )
656  else if( s == "round" )
657  shape = EPAD::ROUND;
658  else if( s == "octagon" )
660  else if( s == "long" )
661  shape = EPAD::LONG;
662  else if( s == "offset" )
664 
665  rot = parseOptionalAttribute<EROT>( aPad, "rot" );
666  stop = parseOptionalAttribute<bool>( aPad, "stop" );
667  thermals = parseOptionalAttribute<bool>( aPad, "thermals" );
668  first = parseOptionalAttribute<bool>( aPad, "first" );
669 }
opt_bool stop
Definition: eagle_parser.h:696
opt_bool thermals
Definition: eagle_parser.h:697
opt_erot rot
Definition: eagle_parser.h:695
ECOORD x
Definition: eagle_parser.h:681
wxString name
Definition: eagle_parser.h:680
opt_ecoord diameter
Definition: eagle_parser.h:684
ECOORD y
Definition: eagle_parser.h:682
opt_bool first
Definition: eagle_parser.h:698
opt_int shape
Definition: eagle_parser.h:694
ECOORD drill
Definition: eagle_parser.h:683

Member Data Documentation

opt_ecoord EPAD::diameter

Definition at line 684 of file eagle_parser.h.

Referenced by EAGLE_PLUGIN::packagePad().

ECOORD EPAD::drill

Definition at line 683 of file eagle_parser.h.

Referenced by EAGLE_PLUGIN::packagePad().

opt_bool EPAD::first

Definition at line 698 of file eagle_parser.h.

wxString EPAD::name

Definition at line 680 of file eagle_parser.h.

Referenced by EAGLE_PLUGIN::packagePad().

opt_erot EPAD::rot

Definition at line 695 of file eagle_parser.h.

Referenced by EAGLE_PLUGIN::packagePad().

opt_int EPAD::shape

Definition at line 694 of file eagle_parser.h.

Referenced by EAGLE_PLUGIN::packagePad().

opt_bool EPAD::stop

Definition at line 696 of file eagle_parser.h.

opt_bool EPAD::thermals

Definition at line 697 of file eagle_parser.h.

ECOORD EPAD::x

Definition at line 681 of file eagle_parser.h.

Referenced by EAGLE_PLUGIN::packagePad().

ECOORD EPAD::y

Definition at line 682 of file eagle_parser.h.

Referenced by EAGLE_PLUGIN::packagePad().


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