public TokenCriterion(String theParamName, List<BaseIdentifierDt> theValue) { myName=theParamName; StringBuilder b = new StringBuilder(); for (BaseIdentifierDt next : theValue) { if (next.getSystemElement().isEmpty() && next.getValueElement().isEmpty()) { continue; } if (b.length() > 0) { b.append(','); } b.append(toValue(next.getSystemElement().getValueAsString(), next.getValueElement().getValue())); } myValue = b.toString(); }
private void extractTokensFromCoding(List<String> theSystems, List<String> theCodes, ResourceTable theEntity, Set<BaseResourceIndexedSearchParam> theListToPopulate, RuntimeSearchParam theParameterDef, CodingDt nextCoding) { if (nextCoding != null && !nextCoding.isEmpty()) { String nextSystem = nextCoding.getSystemElement().getValueAsString(); String nextCode = nextCoding.getCodeElement().getValue(); if (isNotBlank(nextSystem) || isNotBlank(nextCode)) { theSystems.add(nextSystem); theCodes.add(nextCode); } if (!nextCoding.getDisplayElement().isEmpty()) { addStringParam(theEntity, theListToPopulate, theParameterDef, nextCoding.getDisplayElement().getValue()); } } }
@Override public String getValueAsQueryToken(FhirContext theContext) { StringBuilder b= new StringBuilder(); if (getComparatorElement() != null) { b.append(getComparatorElement().getValue()); } if (!getValueElement().isEmpty()) { b.append(getValueElement().getValueAsString()); } b.append('|'); if (!getSystemElement().isEmpty()) { b.append(getSystemElement().getValueAsString()); } b.append('|'); if (!getUnitsElement().isEmpty()) { b.append(getUnitsElement().getValueAsString()); } return b.toString(); }
} else if (nextObject instanceof CodeableConceptDt) { CodeableConceptDt nextCC = (CodeableConceptDt) nextObject; if (!nextCC.getTextElement().isEmpty()) { addStringParam(theEntity, retVal, nextSpDef, nextCC.getTextElement().getValue());
if (nextContact.getValueElement().isEmpty() == false) { addSearchTerm(theEntity, retVal, nextSpName, nextContact.getValue());
public TokenCriterion(String theParamName, List<BaseIdentifierDt> theValue) { myName=theParamName; StringBuilder b = new StringBuilder(); for (BaseIdentifierDt next : theValue) { if (next.getSystemElement().isEmpty() && next.getValueElement().isEmpty()) { continue; } if (b.length() > 0) { b.append(','); } b.append(toValue(next.getSystemElement().getValueAsString(), next.getValueElement().getValue())); } myValue = b.toString(); }
@Override public String getValueAsQueryToken(FhirContext theContext) { StringBuilder b= new StringBuilder(); if (getComparatorElement() != null) { b.append(getComparatorElement().getValue()); } if (!getValueElement().isEmpty()) { b.append(getValueElement().getValueAsString()); } b.append('|'); if (!getSystemElement().isEmpty()) { b.append(getSystemElement().getValueAsString()); } b.append('|'); if (!getUnitsElement().isEmpty()) { b.append(getUnitsElement().getValueAsString()); } return b.toString(); }
@Override public void addRootPropertiesToBundle(String theAuthor, String theServerBase, String theCompleteUrl, Integer theTotalResults, BundleTypeEnum theBundleType, IPrimitiveType<Date> theLastUpdated) { if (myBundle.getAuthorName().isEmpty()) { myBundle.getAuthorName().setValue(theAuthor); } if (theLastUpdated != null && myBundle.getUpdated().isEmpty() && isNotBlank(theLastUpdated.getValueAsString())) { myBundle.getUpdated().setValueAsString(theLastUpdated.getValueAsString()); } if (myBundle.getBundleId().isEmpty()) { myBundle.getBundleId().setValue(UUID.randomUUID().toString()); } if (myBundle.getLinkBase().isEmpty()) { myBundle.getLinkBase().setValue(theServerBase); } if (myBundle.getLinkSelf().isEmpty()) { myBundle.getLinkSelf().setValue(theCompleteUrl); } if (theBundleType != null && myBundle.getType().isEmpty()) { myBundle.getType().setValueAsString(theBundleType.getCode()); } if (myBundle.getTotalResults().isEmpty() && theTotalResults != null) { myBundle.getTotalResults().setValue(theTotalResults); } }