Examples of PersonName


Examples of org.apache.juddi.datatype.PersonName

    this.maker = maker;
  }

  public RegistryObject unmarshal(Element element)
  {
    PersonName obj = new PersonName();

    // Attributes
    // {none}

    // Text Node Value
    obj.setValue(XMLUtils.getText(element));

    // Child Elements
    // {none}

    return obj;
View Full Code Here

Examples of org.apache.juddi.datatype.PersonName

    return obj;
  }

  public void marshal(RegistryObject object,Element parent)
  {
    PersonName name = (PersonName)object;
    Element element = parent.getOwnerDocument().createElement(TAG_NAME);

    String nameValue = name.getValue();
    if ((nameValue != null) && (nameValue.trim().length() > 0))
      element.appendChild(parent.getOwnerDocument().createTextNode(nameValue));

    parent.appendChild(element);
  }
View Full Code Here

Examples of org.dcm4che3.data.PersonName

            values.add(null);
    }

    private void startPersonName(int number) {
        startValue(number);
        pn = new PersonName();
    }
View Full Code Here

Examples of org.ictclas4j.bean.PersonName

    else
      return false;
  }
 
  public static  PersonName chineseNameSplit(String word, PosTagger personTagger ) {
    PersonName result = null;

    if (word != null && personTagger!=null  ) {
      Dictionary personDict =personTagger.getUnknownDict();
      int len = word.length();
      if (len < 2 || len > 4)
        return null;
      String[] atoms = GFString.atomSplit(word);
      for (String s : atoms) {
        if (Utility.charType(s) != Utility.CT_CHINESE && Utility.charType(s) != Utility.CT_OTHER)
          return null;
      }

      String surName = null;
      int surNameLen = 2;
      if (len > 2)
        surName = word.substring(0, surNameLen);
      else if (len == 2)
        surName = word;
      if (!personDict.isExist(surName, 1)) {
        surNameLen = 1;
        if (len > 1)
          surName = word.substring(0, surNameLen);
        else if (len == 1)
          surName = word;
        if (!personDict.isExist(surName, 1)) {
          surName = null;
          surNameLen = 0;
        }
      }
      String giveName = word.substring(surNameLen);
      if (len > 3) {
        String temp = word.substring(surNameLen, surNameLen + 1);
        if (personDict.isExist(temp, 1)) {

          giveName = word.substring(surNameLen + 1);
        }
      }

      double freq = personDict.getFreq(surName, 1);
      String temp = giveName.substring(0, 1);
      double freq2 = personDict.getFreq(temp, 2);

      if (surNameLen != 2
          && ((surNameLen == 0 && len > 2) || giveName.length() > 2 || getForeignCharCount(word) >= 3
              && freq < personDict.getFreq("��", 1) / 40 && freq2 < personDict.getFreq("��", 2) / 20 || (freq < 10 && getForeignCharCount(giveName) == (len - surNameLen) / 2)))
        return null;
      if (len == 2 && personTagger.isGivenName(word))
        return null;
      result=new PersonName();
      result.setFirstName(surName);
      result.setLastName(giveName);
    }
    return result;

  }
View Full Code Here

Examples of org.ictclas4j.bean.PersonName

    else
      return false;
  }

  public static PersonName chineseNameSplit( PosTagger personTagger,String word, int index) {
    PersonName result = null;

    if ( word != null && personTagger != null) {
      Dictionary personDict = personTagger.getUnknownDict();
      int len = word.length();
      if (len < 2 || len > 4)
        return null;
      String[] atoms = GFString.atomSplit(word);
      for (String s : atoms) {
        if (Utility.charType(s) != Utility.CT_CHINESE && Utility.charType(s) != Utility.CT_OTHER)
          return null;
      }

      String surName = null;
      int surNameLen = 2;
      if (len > 2)
        surName = word.substring(0, surNameLen);
      else if (len == 2)
        surName = word;
      if (!personDict.isExist( surName, 1,index)) {
        surNameLen = 1;
        if (len > 1)
          surName = word.substring(0, surNameLen);
        else if (len == 1)
          surName = word;
        if (!personDict.isExist( surName, 1,index)) {
          surName = null;
          surNameLen = 0;
        }
      }
      String giveName = word.substring(surNameLen);
      if (len > 3) {
        String temp = word.substring(surNameLen, surNameLen + 1);
        if (personDict.isExist( temp, 1,index)) {

          giveName = word.substring(surNameLen + 1);
        }
      }

      double freq = personDict.getFreq( surName, 1,index);
      String temp = giveName.substring(0, 1);
      double freq2 = personDict.getFreq( temp, 2,index);

      if (surNameLen != 2
          && ((surNameLen == 0 && len > 2) || giveName.length() > 2 || getForeignCharCount(word) >= 3
              && freq < personDict.getFreq( "��", 1,index) / 40 && freq2 < personDict.getFreq( "��", 2,index) / 20 || (freq < 10 && getForeignCharCount(giveName) == (len - surNameLen) / 2)))
        return null;
      if (len == 2 && personTagger.isGivenName(word))
        return null;
      result = new PersonName();
      result.setFirstName(surName);
      result.setLastName(giveName);
    }
    return result;

  }
View Full Code Here

Examples of org.oasis.wsrp.v2.PersonName

      if (!ParameterValidation.existsAndIsNotEmpty(userInfos))
      {
         return null;
      }

      PersonName name = createNameFrom(userInfos);

      XMLGregorianCalendar bdate = null;
      String bdateAsString = userInfos.get(INFO_USER_BDATE);
      if (bdateAsString != null)
      {
View Full Code Here

Examples of org.openmrs.PersonName

  @Override
    public PersonName getValue(FormEntryContext context, HttpServletRequest request) {
    String family = (String) HtmlFormEntryUtil.getParameterAsType(request, context.getFieldName(this) + "_family", String.class);
    String given = (String) HtmlFormEntryUtil.getParameterAsType(request, context.getFieldName(this) + "_give", String.class);
    if (StringUtils.hasText(family) || StringUtils.hasText(given)) {
      return new PersonName(given, null, family);
    } else {
      return null;
    }
  }
View Full Code Here

Examples of org.uddi.api_v3.PersonName

    }
    assertEquals(names1.size(), names2.size());
    Iterator<PersonName> names1Itr = names1.iterator();
    Iterator<PersonName> names2Itr = names2.iterator();
    while (names1Itr.hasNext()) {
      PersonName name1 = names1Itr.next();
      PersonName name2 = names2Itr.next();
      assertEquals(name1.getLang(), name2.getLang());
      assertEquals(name1.getValue(), name2.getValue());
    }
  }
View Full Code Here

Examples of org.uddi.api_v3.PersonName

    }
    assertEquals(names1.size(), names2.size());
    Iterator<PersonName> names1Itr = names1.iterator();
    Iterator<PersonName> names2Itr = names2.iterator();
    while (names1Itr.hasNext()) {
      PersonName name1 = names1Itr.next();
      PersonName name2 = names2Itr.next();
      assertEquals(name1.getLang(), name2.getLang());
      assertEquals(name1.getValue(), name2.getValue());
    }
  }
View Full Code Here

Examples of org.uddi.api_v3.PersonName

    DiscoveryURLs discoveryURLs = new DiscoveryURLs();
    discoveryURLs.getDiscoveryURL().add(discoveryURL);
   
    //Contact info:
    //Name of contact in English.
    PersonName personName = new PersonName();
    personName.setLang("en");
    personName.setValue(data.getFirstName(true) + data.getLastName(true));
   
    //Address lines for contact.
    AddressLine addressLineOne = new AddressLine();
    addressLineOne.setKeyName("street");
    addressLineOne.setKeyValue("street");
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.