当前位置: 首页>>代码示例>>Java>>正文


Java ResolvedConceptReference.getCodingSchemeName方法代码示例

本文整理汇总了Java中org.LexGrid.LexBIG.DataModel.Core.ResolvedConceptReference.getCodingSchemeName方法的典型用法代码示例。如果您正苦于以下问题:Java ResolvedConceptReference.getCodingSchemeName方法的具体用法?Java ResolvedConceptReference.getCodingSchemeName怎么用?Java ResolvedConceptReference.getCodingSchemeName使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在org.LexGrid.LexBIG.DataModel.Core.ResolvedConceptReference的用法示例。


在下文中一共展示了ResolvedConceptReference.getCodingSchemeName方法的6个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: activeCacheTree

import org.LexGrid.LexBIG.DataModel.Core.ResolvedConceptReference; //导入方法依赖的package包/类
public void activeCacheTree(ResolvedConceptReference ref) {
     _logger.debug("Actively caching tree.");

     String codingScheme = ref.getCodingSchemeName();
     String codingSchemeVersion = ref.getCodingSchemeVersion();
     String code = ref.getCode();

     if (!CacheController.getInstance()
         .containsKey(getTreeKey(codingScheme, code))) {
         _logger.debug("Tree Not Found In Cache.");
         TreeService treeService =
             TreeServiceFactory.getInstance().getTreeService(
                 RemoteServerUtil.createLexBIGService());

         //LexEvsTree tree = treeService.getTree(codingScheme, null, code);
         CodingSchemeVersionOrTag versionOrTag = new CodingSchemeVersionOrTag();
         if (codingSchemeVersion != null) {
	versionOrTag.setVersion(codingSchemeVersion);
}
         LexEvsTree tree = treeService.getTree(codingScheme, versionOrTag, code);
         if (tree == null) return;
         String json =
             treeService.getJsonConverter().buildJsonPathFromRootTree(
                 tree.getCurrentFocus());

        // _cache.put(new Element(getTreeKey(tree), json));
        String treeKey = getTreeKey(tree, codingSchemeVersion);
        //if (treeKey == null) return;

        _cache.put(new Element(treeKey, json));
     }
 }
 
开发者ID:NCIP,项目名称:nci-term-browser,代码行数:33,代码来源:CacheController.java

示例2: getParentConcepts

import org.LexGrid.LexBIG.DataModel.Core.ResolvedConceptReference; //导入方法依赖的package包/类
/**
 * Returns list of Parent Concepts
 * @param ref
 * @return
 * @throws LBException
 */
public Vector<Entity> getParentConcepts(ResolvedConceptReference ref) throws Exception {
    String scheme = ref.getCodingSchemeName();
    String version = ref.getCodingSchemeVersion();
    String code = ref.getCode();
    Direction dir = getCodingSchemeDirection(ref);
    Vector<String> assoNames = getAssociationNames(scheme, version);
    Vector<Entity> superconcepts = getAssociatedConcepts(scheme, version,
            code, assoNames, dir.test());
    return superconcepts;
}
 
开发者ID:NCIP,项目名称:nci-term-browser,代码行数:17,代码来源:CartActionBean.java

示例3: getChildConcepts

import org.LexGrid.LexBIG.DataModel.Core.ResolvedConceptReference; //导入方法依赖的package包/类
/**
 * Returns list of Child Concepts
 * @param ref
 * @return
 */
public Vector<Entity> getChildConcepts(ResolvedConceptReference ref) throws Exception {
    String scheme = ref.getCodingSchemeName();
    String version = ref.getCodingSchemeVersion();
    String code = ref.getCode();
    Direction dir = getCodingSchemeDirection(ref);
    Vector<String> assoNames = getAssociationNames(scheme, version);
    Vector<Entity> supconcepts = getAssociatedConcepts(scheme, version,
            code, assoNames, !dir.test());
    return supconcepts;
}
 
开发者ID:NCIP,项目名称:nci-term-browser,代码行数:16,代码来源:CartActionBean.java

示例4: resolveOneHit

import org.LexGrid.LexBIG.DataModel.Core.ResolvedConceptReference; //导入方法依赖的package包/类
protected List<? extends ResolvedConceptReference> resolveOneHit(ResolvedConceptReference hit) throws LBException{
	List<ResolvedConceptReference> returnList = new ArrayList<ResolvedConceptReference>();

	CodingSchemeVersionOrTag tagOrVersion = new CodingSchemeVersionOrTag();
	if (hit.getCodingSchemeVersion() != null) tagOrVersion.setVersion(hit.getCodingSchemeVersion());

          CodedNodeGraph cng = null;

          if (lbSvc == null) {
		return null;
	}


		cng = lbSvc.getNodeGraph(
			hit.getCodingSchemeName(),
			tagOrVersion,
			null);

          Boolean restrictToAnonymous = Boolean.FALSE;
          cng = cng.restrictToAnonymous(restrictToAnonymous);

          LocalNameList localNameList = new LocalNameList();
          localNameList.addEntry("concept");

          cng = cng.restrictToEntityTypes(localNameList);


	if (_associationNameAndValueList != null) {
		cng =
			cng.restrictToAssociations(
				_associationNameAndValueList,
				_associationQualifierNameAndValueList);
	}

	else {
		String scheme = hit.getCodingSchemeName();
		SimpleDataUtils simpleDataUtils = new SimpleDataUtils(lbSvc);
		boolean isMapping = simpleDataUtils.isMapping(scheme, null);
		if (isMapping) {
			NameAndValueList navl = simpleDataUtils.getMappingAssociationNames(scheme, null);
			if (navl != null) {
				cng = cng.restrictToAssociations(navl, null);
			}
		}
	}

	ConceptReference focus = new ConceptReference();
	focus.setCode(hit.getCode());

	focus.setCodingSchemeName(hit.getCodingSchemeName());
	focus.setCodeNamespace(hit.getCodeNamespace());

	LocalNameList propertyNames = new LocalNameList();
	CodedNodeSet.PropertyType[] propertyTypes = null;
	SortOptionList sortCriteria = null;

	ResolvedConceptReferenceList list =
		cng.resolveAsList(focus,
			_resolveForward, _resolveBackward, 0,
			_resolveAssociationDepth, propertyNames, propertyTypes, sortCriteria,
			_maxToReturn);

	for(ResolvedConceptReference ref : list.getResolvedConceptReference()){
		if (ref.getSourceOf() != null && this.getAssociations(ref.getSourceOf()).size() > 0) {
			returnList.addAll(this.getAssociations(ref.getSourceOf()));
		}

		//if(ref.getSourceOf() != null){
		//	returnList.addAll(this.getAssociations(ref.getSourceOf()));
		//}

		if (ref.getTargetOf() != null && this.getAssociations(ref.getTargetOf()).size() > 0) {
			returnList.addAll(this.getAssociations(ref.getTargetOf()));
		}
		//if(ref.getTargetOf() != null){
			//returnList.addAll(this.getAssociations(ref.getTargetOf()));
		//}
	}
	return returnList;
}
 
开发者ID:NCIP,项目名称:nci-term-browser,代码行数:81,代码来源:SearchByAssociationIteratorDecorator.java

示例5: extract

import org.LexGrid.LexBIG.DataModel.Core.ResolvedConceptReference; //导入方法依赖的package包/类
@Override
public String extract(ResolvedConceptReference ref) {
	return ref.getCodingSchemeName();
}
 
开发者ID:NCIP,项目名称:lexevs-service,代码行数:5,代码来源:MappingExtensionBulkDownloader.java

示例6: resolveOneHit

import org.LexGrid.LexBIG.DataModel.Core.ResolvedConceptReference; //导入方法依赖的package包/类
protected List<? extends ResolvedConceptReference> resolveOneHit(ResolvedConceptReference hit) throws LBException{
	List<ResolvedConceptReference> returnList = new ArrayList<ResolvedConceptReference>();

	CodingSchemeVersionOrTag tagOrVersion = new CodingSchemeVersionOrTag();
	if (hit.getCodingSchemeVersion() != null) tagOrVersion.setVersion(hit.getCodingSchemeVersion());

          CodedNodeGraph cng = null;
		cng = lbs.getNodeGraph(
			hit.getCodingSchemeName(),
			tagOrVersion,
			null);

          Boolean restrictToAnonymous = Boolean.FALSE;
          cng = cng.restrictToAnonymous(restrictToAnonymous);

          LocalNameList localNameList = new LocalNameList();
          localNameList.addEntry("concept");

          cng = cng.restrictToEntityTypes(localNameList);


	if (_associationNameAndValueList != null) {
		cng =
			cng.restrictToAssociations(
				_associationNameAndValueList,
				_associationQualifierNameAndValueList);
	}

	else {
		String scheme = hit.getCodingSchemeName();
		boolean isMapping = DataUtils.isMapping(scheme, null);
		if (isMapping) {
			NameAndValueList navl = DataUtils.getMappingAssociationNames(scheme, null);
			if (navl != null) {
				cng = cng.restrictToAssociations(navl, null);
			}
		}
	}

	ConceptReference focus = new ConceptReference();
	focus.setCode(hit.getCode());
	focus.setCodingSchemeName(hit.getCodingSchemeName());
	focus.setCodeNamespace(hit.getCodeNamespace());

	LocalNameList propertyNames = new LocalNameList();
	CodedNodeSet.PropertyType[] propertyTypes = null;
	SortOptionList sortCriteria = null;

	ResolvedConceptReferenceList list =
		cng.resolveAsList(focus,
			_resolveForward, _resolveBackward, 0,
			_resolveAssociationDepth, propertyNames, propertyTypes, sortCriteria,
			_maxToReturn);

	for(ResolvedConceptReference ref : list.getResolvedConceptReference()){
		if(ref.getSourceOf() != null){
			returnList.addAll(this.getAssociations(ref.getSourceOf()));
		}
		if(ref.getTargetOf() != null){
			returnList.addAll(this.getAssociations(ref.getTargetOf()));
		}
	}
	return returnList;
}
 
开发者ID:NCIP,项目名称:nci-mapping-tool,代码行数:65,代码来源:SearchByAssociationIteratorDecorator.java


注:本文中的org.LexGrid.LexBIG.DataModel.Core.ResolvedConceptReference.getCodingSchemeName方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。