Search in sources :

Example 1 with ArbitraryQuery

use of org.ehrbase.client.openehrclient.defaultrestclient.systematic.compositionquery.queries.arbitrary.ArbitraryQuery in project openEHR_SDK by ehrbase.

the class CanonicalMinimalInstructionTypeQueryIT method setUp.

@Before
public void setUp() throws IOException {
    ehrUUID = openEhrClient.ehrEndpoint().createEhr();
    compositionEndpoint = openEhrClient.compositionEndpoint(ehrUUID);
    arbitraryQuery = new ArbitraryQuery(ehrUUID, openEhrClient);
    flattener = new Flattener(new TestDataTemplateProvider());
    aComposition = new CanonicalJson().unmarshal(IOUtils.toString(CompositionTestDataCanonicalJson.MINIMAL_INSTRUCTION.getStream(), StandardCharsets.UTF_8), Composition.class);
}
Also used : ArbitraryQuery(org.ehrbase.client.openehrclient.defaultrestclient.systematic.compositionquery.queries.arbitrary.ArbitraryQuery) CanonicalJson(org.ehrbase.serialisation.jsonencoding.CanonicalJson) CompositionTestDataCanonicalJson(org.ehrbase.test_data.composition.CompositionTestDataCanonicalJson) Composition(com.nedap.archie.rm.composition.Composition) MinimalInstructionEnV1Composition(org.ehrbase.client.classgenerator.examples.minimalinstructionenv1composition.MinimalInstructionEnV1Composition) Flattener(org.ehrbase.client.flattener.Flattener) TestDataTemplateProvider(org.ehrbase.client.templateprovider.TestDataTemplateProvider) Before(org.junit.Before)

Example 2 with ArbitraryQuery

use of org.ehrbase.client.openehrclient.defaultrestclient.systematic.compositionquery.queries.arbitrary.ArbitraryQuery in project openEHR_SDK by ehrbase.

the class CartesianProductQueryIT method setUp.

@Before
public void setUp() throws IOException {
    ehrUUID = openEhrClient.ehrEndpoint().createEhr();
    compositionEndpoint = openEhrClient.compositionEndpoint(ehrUUID);
    arbitraryQuery = new ArbitraryQuery(ehrUUID, openEhrClient);
    flattener = new Flattener(new TestDataTemplateProvider());
}
Also used : ArbitraryQuery(org.ehrbase.client.openehrclient.defaultrestclient.systematic.compositionquery.queries.arbitrary.ArbitraryQuery) Flattener(org.ehrbase.client.flattener.Flattener) TestDataTemplateProvider(org.ehrbase.client.templateprovider.TestDataTemplateProvider) Before(org.junit.Before)

Example 3 with ArbitraryQuery

use of org.ehrbase.client.openehrclient.defaultrestclient.systematic.compositionquery.queries.arbitrary.ArbitraryQuery in project openEHR_SDK by ehrbase.

the class ArbitraryQueryIT method setUp.

@Before
public void setUp() throws IOException {
    super.setUp(CompositionTestDataCanonicalJson.ALL_TYPES_SYSTEMATIC_TESTS);
    arbitraryQuery = new ArbitraryQuery(ehrUUID, openEhrClient);
}
Also used : ArbitraryQuery(org.ehrbase.client.openehrclient.defaultrestclient.systematic.compositionquery.queries.arbitrary.ArbitraryQuery) Before(org.junit.Before)

Example 4 with ArbitraryQuery

use of org.ehrbase.client.openehrclient.defaultrestclient.systematic.compositionquery.queries.arbitrary.ArbitraryQuery in project openEHR_SDK by ehrbase.

the class ArbitraryQueryDateTimeIT method setUp.

@Before
public void setUp() throws IOException {
    super.setUp(CompositionTestDataCanonicalJson.DATE_TIME_TESTS);
    arbitraryQuery = new ArbitraryQuery(ehrUUID, openEhrClient);
}
Also used : ArbitraryQuery(org.ehrbase.client.openehrclient.defaultrestclient.systematic.compositionquery.queries.arbitrary.ArbitraryQuery) Before(org.junit.Before)

Example 5 with ArbitraryQuery

use of org.ehrbase.client.openehrclient.defaultrestclient.systematic.compositionquery.queries.arbitrary.ArbitraryQuery in project openEHR_SDK by ehrbase.

the class ArbitraryQueryFeederAuditIT method setUp.

@Before
public void setUp() throws IOException {
    ehrUUID = openEhrClient.ehrEndpoint().createEhr();
    compositionEndpoint = openEhrClient.compositionEndpoint(ehrUUID);
    aComposition = new CanonicalJson().unmarshal(IOUtils.toString(CompositionTestDataCanonicalJson.FEEDER_AUDIT_DETAILS.getStream(), StandardCharsets.UTF_8), Composition.class);
    Flattener flattener = new Flattener(new TestDataTemplateProvider());
    TestAllTypesEnV1Composition testAllTypesEnV1Composition = flattener.flatten(aComposition, TestAllTypesEnV1Composition.class);
    // create the composition
    TestAllTypesEnV1Composition comp = compositionEndpoint.mergeCompositionEntity(testAllTypesEnV1Composition);
    compositionUUID = comp.getVersionUid().getUuid();
    arbitraryQuery = new ArbitraryQuery(ehrUUID, openEhrClient);
}
Also used : ArbitraryQuery(org.ehrbase.client.openehrclient.defaultrestclient.systematic.compositionquery.queries.arbitrary.ArbitraryQuery) CanonicalJson(org.ehrbase.serialisation.jsonencoding.CanonicalJson) CompositionTestDataCanonicalJson(org.ehrbase.test_data.composition.CompositionTestDataCanonicalJson) Composition(com.nedap.archie.rm.composition.Composition) TestAllTypesEnV1Composition(org.ehrbase.client.classgenerator.examples.testalltypesenv1composition.TestAllTypesEnV1Composition) Flattener(org.ehrbase.client.flattener.Flattener) TestAllTypesEnV1Composition(org.ehrbase.client.classgenerator.examples.testalltypesenv1composition.TestAllTypesEnV1Composition) TestDataTemplateProvider(org.ehrbase.client.templateprovider.TestDataTemplateProvider) Before(org.junit.Before)

Aggregations

ArbitraryQuery (org.ehrbase.client.openehrclient.defaultrestclient.systematic.compositionquery.queries.arbitrary.ArbitraryQuery)7 Before (org.junit.Before)7 Flattener (org.ehrbase.client.flattener.Flattener)4 TestDataTemplateProvider (org.ehrbase.client.templateprovider.TestDataTemplateProvider)4 Composition (com.nedap.archie.rm.composition.Composition)3 CanonicalJson (org.ehrbase.serialisation.jsonencoding.CanonicalJson)3 CompositionTestDataCanonicalJson (org.ehrbase.test_data.composition.CompositionTestDataCanonicalJson)3 MinimalInstructionEnV1Composition (org.ehrbase.client.classgenerator.examples.minimalinstructionenv1composition.MinimalInstructionEnV1Composition)1 TestAllTypesEnV1Composition (org.ehrbase.client.classgenerator.examples.testalltypesenv1composition.TestAllTypesEnV1Composition)1 VirologischerBefundComposition (org.ehrbase.client.classgenerator.examples.virologischerbefundcomposition.VirologischerBefundComposition)1 SimpleSelectQuery (org.ehrbase.client.openehrclient.defaultrestclient.systematic.compositionquery.queries.simple.SimpleSelectQuery)1