Search in sources :

Example 6 with Operation

use of org.hl7.fhir.utilities.graphql.Operation in project beneficiary-fhir-data by CMSgov.

the class R4CoverageResourceProvider method searchByBeneficiary.

/**
 * Adds support for the FHIR "search" operation for {@link Coverage}s, allowing users to search by
 * {@link Coverage#getBeneficiary()}.
 *
 * <p>The {@link Search} annotation indicates that this method supports the search operation.
 * There may be many different methods annotated with this {@link Search} annotation, to support
 * many different search criteria.
 *
 * @param beneficiary a {@link ReferenceParam} for the {@link Coverage#getBeneficiary()} to try
 *     and find matches for
 * @param startIndex an {@link OptionalParam} for the startIndex (or offset) used to determine
 *     pagination
 * @param lastUpdated an {@link OptionalParam} to filter the results based on the passed date
 *     range
 * @param requestDetails a {@link RequestDetails} containing the details of the request URL, used
 *     to parse out pagination values
 * @return Returns a {@link List} of {@link Coverage}s, which may contain multiple matching
 *     resources, or may also be empty.
 */
@Search
@Trace
public Bundle searchByBeneficiary(@RequiredParam(name = Coverage.SP_BENEFICIARY) @Description(shortDefinition = "The patient identifier to search for") ReferenceParam beneficiary, @OptionalParam(name = "startIndex") @Description(shortDefinition = "The offset used for result pagination") String startIndex, @OptionalParam(name = "_lastUpdated") @Description(shortDefinition = "Include resources last updated in the given range") DateRangeParam lastUpdated, RequestDetails requestDetails) {
    List<IBaseResource> coverages;
    try {
        Beneficiary beneficiaryEntity = findBeneficiaryById(beneficiary.getIdPart(), lastUpdated);
        if (!beneficiaryEntity.getBeneEnrollmentReferenceYear().isPresent()) {
            throw new ResourceNotFoundException("Cannot find coverage for non present enrollment year");
        }
        coverages = CoverageTransformerV2.transform(metricRegistry, beneficiaryEntity);
    } catch (NoResultException e) {
        coverages = new LinkedList<IBaseResource>();
    }
    OffsetLinkBuilder paging = new OffsetLinkBuilder(requestDetails, "/Coverage?");
    Operation operation = new Operation(Operation.Endpoint.V2_COVERAGE);
    operation.setOption("by", "beneficiary");
    operation.setOption("pageSize", paging.isPagingRequested() ? "" + paging.getPageSize() : "*");
    operation.setOption("_lastUpdated", Boolean.toString(lastUpdated != null && !lastUpdated.isEmpty()));
    operation.publishOperationName();
    // Add bene_id to MDC logs
    TransformerUtilsV2.logBeneIdToMdc(Arrays.asList(beneficiary.getIdPart()));
    return TransformerUtilsV2.createBundle(paging, coverages, loadedFilterManager.getTransactionTime());
}
Also used : OffsetLinkBuilder(gov.cms.bfd.server.war.commons.OffsetLinkBuilder) NoResultException(javax.persistence.NoResultException) Operation(gov.cms.bfd.server.war.Operation) IBaseResource(org.hl7.fhir.instance.model.api.IBaseResource) ResourceNotFoundException(ca.uhn.fhir.rest.server.exceptions.ResourceNotFoundException) LinkedList(java.util.LinkedList) Beneficiary(gov.cms.bfd.model.rif.Beneficiary) Trace(com.newrelic.api.agent.Trace) Search(ca.uhn.fhir.rest.annotation.Search)

Example 7 with Operation

use of org.hl7.fhir.utilities.graphql.Operation in project beneficiary-fhir-data by CMSgov.

the class R4ExplanationOfBenefitResourceProvider method read.

/**
 * Adds support for the FHIR "read" operation, for {@link ExplanationOfBenefit}s. The {@link Read}
 * annotation indicates that this method supports the read operation.
 *
 * <p>Read operations take a single parameter annotated with {@link IdParam}, and should return a
 * single resource instance.
 *
 * @param eobId The read operation takes one parameter, which must be of type {@link IdType} and
 *     must be annotated with the {@link IdParam} annotation.
 * @param requestDetails the request details for the read
 * @return Returns a resource matching the specified {@link IdDt}, or <code>null</code> if none
 *     exists.
 */
@SuppressWarnings({ "rawtypes", "unchecked" })
@Read(version = false)
@Trace
public ExplanationOfBenefit read(@IdParam IdType eobId, RequestDetails requestDetails) {
    if (eobId == null)
        throw new IllegalArgumentException();
    if (eobId.getVersionIdPartAsLong() != null)
        throw new IllegalArgumentException();
    String eobIdText = eobId.getIdPart();
    if (eobIdText == null || eobIdText.trim().isEmpty())
        throw new IllegalArgumentException();
    Matcher eobIdMatcher = EOB_ID_PATTERN.matcher(eobIdText);
    if (!eobIdMatcher.matches())
        throw new IllegalArgumentException("Unsupported ID pattern: " + eobIdText);
    String eobIdTypeText = eobIdMatcher.group(1);
    Optional<ClaimTypeV2> eobIdType = ClaimTypeV2.parse(eobIdTypeText);
    if (!eobIdType.isPresent())
        throw new ResourceNotFoundException(eobId);
    String eobIdClaimIdText = eobIdMatcher.group(2);
    boolean includeTaxNumbers = returnIncludeTaxNumbers(requestDetails);
    Operation operation = new Operation(Operation.Endpoint.V2_EOB);
    operation.setOption("IncludeTaxNumbers", "" + includeTaxNumbers);
    operation.setOption("by", "id");
    operation.publishOperationName();
    Class<?> entityClass = eobIdType.get().getEntityClass();
    CriteriaBuilder builder = entityManager.getCriteriaBuilder();
    CriteriaQuery criteria = builder.createQuery(entityClass);
    Root root = criteria.from(entityClass);
    eobIdType.get().getEntityLazyAttributes().stream().forEach(a -> root.fetch(a));
    criteria.select(root);
    criteria.where(builder.equal(root.get(eobIdType.get().getEntityIdAttribute()), eobIdClaimIdText));
    Object claimEntity = null;
    Long eobByIdQueryNanoSeconds = null;
    Timer.Context timerEobQuery = metricRegistry.timer(MetricRegistry.name(getClass().getSimpleName(), "query", "eob_by_id")).time();
    try {
        claimEntity = entityManager.createQuery(criteria).getSingleResult();
    } catch (NoResultException e) {
        throw new ResourceNotFoundException(eobId);
    } finally {
        eobByIdQueryNanoSeconds = timerEobQuery.stop();
        TransformerUtilsV2.recordQueryInMdc("eob_by_id", eobByIdQueryNanoSeconds, claimEntity == null ? 0 : 1);
    }
    ExplanationOfBenefit eob = eobIdType.get().getTransformer().transform(metricRegistry, claimEntity, Optional.of(includeTaxNumbers));
    return eob;
}
Also used : CriteriaBuilder(javax.persistence.criteria.CriteriaBuilder) Root(javax.persistence.criteria.Root) Matcher(java.util.regex.Matcher) CriteriaQuery(javax.persistence.criteria.CriteriaQuery) Operation(gov.cms.bfd.server.war.Operation) NoResultException(javax.persistence.NoResultException) ExplanationOfBenefit(org.hl7.fhir.r4.model.ExplanationOfBenefit) Timer(com.codahale.metrics.Timer) ResourceNotFoundException(ca.uhn.fhir.rest.server.exceptions.ResourceNotFoundException) Read(ca.uhn.fhir.rest.annotation.Read) Trace(com.newrelic.api.agent.Trace)

Example 8 with Operation

use of org.hl7.fhir.utilities.graphql.Operation in project beneficiary-fhir-data by CMSgov.

the class R4PatientResourceProvider method searchByIdentifier.

/**
 * Adds support for the FHIR "search" operation for {@link Patient}s, allowing users to search by
 * {@link Patient#getIdentifier()}. Specifically, the following criteria are supported:
 *
 * <p>Searches that don't match one of the above forms are not supported.
 *
 * <p>The {@link Search} annotation indicates that this method supports the search operation.
 * There may be many different methods annotated with this {@link Search} annotation, to support
 * many different search criteria.
 *
 * @param identifier an {@link Identifier} {@link TokenParam} for the {@link
 *     Patient#getIdentifier()} to try and find a matching {@link Patient} for
 * @param startIndex an {@link OptionalParam} for the startIndex (or offset) used to determine
 *     pagination
 * @param lastUpdated an {@link OptionalParam} to filter the results based on the passed date
 *     range
 * @param requestDetails a {@link RequestDetails} containing the details of the request URL, used
 *     to parse out pagination values
 * @return Returns a {@link List} of {@link Patient}s, which may contain multiple matching
 *     resources, or may also be empty.
 */
@Search
@Trace
public Bundle searchByIdentifier(@RequiredParam(name = Patient.SP_IDENTIFIER) @Description(shortDefinition = "The patient identifier to search for") TokenParam identifier, @OptionalParam(name = "startIndex") @Description(shortDefinition = "The offset used for result pagination") String startIndex, @OptionalParam(name = "_lastUpdated") @Description(shortDefinition = "Include resources last updated in the given range") DateRangeParam lastUpdated, RequestDetails requestDetails) {
    if (identifier.getQueryParameterQualifier() != null) {
        throw new InvalidRequestException("Unsupported query parameter qualifier: " + identifier.getQueryParameterQualifier());
    }
    if (!SUPPORTED_HASH_IDENTIFIER_SYSTEMS.contains(identifier.getSystem()))
        throw new InvalidRequestException("Unsupported identifier system: " + identifier.getSystem());
    RequestHeaders requestHeader = RequestHeaders.getHeaderWrapper(requestDetails);
    Operation operation = new Operation(Operation.Endpoint.V2_PATIENT);
    operation.setOption("by", "identifier");
    requestHeader.getNVPairs().forEach((n, v) -> operation.setOption(n, v.toString()));
    operation.setOption("_lastUpdated", Boolean.toString(lastUpdated != null && !lastUpdated.isEmpty()));
    operation.publishOperationName();
    List<IBaseResource> patients;
    try {
        Patient patient;
        switch(identifier.getSystem()) {
            case TransformerConstants.CODING_BBAPI_BENE_MBI_HASH:
                patient = queryDatabaseByMbiHash(identifier.getValue(), requestHeader);
                break;
            case TransformerConstants.CODING_BBAPI_BENE_HICN_HASH:
            case TransformerConstants.CODING_BBAPI_BENE_HICN_HASH_OLD:
                patient = queryDatabaseByHicnHash(identifier.getValue(), requestHeader);
                break;
            default:
                throw new InvalidRequestException("Unsupported identifier system: " + identifier.getSystem());
        }
        patients = QueryUtils.isInRange(patient.getMeta().getLastUpdated().toInstant(), lastUpdated) ? Collections.singletonList(patient) : Collections.emptyList();
    } catch (NoResultException e) {
        patients = new LinkedList<>();
    }
    OffsetLinkBuilder paging = new OffsetLinkBuilder(requestDetails, "/Patient?");
    return TransformerUtilsV2.createBundle(paging, patients, loadedFilterManager.getTransactionTime());
}
Also used : OffsetLinkBuilder(gov.cms.bfd.server.war.commons.OffsetLinkBuilder) Patient(org.hl7.fhir.r4.model.Patient) InvalidRequestException(ca.uhn.fhir.rest.server.exceptions.InvalidRequestException) Operation(gov.cms.bfd.server.war.Operation) NoResultException(javax.persistence.NoResultException) RequestHeaders(gov.cms.bfd.server.war.commons.RequestHeaders) IBaseResource(org.hl7.fhir.instance.model.api.IBaseResource) LinkedList(java.util.LinkedList) Trace(com.newrelic.api.agent.Trace) Search(ca.uhn.fhir.rest.annotation.Search)

Example 9 with Operation

use of org.hl7.fhir.utilities.graphql.Operation in project beneficiary-fhir-data by CMSgov.

the class R4PatientResourceProvider method searchByLogicalId.

/**
 * Adds support for the FHIR "search" operation for {@link Patient}s, allowing users to search by
 * {@link Patient#getId()}.
 *
 * <p>The {@link Search} annotation indicates that this method supports the search operation.
 * There may be many different methods annotated with this {@link Search} annotation, to support
 * many different search criteria.
 *
 * @param logicalId a {@link TokenParam} (with no system, per the spec) for the {@link
 *     Patient#getId()} to try and find a matching {@link Patient} for
 * @param startIndex an {@link OptionalParam} for the startIndex (or offset) used to determine
 *     pagination
 * @param lastUpdated an {@link OptionalParam} to filter the results based on the passed date
 *     range
 * @param requestDetails a {@link RequestDetails} containing the details of the request URL, used
 *     to parse out pagination values
 * @return Returns a {@link List} of {@link Patient}s, which may contain multiple matching
 *     resources, or may also be empty.
 */
@Search
@Trace
public Bundle searchByLogicalId(@RequiredParam(name = Patient.SP_RES_ID) @Description(shortDefinition = "The patient identifier to search for") TokenParam logicalId, @OptionalParam(name = "startIndex") @Description(shortDefinition = "The offset used for result pagination") String startIndex, @OptionalParam(name = "_lastUpdated") @Description(shortDefinition = "Include resources last updated in the given range") DateRangeParam lastUpdated, RequestDetails requestDetails) {
    if (logicalId.getQueryParameterQualifier() != null)
        throw new InvalidRequestException("Unsupported query parameter qualifier: " + logicalId.getQueryParameterQualifier());
    if (logicalId.getSystem() != null && !logicalId.getSystem().isEmpty())
        throw new InvalidRequestException("Unsupported query parameter system: " + logicalId.getSystem());
    if (logicalId.getValueNotNull().isEmpty())
        throw new InvalidRequestException("Unsupported query parameter value: " + logicalId.getValue());
    List<IBaseResource> patients;
    if (loadedFilterManager.isResultSetEmpty(logicalId.getValue(), lastUpdated)) {
        patients = Collections.emptyList();
    } else {
        try {
            patients = Optional.of(read(new IdType(logicalId.getValue()), requestDetails)).filter(p -> QueryUtils.isInRange(p.getMeta().getLastUpdated().toInstant(), lastUpdated)).map(p -> Collections.singletonList((IBaseResource) p)).orElse(Collections.emptyList());
        } catch (ResourceNotFoundException e) {
            patients = Collections.emptyList();
        }
    }
    /*
     * Publish the operation name. Note: This is a bit later than we'd normally do this, as we need
     * to override the operation name that was published by the possible call to read(...), above.
     */
    RequestHeaders requestHeader = RequestHeaders.getHeaderWrapper(requestDetails);
    Operation operation = new Operation(Operation.Endpoint.V2_PATIENT);
    operation.setOption("by", "id");
    // track all api hdrs
    requestHeader.getNVPairs().forEach((n, v) -> operation.setOption(n, v.toString()));
    operation.setOption("_lastUpdated", Boolean.toString(lastUpdated != null && !lastUpdated.isEmpty()));
    operation.publishOperationName();
    OffsetLinkBuilder paging = new OffsetLinkBuilder(requestDetails, "/Patient?");
    Bundle bundle = TransformerUtilsV2.createBundle(paging, patients, loadedFilterManager.getTransactionTime());
    return bundle;
}
Also used : IdParam(ca.uhn.fhir.rest.annotation.IdParam) Arrays(java.util.Arrays) PatientLinkBuilder(gov.cms.bfd.server.war.commons.PatientLinkBuilder) Description(ca.uhn.fhir.model.api.annotation.Description) Identifier(org.hl7.fhir.r4.model.Identifier) NoResultException(javax.persistence.NoResultException) StringUtils(org.apache.commons.lang3.StringUtils) BigDecimal(java.math.BigDecimal) DateRangeParam(ca.uhn.fhir.rest.param.DateRangeParam) Predicate(javax.persistence.criteria.Predicate) IResourceProvider(ca.uhn.fhir.rest.server.IResourceProvider) IBaseResource(org.hl7.fhir.instance.model.api.IBaseResource) Map(java.util.Map) CriteriaBuilder(javax.persistence.criteria.CriteriaBuilder) JoinType(javax.persistence.criteria.JoinType) BeneficiaryHistory(gov.cms.bfd.model.rif.BeneficiaryHistory) LoadedFilterManager(gov.cms.bfd.server.war.commons.LoadedFilterManager) Patient(org.hl7.fhir.r4.model.Patient) SingularAttribute(javax.persistence.metamodel.SingularAttribute) CriteriaQuery(javax.persistence.criteria.CriteriaQuery) IdDt(ca.uhn.fhir.model.primitive.IdDt) InvalidRequestException(ca.uhn.fhir.rest.server.exceptions.InvalidRequestException) BeneficiaryMonthly_(gov.cms.bfd.model.rif.BeneficiaryMonthly_) QueryHints(org.hibernate.jpa.QueryHints) Collectors(java.util.stream.Collectors) BeneficiaryMonthly(gov.cms.bfd.model.rif.BeneficiaryMonthly) Objects(java.util.Objects) Beneficiary(gov.cms.bfd.model.rif.Beneficiary) List(java.util.List) BeneficiaryHistory_(gov.cms.bfd.model.rif.BeneficiaryHistory_) TransformerConstants(gov.cms.bfd.server.war.commons.TransformerConstants) Year(java.time.Year) LocalDate(java.time.LocalDate) Timer(com.codahale.metrics.Timer) Optional(java.util.Optional) OptionalParam(ca.uhn.fhir.rest.annotation.OptionalParam) QueryUtils(gov.cms.bfd.server.war.commons.QueryUtils) Trace(com.newrelic.api.agent.Trace) HashMap(java.util.HashMap) RequestHeaders(gov.cms.bfd.server.war.commons.RequestHeaders) TypedQuery(javax.persistence.TypedQuery) Beneficiary_(gov.cms.bfd.model.rif.Beneficiary_) ArrayList(java.util.ArrayList) RequiredParam(ca.uhn.fhir.rest.annotation.RequiredParam) Inject(javax.inject.Inject) Strings(com.google.common.base.Strings) RequestDetails(ca.uhn.fhir.rest.api.server.RequestDetails) Search(ca.uhn.fhir.rest.annotation.Search) CcwCodebookVariable(gov.cms.bfd.model.codebook.data.CcwCodebookVariable) ResourceNotFoundException(ca.uhn.fhir.rest.server.exceptions.ResourceNotFoundException) CommonHeaders(gov.cms.bfd.server.war.commons.CommonHeaders) LinkedList(java.util.LinkedList) Root(javax.persistence.criteria.Root) Read(ca.uhn.fhir.rest.annotation.Read) OffsetLinkBuilder(gov.cms.bfd.server.war.commons.OffsetLinkBuilder) MetricRegistry(com.codahale.metrics.MetricRegistry) Operation(gov.cms.bfd.server.war.Operation) EntityManager(javax.persistence.EntityManager) PersistenceContext(javax.persistence.PersistenceContext) IdType(org.hl7.fhir.r4.model.IdType) TokenParam(ca.uhn.fhir.rest.param.TokenParam) Component(org.springframework.stereotype.Component) MDC(org.slf4j.MDC) YearMonth(java.time.YearMonth) Bundle(org.hl7.fhir.r4.model.Bundle) Collections(java.util.Collections) OffsetLinkBuilder(gov.cms.bfd.server.war.commons.OffsetLinkBuilder) Bundle(org.hl7.fhir.r4.model.Bundle) InvalidRequestException(ca.uhn.fhir.rest.server.exceptions.InvalidRequestException) Operation(gov.cms.bfd.server.war.Operation) IBaseResource(org.hl7.fhir.instance.model.api.IBaseResource) ResourceNotFoundException(ca.uhn.fhir.rest.server.exceptions.ResourceNotFoundException) RequestHeaders(gov.cms.bfd.server.war.commons.RequestHeaders) IdType(org.hl7.fhir.r4.model.IdType) Trace(com.newrelic.api.agent.Trace) Search(ca.uhn.fhir.rest.annotation.Search)

Example 10 with Operation

use of org.hl7.fhir.utilities.graphql.Operation in project beneficiary-fhir-data by CMSgov.

the class EndpointJsonResponseComparatorIT method eobReadHha.

/**
 * @return the results of the {@link
 *     ExplanationOfBenefitResourceProvider#read(org.hl7.fhir.dstu3.model.IdType)} operation for
 *     HHA claims
 */
public static String eobReadHha() {
    List<Object> loadedRecords = ServerTestUtils.get().loadData(Arrays.asList(StaticRifResourceGroup.SAMPLE_A.getResources()));
    IGenericClient fhirClient = createFhirClientAndSetEncoding();
    JsonInterceptor jsonInterceptor = createAndRegisterJsonInterceptor(fhirClient);
    HHAClaim hhaClaim = loadedRecords.stream().filter(r -> r instanceof HHAClaim).map(r -> (HHAClaim) r).findFirst().get();
    fhirClient.read().resource(ExplanationOfBenefit.class).withId(TransformerUtils.buildEobId(ClaimType.HHA, hhaClaim.getClaimId())).execute();
    return jsonInterceptor.getResponse();
}
Also used : Arrays(java.util.Arrays) Bundle(org.hl7.fhir.dstu3.model.Bundle) InpatientClaim(gov.cms.bfd.model.rif.InpatientClaim) Disabled(org.junit.jupiter.api.Disabled) PartDEvent(gov.cms.bfd.model.rif.PartDEvent) SNFClaim(gov.cms.bfd.model.rif.SNFClaim) Matcher(java.util.regex.Matcher) BeforeAll(org.junit.jupiter.api.BeforeAll) JsonNode(com.fasterxml.jackson.databind.JsonNode) IGenericClient(ca.uhn.fhir.rest.client.api.IGenericClient) Path(java.nio.file.Path) MethodSource(org.junit.jupiter.params.provider.MethodSource) OutpatientClaim(gov.cms.bfd.model.rif.OutpatientClaim) Coverage(org.hl7.fhir.dstu3.model.Coverage) ImmutableSet(com.google.common.collect.ImmutableSet) ExplanationOfBenefit(org.hl7.fhir.dstu3.model.ExplanationOfBenefit) MedicareSegment(gov.cms.bfd.server.war.commons.MedicareSegment) Set(java.util.Set) Arguments(org.junit.jupiter.params.provider.Arguments) Collectors(java.util.stream.Collectors) ExplanationOfBenefitResourceProvider(gov.cms.bfd.server.war.stu3.providers.ExplanationOfBenefitResourceProvider) StandardCharsets(java.nio.charset.StandardCharsets) ArrayNode(com.fasterxml.jackson.databind.node.ArrayNode) UncheckedIOException(java.io.UncheckedIOException) JsonArray(com.google.gson.JsonArray) Beneficiary(gov.cms.bfd.model.rif.Beneficiary) List(java.util.List) CapabilityStatement(org.hl7.fhir.dstu3.model.CapabilityStatement) TransformerConstants(gov.cms.bfd.server.war.commons.TransformerConstants) Stream(java.util.stream.Stream) CarrierClaim(gov.cms.bfd.model.rif.CarrierClaim) Optional(java.util.Optional) Pattern(java.util.regex.Pattern) TransformerUtils(gov.cms.bfd.server.war.stu3.providers.TransformerUtils) ExtraParamsInterceptor(gov.cms.bfd.server.war.stu3.providers.ExtraParamsInterceptor) CoverageResourceProvider(gov.cms.bfd.server.war.stu3.providers.CoverageResourceProvider) RequestHeaders(gov.cms.bfd.server.war.commons.RequestHeaders) ClaimType(gov.cms.bfd.server.war.stu3.providers.ClaimType) Supplier(java.util.function.Supplier) ObjectNode(com.fasterxml.jackson.databind.node.ObjectNode) ArrayList(java.util.ArrayList) HHAClaim(gov.cms.bfd.model.rif.HHAClaim) PipelineTestUtils(gov.cms.bfd.pipeline.sharedutils.PipelineTestUtils) OutputStreamWriter(java.io.OutputStreamWriter) DMEClaim(gov.cms.bfd.model.rif.DMEClaim) Assertions.assertEquals(org.junit.jupiter.api.Assertions.assertEquals) StaticRifResourceGroup(gov.cms.bfd.model.rif.samples.StaticRifResourceGroup) ServerTestUtils(gov.cms.bfd.server.war.ServerTestUtils) Arguments.arguments(org.junit.jupiter.params.provider.Arguments.arguments) CommonHeaders(gov.cms.bfd.server.war.commons.CommonHeaders) PatientResourceProvider(gov.cms.bfd.server.war.stu3.providers.PatientResourceProvider) Iterator(java.util.Iterator) Files(java.nio.file.Files) HospiceClaim(gov.cms.bfd.model.rif.HospiceClaim) ObjectMapper(com.fasterxml.jackson.databind.ObjectMapper) FileOutputStream(java.io.FileOutputStream) JsonProcessingException(com.fasterxml.jackson.core.JsonProcessingException) IOException(java.io.IOException) EncodingEnum(ca.uhn.fhir.rest.api.EncodingEnum) File(java.io.File) Consumer(java.util.function.Consumer) AfterEach(org.junit.jupiter.api.AfterEach) ParameterizedTest(org.junit.jupiter.params.ParameterizedTest) Paths(java.nio.file.Paths) Patient(org.hl7.fhir.dstu3.model.Patient) Comparator(java.util.Comparator) Collections(java.util.Collections) IGenericClient(ca.uhn.fhir.rest.client.api.IGenericClient) HHAClaim(gov.cms.bfd.model.rif.HHAClaim)

Aggregations

Parameters (org.hl7.fhir.r4.model.Parameters)72 Test (org.junit.jupiter.api.Test)69 RestIntegrationTest (org.opencds.cqf.ruler.test.RestIntegrationTest)63 SpringBootTest (org.springframework.boot.test.context.SpringBootTest)63 StringType (org.hl7.fhir.r4.model.StringType)62 ArrayList (java.util.ArrayList)60 IOException (java.io.IOException)54 List (java.util.List)54 Bundle (org.hl7.fhir.r4.model.Bundle)53 IGenericClient (ca.uhn.fhir.rest.client.api.IGenericClient)52 Collectors (java.util.stream.Collectors)51 Beneficiary (gov.cms.bfd.model.rif.Beneficiary)50 RequestHeaders (gov.cms.bfd.server.war.commons.RequestHeaders)48 FileOutputStream (java.io.FileOutputStream)47 Collections (java.util.Collections)47 Optional (java.util.Optional)47 File (java.io.File)46 Arrays (java.util.Arrays)46 CommonHeaders (gov.cms.bfd.server.war.commons.CommonHeaders)45 TransformerConstants (gov.cms.bfd.server.war.commons.TransformerConstants)45