/[ghosts]/ghosts/gedcomparser/src/GEDCOMParser/Place.cpp
ViewVC logotype

Diff of /ghosts/gedcomparser/src/GEDCOMParser/Place.cpp

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.4 by cpcp, Mon Feb 17 21:19:22 2003 UTC revision 1.5 by cpcp, Thu Feb 20 22:09:15 2003 UTC
# Line 22  Line 22 
22  #include "Place.hh"  #include "Place.hh"
23  #include <iostream>  #include <iostream>
24  #include "GEDCOMParser/Visitor/GEDCOMVisitor.hh"  #include "GEDCOMParser/Visitor/GEDCOMVisitor.hh"
25    #include "GEDCOMParser/GEDCOMFactory.hh"
26    #include "GEDCOMParser/GEDCOMFactoryAccessor.hh"
27    
28  void GEDCOMParser::Place::setPlaceValue(std::string const & pvalue)  void GEDCOMParser::Place::setPlaceValue(std::string const & pvalue)
29  {  {
# Line 35  void GEDCOMParser::Place::setPlaceHierar Line 37  void GEDCOMParser::Place::setPlaceHierar
37    return;    return;
38  }  }
39    
40  void GEDCOMParser::Place::addSourceCitation(SourceCitation * const src_citation)  GEDCOMParser::SourceCitation * GEDCOMParser::Place::addSourceCitation(GEDCOMParser::SourceCitation * const data = 0)
41  {  {
42    _citations.push_back(SmartPtr<SourceCitation>(src_citation));    GEDCOMParser::SourceCitation  * tmp_data = data;
43    return;    if (data == 0)
44        {
45          GEDCOMParser::GEDCOMFactory * factory = GEDCOMParser::GEDCOMFactoryAccessor::getFactory();
46          GEDCOMParser::SourceCitation  * tmp_data = factory->createSourceCitation();
47        }
48      _citations.push_back(SmartPtr<SourceCitation>(tmp_data));
49      return _citations.back().getPtr();
50  }  }
51    
52  void GEDCOMParser::Place::addNoteStructure(NoteStructure * const note_structure)  GEDCOMParser::NoteStructure * GEDCOMParser::Place::addNoteStructure(GEDCOMParser::NoteStructure * const data = 0)
53  {  {
54    _notes.push_back(SmartPtr<NoteStructure>(note_structure));    GEDCOMParser::NoteStructure  * tmp_data = data;
55    return;    if (data == 0)
56        {
57          GEDCOMParser::GEDCOMFactory * factory = GEDCOMParser::GEDCOMFactoryAccessor::getFactory();
58          GEDCOMParser::NoteStructure  * tmp_data = factory->createNoteStructure();
59        }
60      _notes.push_back(SmartPtr<NoteStructure>(tmp_data));
61      return _notes.back().getPtr();
62  }  }
63    
64  GEDCOMParser::SourceCitations_t const & GEDCOMParser::Place::getSourceCitations(void) const  GEDCOMParser::SourceCitations_t const & GEDCOMParser::Place::getSourceCitations(void) const

Legend:
Removed from v.1.4  
changed lines
  Added in v.1.5

savannah-hackers-public@gnu.org
ViewVC Help
Powered by ViewVC 1.1.26