Download gedcomx.pm
This Perl module contains general services used by other
programs.
sub loopGedcom - loop through Gedcom data
This subroutine takes two parameters:
- block of code that processes each Gedcom record.
- array containing Gedcom records to process.
sub loopGedFile - loop through Gedcom files
This subroutine takes two parameters:
- block of code that processes each Gedcom record.
- array containing list of file names of Gedcom files.
sub mainName - return main part of surname
This subroutine returns the main part of a surname. For example,
mainName 'van Apeldoorn' returns the string
Apeldoorn.
Download gedcom.pm
This Perl module contains general services used by other
programs. These are more substantial services using Perl objects to
represent Gedcom records.
Package General
General services not associated with any specific object.
exported methods:
mainName(name)
- Returns the main part of a name. ie, that part of a name
following any lower case prefixes.
Package Gedcom
Object that represents the data in a gedcom file.
exported methods:
new
- Create new Gedcom object.
data{(record)}
- Get or set data of a Gedcom object.
read(filename)
- Read from a Gedcom file.
write(filename)
- Write data to a Gedcom file.
Package GedcomRecord
This is the base class for all gedcom records. For many gedcom
tags, this class is sufficient to represent the data, but for some
tags, such as INDI and DATE, sub-classes
are used.
exported methods:
new(tag{,text{,label}})
- Create new Gedcom record object from specified tag, text, and
label.
tag{(tag)}
- Get or set tag in Gedcom record.
label{(label)}
- Get or set label in record.
text{(text)}
- Get of set text in record.
parent{(parent)}
- Get or set parent of record.
additem(record)
- Add a subsidiary record to this gedcom record.
printrecord(file)
- Write out this and subsidiary records.
record
- Return string representing gedcom record.
attrs(tag)
- Return list of subsidiary records with specified tag.
firstattr(tag)
- Return first subsidiary record with specified tag.
isEvent
- Returns 0, indicating record is not an event.
isIndiEvent
- Returns 0, not an individual event.
isFamEvent
- Returns 0, not a family event.
events
- Returns list of events.
Package GenIndi
Package GenIndi inherits from
GedcomRecord and represents an individual (gedcom record
with tag INDI).
exported methods:
fullname
- Returns full name of individual.
surname
- Returns surname.
givennames
- Returns given names.
compByName(indi)
- Returns -1, 0, 1 if specified individual has name less than,
equal, or greater than this individual.
Package GenEvent
Package GenEvent inherits from
GedcomRecord and represents any event objects. The following
gedcom tags produce GenEvent objects:
ADOP, ANUL, BIRT,
BAPM, BARM, BASM,
BLES, BURI, CENS,
CHR, CHRA, CONF,
CREM, DEAT, EMIG,
DIV, DIVF, ENGA,
FCOM, GRAD, IMMI,
MARR, MARB, MARC,
MARL, MARS, NATU,
ORDN, RETI, PROB,
WILL, and EVEN.
exported methods:
isEvent
- Returns 1.
isIndiEvent
- Returns 1 if event is associated with individual.
isFamEvent
- Returns 1 if event is associated with family.
getDate
- Returns date gedcom record.
getPlace
- Returns place gedcom record.
Package GenName
Package GenName inherits from
GedcomRecord and represents NAME objects.
exported methods:
fullname
- Returns full name of individual.
surname
- Returns surname.
givennames
- Returns given names.
package GenDate
Package GenDate inherits from
GedcomRecord and represents DATE objects.
exported methods:
comp(date)
- -- Returns -1, 0, 1 if specified date is less than, equal, or
greater than this date.
|