- 使用 Spring Initializr 创建 Spring Boot 应用程序
- 在Spring Boot中配置Cassandra
- 在 Spring Boot 上配置 Tomcat 连接池
- 将Camel消息路由到嵌入WildFly的Artemis上
本文整理了Java中pl.edu.icm.model.bwmeta.y.YElement
类的一些代码示例,展示了YElement
类的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。YElement
类的具体详情如下:
包路径:pl.edu.icm.model.bwmeta.y.YElement
类名称:YElement
暂无
代码示例来源:origin: pl.edu.icm.bwmeta/bwmeta-2-foreign-transformers
private YElement buildVolumeElementFromSeries(ProceedingsSeriesMetadata proceedingsSeriesMetadata, YElement parent, CrossrefIdGenerator generator) {
YElement bookVolumeElement = new YElement();
bookVolumeElement.addStructure(buildStructureFromParent(parent, HierarchyWithLevelIds.EXT_HIERARCHY_BOOK, HierarchyWithLevelIds.EXT_LEVEL_BOOK_VOLUME));
bookVolumeElement.addName(new YName(proceedingsSeriesMetadata.getVolume()));
String id = generator.generateBookVolumeId(parent.getId(), proceedingsSeriesMetadata.getVolume());
bookVolumeElement.setId(id);
return bookVolumeElement;
}
代码示例来源:origin: pl.edu.icm.yadda/bwmeta-import
private void updateVolume(ZentralBlattSoFieldParser.SoFieldData soData) {
if (soData.volume != null && soData.volume.length() > 0) {
YAncestor ancestor = new YAncestor(YConstants.EXT_LEVEL_JOURNAL_VOLUME); // TODO
// UID?
YName volumeName = new YName(soData.volume);
yVolume.addName(volumeName);
ancestor.setIdentity(yVolume.getId());
ancestor.addName(volumeName);
yIssue.getStructure(YConstants.EXT_HIERARCHY_JOURNAL).addAncestor(ancestor);
yArticle.getStructure(YConstants.EXT_HIERARCHY_JOURNAL).addAncestor(ancestor);
}
}
代码示例来源:origin: pl.edu.icm.yadda/yadda-analysis-impl
@Override
public void store(EnrichedPayload<YElement>[] data, ProcessContext ctx)
throws Exception {
for(EnrichedPayload<YElement> enrichedP : data){
log.info("----------------------\n" +
"Element Id:" + enrichedP.getObject().getId() + "\n" +
"Element Name:" + enrichedP.getObject().getNames().get(0) + "\n" +
"Element Structures:" + enrichedP.getObject().getStructures() + "\n");
}
}
代码示例来源:origin: pl.edu.icm.yadda/yadda-analysis-impl
private static void updateYElementTagsWithZblTags(YElement ye, YElement zblye) {
for (YTagList tl : zblye.getTagLists())
ye.addTagList(tl);
}
代码示例来源:origin: pl.edu.icm.yadda/yadda-analysis-impl
private static void updateYElementIdsWithZblIds(YElement ye, YElement zblye) {
for (YId i : zblye.getIds())
if (ye.getId(i.getScheme()) == null)
ye.addId(i);
}
代码示例来源:origin: pl.edu.icm.synat/synat-process-common
/**
* Modifies input {@code element} {@code YElement} if {@code enrichedYElement} {@code YElement}
* is enriched. The {@code YTagList} with {@code TagTypes.TG_KEYWORD}.
* The {@code maxKeywords} is used to estimate {@code YTagList} {@code YTagList#getValues()} amount.
* @param element, will be updated with classification.
* @param enrichedYElement, should has classification.
* @return {@code true} if meta data was modify
* {@code false} otherwise.
*/
protected boolean modifyIfNeeded(YElement element, final YElement enrichedYElement) {
if ( ! enrichedYElement.getTagLists(TG_SONCA_KEYWORDS).isEmpty()) {
prepareKeywords(enrichedYElement, TG_SONCA_KEYWORDS, element, TagTypes.TG_KEYWORD);
element.addAttribute(AT_CLASSIFICATION_OECD_BY, "Sonca");
return true;
}
return false;
}
代码示例来源:origin: pl.edu.icm.bwmeta/bwmeta-2-foreign-transformers
private YElement buildBookFromBookMetadata(BookMetadata bookMetadata, YElement parent, CrossrefIdGenerator generator) {
YElement bookElement = new YElement();
bookElement.addStructure(buildStructureFromParent(parent, HierarchyWithLevelIds.EXT_HIERARCHY_BOOK, HierarchyWithLevelIds.EXT_LEVEL_BOOK_BOOK));
bookElement.getNames().addAll(convertTitles(bookMetadata.getTitles()));
bookElement.getContributors().addAll(convert(bookMetadata.getContributors(), bookElement));
bookElement.getDates().addAll(convertDates(bookMetadata.getPublicationDates()));
bookElement.getRelations().addAll(convertCitationList(bookMetadata.getCitationList()));
bookElement.getIds().addAll(convertIsbns(bookMetadata.getIsbns()));
if (bookMetadata.getDoiData() != null) {
bookElement.getIds().add(new YId(IdSchemaIds.EXT_SCHEME_DOI, bookMetadata.getDoiData().getDoi()));
}
String id = generator.generateBookId(bookElement.getFirstIdOrNullIfAny(IdSchemaIds.EXT_SCHEME_DOI),
bookElement.getFirstIdOrNullIfAny(IdSchemaIds.EXT_SCHEME_ISBN), bookElement.getFirstIdOrNullIfAny(IdSchemaIds.EXT_SCHEME_EISBN),
getDefaultName(bookElement));
bookElement.setId(id);
return bookElement;
}
代码示例来源:origin: pl.edu.icm.synat/synat-importer-yadda
private YElement prepareYElement(String id, Properties prop) {
YElement yElement = new YElement();
yElement.setId(id);
if (!prop.getProperty("title").isEmpty()) {
yElement.addName(new YName(prepareProperty("title", prop)));
}
yElement.addDescription(new YDescription(YLanguage.Undetermined, prepareProperty("description", prop), DescriptionTypes.DS_SUMMARY));
if (!prop.getProperty("key-words").isEmpty()) {
List<String> tags = new ArrayList<String>(Arrays.asList(prepareProperty("key-words", prop).split(",")));
yElement.addTagList(new YTagList().setType(TagTypes.TG_KEYWORD).setValues(tags));
}
if (!prop.getProperty("supplier").isEmpty()) {
yElement.addAttribute("copyright-holder", prepareProperty("supplier", prop));
}
if (!prop.getProperty("duration").isEmpty()) {
yElement.addAttribute("duration", prepareProperty("duration", prop));
}
yElement.addLanguage(YLanguage.Undetermined);
return yElement;
}
代码示例来源:origin: pl.edu.icm.bwmeta/bwmeta-2-foreign-transformers
@Override
public YElement process(Book book, YElement parent, CrossrefIdGenerator generator) {
BookSetMetadata bookSetMetadata = book.getBookSetMetadata();
YElement element = new YElement();
SetMetadata setMetadata = bookSetMetadata.getSetMetadata();
List<YName> setNames = convertTitles(setMetadata.getTitles());
element.getIds().addAll(convertIsbns(setMetadata.getIsbns()));
element.getNames().addAll(setNames);
String id = generator.generateBookSetId(element.getFirstIdOrNullIfAny(IdSchemaIds.EXT_SCHEME_ISBN), getDefaultName(element));
element.setId(id);
element.addStructure(buildStructureFromParent(parent, HierarchyWithLevelIds.EXT_HIERARCHY_BOOK, HierarchyWithLevelIds.EXT_LEVEL_BOOK_SERIES));
if (StringUtils.isNotBlank(bookSetMetadata.getLanguage())) {
element.addLanguage(YLanguage.byCode(bookSetMetadata.getLanguage()));
}
return element;
}
代码示例来源:origin: pl.edu.icm.synat/synat-importer-direct
public static void copyDataToAncestor(YElement ele, YAncestor anc) {
anc.getNames().addAll(ele.getNames());
anc.getIds().addAll(ele.getIds());
anc.getDates().addAll(ele.getDates());
anc.setIdentity(ele.getId());
}
代码示例来源:origin: pl.edu.icm.synat/synat-portal-core
public static YContributor getContributor(YElement element, final String requestPersonId) {
for(YContributor contributor:element.getContributors()){
String personId = BwmetaContributorUtils.buildContributorId(element.getId(), contributor);
if(personId.equals(requestPersonId)){
return contributor;
}
}
throw new NotFoundException(requestPersonId);
}
代码示例来源:origin: pl.edu.icm.bwmeta/bwmeta-2-foreign-transformers
private YElement buildBookSeriesElement(SeriesMetadata seriesMetadata, YElement conferenceEventElement, CrossrefIdGenerator generator) {
YElement element = new YElement();
extractSeriesMetadata(null, generator, element, seriesMetadata);
YRelation proceedingsRelation = new YRelation(RelationTypes.RL_PROCEEDINGS_OF, new YId(StringUtils.EMPTY, conferenceEventElement.getId()));
element.getRelations().add(proceedingsRelation);
return element;
}
代码示例来源:origin: pl.edu.icm.bwmeta/bwmeta-2-foreign-transformers
articleIdPublisher=JDOMHelper.getChild(ameta, "article-id");
idValue = getIdGenerator().getArticleId(null, articleIdDoi==null?null:articleIdDoi.getValue(), articleIdPublisher==null?null:articleIdPublisher.getValue(), articleId==null?null:articleId.getValue(), parent==null?null:parent.getId());
} catch (NullPointerException ex) {
log.error("Missing eudml-id for article: " + atitle.getValue());
article.addDescription(y.description(JDOMHelper.getYLang(aabstract), JDOMHelper.textOfElement(aabstract), DS_ABSTRACT));
article.addLanguage(JDOMHelper.getYLang(ameta));
article.addName(y.name(JDOMHelper.getYLang(tr), JDOMHelper.textOfElement(JDOMHelper.getChild(tr, "trans-title")),NameTypes.NM_CANONICAL));
article.addDescription(y.description(JDOMHelper.getYLang(tr), JDOMHelper.textOfElement(tr), "trans-abstract"));
代码示例来源:origin: pl.edu.icm.synat/synat-business-services-api
@Override
public boolean isContentAvailable(YElement yElement) {
String mainLevel = fetchCurrentStructureLevel(yElement);
if (yElement.getContents() != null && !yElement.getContents().isEmpty()) {
return checkContentAvailable(yElement.getContents(), mainLevel);
}
return false;
}
代码示例来源:origin: pl.edu.icm.synat/synat-portal-core
private YAncestor getAncestor(YElement element, String hierarchy, String level) {
YStructure structure = element.getStructure(hierarchy);
if(structure == null){
return null;
}
YAncestor ancestor = structure.getAncestor(level);
return ancestor;
}
代码示例来源:origin: pl.edu.icm.yadda/yaddaweb-lite-core
@Deprecated
private String getPosition(YElement element) {
String position = null;
for(YStructure structure : element.getStructures()) {
YCurrent current = structure.getCurrent();
position = current.getPosition();
if(position != null) {
break;
}
}
return position;
}
代码示例来源:origin: pl.edu.icm.synat/synat-portal-core
public void exposeContentDetails(YElement yElement, Model model) {
model.addAttribute(HAS_CONTENT_RENDERABLE_PARTS, resourceDisplayUtils.hasRenderableParts(yElement));
if (yElement.getStructure(HierarchyWithLevelIds.EXT_HIERARCHY_BOOK) != null
&& yElement.getStructure(HierarchyWithLevelIds.EXT_HIERARCHY_BOOK).getCurrent() != null) {
model.addAttribute(
HAS_CONTENT_CHAPTERS_PARTS,
relatedDisplayUtils.verifyIfIsSomeoneAncestor(yElement.getId(), yElement.getStructure(HierarchyWithLevelIds.EXT_HIERARCHY_BOOK)
.getCurrent().getLevel()));
} else {
model.addAttribute(HAS_CONTENT_CHAPTERS_PARTS, false);
}
}
代码示例来源:origin: pl.edu.icm.synat/synat-importer-speech-to-text
private void prepareYElementFromApi(Video video, YElement yElement) throws ParseException {
yElement.addName(new YName(video.getSnippet().getTitle()));
yElement.addDescription(new YDescription(YLanguage.Undetermined, video.getSnippet().getDescription()
, DescriptionTypes.DS_SUMMARY));
prepareDate(video, yElement);
String license = video.getStatus().getLicense();
if(null != license && license.contains("creativeCommon")) {
yElement.addTagList(new YTagList().setType(YModelUtils.LICENSE).addValue("cc0"));
}
prepareContent(video, yElement);
List<String> tags = video.getSnippet().getTags();
if (CollectionUtils.isNotEmpty(tags)) {
yElement.addTagList(new YTagList().setType(TagTypes.TG_KEYWORD).setValues(tags));
}
YCurrent currentLevel = new YCurrent().setLevel(VideoConstants.VIDEO_CURRENT_LEVEL);
yElement.addStructure(new YStructure()
.setHierarchy(HierarchyWithLevelIds.EXT_HIERARCHY_PUBLICATION)
.setCurrent(currentLevel));
prepareAttributes(video, yElement);
}
代码示例来源:origin: pl.edu.icm.yadda/yaddaweb-lite-core
protected IViewBuilder<CatalogInformationEnhancedObject<YExportable>> resolveElement(YElement e,
Map<String, Object> parameters) {
for (YStructure level : e.getStructures()) {
final String levelId = level.getCurrent().getLevel();
if (elementViewBuilders.containsKey(levelId)) {
return elementViewBuilders.get(levelId);
}
}
throw new SystemException(Modules.DETAILS, "View for BWMETA1 element " + e.getId() + " not found");
}
代码示例来源:origin: pl.edu.icm.bwmeta/bwmeta-2-foreign-transformers
protected void fillIdentifiers(YElement yElement, List<YExportable> referedElements, Map<String, List<StringWithAttributes>> ret) {
// identifier element
ret.put(E_IDENTIFIER, new ArrayList<StringWithAttributes>());
ret.get(E_IDENTIFIER).add(new StringWithAttributes(yElement.getId()));
for (YId yId : yElement.getIds()) {
StringWithAttributes id = new StringWithAttributes(yId.getValue());
id.getAttributes().put("scheme", yId.getScheme());
ret.get(E_IDENTIFIER).add(id);
}
}
本文整理了Java中pl.edu.icm.model.bwmeta.YElement类的一些代码示例,展示了YElement类的具体用法。这些代码示例主要来源于Github/Stackoverflow
本文整理了Java中pl.edu.icm.model.bwmeta.YContributor类的一些代码示例,展示了YContributor类的具体用法。这些代码示例主要来源于Github/Stack
本文整理了Java中pl.edu.icm.model.bwmeta.y.YContentFile类的一些代码示例,展示了YContentFile类的具体用法。这些代码示例主要来源于Github/Sta
本文整理了Java中pl.edu.icm.model.bwmeta.y.YDescription类的一些代码示例,展示了YDescription类的具体用法。这些代码示例主要来源于Github/Sta
本文整理了Java中pl.edu.icm.model.bwmeta.y.YCurrent类的一些代码示例,展示了YCurrent类的具体用法。这些代码示例主要来源于Github/Stackoverfl
本文整理了Java中pl.edu.icm.model.bwmeta.y.YName类的一些代码示例,展示了YName类的具体用法。这些代码示例主要来源于Github/Stackoverflow/Mav
本文整理了Java中pl.edu.icm.model.bwmeta.y.YStructure类的一些代码示例,展示了YStructure类的具体用法。这些代码示例主要来源于Github/Stackov
本文整理了Java中pl.edu.icm.model.bwmeta.y.YElement类的一些代码示例,展示了YElement类的具体用法。这些代码示例主要来源于Github/Stackoverfl
本文整理了Java中pl.edu.icm.model.bwmeta.y.YCategoryRef类的一些代码示例,展示了YCategoryRef类的具体用法。这些代码示例主要来源于Github/Sta
本文整理了Java中pl.edu.icm.model.bwmeta.y.YContentDirectory类的一些代码示例,展示了YContentDirectory类的具体用法。这些代码示例主要来源于
本文整理了Java中pl.edu.icm.model.bwmeta.y.YContentEntry类的一些代码示例,展示了YContentEntry类的具体用法。这些代码示例主要来源于Github/S
本文整理了Java中pl.edu.icm.model.bwmeta.y.YId类的一些代码示例,展示了YId类的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平
本文整理了Java中pl.edu.icm.model.bwmeta.y.YRelation类的一些代码示例,展示了YRelation类的具体用法。这些代码示例主要来源于Github/Stackover
本文整理了Java中pl.edu.icm.model.bwmeta.y.YAncestor类的一些代码示例,展示了YAncestor类的具体用法。这些代码示例主要来源于Github/Stackover
本文整理了Java中pl.edu.icm.model.bwmeta.y.YAffiliation类的一些代码示例,展示了YAffiliation类的具体用法。这些代码示例主要来源于Github/Sta
本文整理了Java中pl.edu.icm.model.bwmeta.y.YDate类的一些代码示例,展示了YDate类的具体用法。这些代码示例主要来源于Github/Stackoverflow/Mav
本文整理了Java中pl.edu.icm.model.bwmeta.y.YLanguage类的一些代码示例,展示了YLanguage类的具体用法。这些代码示例主要来源于Github/Stackover
本文整理了Java中pl.edu.icm.model.bwmeta.y.YContributor类的一些代码示例,展示了YContributor类的具体用法。这些代码示例主要来源于Github/Sta
本文整理了Java中pl.edu.icm.model.bwmeta.y.YTagList类的一些代码示例,展示了YTagList类的具体用法。这些代码示例主要来源于Github/Stackoverfl
本文整理了Java中pl.edu.icm.model.bwmeta.y.YAttribute类的一些代码示例,展示了YAttribute类的具体用法。这些代码示例主要来源于Github/Stackov
我是一名优秀的程序员,十分优秀!