Event::getPerson - jcobban/Genealogy GitHub Wiki

$event->getPerson()

Up: class Event

This method returns an instance of Person associated with the Event. The instance depends upon the value of 'idtype':

ID Type returns
IDTYPE_INDIV $event->getAssociatedRecord()
IDTYPE_MAR $event->getAssociatedRecord()->getHusband() if husband is defined, otherwise getWife()
IDTYPE_CHILD $event->getAssociatedRecord()->getPerson()

Next: $event->setAssociatedRecord()