Search in sources :

Example 6 with ExtrinsicObjectType

use of oasis.names.tc.ebxml_regrep.xsd.rim._3.ExtrinsicObjectType in project nhin-d by DirectProject.

the class DirectDocument2Test method testAuthorSpecialty.

/**
     * Test authorSpecialty.
     * 
     * @throws Exception
     */
public void testAuthorSpecialty() throws Exception {
    DirectDocument2 document = new DirectDocument2();
    DirectDocument2.Metadata metadata = document.getMetadata();
    String value = "input";
    metadata.setAuthorSpecialty(value);
    ExtrinsicObjectType eot = metadata.generateExtrinsicObjectType();
    metadata = new DirectDocument2.Metadata();
    metadata.setValues(eot);
    assertEquals("Output does not match expected", value, metadata.getAuthorSpecialty());
}
Also used : ExtrinsicObjectType(oasis.names.tc.ebxml_regrep.xsd.rim._3.ExtrinsicObjectType)

Example 7 with ExtrinsicObjectType

use of oasis.names.tc.ebxml_regrep.xsd.rim._3.ExtrinsicObjectType in project nhin-d by DirectProject.

the class DirectDocument2Test method testAuthorPerson.

/**
     * Test sourcePatient.
     * 
     * @throws Exception
     */
/*    public void testSourcePatient() throws Exception
    {
        DirectDocument2 document = new DirectDocument2();
        DirectDocument2.Metadata metadata = document.getMetadata();

        SimplePerson sourcePatient = new SimplePerson();
        sourcePatient.setFirstName("first");
        sourcePatient.setMiddleName("middle");
        sourcePatient.setLastName("last");
        sourcePatient.setLocalId("localId");
        sourcePatient.setLocalOrg("localOrg");
        sourcePatient.setBirthDateTime("19560527");
        sourcePatient.setGenderCode("M");
        sourcePatient.setStreetAddress1("street");
        sourcePatient.setCity("city");
        sourcePatient.setState("state");
        sourcePatient.setZipCode("zip");

        metadata.setSourcePatient(sourcePatient);

        ExtrinsicObjectType eot = metadata.generateExtrinsicObjectType();

        metadata = new DirectDocument2.Metadata();
        metadata.setValues(eot);

        assertEquals("Output does not match expected", sourcePatient.getFirstName(), metadata.getSourcePatient().getFirstName());
        assertEquals("Output does not match expected", sourcePatient.getMiddleName(), metadata.getSourcePatient().getMiddleName());
        assertEquals("Output does not match expected", sourcePatient.getLastName(), metadata.getSourcePatient().getLastName());
        assertEquals("Output does not match expected", sourcePatient.getLocalId(), metadata.getSourcePatient().getLocalId());
        assertEquals("Output does not match expected", sourcePatient.getLocalOrg(), metadata.getSourcePatient().getLocalOrg());
        assertEquals("Output does not match expected", sourcePatient.getBirthDateTime(), metadata.getSourcePatient().getBirthDateTime());
        assertEquals("Output does not match expected", sourcePatient.getGenderCode(), metadata.getSourcePatient().getGenderCode());
        assertEquals("Output does not match expected", sourcePatient.getStreetAddress1(), metadata.getSourcePatient().getStreetAddress1());
        assertEquals("Output does not match expected", sourcePatient.getCity(), metadata.getSourcePatient().getCity());
        assertEquals("Output does not match expected", sourcePatient.getState(), metadata.getSourcePatient().getState());
        assertEquals("Output does not match expected", sourcePatient.getZipCode(), metadata.getSourcePatient().getZipCode());
    }
*/
/**
     * Test authorPerson.
     * 
     * @throws Exception
     */
public void testAuthorPerson() throws Exception {
    DirectDocument2 document = new DirectDocument2();
    DirectDocument2.Metadata metadata = document.getMetadata();
    String value = "input";
    metadata.setAuthorPerson(value);
    ExtrinsicObjectType eot = metadata.generateExtrinsicObjectType();
    metadata = new DirectDocument2.Metadata();
    metadata.setValues(eot);
    assertEquals("Output does not match expected", value, metadata.getAuthorPerson());
}
Also used : ExtrinsicObjectType(oasis.names.tc.ebxml_regrep.xsd.rim._3.ExtrinsicObjectType)

Example 8 with ExtrinsicObjectType

use of oasis.names.tc.ebxml_regrep.xsd.rim._3.ExtrinsicObjectType in project nhin-d by DirectProject.

the class DirectDocument2Test method testHealthcareFacilityTypeCode.

/**
     * Test healthcareFacilityTypeCode.
     * 
     * @throws Exception
     */
public void testHealthcareFacilityTypeCode() throws Exception {
    DirectDocument2 document = new DirectDocument2();
    DirectDocument2.Metadata metadata = document.getMetadata();
    String value = "input";
    metadata.setHealthcareFacilityTypeCode(value);
    ExtrinsicObjectType eot = metadata.generateExtrinsicObjectType();
    metadata = new DirectDocument2.Metadata();
    metadata.setValues(eot);
    assertEquals("Output does not match expected", value, metadata.getHealthcareFacilityTypeCode());
    assertEquals("Output does not match expected", null, metadata.getHealthcareFacilityTypeCode_localized());
    metadata.setHealthcareFacilityTypeCode(value, true);
    eot = metadata.generateExtrinsicObjectType();
    metadata = new DirectDocument2.Metadata();
    metadata.setValues(eot);
    assertEquals("Output does not match expected", value, metadata.getHealthcareFacilityTypeCode());
    assertEquals("Output does not match expected", value, metadata.getHealthcareFacilityTypeCode_localized());
}
Also used : ExtrinsicObjectType(oasis.names.tc.ebxml_regrep.xsd.rim._3.ExtrinsicObjectType)

Example 9 with ExtrinsicObjectType

use of oasis.names.tc.ebxml_regrep.xsd.rim._3.ExtrinsicObjectType in project nhin-d by DirectProject.

the class DirectDocument2Test method testHash.

/**
     * Test hash.
     * 
     * @throws Exception
     */
public void testHash() throws Exception {
    DirectDocument2 document = new DirectDocument2();
    DirectDocument2.Metadata metadata = document.getMetadata();
    String value = "input";
    metadata.setHash(value);
    ExtrinsicObjectType eot = metadata.generateExtrinsicObjectType();
    metadata = new DirectDocument2.Metadata();
    metadata.setValues(eot);
    assertEquals("Output does not match expected", value, metadata.getHash());
}
Also used : ExtrinsicObjectType(oasis.names.tc.ebxml_regrep.xsd.rim._3.ExtrinsicObjectType)

Example 10 with ExtrinsicObjectType

use of oasis.names.tc.ebxml_regrep.xsd.rim._3.ExtrinsicObjectType in project nhin-d by DirectProject.

the class DirectDocument2Test method testHealthcareFacilityTypeCode_localized.

/**
     * Test healthcareFacilityTypeCode_localized.
     * 
     * @throws Exception
     */
public void testHealthcareFacilityTypeCode_localized() throws Exception {
    DirectDocument2 document = new DirectDocument2();
    DirectDocument2.Metadata metadata = document.getMetadata();
    String value = "input";
    metadata.setHealthcareFacilityTypeCode(UUID.randomUUID().toString());
    metadata.setHealthcareFacilityTypeCode_localized(value);
    ExtrinsicObjectType eot = metadata.generateExtrinsicObjectType();
    metadata = new DirectDocument2.Metadata();
    metadata.setValues(eot);
    assertEquals("Output does not match expected", value, metadata.getHealthcareFacilityTypeCode_localized());
}
Also used : ExtrinsicObjectType(oasis.names.tc.ebxml_regrep.xsd.rim._3.ExtrinsicObjectType)

Aggregations

ExtrinsicObjectType (oasis.names.tc.ebxml_regrep.xsd.rim._3.ExtrinsicObjectType)46 RegistryPackageType (oasis.names.tc.ebxml_regrep.xsd.rim._3.RegistryPackageType)8 JAXBElement (javax.xml.bind.JAXBElement)7 RegistryObjectListType (oasis.names.tc.ebxml_regrep.xsd.rim._3.RegistryObjectListType)7 ArrayList (java.util.ArrayList)5 AssociationType1 (oasis.names.tc.ebxml_regrep.xsd.rim._3.AssociationType1)5 IdentifiableType (oasis.names.tc.ebxml_regrep.xsd.rim._3.IdentifiableType)5 SlotType1 (oasis.names.tc.ebxml_regrep.xsd.rim._3.SlotType1)5 OrganizationType (oasis.names.tc.ebxml_regrep.xsd.rim._3.OrganizationType)4 PersonType (oasis.names.tc.ebxml_regrep.xsd.rim._3.PersonType)4 RegistryObjectType (oasis.names.tc.ebxml_regrep.xsd.rim._3.RegistryObjectType)4 ServiceType (oasis.names.tc.ebxml_regrep.xsd.rim._3.ServiceType)4 Date (java.util.Date)3 ClassificationType (oasis.names.tc.ebxml_regrep.xsd.rim._3.ClassificationType)3 Metacard (ddf.catalog.data.Metacard)2 OffsetDateTime (java.time.OffsetDateTime)2 HashMap (java.util.HashMap)2 QName (javax.xml.namespace.QName)2 SubmitObjectsRequest (oasis.names.tc.ebxml_regrep.xsd.lcm._3.SubmitObjectsRequest)2 ExternalIdentifierType (oasis.names.tc.ebxml_regrep.xsd.rim._3.ExternalIdentifierType)2