@Override public String toString() { ToStringBuilder builder = new ToStringBuilder(this, ToStringStyle.SHORT_PREFIX_STYLE); builder.append("value", getValue()); return builder.toString(); }
UriParam param = (UriParam) nextOr; String value = param.getValue(); if (value == null) { continue;
IdType resourceId = new IdType(next.getValue()); ValidateUtil.isTrueOrThrowInvalidRequest(resourceId.hasResourceType(), RESOURCE_ID + " parameter must have resource type"); ValidateUtil.isTrueOrThrowInvalidRequest(resourceId.hasIdPart(), RESOURCE_ID + " parameter must have resource ID part");
@Override public String toString() { ToStringBuilder builder = new ToStringBuilder(this, ToStringStyle.SHORT_PREFIX_STYLE); builder.append("value", getValue()); return builder.toString(); }
UriParam param = (UriParam) nextOr; String value = param.getValue(); if (value == null) { continue;
IdType resourceId = new IdType(next.getValue()); ValidateUtil.isTrueOrThrowInvalidRequest(resourceId.hasResourceType(), RESOURCE_ID + " parameter must have resource type"); ValidateUtil.isTrueOrThrowInvalidRequest(resourceId.hasIdPart(), RESOURCE_ID + " parameter must have resource ID part");
/** * Handles the PIXm Retrieve. Note that this is not part of the specification, but a useful variant that allows to use resource IDs * in requests such as .../Patient/4711/$ihe-pix would be equivalent with .../Patient/$ihe-pix?sourceIdentifier=URI|4711 where URI * identifies the NamingSystem used for resource IDs * * @param resourceId resource ID * @param targetSystemParam target system URI * @param httpServletRequest servlet request * @param httpServletResponse servlet response * @return {@link Parameters} containing found identifiers */ @Operation(name = Iti83Constants.PIXM_OPERATION_NAME, type = Patient.class, idempotent = true, returnParameters = {@OperationParam(name = "return", type = Identifier.class, max = 100)}) public Parameters pixmRetrieve( @IdParam IdType resourceId, @OperationParam(name = TARGET_SYSTEM_NAME) UriParam targetSystemParam, HttpServletRequest httpServletRequest, HttpServletResponse httpServletResponse) { UriType targetUri = targetSystemParam == null ? null : new UriType(targetSystemParam.getValue()); Parameters inParams = new Parameters(); inParams.addParameter().setName(SOURCE_IDENTIFIER_NAME).setValue(new Identifier().setValue(resourceId.getIdPart())); inParams.addParameter().setName(TARGET_SYSTEM_NAME).setValue(targetUri); // Run down the route return requestResource(inParams, Parameters.class, httpServletRequest, httpServletResponse); } }
/** * Handles the PIXm Query * * @param sourceIdentifierParam Identifier to search for. Should be an {@link Identifier}, but obviously * non-primitive types are forbidden in GET operations * @param targetSystemParam target system URI * @return {@link Parameters} containing found identifiers */ @SuppressWarnings("unused") @Operation(name = Iti83Constants.PIXM_OPERATION_NAME, type = Patient.class, idempotent = true, returnParameters = {@OperationParam(name = "return", type = Identifier.class, max = 100)}) public Parameters pixmQuery( @OperationParam(name = SOURCE_IDENTIFIER_NAME) TokenParam sourceIdentifierParam, @OperationParam(name = TARGET_SYSTEM_NAME) UriParam targetSystemParam, HttpServletRequest httpServletRequest, HttpServletResponse httpServletResponse) { Identifier sourceIdentifier = new Identifier() .setSystem(sourceIdentifierParam.getSystem()) .setValue(sourceIdentifierParam.getValue()); UriType targetUri = targetSystemParam == null ? null : new UriType(targetSystemParam.getValue()); Parameters inParams = new Parameters(); inParams.addParameter().setName(SOURCE_IDENTIFIER_NAME).setValue(sourceIdentifier); inParams.addParameter().setName(TARGET_SYSTEM_NAME).setValue(targetUri); // Run down the route return requestResource(inParams, Parameters.class, httpServletRequest, httpServletResponse); }
sourceIdentifier.setValue(resourceId.getIdPart()); UriType targetUri = targetSystemParam == null ? null : new UriType(targetSystemParam.getValue());