コード例 #1
0
ファイル: ParserTest.php プロジェクト: mrkrstphr/php-gedcom
 /**
  *
  */
 public function testNote()
 {
     $firstNote = current($this->gedcom->getNote());
     $this->assertEquals($firstNote->getNote(), 'Test link to a graphics file about the main Submitter of this file.');
     $this->assertEquals($firstNote->getChan()->getDate(), '24 May 1999');
     $this->assertEquals($firstNote->getChan()->getTime(), '16:39:55');
 }
コード例 #2
0
ファイル: Writer.php プロジェクト: hybr/jpm
 /**
  *
  * @param \PhpGedcom\Gedcom $gedcom The GEDCOM object
  * @param string $format The format to convert the GEDCOM object to
  * @return string The contents of the document in the converted format
  */
 public static function convert(\PhpGedcom\Gedcom &$gedcom, $format = self::GEDCOM55)
 {
     $head = $gedcom->getHead();
     $output = \PhpGedcom\Writer\Head::convert($head, $format);
     return $output;
 }
コード例 #3
0
ファイル: Writer.php プロジェクト: mrkrstphr/php-gedcom
 /**
  *
  * @param \PhpGedcom\Gedcom $gedcom The GEDCOM object
  * @param string $format The format to convert the GEDCOM object to
  * @return string The contents of the document in the converted format
  */
 public static function convert(Gedcom $gedcom, $format = self::GEDCOM55)
 {
     $head = $gedcom->getHead();
     $output = Head::convert($head, $format);
     return $output;
 }