Esempio n. 1
0
        public void AddUserRef(string reference)
        {
            GEDCOMUserReference uRef = new GEDCOMUserReference(Owner, this, "", "");

            uRef.StringValue = reference;
            UserReferences.Add(uRef);
        }
Esempio n. 2
0
        public override void Assign(GEDCOMTag source)
        {
            GEDCOMRecord sourceRec = source as GEDCOMRecord;

            if (sourceRec == null)
            {
                throw new ArgumentException(@"Argument is null or wrong type", "source");
            }

            base.Assign(source);

            foreach (GEDCOMNotes sourceNote in sourceRec.fNotes)
            {
                GEDCOMNotes copy = (GEDCOMNotes)GEDCOMNotes.Create(Owner, this, "", "");
                copy.Assign(sourceNote);
                Notes.Add(copy);
            }

            foreach (GEDCOMMultimediaLink sourceMediaLink in sourceRec.fMultimediaLinks)
            {
                GEDCOMMultimediaLink copy = (GEDCOMMultimediaLink)GEDCOMMultimediaLink.Create(Owner, this, "", "");
                copy.Assign(sourceMediaLink);
                MultimediaLinks.Add(copy);
            }

            foreach (GEDCOMSourceCitation sourceSrcCit in sourceRec.fSourceCitations)
            {
                GEDCOMSourceCitation copy = (GEDCOMSourceCitation)GEDCOMSourceCitation.Create(Owner, this, "", "");
                copy.Assign(sourceSrcCit);
                SourceCitations.Add(copy);
            }

            foreach (GEDCOMUserReference sourceUserRef in sourceRec.fUserReferences)
            {
                GEDCOMUserReference copy = (GEDCOMUserReference)GEDCOMUserReference.Create(Owner, this, "", "");
                copy.Assign(sourceUserRef);
                UserReferences.Add(copy);
            }
        }