本文整理汇总了Java中org.LexGrid.LexBIG.DataModel.Core.ConceptReference.setCodingSchemeName方法的典型用法代码示例。如果您正苦于以下问题:Java ConceptReference.setCodingSchemeName方法的具体用法?Java ConceptReference.setCodingSchemeName怎么用?Java ConceptReference.setCodingSchemeName使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类org.LexGrid.LexBIG.DataModel.Core.ConceptReference
的用法示例。
在下文中一共展示了ConceptReference.setCodingSchemeName方法的8个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: createConceptReferenceList
import org.LexGrid.LexBIG.DataModel.Core.ConceptReference; //导入方法依赖的package包/类
public ConceptReferenceList createConceptReferenceList(
String[] codes, String codingSchemeName, String ns) {
if (codes == null) {
return null;
}
ConceptReferenceList list = new ConceptReferenceList();
for (int i = 0; i < codes.length; i++) {
ConceptReference cr = new ConceptReference();
cr.setCodingSchemeName(codingSchemeName);
cr.setConceptCode(codes[i]);
if (ns != null) {
cr.setCodeNamespace(ns);
}
list.addConceptReference(cr);
}
return list;
}
示例2: createConceptReferenceList
import org.LexGrid.LexBIG.DataModel.Core.ConceptReference; //导入方法依赖的package包/类
public static ConceptReferenceList createConceptReferenceList(String[] codes, String codingSchemeName)
{
if (codes == null)
{
return null;
}
ConceptReferenceList list = new ConceptReferenceList();
for (int i = 0; i < codes.length; i++)
{
ConceptReference cr = new ConceptReference();
cr.setCodingSchemeName(codingSchemeName);
cr.setConceptCode(codes[i]);
list.addConceptReference(cr);
}
return list;
}
示例3: createConceptReferenceList
import org.LexGrid.LexBIG.DataModel.Core.ConceptReference; //导入方法依赖的package包/类
/**
* @param codes
* @param codingSchemeName
* @return
*/
private ConceptReferenceList createConceptReferenceList(String[] codes,
String codingSchemeName) {
if (codes == null)
return null;
ConceptReferenceList list = new ConceptReferenceList();
for (int i = 0; i < codes.length; i++) {
ConceptReference cr = new ConceptReference();
cr.setCodingSchemeName(codingSchemeName);
cr.setConceptCode(codes[i]);
list.addConceptReference(cr);
}
return list;
}
示例4: createConceptReferenceList
import org.LexGrid.LexBIG.DataModel.Core.ConceptReference; //导入方法依赖的package包/类
public static ConceptReferenceList createConceptReferenceList(
Vector codes, String codingSchemeName) {
if (codes == null) {
return null;
}
ConceptReferenceList list = new ConceptReferenceList();
for (int i = 0; i < codes.size(); i++) {
String code = (String) codes.elementAt(i);
ConceptReference cr = new ConceptReference();
if (codingSchemeName != null) cr.setCodingSchemeName(codingSchemeName);
cr.setConceptCode(code);
list.addConceptReference(cr);
}
return list;
}
示例5: createConceptReferenceList
import org.LexGrid.LexBIG.DataModel.Core.ConceptReference; //导入方法依赖的package包/类
public ConceptReferenceList createConceptReferenceList(
String[] codes, String codingSchemeName) {
if (codes == null) {
return null;
}
ConceptReferenceList list = new ConceptReferenceList();
for (int i = 0; i < codes.length; i++) {
ConceptReference cr = new ConceptReference();
cr.setCodingSchemeName(codingSchemeName);
cr.setConceptCode(codes[i]);
list.addConceptReference(cr);
}
return list;
}
示例6: isCodeInValueSet
import org.LexGrid.LexBIG.DataModel.Core.ConceptReference; //导入方法依赖的package包/类
public static Boolean isCodeInValueSet(String code, String codingScheme, String vsd_uri) {
try {
String URL = "http://ncias-q541-v.nci.nih.gov:29080/lexevsapi60";
URL = "http://localhost:19280/lexevsapi60";
LexEVSDistributed distributed =
(LexEVSDistributed)
ApplicationServiceProvider.getApplicationServiceFromUrl(URL, "EvsServiceInfo");
LexEVSValueSetDefinitionServices vds = distributed.getLexEVSValueSetDefinitionServices();
java.lang.String valueSetDefinitionRevisionId = null;
AbsoluteCodingSchemeVersionReferenceList csVersionList = getEntireAbsoluteCodingSchemeVersionReferenceList();
java.lang.String csVersionTag = null;
ResolvedValueSetCodedNodeSet rvs_cns = vds.getCodedNodeSetForValueSetDefinition(
new URI(vsd_uri),
valueSetDefinitionRevisionId,
csVersionList,
csVersionTag);
if (rvs_cns == null) return false;
CodedNodeSet cns = rvs_cns.getCodedNodeSet();
ConceptReference conceptReference = new ConceptReference();
conceptReference.setConceptCode(code);
if (codingScheme != null) {
conceptReference.setCodingSchemeName(codingScheme);
}
java.lang.Boolean bool_obj = cns.isCodeInSet(conceptReference);
return bool_obj;
} catch (Exception ex) {
ex.printStackTrace();
}
Boolean retval = null;
return retval;
}
示例7: resolveOneHit
import org.LexGrid.LexBIG.DataModel.Core.ConceptReference; //导入方法依赖的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;
}
示例8: resolveOneHit
import org.LexGrid.LexBIG.DataModel.Core.ConceptReference; //导入方法依赖的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;
}