'5      !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdefghijklmnopqrstuvwxyz{|}~      !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdefghijklmnopqrstuvwxyz{|}~(Decoder for the ANSEL character encoding(c) Callum Lowcay, 2017BSD3cwslowcay@gmail.com experimentalGHCNone!Decode an ANSEL string to UnicodeThe string to encode Unicode text$Common utility functions for parsing(c) Callum Lowcay, 2017BSD3cwslowcay@gmail.com experimentalGHCNone  Parsers from # using the default error component.Flipped version of $Replace failure with a default value1Trim leading and trailing whitespace off a stringConvert h:m:s.fs time to 9Parse a GEDCOM exact time value into (h, m, s, fs) formatTParse a GEDCOM exact date into (day, month, year). Months are number from 1 to 12.Parse a Gregorian/Julian monthParse a French calendar monthParse a Hebrew calendar monthParse a Gregorian year. GEDCOM allows one to specify two versions of the same year for cases where the historical year started in March instead of January. This function attempts to return the modern year number (assuming the year starts in January.   1+Common utility functions for parsing GEDCOM(c) Callum Lowcay, 2017BSD3cwslowcay@gmail.com experimentalGHCNoneIThe level field The tag fieldA cross reference IDAn escape sequence Line textThe value field A GEDCOM lineA GEDCOM subtreeA raw GEDCOM syntax tree A reference to another structureAlready dereferenced.The  to look upA parse error.A badly formatted GEDCOM line,A reference where a reference wasn't allowed2Missing a reference where a reference was required"Two targets for the same referenceA badly formatted field  The wrong tag &An error arising from dereferencing a  %The referred structure doesn't exist. )Dereferenced structure had the wrong typeExtract the line text<Trim white space off the start an end of a GEDCOM line text.Ignore escape sequencesIgnore certain escape sequences& $   Low-level GEDCOM parser(c) Callum Lowcay, 2017BSD3cwslowcay@gmail.com experimentalGHCNoneLParse any_char. Parse non_at.Parse alphanum. Parse delim. Parse escape.Parse escape_text. Parse level.Parse line_item.Parse pointer.Parse line_valueParse optional_line_value. Parse optional_xref_ID.  Parse tag. parse terminator. Parse xref_ID. Parse gedcom_line. Convert local ids to global ids. Convert local ids to global ids.Parse a line at a fixed levelParse a GEDCOM subtree!Parse the raw GEDCOM syntax tree.     The parent structure's ID The local ID. A global ID.The parent structure's ID.The line to update.7An updated line where local ID's have been made global.The parent ID The level to parse the line at The parent ID%The level where the subtree is rooted     !Monads for parsing GEDCOM records(c) Callum Lowcay, 2017BSD3cwslowcay@gmail.com experimentalGHCNoneI MA monad for parsing an instance of a GEDCOM structure from a GEDCOM subtree.GA Monad for parsing GEDCOM structures out of a list of GEDCOM subtrees.@A parser that extracts a GEDCOM structure from a GEDCOM subtree.Run a  into a .'Parse multiple instances of a structure)Parse an optional instance of a structure(Parse a required instance of a structure-Add a reference to the cross reference table.Run a G, returning either an error or a value, and the cross reference table. The subtree to parse.lEither parsed structure, or the subtree itself if the subtree doesn't contain the expected GEDCOM structure.)The subtrees to parse the structure from.%The MultiMonad that does the parsing./The tag that identifies the required structure.The cross reference to add.(The value the reference will resolve to.  GEDCOM data structures(c) Callum Lowcay, 2017BSD3cwslowcay@gmail.com experimentalGHCNones GPart of the GEDCOM standard, but only for LDS use so far as I am aware.GPart of the GEDCOM standard, but only for LDS use so far as I am aware./Automated Record ID. From the GEDCOM standard:"This number is intended to serve as a more sure means of identification of a record for reconciling differences in data between two interfacing systems."*A year in some calendar. May be negative.Assessment of the quality of a source. A number from 0 to 3 with 0 indicating unreliable information and 3 being direct primary evidence. LongitudeLatitudeA natural language.gCustom reference added by the creator of this file. The format of this reference is not standardized.Description of a source. The first field contains a description of the source. The second field contains sections of text from the source.!Sex.%"The type of Roman transliteration.&Chinese Pinyin'Japanese Romaji(Chinese Wade-Giles)Something else*(A Roman transliteration of a place name.,.Privacy restrictions associated with a record.0#The type of phonetic transcription.1 Japanese kana2Korean hanguel3Something else4)A phonetic transcription of a place name.6.How a child is associated with his/her family.; Which parent??A personal name. The first field is the full name of the individual. The second field contains just the surname of the individual (or Nothing if unspecified)A,A global location in longitude and latitude.CA range of datesD9A range of dates with a start date and optional end date.E2A range of dates with only the end date specified.FnA date. The format is day / month / year and months are numbered 1 to 12 (or 1 to 13 for certain calendars).HMetadata about a child linkLRA character set and optional version (the version is unused so far as I am aware)N"The date a record was last changedPA call number for citationsR A calendarWxInformation about an adoption, including the family the subject was adopted into and which parent(s) adopted the child.YRecognised event types.ZFamily of individual census.[A family event\An individual event]Some other kind of event.^2Recognised types of events concerning individuals.uAny other kind of event.v/Recognised types of events concerning families.Any other kind of event.A range of dates.(A date that is only approximately known.3Dates, including date ranges and approximate dates.iA date in a format that doesn't fit the other categories. May include an interpretation in the optional F field. Name types.Any other kind of name.9The kind of multimedia (not necessarily a computer file).Any other kind of multimedia."Supported multimedia file formats.Any other file type.&Information about a multimedia format.#Information about a multimedia file#Contact details associated with an  An address,Citation of a repository of source material.Citation of source material.8Either a description of the source, or a reference to a R3 record which describes the source in more detail.8Classification of extra information about an individual.Caste.'Physical description of the individual.Scholastic achievement.National id number.National or tribal origin.Number of children.Number of marriages. Occupation.Property the individual owned.Religious affiliation.Place of residence.Social security number.Title of nobility.None of the above.&Extra information about an individual.Parts of a person's name.pParts of the name that precede the other names. Example from the GEDCOM standard (prefix highlighted in bold): Lt. Cmndr. Joseph Allen jr. Given names NicknamesZSurname prefixes. Example from the GEDCOM standard (surname prefix highlighted in bold):de la CruzSurname or family namesrParts of the name that come after all other names. Example from the GEDCOM standard (suffix highlighted in bold)Lt. Cmndr. Joseph Allen jr.+A Roman transliteration of a person's name.,A phonetic transcription of a person's name.The name of a person.A physical place."An event concerning an individual. "Details about an individual event. An event concerning a family.Details about a family event.Details about an event.#TA link from an individual to a family record where they are registered as a spouse.'SA link from an individual to a family record where they are registered as a child.-#An association between individuals.37Information about what events are recorded in a source.8Extra data about a source.=VThe submitter record. Information about someone who submitted data to this database.G4The submission record. Information about this file.RPThe source record. A source of information that may be cited by other records.`yThe repository record. Represents a repository of sources (for example a collection of documents or a physical library)h6The note record (for attaching notes to other records)o4The multimedia record (for linking multimedia files)xThe individual recordThe family record0Information about the source of this GEDCOM dataInformation about a corporationOWhere the GEDCOM data is sourced from (e.g. the program that created the file)IThe actual database format. Only the default LineageLinked is supported.&The database format and version number The headerThe root structure  !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdefghijklmnopqrstuvwxyz{|}~      !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdefghijklmnopqrstuvwxyz{|}~  !"#$%)&'(*+,-./0312456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXY]Z[\^u_`abcdefghijklmnopqrstvwxyz{|}~      !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdefghijklmnopqrstuvwxyz{|}~K  !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdefghijklmnopqrstuv wxyz{|}~        !"#$%&'()*+,-./0123456789:;<= >?@ABCDEFG HIJKLMNOPQR STUVWXYZ[\]^_`abcdefghijklmnopqrstuvwxyz{|}~  GEDCOM high level parsers(c) Callum Lowcay, 2017BSD3cwslowcay@gmail.com experimentalGHCNoneIJL_=A function that adds references to the cross reference table.Handler for general tags. 6Handler for tags that cannot contain cross references.!Parse a ' value from the raw GEDCOM syntax tree."Parse a .#Parse a .$Parse a .%Parse a .&Parse a .' Parse an x.(Parse a Node.)Parse a `.*Parse a R.+Parse a =.,Parse a G.-Parse a ,..Parse a list of  s./Parse a FamiltyEventDetail.0 Parse an .1Parse an AGE tag.2Parse a 8.3Parse a .4Parse a 4.5Parse a *.6Parse a 0.7Parse a %.8Parse a A.9Parse a  or  value.:Parse a .; Extract a ? from a string.<Parse a .=Parse a  structure.>Parse a .?Parse a .@Parse a !.AParse a list of s.BParse a list of sC Parse an  .DParse a '.EParse a 6.FParse a H.GParse a #.H Parse an -.IParse a 3.JParse a .KParse a P.LParse a .MParse a .NParse a .OParse a L.PParse a N.QParse .R Parse an .SParse a .T'Decode a calendar escape sequence to a R.UPrepare text for parsing a .VAttempt to extract a C% from a string with escape sequences.WAttempt to extract a % from a string with escape sequences.XAttempt to extract a % from a string with escape sequences.YAttempt to extract a % from a string with escape sequences.ZAttempt to extract a F% from a string with escape sequences.[Parse a F( from a given string assuming the given R.\Parse an exact date.]Parse an exact date and time.^Parse a o record._Parse a o link.`Actual parser for o values.aParse a .bParse a .cParse a .dParse a v.e Parse an ^.f Parse an Y.gParse a place form structure.hParse a .iParse a version structure.jParse a NAME tag.kParse a copyright tag.lParse a file name.m Parse an .nParse a  .oParse a .pParse a .qParse a .rParse a boolean value.sParse a Word value.tExtract the text from a tag.u4Extract a list of comma separated values from a tag.vDon't add any references.wAdd direct references only.xaParse a tag which is either a GEDCOM structure, or a reference to the expected GEDCOM structure.yParse a tag which cannot contain a cross reference (i.e. the tag must contain the structure itself, not a reference to another structure).zaParse a tag which must contain a cross reference to another structure, not the structure itself.{&The most general tag parsing function.|Handle CONT and CONC tags._ !"#$%&'()*+,-./0123456789The tag to parse>The single character prefix that indicates a positive value. <The single character prefix that indicates a negative value.:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdefghijklmnopqrstuvwxThe tag to parse.A handler for the tagyThe tag to parse.A handler for the tag.z{The tag to parse.!How to register cross references./How to convert the tag into a GEDCOM structure.|The value of the first line The sub treeVThe concatenation of the values of all the CONT and CONC tags, and the remaining tags.!"_ !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdefghijklmnopqrstuvwxyz{|&Parser for the GEDCOM genealogy format(c) Callum Lowcay, 2017BSD3cwslowcay@gmail.com experimentalGHCNoneTA table of cross references2Lookup up a reference in the cross reference table#Parse Gedcom data from a ByteStringParse Gedcom data from a file}The reference to look upThe table to look up inThe value or an error+The filename from which the string was readThe string to parse6The Gedcom data and cross reference table, or an errorThe file to read6The Gedcom data and cross reference table, or an error  !"#$%)&'(*+,-./0312456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXY]Z[\^u_`abcdefghijklmnopqrstvwxyz{|}~      !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdefghijklmnopqrstuvwxyz{|}~  xyz{|}~opqrstuvwhijklmn`abcdefgRSTUVWXYZ[\]^_GHIJKLMNOPQ=>?@ABCDEF89:;<34567-./012'()*+,#$%& !"     vwxyz{|}~^_`abcdefghijklmnopqrstuYZ[\]WXRSTUVPQNOLMHIJKFGCDEAB?@;<=>6789:450123,-./*+%&'()!"#$  }~      !"#$%&'$(()*+,-./-00123456789::;;<=>??@ABCDDEEFFGHIJKLLMNOPMQRSTUVWXYZ[\]^_`abcdefgQhijklmnopqrshtuvwxyz{|}~        !"#$%&'()**+,-./01234567789:;<=>>?@ABCDDEFGHIJKLLMNOPQRSTUVWXYZ[\]^_`aabcdefghijklmnoopqrsstuvvwxyz{|}~       !"#$%&'()*+,-./0123456789:;<=>?@ABCDE%gedcom-0.1.0.0-Kn7OsWqAYwy6hhFSb63Ka7Data.Text.Encoding.ANSEL Data.GedcomData.Gedcom.Internal.CommonData.Gedcom.CommonData.Gedcom.LineParserData.Gedcom.ParseMonadsData.Gedcom.StructureData.Gedcom.Parser decodeANSELGDXRefIDGDRefGDErrorLineFormatError UnexpectedRef RequiredRef DuplicateRef FormatErrorTagError GDRefError RefNotPresent WrongRefTypeRFNAFNRINYearQualityAssessment LongitudeLatitudeLanguage UserReferenceSourceDescriptionSexMaleFemale Undetermined RomanTypePinyinRomaji WadeGilesRomanPlaceNameRestrictionNotice ConfidentialLockedPrivacy PhoneticTypeKanaHangulPhoneticPlaceNamePedigreeAdoptedByBirthFosterSealingParentHusbandWife BothParentsNameMapCoord DatePeriodDateFromDateToDateChildLinkStatus Challenged DisprovedProvenCharset ChangeDate CallNumberCalendar GregorianJulianHebrewFrenchAdoptionDetail EventTypeCensusFamilyEventTypeVIndividualEventTypeVIndividualEventTypeBirth ChristeningDeathBurial CremationAdoptionBaptism BarMitzvah BasMitzvahBlessingChristeningAdult ConfirmationFirstCommunion OrdinationNaturalization Emigration Immigration IndvCensusProbateWill Graduation RetirementFamilyEventTypeAnnuled FamCensusDivorce DivorceFiled Engagement MarriageBannMarriageContractMarriageMarriageLicenseMarriageSettlement Residence DateRange DateBefore DateAfter DateBetween DateApprox DateAboutDateCalculated DateEstimated DateValueDateV DateApproxV DatePeriodV DateRangeV DatePhraseNameTypeAKA BirthName ImmigrantMaidenMarriedMultimediaTypeMT_AUDIOMT_BOOKMT_CARD MT_ELECTRONICMT_FICHEMT_FILM MT_MAGAZINE MT_MANUSCRIPTMT_MAP MT_NEWSPAPERMT_PHOTO MT_TOMBSTONEMT_VIDEOMT_OTHERMultimediaFileFormatMF_BMPMF_GIFMF_JPGMF_OLEMF_PCXMF_TIFMF_WAVMF_OTHERMultimediaFormatMultimediaFilemultimediaFileLinkmultimediaFileFormatmultimediaTitleContactDetails addressPhone addressEmail addressFax addressWWWAddress addressLines addressCity addressStateaddressPostcodeaddressCountryaddressContactRepositoryCitationrepoCiteRepository repoCiteNoterepoCiteCallNumberSourceCitation citeSourcecitePageciteMultimediaciteNote citeQualityIndividualAttributeTypeCastePhysicalDescription Education NationalIDNationalOrigin NChildren NMarriages Occupation PossessionsReligion ResidesAtSocialSecurityTitleFactIndividualAttributePersonalNamePiecesnamePiecePrefixnamePieceGivennamePieceNicknamenamePieceSurnamePrefixnamePieceSurnamenamePieceSuffixnamePieceNameNotenamePirceSourceCitation RomanizedName romanziedName romanziedTyperomanziedPieces PhoneticName phoneticName phoneticTypephoneticPieces PersonalNamepersonalNameNamepersonalNameTypepersonalNamePiecespersonalNamePhoneticpersonalNameRomanPlace placeName placeForm placePhonetic placeRomanplaceMap placeNoteIndividualEventindividualEventTypeindividualEventDetailIndividualEventDetailindividualEventDetailDetailindividualEventDetailAge FamilyEventfamilyEventTypefamilyEventDetailFamilyEventDetailfamilyEventDetailAgeHusbandfamilyEventDetailAgeWifefamilyEventDetailDetail EventDetaileventDetailTypeeventDetailDateeventDetailPlaceeventDetailAddresseventDetailAgencyeventDetailReligioneventDetailCauseeventDetailRestrictionNoticeeventDetailNoteeventDetailSourceCitationeventDetailMultimediaSpouseToFamilyLinkspouseToFamilyLinkFamilyspouseToFamilyLinkNoteChildToFamilyLinkchildLinkFamilychildLinkPedigreechildLinkStatus childLinkNote AssociationassociationIndividualassociationRelationassociationCitationassociationNoteSourceRecordedEventsourceRecordedEventTypesourceRecordedDatesourceRecordedPlace SourceDatasourceDataEventsRecordedsourceDataAgencysourceDataNote Submitter submitterNamesubmitterAddresssubmitterMedia submitterLang submitterRFN submitterRIN submitterNotesubmitterChangeDate SubmissionsubmissionSubmittersubmissionFamilyFilesubmissionTempleCodesubmissionAncestorGenerationssubmissionDescendentGenerationssubmissionOrdinanceProcessing submissionRINsubmissionNotesubmissionChangeDateSource sourceData sourceAuthor sourceTitlesourceShortTitlesourcePublicationFacts sourceTextsourceRepositoryCitationssourceUserReference sourceRINsourceChangeDate sourceNotesourceMultimedia RepositoryrepositoryNamerepositoryAddressrepositoryNoterepositoryUserReference repositoryRINrepositoryChangeDateNotenoteTextnoteUserReferencenoteRINnoteSourceCitationnoteChangeDate MultimediamultimediaFilemultimediaTitlmultimediaUserReference multimediaRINmultimediaNotemultimediaSourceCitationmultimediaChangeDate IndividualindividualRestrictionNoticeindividualName individualSexindividualEventindividualAttributeindividualChildToFamilyLinkindividualSpouseToFamilyLinkindividualSubmitterindividualAssociationindividualAliasindividualAncestorInterestindividualDescendantInterest individualRFN individualAFNindividualUserReference individualRINindividualChangeDateindividualNoteindividualSourceCitationindividualMultimediaFamilyfamilyRestrictionNotice familyEvent familyHusband familyWifefamilyChildrenfamilyTotalChildrenfamilySubitterfamilyUserReference familyRINfamilyChangeDate familyNotefamilySourceCitationfamilyMultimediaHeaderSourceDataheaderSourceDataNameheaderSourceDataDateheaderSourceDataCopyrightCorpcorpName corpAddress HeaderSourceheaderSourceSystemIDheaderSourceVersionheaderSourceNameheaderSourceCorpheaderSourceData GedcomFormGedcomLineageLinkedGedcomUnsupported GedcomFormat gedcomVersion gedcomFormHeader headerSourceheaderDestination headerDateheaderSubmitterheaderSubmission headerFileheaderCopyrightheaderGedcomFormat headerCharset headerLangheaderPlaceForm headerNoteGedcom gedcomHeader gedcomFamilygedcomIndividualgedcomMultimedia gedcomNotegedcomRepository gedcomSourcegedcomSubmitter XRefTablegdLookupparseGedcomStringparseGedcomFile$fShowXRefTabledecodeANSELCharisAscii isDiacritic composedTablecombiningTableParser#text-1.2.2.2-KC7dWoG09dA1F6jKj5GSqhData.Text.InternalText<&>base Data.Functor<$> withDefaulttrim timeToPicos time-1.6.0.1Data.Time.Clock.ScaleDiffTime timeValue dateExactmonthmonthFrmonthHebyearGregGDLevelGDTagGDEscape GDLineItem GDLineValueGDLineGDTreeGDRoot GDStructureGDXRef gdLineDatagdTrimLineItemgdIgnoreEscapesgdFilterEscapes GDLineItemV GDXRefIDV$fMonoidGDLineItem$fShowGDRefError gdAnyChargdNonAt gdAlphaNumgdDelimgdEscape gdEscapeTextgdLevel gdLineItem gdPointer gdLineValuegdOptionalLineValuegdOptionalXRefIDgdTag gdTerminatorgdXRefIDgdLine gdExpandIDgdExpandPointer gdLineLevelgdTreegdRootStructureMonad MultiMonadStructureParser runMultiMonad parseMulti parseOptional parseRequired addReference runStructure RegisterRef TagHandler NoLinkHandler parseGedcom parseHeaderparseHeaderSource parseCorpparseHeaderSourceData parseFamilyparseIndividual parseNoteparseRepository parseSourceparseSubmitterparseSubmissionparseRestrictionNoticeparseFamilyEventparseFamilyEventDetailparseEventDetailparseAgeparseSourceData parsePlaceparsePhoneticPlaceNameparseRomanPlaceNameparsePhoneticTypeparseRomanType parseMapCoord parseLongLatparsePersonalNamegetPersonalName parseNameTypeparseNamePiecesparsePhoneticNameparseRomanNameparseSexparseIndividualAttributeparseIndividualEventparseIndividualEventDetailparseChildToFamilyLink parsePedigreeparseChildLinkStatusparseSpouseToFamilyLinkparseAssociationparseSourceRecordedEventparseRepositoryCitationparseCallNumberparseSourceCitationparseGedcomFormatparseGedcomForm parseCharsetparseChangeDateparseContactDetails parseAddressparseDateValuedecodeCalendarEscapeprepareDateTextparseDatePeriodparseDateRangeparseDateApproxparseDatePhrase parseDategetDateparseExactDateparseExactDateTimeparseMultimediaRecordparseMultimediaparseMultimediaRawparseMultimediaFileparseMultimediaFormatparseMultimediaTypegetFamilyEventTypegetIndividualEventType getEventTypeparsePlaceFormparseUserReference parseVersion parseNameparseCopyright parseFileparseAFNparseRFNparseRIN parseLanguage parseQuality parseBoolTag parseWordTag parseTextTag parseListTagnullrrefdefrrefparseTagparseNoLinkTag parseLinkTag parseTagFull parseCont