gpt4 book ai didi

pl.edu.icm.model.bwmeta.y.YContributor.getOneAttributeSimpleValue()方法的使用及代码示例

转载 作者:知者 更新时间:2024-03-16 07:06:40 29 4
gpt4 key购买 nike

本文整理了Java中pl.edu.icm.model.bwmeta.y.YContributor.getOneAttributeSimpleValue()方法的一些代码示例,展示了YContributor.getOneAttributeSimpleValue()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。YContributor.getOneAttributeSimpleValue()方法的具体详情如下:
包路径:pl.edu.icm.model.bwmeta.y.YContributor
类名称:YContributor
方法名:getOneAttributeSimpleValue

YContributor.getOneAttributeSimpleValue介绍

暂无

代码示例

代码示例来源:origin: pl.edu.icm.yadda/yaddaweb-lite-core

protected String resolveEmail(final YContributor contributor) {
  String email = contributor.getOneAttributeSimpleValue(YConstants.AT_CONTACT_TYPE_EMAIL);
  if (StringUtils.isEmpty(email)) {
    email = contributor.getOneAttributeSimpleValue(YConstants.AT_CONTACT_EMAIL);
  }
  return email;
}

代码示例来源:origin: pl.edu.icm.yadda.repowebeditor/repository-web-editor-core

private boolean isCorrespondenceAuthor(YContributor personContributor, Set<String> affiliationNames){
    String correspondeceAff = personContributor.getOneAttributeSimpleValue(CommonAttributeTypes.AT_CORRESPONDENCE);
    return StringUtils.isNotBlank(correspondeceAff) && affiliationNames.contains(correspondeceAff);
  }
}

代码示例来源:origin: pl.edu.icm.yadda/yadda-analysis-impl

private static void proceedZblFingerPrint(YContributor yc,
    LinkedList<PredicateAndObject> pao) {
  //FIXME getOneAttributeSimpleValue może zwracać null; 
  //trzeba sprawdzić czy takie sytuacje się jescze zdarzają 
  //(czy istnieje ryzyko null pointer exceptiona)
  String zblfingerprint = yc.getOneAttributeSimpleValue(YConstants.AT_ZBL_AUTHOR_FINGERPRINT);
  if(zblfingerprint!=null && !zblfingerprint.isEmpty()){
    pao.add(new PredicateAndObject(RelConstants.RL_IS_PERSON, RelConstants.NS_ZBL_PERSON + zblfingerprint));
  }
}

代码示例来源:origin: pl.edu.icm.bwmeta/bwmeta-2-foreign-transformers

public void updateArticleInBookWithBookMeta(Element bmeta, final YElement article) {
  
  YDate date = article.getDate(DateTypes.DT_PUBLISHED);
  if (date == null) {
    updater.updateElementPubdate(bmeta, article);
  }
  
  boolean noPublisher = true;
  List<YContributor> yContributorList  = article.getContributors();
  List<YContributor> yPublisherList = new ArrayList<YContributor>();
   for (YContributor yContributor : yContributorList) {
     if (yContributor.getRole().equals(ContributorRoles.CR_PUBLISHER)) {
       yPublisherList.add(yContributor);
     }
   }
   if (!yPublisherList.isEmpty()) {
     String publisher = yPublisherList.get(0).getOneName(NameTypes.NM_CANONICAL).getText();
     String location = yPublisherList.get(0).getOneAttributeSimpleValue(NlmToYConstants.AT_PUBLISHER_LOCATION);
     if (publisher != null && location != null) {
       noPublisher = false;
     }
   }
   if (noPublisher) {
     updater.updateElementPublisher(bmeta, article);
   }
}

代码示例来源:origin: pl.edu.icm.synat/synat-process-common

final String email = contributor.getOneAttributeSimpleValue(CommonAttributeTypes.AT_CONTACT_EMAIL);
if (StringUtils.isNotBlank(email)) {
  final String newEmail = StringUtils.removePattern(email, "E[-]?mail:");

代码示例来源:origin: pl.edu.icm.yadda/yadda-client-common-api

private String getContributorLastName(final YContributor cont) {
  if (cont.getOneName(YConstants.NM_SURNAME) != null) {
    return cont.getOneName(YConstants.NM_SURNAME).getText();
  }
  final YAttribute person = cont.getOneAttribute(YConstants.AT_CONTRIBUTOR_PERSON);
  if (person != null) {
    return person.getOneAttributeSimpleValue(YConstants.AT_CONTRIBUTOR_PERSON_LASTNAME);
  } else {
    return cont.getOneAttributeSimpleValue(YConstants.AT_CONTRIBUTOR_PERSON_LASTNAME);
  }
}

代码示例来源:origin: pl.edu.icm.yadda/yadda-client-common-api

private String getContributorFirstName(final YContributor cont) {
  if (cont.getOneName(YConstants.NM_FORENAMES) != null) {
    return cont.getOneName(YConstants.NM_FORENAMES).getText();
  }
  final YAttribute person = cont.getOneAttribute(YConstants.AT_CONTRIBUTOR_PERSON);
  if (person != null) {
    return person.getOneAttributeSimpleValue(YConstants.AT_CONTRIBUTOR_PERSON_FIRSTNAME);
  } else {
    return cont.getOneAttributeSimpleValue(YConstants.AT_CONTRIBUTOR_PERSON_FIRSTNAME);
  }
}

代码示例来源:origin: pl.edu.icm.yadda/yadda-analysis-impl

String zblfingerprint = yc.getOneAttributeSimpleValue(YConstants.AT_ZBL_AUTHOR_FINGERPRINT);
if(zblfingerprint!=null && !zblfingerprint.isEmpty()){
  pao.add(new PredicateAndObject(RelConstants.RL_IS_PERSON, RelConstants.NS_ZBL_PERSON + zblfingerprint));

代码示例来源:origin: pl.edu.icm.synat/synat-business-services-api

/**
 * Creates PublisherData using YElement
 *
 * @param yElement
 *            metadata element used to create object
 */
public PublisherData createPublisherData(YContributor contributor) {
  PublisherData pd = new PublisherData();
  populateBaseProperties(contributor, pd);
  if (contributor.getOneAttribute(CommonAttributeTypes.AT_CONTACT_URL) != null) {
    pd.setUrl(contributor.getOneAttribute(CommonAttributeTypes.AT_CONTACT_URL).getValue());
  }
  final String email = contributor.getOneAttributeSimpleValue(CommonAttributeTypes.AT_CONTACT_EMAIL);
  if (StringUtils.isNotBlank(email)) {
    pd.setEmail(email);
  }
  return pd;
}

代码示例来源:origin: pl.edu.icm.synat/synat-portal-core

final String email = contributor.getOneAttributeSimpleValue(CommonAttributeTypes.AT_CONTACT_EMAIL);
final ContributorData personData; 
if(StringUtils.isNotBlank(canonicalName)){

代码示例来源:origin: pl.edu.icm.yadda.repowebeditor/repository-web-editor-core

private PersonInfo transformToPersonInfo(YContributor personContributor, Set<String> affiliationNames) {
  String canonical = nameExtractor.getCanonicalName(personContributor);
  String forenames = nameExtractor.getForenames(personContributor);
  String surname = nameExtractor.getSurname(personContributor);
  String email = personContributor.getOneAttributeSimpleValue(AttributeConstants.CONTACT_EMAIL);
  Boolean isCorrespondenceAuthor = isCorrespondenceAuthor(personContributor, affiliationNames);
  PersonInfo personInfo = new PersonInfo.Builder(canonical)
      .forenames(forenames)
      .surname(surname)
      .affiliationNames(affiliationNames)
      .email(email)
      .correspondingAuthor(isCorrespondenceAuthor)
      .build();
  return personInfo;
}

29 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com