25 |
#include "GEDCOMParser/GEDCOMFactory.hh" |
#include "GEDCOMParser/GEDCOMFactory.hh" |
26 |
#include "GEDCOMParser/GEDCOMFactoryAccessor.hh" |
#include "GEDCOMParser/GEDCOMFactoryAccessor.hh" |
27 |
|
|
28 |
|
#include <iostream> |
29 |
|
|
30 |
|
std::string const GEDCOMParser::IndividualRecord::MALE = "M"; |
31 |
|
std::string const GEDCOMParser::IndividualRecord::FEMALE = "F"; |
32 |
|
|
33 |
GEDCOMParser::IndividualRecord::IndividualRecord(std::string const &id = "") |
GEDCOMParser::IndividualRecord::IndividualRecord(std::string const &id = "") |
34 |
{ |
{ |
35 |
if (id != "") |
if (id != "") |
249 |
{ |
{ |
250 |
} |
} |
251 |
|
|
252 |
|
void GEDCOMParser::IndividualRecord::RemoveFamilyLink(GEDCOMParser::SpouseToFamilyLink * family_link) |
253 |
|
{ |
254 |
|
GEDCOMParser::SpouseToFamilyLinks_t::iterator iter_to_delete = find_if(_spouse_to_family_links.begin(), _spouse_to_family_links.end(), GEDCOMParser::SpouseToFamilyLink::IsEqualByFamsXref(family_link->getFamsXref())); |
255 |
|
if (iter_to_delete != _spouse_to_family_links.end()) |
256 |
|
{ |
257 |
|
_spouse_to_family_links.erase(iter_to_delete); |
258 |
|
} |
259 |
|
return; |
260 |
|
} |
261 |
|
|
262 |
|
void GEDCOMParser::IndividualRecord::RemoveFamilyLink(GEDCOMParser::ChildToFamilyLink * family_link) |
263 |
|
{ |
264 |
|
GEDCOMParser::ChildToFamilyLinks_t::iterator iter_to_delete = find_if(_child_to_family_links.begin(), _child_to_family_links.end(), GEDCOMParser::ChildToFamilyLink::IsEqualByFamcXref(family_link->getFamcXref())); |
265 |
|
if (iter_to_delete != _child_to_family_links.end()) |
266 |
|
{ |
267 |
|
_child_to_family_links.erase(iter_to_delete); |
268 |
|
} |
269 |
|
return; |
270 |
|
} |
271 |
|
|
272 |
GEDCOMParser::AliaXrefs_t const &GEDCOMParser::IndividualRecord::getAliaXrefs(void) const |
GEDCOMParser::AliaXrefs_t const &GEDCOMParser::IndividualRecord::getAliaXrefs(void) const |
273 |
{ |
{ |
353 |
{ |
{ |
354 |
return _child_to_family_links; |
return _child_to_family_links; |
355 |
} |
} |
|
|
|
|
GEDCOMParser::ChildToFamilyLinks_t &GEDCOMParser::IndividualRecord::getChildToFamilyLinks(void) |
|
|
{ |
|
|
return _child_to_family_links; |
|
|
} |
|
356 |
|
|
357 |
GEDCOMParser::SpouseToFamilyLinks_t const &GEDCOMParser::IndividualRecord::getSpouseToFamilyLinks(void) const |
GEDCOMParser::SpouseToFamilyLinks_t const &GEDCOMParser::IndividualRecord::getSpouseToFamilyLinks(void) const |
358 |
{ |
{ |