本文整理汇总了Java中org.opencds.cqf.cql.terminology.CodeSystemInfo类的典型用法代码示例。如果您正苦于以下问题:Java CodeSystemInfo类的具体用法?Java CodeSystemInfo怎么用?Java CodeSystemInfo使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。
CodeSystemInfo类属于org.opencds.cqf.cql.terminology包,在下文中一共展示了CodeSystemInfo类的6个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: lookup
import org.opencds.cqf.cql.terminology.CodeSystemInfo; //导入依赖的package包/类
@Override
public Code lookup(Code code, CodeSystemInfo codeSystem) throws ResourceNotFoundException {
// TODO: Implement as CodeSystem/$lookup
// http://hl7.org/fhir/2016Sep/codesystem-operations.html#lookup
Parameters respParam = fhirClient
.operation()
.onType(CodeSystem.class)
.named("lookup")
.withParameter(Parameters.class, "code", new CodeType(code.getCode()))
.andParameter("system", new UriType(codeSystem.getId()))
.execute();
return code.withSystem(codeSystem.getId())
.withDisplay(((StringType)respParam.getParameter().get(1).getValue()).getValue());
}
示例2: inCodeSystem
import org.opencds.cqf.cql.terminology.CodeSystemInfo; //导入依赖的package包/类
public Object inCodeSystem(Context context, Object code, Object codeSystem) {
if (code == null) {
return null;
}
CodeSystemDef csd = resolveCSR(context, (CodeSystemRef)codeSystem);
CodeSystemInfo csi = new CodeSystemInfo().withId(csd.getId()).withVersion(csd.getVersion());
TerminologyProvider provider = context.resolveTerminologyProvider();
if (code instanceof String) {
return provider.lookup(new Code().withCode((String) code), csi) != null;
}
else if (code instanceof Code) {
return provider.lookup((Code) code, csi) != null;
}
else if (code instanceof Concept) {
for (Code codes : ((Concept)code).getCodes()) {
if (provider.lookup(codes, csi) != null) {
return true;
}
}
return false;
}
throw new IllegalArgumentException(String.format("Cannot InCodeSystem Code arguments of type '%s'.", code.getClass().getName()));
}
示例3: lookup
import org.opencds.cqf.cql.terminology.CodeSystemInfo; //导入依赖的package包/类
@Override
public Code lookup(Code code, CodeSystemInfo codeSystem) throws ResourceNotFoundException {
CodeSystem cs = codeSystemProvider.getDao().read(new IdType(codeSystem.getId()));
for (CodeSystem.ConceptDefinitionComponent concept : cs.getConcept()) {
if (concept.getCode().equals(code.getCode()))
return code.withSystem(codeSystem.getId()).withDisplay(concept.getDisplay());
}
return code;
}
示例4: lookup
import org.opencds.cqf.cql.terminology.CodeSystemInfo; //导入依赖的package包/类
@Override
public org.opencds.cqf.cql.runtime.Code lookup(
org.opencds.cqf.cql.runtime.Code code, CodeSystemInfo codeSystem) {
throw new UnsupportedOperationException();
}
开发者ID:Discovery-Research-Network-SCCM,项目名称:FHIR-CQL-ODM-service,代码行数:6,代码来源:TestTerminologyProvider.java
示例5: evaluate
import org.opencds.cqf.cql.terminology.CodeSystemInfo; //导入依赖的package包/类
@Override
public Object evaluate(Context context) {
return new CodeSystemInfo().withId(getId()).withVersion(getVersion());
}
示例6: evaluate
import org.opencds.cqf.cql.terminology.CodeSystemInfo; //导入依赖的package包/类
@Override
public Object evaluate(Context context) {
CodeSystemInfo info = (CodeSystemInfo) getCodeSystem().evaluate(context);
return new Code().withCode(this.getId()).withSystem(info.getId());
}