KiCad PCB EDA Suite
CADSTAR_ARCHIVE_PARSER::VARIANT Struct Reference

< Nodename = "VARIANT" or "VMASTER" (master variant More...

#include <cadstar_archive_parser.h>

Inheritance diagram for CADSTAR_ARCHIVE_PARSER::VARIANT:
CADSTAR_ARCHIVE_PARSER::PARSER

Public Member Functions

void Parse (XNODE *aNode, PARSER_CONTEXT *aContext) override
 

Public Attributes

VARIANT_ID ID = wxEmptyString
 
VARIANT_ID ParentID = wxEmptyString
 if empty, then this one is the master More...
 
wxString Name = wxEmptyString
 
wxString Description = wxEmptyString
 

Detailed Description

< Nodename = "VARIANT" or "VMASTER" (master variant

Definition at line 249 of file cadstar_archive_parser.h.

Member Function Documentation

◆ Parse()

void CADSTAR_ARCHIVE_PARSER::VARIANT::Parse ( XNODE aNode,
PARSER_CONTEXT aContext 
)
overridevirtual

Implements CADSTAR_ARCHIVE_PARSER::PARSER.

Definition at line 135 of file cadstar_archive_parser.cpp.

136 {
137  wxASSERT( aNode->GetName() == wxT( "VMASTER" ) || aNode->GetName() == wxT( "VARIANT" ) );
138 
139  ID = GetXmlAttributeIDString( aNode, 0 );
140 
141  if( aNode->GetName() == wxT( "VMASTER" ) )
142  {
143  Name = GetXmlAttributeIDString( aNode, 1 );
144  Description = GetXmlAttributeIDString( aNode, 2 );
145  }
146  else
147  {
148  ParentID = GetXmlAttributeIDString( aNode, 1 );
149  Name = GetXmlAttributeIDString( aNode, 2 );
150  Description = GetXmlAttributeIDString( aNode, 3 );
151  }
152 }
VARIANT_ID ParentID
if empty, then this one is the master
static wxString GetXmlAttributeIDString(XNODE *aNode, unsigned int aID, bool aIsRequired=true)

References CADSTAR_ARCHIVE_PARSER::GetXmlAttributeIDString().

Referenced by CADSTAR_ARCHIVE_PARSER::VARIANT_HIERARCHY::Parse().

Member Data Documentation

◆ Description

wxString CADSTAR_ARCHIVE_PARSER::VARIANT::Description = wxEmptyString

◆ ID

VARIANT_ID CADSTAR_ARCHIVE_PARSER::VARIANT::ID = wxEmptyString

◆ Name

wxString CADSTAR_ARCHIVE_PARSER::VARIANT::Name = wxEmptyString

◆ ParentID

VARIANT_ID CADSTAR_ARCHIVE_PARSER::VARIANT::ParentID = wxEmptyString

if empty, then this one is the master

Definition at line 252 of file cadstar_archive_parser.h.


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