Package net.sourceforge.gedapi.view

Examples of net.sourceforge.gedapi.view.GLink


          throw new RuntimeException("SEND MSG TO BROWSER: In the GEDCOM file '"+gedcomURL.getGedcomURL()+"' there is a GLink event/attribute that does not have a PLAC tag!!");
        }
        else
        {
          //individual.glinks.add(placProp.getValue());
          GLink newGLink = new GLink();
          newGLink.setToURLName(propValue);
          newGLink.setToURL(placProp.getValue());

          // DONE: get the date of the glink from prop.getProperty("DATE", false).getValue().trim()
          // and look for a corresponding GLink-Relation EVEN tag whose PLAC tag is the same as placProp.getValue()
          // if one is found then add in the newGLink.setFromRelation() and newGLink.setToRelation()
          Property dateProp = prop.getProperty("DATE", false);
          if(dateProp != null)
          {
            newGLink.setDate(dateProp.getValue().trim());
          }
          String glinkRelation = getGLinkRelation(propList, newGLink.getToURL());
          if(glinkRelation != null)
          {
            String[] glinkRelations = GLinkPattern.splitRelation(glinkRelation);
            newGLink.setFromRelation(glinkRelations[0]);
            newGLink.setToRelation(glinkRelations[1]);
          }
          individual.glinks.add(newGLink);
        }
       
        LOG.finer("The property is: "+placProp);
View Full Code Here


            if(toURLName == null || toURLName.trim().equals(""))
            {
              toURLName = NOT_NAMED;
            }
           
        GLink newGLink = new GLink();
        //LOG.finest("The toURLName is: "+toURLName);
        newGLink.setToURLName(toURLName);
        Node glinkNode = nextNodeWithName(firstChild, "g:glink");
            //LOG.finest("The toURL node name is: "+glinkNode.getNodeName());
        newGLink.setToURL(glinkNode.getTextContent());
        //LOG.finest("The toURL is: "+newGLink.getToURL());
       
        // DONE: get the date of the glink from ????
        // and get the fromRelation and toRelation from ???? and set them
        // with newGLink.setFromRelation() and newGLink.setToRelation()
        Node relationNode = nextNodeWithName(firstChild, "g:relation");
            //LOG.finest("The relation node name is: "+relationNode.getNodeName());
        if(relationNode != null && "g:relation".equals(relationNode.getNodeName()))
        {
          String[] glinkRelations = GLinkPattern.splitRelation(relationNode.getTextContent());
          newGLink.setFromRelation(glinkRelations[0]);
          newGLink.setToRelation(glinkRelations[1]);
        }
        //LOG.finest("The fromRelation is: "+newGLink.getFromRelation());
        //LOG.finest("The toRelation is: "+newGLink.getToRelation());
       
        if(relationNode != null)
        {
          //nextSibling = nextSibling.getNextSibling();
          Node dateNode = nextNodeWithName(firstChild, "g:lastChangeDate");
              //LOG.finest("The date node name is: "+dateNode.getNodeName());
          if(dateNode != null && "g:lastChangeDate".equals(dateNode.getNodeName()))
          {
            newGLink.setDate(dateNode.getTextContent());
          }
        }
        //LOG.finest("The lastChangeDate is: "+newGLink.getDate());
        individual.glinks.add(newGLink);
          }
View Full Code Here

TOP

Related Classes of net.sourceforge.gedapi.view.GLink

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.