@Override public void setValuesAsQueryTokens(FhirContext theContext, String theParamName, List<QualifiedParamList> theParameters) throws InvalidRequestException { myValues.clear(); for (QualifiedParamList nextParam : theParameters) { T nextList = newInstance(); nextList.setValuesAsQueryTokens(theContext, theParamName, nextParam); myValues.add(nextList); } }
@Override public IQueryParameterOr<?> parse(FhirContext theContext, String theParamName, List<QualifiedParamList> theString) throws InternalErrorException, InvalidRequestException { IQueryParameterOr<?> dt; try { dt = newInstance(); if (theString.size() == 0 || theString.get(0).size() == 0) { return dt; } if (theString.size() > 1) { throw new InvalidRequestException("Multiple values detected for non-repeatable parameter '" + theParamName + "'. This server is not configured to allow multiple (AND/OR) values for this param."); } dt.setValuesAsQueryTokens(theContext, theParamName, theString.get(0)); } catch (SecurityException e) { throw new InternalErrorException(e); } return dt; } }
@Override public void setValuesAsQueryTokens(FhirContext theContext, String theParamName, List<QualifiedParamList> theParameters) throws InvalidRequestException { myValues.clear(); for (QualifiedParamList nextParam : theParameters) { T nextList = newInstance(); nextList.setValuesAsQueryTokens(theContext, theParamName, nextParam); myValues.add(nextList); } }
@Override public IQueryParameterOr<?> parse(FhirContext theContext, String theParamName, List<QualifiedParamList> theString) throws InternalErrorException, InvalidRequestException { IQueryParameterOr<?> dt; try { dt = newInstance(); if (theString.size() == 0 || theString.get(0).size() == 0) { return dt; } if (theString.size() > 1) { throw new InvalidRequestException("Multiple values detected for non-repeatable parameter '" + theParamName + "'. This server is not configured to allow multiple (AND/OR) values for this param."); } dt.setValuesAsQueryTokens(theContext, theParamName, theString.get(0)); } catch (SecurityException e) { throw new InternalErrorException(e); } return dt; } }