All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.ibm.fhir.persistence.jdbc.util.RevIncludeExtension Maven / Gradle / Ivy

There is a newer version: 4.11.1
Show newest version
/*
 * (C) Copyright IBM Corp. 2021
 *
 * SPDX-License-Identifier: Apache-2.0
 */

package com.ibm.fhir.persistence.jdbc.util;

import java.util.List;

import com.ibm.fhir.persistence.exception.FHIRPersistenceException;
import com.ibm.fhir.persistence.jdbc.domain.SearchExtension;
import com.ibm.fhir.persistence.jdbc.domain.SearchQueryVisitor;
import com.ibm.fhir.search.parameters.InclusionParameter;

/**
 * SearchExtension for building _revinclude queries
 */
public class RevIncludeExtension implements SearchExtension {

    private final InclusionParameter inclusionParm;

    private final List ids;

    public RevIncludeExtension(InclusionParameter inclusionParm, List ids) {
        this.inclusionParm = inclusionParm;
        this.ids = ids;
    }

    @Override
    public  T visit(T query, SearchQueryVisitor visitor) throws FHIRPersistenceException {
        return visitor.addRevIncludeFilter(query, inclusionParm, ids);
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy