21 |
*/ |
*/ |
22 |
#include "GEDCOMParser/Association.hh" |
#include "GEDCOMParser/Association.hh" |
23 |
#include "GEDCOMParser/Visitor/GEDCOMVisitor.hh" |
#include "GEDCOMParser/Visitor/GEDCOMVisitor.hh" |
24 |
|
#include "GEDCOMParser/GEDCOMFactory.hh" |
25 |
|
#include "GEDCOMParser/GEDCOMFactoryAccessor.hh" |
26 |
|
|
27 |
void GEDCOMParser::Association::addIndiXref(std::string const & value) |
void GEDCOMParser::Association::addIndiXref(std::string const & value) |
28 |
{ |
{ |
42 |
return; |
return; |
43 |
} |
} |
44 |
|
|
45 |
void GEDCOMParser::Association::addNoteStructure(GEDCOMParser::NoteStructure * const note) |
GEDCOMParser::NoteStructure * GEDCOMParser::Association::addNoteStructure(GEDCOMParser::NoteStructure * const data = 0) |
46 |
{ |
{ |
47 |
_notes.push_back(SmartPtr<NoteStructure>(note)); |
GEDCOMParser::NoteStructure * tmp_data = data; |
48 |
return; |
if (data == 0) |
49 |
|
{ |
50 |
|
GEDCOMParser::GEDCOMFactory * factory = GEDCOMParser::GEDCOMFactoryAccessor::getFactory(); |
51 |
|
GEDCOMParser::NoteStructure * tmp_data = factory->createNoteStructure(); |
52 |
|
} |
53 |
|
_notes.push_back(SmartPtr<NoteStructure>(tmp_data)); |
54 |
|
return _notes.back().getPtr(); |
55 |
} |
} |
56 |
|
|
57 |
void GEDCOMParser::Association::addSourceCitation(GEDCOMParser::SourceCitation * const citation) |
GEDCOMParser::SourceCitation * GEDCOMParser::Association::addSourceCitation(GEDCOMParser::SourceCitation * const data = 0) |
58 |
{ |
{ |
59 |
_citations.push_back(SmartPtr<SourceCitation>(citation)); |
GEDCOMParser::SourceCitation * tmp_data = data; |
60 |
return; |
if (data == 0) |
61 |
|
{ |
62 |
|
GEDCOMParser::GEDCOMFactory * factory = GEDCOMParser::GEDCOMFactoryAccessor::getFactory(); |
63 |
|
GEDCOMParser::SourceCitation * tmp_data = factory->createSourceCitation(); |
64 |
|
} |
65 |
|
_citations.push_back(SmartPtr<SourceCitation>(tmp_data)); |
66 |
|
return _citations.back().getPtr(); |
67 |
} |
} |
68 |
|
|
69 |
GEDCOMParser::IndiXrefs_t const &GEDCOMParser::Association::getIndiXrefs(void) const |
GEDCOMParser::IndiXrefs_t const &GEDCOMParser::Association::getIndiXrefs(void) const |