Geant4 11.4.0
Toolkit for the simulation of the passage of particles through matter
Loading...
Searching...
No Matches
GIDI_suite.cc
Go to the documentation of this file.
1/*
2# <<BEGIN-copyright>>
3# Copyright 2019, Lawrence Livermore National Security, LLC.
4# This file is part of the gidiplus package (https://github.com/LLNL/gidiplus).
5# gidiplus is licensed under the MIT license (see https://opensource.org/licenses/MIT).
6# SPDX-License-Identifier: MIT
7# <<END-copyright>>
8*/
9
10#include "GIDI.hpp"
11#include <HAPI.hpp>
12
13namespace GIDI {
14
15/*! \class Suite
16 * This class is used to store a list (i.e., suite) of similar type **GNDS** nodes.
17*/
18
19/* *********************************************************************************************************//**
20 ***********************************************************************************************************/
21
22Suite::Suite( std::string const &a_keyName ) :
23 GUPI::Ancestry( "" ),
24 m_keyName( a_keyName ),
25 m_styles( nullptr ),
26 m_allowsLazyParsing( false ) {
27
28}
29
30/* *********************************************************************************************************//**
31 * @param a_moniker [in] The **GNDS** moniker for the Suite instance.
32 * @param a_keyName [in] The name of the key for elements of *this*.
33 ***********************************************************************************************************/
34
35Suite::Suite( std::string const &a_moniker, std::string const &a_keyName ) :
36 GUPI::Ancestry( a_moniker ),
37 m_keyName( a_keyName ),
38 m_styles( nullptr ),
39 m_allowsLazyParsing( false ) {
40
41}
42
43/* *********************************************************************************************************//**
44 * @param a_construction [in] Used to pass user options to the constructor.
45 * @param a_moniker [in] The **GNDS** moniker for the Suite instance.
46 * @param a_node [in] The HAPI::Node to be parsed and used to construct the Suite.
47 * @param a_keyName [in] The name of the key for referencing up child nodes.
48 * @param a_setupInfo [in] Information create my the Protare constructor to help in parsing.
49 * @param a_pops [in] The *external* PoPI::Database instance used to get particle indices and possibly other particle information.
50 * @param a_internalPoPs [in] The *internal* PoPI::Database instance used to get particle indices and possibly other particle information.
51 * This is the <**PoPs**> node under the <**reactionSuite**> node.
52 * @param a_parseSuite [in] This function to call to parse each sub-node.
53 * @param a_styles [in] The <**styles**> node under the <**reactionSuite**> node.
54 * @param a_allowsLazyParsing [in] Boolean stating if the suite allows lazy parsing.
55 ***********************************************************************************************************/
56
57Suite::Suite( Construction::Settings const &a_construction, std::string const &a_moniker, std::string const &a_keyName, HAPI::Node const &a_node,
58 SetupInfo &a_setupInfo, PoPI::Database const &a_pops, PoPI::Database const &a_internalPoPs, parseSuite a_parseSuite,
59 Styles::Suite const *a_styles, bool a_allowsLazyParsing ) :
60 GUPI::Ancestry( a_moniker ),
61 m_keyName( a_keyName ),
62 m_styles( a_styles ),
63 m_allowsLazyParsing( a_allowsLazyParsing ),
64 m_href( "" ) {
65
66 HAPI::Node const node = a_node.child( a_moniker.c_str( ) );
67 m_href = node.attribute_as_string( GIDI_hrefChars );
68
69 if( !node.empty( ) ) parse( a_construction, node, a_setupInfo, a_pops, a_internalPoPs, a_parseSuite, a_styles );
70}
71
72/* *********************************************************************************************************//**
73 ***********************************************************************************************************/
74
76
77 for( std::vector<Form *>::const_iterator iter = m_forms.begin( ); iter < m_forms.end( ); ++iter ) delete *iter;
78}
79
80/* *********************************************************************************************************//**
81 * This methods parses all the child nodes of *a_node*.
82 *
83 * @param a_construction [in] Used to pass user options to the constructor.
84 * @param a_node [in] The HAPI::Node to be parsed and used to construct the Product.
85 * @param a_setupInfo [in] Information create my the Protare constructor to help in parsing.
86 * @param a_pops [in] The *external* PoPI::Database instance used to get particle indices and possibly other particle information.
87 * @param a_internalPoPs [in] The *internal* PoPI::Database instance used to get particle indices and possibly other particle information.
88 * This is the <**PoPs**> node under the <**reactionSuite**> node.
89 * @param a_parseSuite [in] This function to call to parse each sub-node.
90 * @param a_styles [in] The <**styles**> node under the <**reactionSuite**> node.
91 ***********************************************************************************************************/
92
93void Suite::parse( Construction::Settings const &a_construction, HAPI::Node const &a_node, SetupInfo &a_setupInfo, PoPI::Database const &a_pops,
94 PoPI::Database const &a_internalPoPs, parseSuite a_parseSuite, GIDI::Styles::Suite const *a_styles ) {
95
96 for( HAPI::Node child = a_node.first_child( ); !child.empty( ); child.to_next_sibling( ) ) {
97 std::string name( child.name( ) );
98
99 Form *form = nullptr;
100
101 if( m_allowsLazyParsing && a_construction.lazyParsing( ) ) {
102 form = new LazyParsingHelperForm( a_construction, this, child, a_setupInfo, a_pops, a_internalPoPs, name, a_styles, a_parseSuite ); }
103 else {
104 form = a_parseSuite( a_construction, this, child, a_setupInfo, a_pops, a_internalPoPs, name, a_styles );
105 }
106 if( form != nullptr ) add( form );
107 }
108}
109
110/* *********************************************************************************************************//**
111 * Returns the index of the node in *this* that has keyValue *a_keyValue*.
112
113 * @return [in] The index of the node with keyValue *a_keyValue* in *this*.
114 ***********************************************************************************************************/
115
116std::size_t Suite::operator[]( std::string const &a_keyValue ) const {
117
118 auto iter = m_map.find( a_keyValue );
119 if( iter == m_map.end( ) ) {
120 throw Exception( "form '" + a_keyValue + "' not in suite " + toXLink( ) + "." );
121 }
122
123 return( iter->second );
124}
125
126/* *********************************************************************************************************//**
127 * Adds the node *a_form* to *this*.
128 *
129 * @param a_form [in] The form to add.
130 ***********************************************************************************************************/
131
132void Suite::add( Form *a_form ) {
133
134 std::size_t i1 = 0;
135
136 for( Suite::iterator iter = m_forms.begin( ); iter != m_forms.end( ); ++iter, ++i1 ) {
137 if( (*iter)->keyValue( ) == a_form->keyValue( ) ) {
138 m_forms[i1] = a_form;
139 a_form->setAncestor( this );
140 return;
141 }
142 }
143 m_map[a_form->keyValue( )] = m_forms.size( );
144 m_forms.push_back( a_form );
145 a_form->setAncestor( this );
146}
147
148/* *********************************************************************************************************//**
149 * Check to see if the form is a **LazyParsingHelperForm**, it so, parses the form, loads it before returning the requested form.
150 *
151 * @param a_index [in] The index of the child to return.
152 *
153 * @return The form at index *a_index*.
154 ***********************************************************************************************************/
155
157
158 Form *form = m_forms[a_index];
159
160 if( form->type( ) == FormType::lazyParsingHelperForm ) {
162 form = lazyParsingHelperForm->parse( );
163 if( form == nullptr ) { // Happens because several forms (e.g., CoulombPlusNuclearElastic) are not needed by transport codes and are not parsed.
164 form = lazyParsingHelperForm; }
165 else {
166 form->setAncestor( this );
167 m_forms[a_index] = form;
169 }
170 }
171
172 return( form );
173}
174
175/* *********************************************************************************************************//**
176 * Check to see if the form is a **LazyParsingHelperForm**, it so, parses the form, loads it before returning the requested form.
177 *
178 * @param a_index [in] The index of the child to return.
179 *
180 * @return The form at index *a_index*.
181 ***********************************************************************************************************/
182
183Form *Suite::checkLazyParsingHelperForm( std::size_t a_index ) const {
184
185 Form *form = m_forms[a_index];
186
187 if( form->type( ) == FormType::lazyParsingHelperForm ) {
189 form = lazyParsingHelperForm->parse( );
190 if( form != nullptr ) {
191 form->setAncestor( const_cast<Suite *>( this ) );
192 m_forms[a_index] = form;
194 }
195 }
196
197 return( form );
198}
199/* *********************************************************************************************************//**
200 * Check to see if the form is a **LazyParsingHelperForm**, it so, parses the form, loads it before returning the requested form.
201 *
202 * @param a_iter [in] Iterator to the **Form** to check.
203 *
204 * @return The iterator to the old or converted form.
205 ***********************************************************************************************************/
206
208
209 if( a_iter == end( ) ) return( a_iter );
210
211 std::size_t index = (*this)[(*a_iter)->keyValue()];
212 ++a_iter;
214
215 return( --a_iter );
216}
217
218/* *********************************************************************************************************//**
219 * Check to see if the form is a **LazyParsingHelperForm**, it so, parses the form, loads it before returning the requested form.
220 *
221 * @param a_iter [in] Iterator to the **Form** to check.
222 *
223 * @return The form at index *a_index*.
224 ***********************************************************************************************************/
225
227
228 if( a_iter == end( ) ) return( a_iter );
229
230 std::size_t index = (*this)[(*a_iter)->keyValue()];
231 a_iter++;
233
234 return( --a_iter );
235}
236
237/* *********************************************************************************************************//**
238 * Returns the iterator to the node with keyValue *a_keyValue*.
239 *
240 * @param a_keyValue [in] The keyValue of the node to find.
241 * @param a_convertLazyParsingHelperForm [in] If true and requested form is a LazyParsingHelperForm instance, that instance is replaced with the parsed form.
242 *
243 * @return The iterator to the node with keyValue *a_keyValue*.
244 ***********************************************************************************************************/
245
246Suite::iterator Suite::find( std::string const &a_keyValue, bool a_convertLazyParsingHelperForm ) {
247
248 for( Suite::iterator iter = m_forms.begin( ); iter != m_forms.end( ); ++iter ) {
249 if( (*iter)->keyValue( ) == a_keyValue ) {
250 if( a_convertLazyParsingHelperForm ) return( checkLazyParsingHelperFormIterator( iter ) );
251 return( iter );
252 }
253 }
254 return( m_forms.end( ) );
255}
256
257/* *********************************************************************************************************//**
258 * Returns the iterator to the node with keyValue *a_keyValue*.
259 *
260 * @param a_keyValue [in] The keyValue of the node to find.
261 * @param a_convertLazyParsingHelperForm [in] If true and requested form is a LazyParsingHelperForm instance, that instance is replaced with the parsed form.
262 *
263 * @return The iterator to the node with keyValue *a_keyValue*.
264 ***********************************************************************************************************/
265
266Suite::const_iterator Suite::find( std::string const &a_keyValue, bool a_convertLazyParsingHelperForm ) const {
267
268 for( Suite::const_iterator iter = m_forms.begin( ); iter != m_forms.end( ); ++iter ) {
269 if( (*iter)->keyValue( ) == a_keyValue ) {
270 if( a_convertLazyParsingHelperForm ) return( checkLazyParsingHelperFormIterator( iter ) );
271 return( iter );
272 }
273 }
274 return( m_forms.end( ) );
275}
276
277/* *********************************************************************************************************//**
278 * Returns a list of iterators to the nodes in *this* that have **GNDS** moniker *a_moniker*.
279 *
280 * @param a_moniker [in] The moniker to search for.
281 *
282 * @return List of iterators to the nodes in *this* that have moniker *a_moniker*.
283 ***********************************************************************************************************/
284
285std::vector<Suite::iterator> Suite::findAllOfMoniker( std::string const &a_moniker ) {
286
287 std::vector<Suite::iterator> iters;
288
289 for( Suite::iterator iter = m_forms.begin( ); iter != m_forms.end( ); ++iter ) {
290 if( (*iter)->moniker( ) == a_moniker ) iters.push_back( iter );
291 }
292
293 return( iters );
294}
295
296/* *********************************************************************************************************//**
297 * Returns a list of iterators to the nodes in *this* that have **GNDS** moniker *a_moniker*.
298 *
299 * @param a_moniker [in] The moniker to search for.
300 *
301 * @return List of iterators to the nodes in *this* that have moniker *a_moniker*.
302 ***********************************************************************************************************/
303
304std::vector<Suite::const_iterator> Suite::findAllOfMoniker( std::string const &a_moniker ) const {
305
306 std::vector<Suite::const_iterator> iters;
307
308 for( Suite::const_iterator iter = m_forms.begin( ); iter != m_forms.end( ); ++iter ) {
309 if( (*iter)->moniker( ) == a_moniker ) iters.push_back( iter );
310 }
311
312 return( iters );
313}
314
315/* *********************************************************************************************************//**
316 * This method finds the nearest form of instance Functions::XYs1d in *this* that is prior to the form with label *a_label*.
317 *
318 * @param a_label [in] The label of the form to start from when looking backwards.
319 * @param a_formType [in] The type of form to return.
320 *
321 * @return Pointer to an Functions::XYs1d instance of nullptr if one not found.
322 ***********************************************************************************************************/
323
324Form const *Suite::findInstanceOfTypeInLineage( std::string const &a_label, std::string const &a_moniker ) const {
325
326 Form const *form1 = nullptr;
327 auto formIter = m_forms.end( );
328
329 for( auto iter = m_forms.begin( ); iter != m_forms.end( ); ++iter ) {
330 if( (*iter)->label( ) == a_label ) break;
331 if( (*iter)->actualMoniker( ) == a_moniker ) formIter = iter;
332 }
333
334 if( formIter != m_forms.end( ) ) {
335 form1 = *checkLazyParsingHelperFormIterator( formIter );
336 }
337
338 return( form1 );
339}
340
341/* *********************************************************************************************************//**
342 * This method finds the nearest form of instance Functions::XYs1d in *this* that is prior to the form with label *a_label*.
343 *
344 * @param a_styles [in] The styles suite for the protare.
345 * @param a_label [in] The label of the form to start from when looking backwards.
346 * @param a_formType [in] The type of form to return.
347 *
348 * @return Pointer to an Functions::XYs1d instance of nullptr if one not found.
349 ***********************************************************************************************************/
350
351Form *Suite::findInstanceOfTypeInLineage( Styles::Suite const &a_styles, std::string const &a_label, std::string const &a_moniker ) {
352
353 auto stylesIter = a_styles.find( a_label );
354 if( stylesIter != a_styles.end( ) ) {
355 auto suiteIter = find( a_label );
356 if( suiteIter != end( ) ) {
357 if( (*suiteIter)->actualMoniker( ) == a_moniker ) return( *checkLazyParsingHelperFormIterator( suiteIter ) );
358 }
359 Styles::Base const *style = static_cast<Styles::Base const *>( *stylesIter );
360 return( findInstanceOfTypeInLineage( a_styles, style->getDerivedStyle( )->keyValue( ), a_moniker ) );
361 }
362
363 return( nullptr );
364}
365
366/* *********************************************************************************************************//**
367 * Only for internal use. Called by ProtareTNSL instance to zero the lower energy multi-group data covered by the ProtareSingle that
368 * contains the TNSL data covers the lower energy multi-group data.
369 *
370 * @param a_maximumTNSL_MultiGroupIndex [in] A map that contains labels for heated multi-group data and the last valid group boundary
371 * for the TNSL data for that boundary.
372 ***********************************************************************************************************/
373
374void Suite::modifiedMultiGroupElasticForTNSL( std::map<std::string,std::size_t> const &a_maximumTNSL_MultiGroupIndex ) {
375
376 for( auto iter = a_maximumTNSL_MultiGroupIndex.begin( ); iter != a_maximumTNSL_MultiGroupIndex.end( ); ++iter ) {
377 auto formIter = find( iter->first, true );
378
379 if( formIter == m_forms.end( ) ) continue;
380
381 if( (*formIter)->type( ) == FormType::gridded1d ) {
382 reinterpret_cast<Functions::Gridded1d *>( (*formIter) )->modifiedMultiGroupElasticForTNSL( iter->second ); }
383 else if( (*formIter)->type( ) == FormType::gridded3d ) {
384 reinterpret_cast<Functions::Gridded3d *>( (*formIter) )->modifiedMultiGroupElasticForTNSL( iter->second );
385 }
386 }
387}
388
389/* *********************************************************************************************************//**
390 * Used by GUPI::Ancestry to tranverse GNDS nodes. This method returns a pointer to a derived class' a_item member or nullptr if none exists.
391 *
392 * @param a_item [in] The name of the class member whose pointer is to be return.
393 * @return The pointer to the class member or nullptr if class does not have a member named a_item.
394 ***********************************************************************************************************/
395
396GUPI::Ancestry *Suite::findInAncestry3( std::string const &a_item ) {
397
398 std::size_t index( a_item.find( '=' ) ), lastQuote = a_item.size( ) - 2;
399
400 if( index == std::string::npos ) return( nullptr );
401 ++index;
402 if( index > lastQuote ) throw Exception( "Suite::findInAncestry3: invalide xlink" );
403 if( a_item[index] != '\'' ) throw Exception( "Suite::findInAncestry3: invalid xlink, missing '." );
404 ++index;
405 if( a_item[lastQuote] != '\'' ) throw Exception( "Suite::findInAncestry3: invalid xlink, missing endl '." );
406
407 std::string keyValue( a_item.substr( index, lastQuote - index ) );
408
409 return( get<GUPI::Ancestry>( keyValue ) );
410}
411
412/* *********************************************************************************************************//**
413 * Used by GUPI::Ancestry to tranverse GNDS nodes. This method returns a pointer to a derived class' a_item member or nullptr if none exists.
414 *
415 * @param a_item [in] The name of the class member whose pointer is to be return.
416 * @return The pointer to the class member or nullptr if class does not have a member named a_item.
417 ***********************************************************************************************************/
418
419GUPI::Ancestry const *Suite::findInAncestry3( std::string const &a_item ) const {
420
421 std::size_t index( a_item.find( '=' ) ), lastQuote = a_item.size( ) - 2;
422
423 if( index == std::string::npos ) return( nullptr );
424 ++index;
425 if( index > lastQuote ) throw Exception( "Suite::findInAncestry3: invalide xlink" );
426 if( a_item[index] != '\'' ) throw Exception( "Suite::findInAncestry3: invalid xlink, missing '." );
427 ++index;
428 if( a_item[lastQuote] != '\'' ) throw Exception( "Suite::findInAncestry3: invalid xlink, missing endl '." );
429
430 std::string keyValue( a_item.substr( index, lastQuote - index ) );
431
432 return( get<GUPI::Ancestry>( keyValue ) );
433}
434
435/* *********************************************************************************************************//**
436 * Fills the argument *a_writeInfo* with the XML lines that represent *this*. Recursively enters each sub-node.
437 *
438 * @param a_writeInfo [in/out] Instance containing incremental indentation and other information and stores the appended lines.
439 * @param a_indent [in] The amount to indent *this* node.
440 ***********************************************************************************************************/
441
442void Suite::toXMLList( GUPI::WriteInfo &a_writeInfo, std::string const &a_indent ) const {
443
444 std::string indent2 = a_writeInfo.incrementalIndent( a_indent );
445
446 if( size( ) == 0 ) return;
447
448 std::string XMLLine( a_indent + "<" + moniker( ) + ">" );
449 a_writeInfo.push_back( XMLLine );
450
451 for( Suite::const_iterator iter = m_forms.begin( ); iter != m_forms.end( ); ++iter ) (*iter)->toXMLList( a_writeInfo, indent2 );
452
453 a_writeInfo.addNodeEnder( moniker( ) );
454}
455
456/* *********************************************************************************************************//**
457 * Prints the list of node keyValues to std::cout.
458 *
459 * @param a_header [in] A string printed before the list of keyValues is printed.
460 ***********************************************************************************************************/
461
462void Suite::printFormLabels( std::string const &a_header ) const {
463
464 std::cout << a_header << ": size = " << size( ) << std::endl;
465
466 for( Suite::const_iterator iter = m_forms.begin( ); iter != m_forms.end( ); ++iter )
467 std::cout << " " << (*iter)->keyValue( ) << std::endl;
468}
469
470/*! \class Component
471 * This class is used to store a list (i.e., suite) of similar type **GNDS** form nodes.
472*/
473
474/* *********************************************************************************************************//**
475 * @param a_construction [in] Used to pass user options to the constructor.
476 * @param a_moniker [in] The **GNDS** moniker for the Suite instance.
477 * @param a_keyName [in] The key name for elements of *this*.
478 * @param a_node [in] The HAPI::Node to be parsed and used to construct the Product.
479 * @param a_setupInfo [in] Information create my the Protare constructor to help in parsing.
480 * @param a_pops [in] The *external* PoPI::Database instance used to get particle indices and possibly other particle information.
481 * @param a_internalPoPs [in] The *internal* PoPI::Database instance used to get particle indices and possibly other particle information.
482 * This is the <**PoPs**> node under the <**reactionSuite**> node.
483 * @param a_parseSuite [in] This function to call to parse each sub-node.
484 * @param a_styles [in] The <**styles**> node under the <**reactionSuite**> node.
485 ***********************************************************************************************************/
486
487Component::Component( Construction::Settings const &a_construction, std::string const &a_moniker, std::string const &a_keyName,
488 HAPI::Node const &a_node, SetupInfo &a_setupInfo, PoPI::Database const &a_pops, PoPI::Database const &a_internalPoPs,
489 parseSuite a_parseSuite, Styles::Suite const *a_styles ) :
490 Suite( a_construction, a_moniker, a_keyName, a_node, a_setupInfo, a_pops, a_internalPoPs, a_parseSuite, a_styles, true ) {
491
492}
493
494/* *********************************************************************************************************//**
495 * @param a_moniker [in] The **GNDS** moniker for the Suite instance.
496 * @param a_keyName [in] The key name for elements of *this*.
497 ***********************************************************************************************************/
498
499Component::Component( std::string const &a_moniker, std::string const &a_keyName ) :
500 Suite( a_moniker, a_keyName ) {
501
502}
503
504/*! \class LazyParsingHelperForm
505 * This class stores information about a GNDS node so that it can be parsed at a later time if needed.
506*/
507
508/* *********************************************************************************************************//**
509 * Constructor that stores information so the *a_node* can be parsed at a later time.
510 *
511 * @param a_construction [in] Used to pass user options for parsing.
512 * @param a_parent [in] The parent GIDI::Suite that the returned Form will be added to.
513 * @param a_node [in] The **HAPI::Node** to be parsed.
514 * @param a_setupInfo [in] Information create my the Protare constructor to help in parsing.
515 * @param a_pops [in] A PoPs Database instance used to get particle indices and possibly other particle information.
516 * @param a_internalPoPs [in] The *internal* PoPI::Database instance used to get particle indices and possibly other particle information.
517 * This is the <**PoPs**> node under the <**reactionSuite**> node.
518 * @param a_name [in] The moniker for the node to be parsed.
519 * @param a_styles [in] A pointer to the <**styles**> node.
520 * @param a_parser [in] The parser function for the suite the actual form will be inserted into.
521 ***********************************************************************************************************/
522
524 SetupInfo &a_setupInfo, PoPI::Database const &a_pops, PoPI::Database const &a_internalPoPs, std::string const &a_name,
525 Styles::Suite const *a_styles, parseSuite a_parser ) :
526 Form( a_node, a_setupInfo, FormType::lazyParsingHelperForm, a_parent ),
527 m_construction( a_construction ),
528 m_node( a_node ),
529 m_setupInfo( a_setupInfo ),
530 m_pops( &a_pops ),
531 m_internalPoPs( &a_internalPoPs ),
532 m_name( a_name ),
533 m_styles( a_styles ),
534 m_parser( a_parser ) {
535
536 m_construction.setLazyParsing( false );
537 m_setupInfo.m_protare->incrementNumberOfLazyParsingHelperForms( );
538}
539
540/* *********************************************************************************************************//**
541 * Constructor that stores information so the *a_node* can be parsed at a later time.
542 ***********************************************************************************************************/
543
545
546 Form *form = m_parser( m_construction, parent( ), m_node, m_setupInfo, *m_pops, *m_internalPoPs, m_name, m_styles );
547 m_setupInfo.m_protare->incrementNumberOfLazyParsingHelperFormsReplaced( );
548
549 return( form );
550}
551
552/* *********************************************************************************************************//**
553 ***********************************************************************************************************/
554
558
559}
#define GIDI_hrefChars
Definition GIDI.hpp:440
Component(Construction::Settings const &a_construction, std::string const &a_moniker, std::string const &a_keyName, HAPI::Node const &a_node, SetupInfo &a_setupInfo, PoPI::Database const &a_pops, PoPI::Database const &a_internalPoPs, parseSuite a_parseSuite, Styles::Suite const *a_styles)
std::string const & keyValue() const
Definition GIDI_form.cc:149
FormType type() const
Definition GIDI.hpp:667
Form(FormType a_type)
Definition GIDI_form.cc:25
Suite * parent() const
Definition GIDI.hpp:656
LazyParsingHelperForm(Construction::Settings const &a_construction, Suite *a_parent, HAPI::Node const &a_node, SetupInfo &a_setupInfo, PoPI::Database const &a_pops, PoPI::Database const &a_internalPoPs, std::string const &a_name, Styles::Suite const *a_styles, parseSuite a_parser)
void parse(Construction::Settings const &a_construction, HAPI::Node const &a_node, SetupInfo &a_setupInfo, PoPI::Database const &a_pops, PoPI::Database const &a_internalPoPs, parseSuite a_parseSuite, Styles::Suite const *a_styles)
Definition GIDI_suite.cc:93
std::vector< iterator > findAllOfMoniker(std::string const &a_moniker)
Form * checkLazyParsingHelperForm(std::size_t a_index)
iterator checkLazyParsingHelperFormIterator(iterator a_iter)
GUPI::Ancestry * findInAncestry3(std::string const &a_item)
Form const * findInstanceOfTypeInLineage(std::string const &_label, std::string const &a_moniker) const
void printFormLabels(std::string const &a_header) const
void toXMLList(GUPI::WriteInfo &a_writeInfo, std::string const &a_indent="") const
Suite(std::string const &a_keyName=GIDI_labelChars)
Definition GIDI_suite.cc:22
Forms::iterator iterator
Definition GIDI.hpp:2592
std::size_t operator[](std::string const &a_label) const
void add(Form *a_form)
T * get(std::size_t a_Index)
Definition GIDI.hpp:2642
iterator find(std::string const &a_label, bool a_convertLazyParsingHelperForm=false)
iterator end()
Definition GIDI.hpp:2596
std::size_t size() const
Definition GIDI.hpp:2591
Forms::const_iterator const_iterator
Definition GIDI.hpp:2593
void modifiedMultiGroupElasticForTNSL(std::map< std::string, std::size_t > const &a_maximumTNSL_MultiGroupIndex)
void setAncestor(Ancestry *a_ancestor)
Definition GUPI.hpp:106
std::string const & moniker() const
Definition GUPI.hpp:102
Ancestry(std::string const &a_moniker, std::string const &a_attribute="")
std::string toXLink() const
void push_back(std::string const &a_line)
Definition GUPI.hpp:53
void addNodeEnder(std::string const &a_moniker)
Definition GUPI.hpp:59
std::string incrementalIndent(std::string const &indent)
Definition GUPI.hpp:52
bool empty() const
Definition HAPI_Node.cc:150
std::string attribute_as_string(const char *a_name) const
Definition HAPI.hpp:179
Node first_child() const
Definition HAPI_Node.cc:82
Node child(const char *name) const
Definition HAPI_Node.cc:72
Definition GIDI.hpp:32
FormType
Definition GIDI.hpp:118
@ lazyParsingHelperForm
Definition GIDI.hpp:118
Form *(* parseSuite)(Construction::Settings const &a_construction, Suite *a_parent, HAPI::Node const &a_node, SetupInfo &a_setupInfo, PoPI::Database const &a_pop, PoPI::Database const &a_internalPoPs, std::string const &a_name, Styles::Suite const *a_styles)
Definition GIDI.hpp:86
Definition GUPI.hpp:20