Package ca.uhn.hl7v2.model.v22.segment

Examples of ca.uhn.hl7v2.model.v22.segment.QRD


        // Populate the PID Segment
        MSA msa = adr.getMSA();
        msa.getAcknowledgementCode().setValue("AA");
        msa.getMessageControlID().setValue("123");

        QRD qrd = adr.getQRD();
        qrd.getQueryDateTime().getTimeOfAnEvent().setValue("20080805120000");

        return adr.getMessage();
    }
View Full Code Here


                    .process(new Processor() {
                        public void process(Exchange exchange) throws Exception {
                            Message input = exchange.getIn().getBody(Message.class);

                            assertEquals("2.4", input.getVersion());
                            QRD qrd = (QRD)input.get("QRD");
                            assertEquals("0101701234", qrd.getWhoSubjectFilter(0).getIDNumber().getValue());

                            Message response = createHL7AsMessage();
                            exchange.getOut().setBody(response);
                        }
                    })
View Full Code Here

        // Populate the PID Segment
        MSA msa = adr.getMSA();
        msa.getAcknowledgementCode().setValue("AA");
        msa.getMessageControlID().setValue("123");

        QRD qrd = adr.getQRD();
        qrd.getQueryDateTime().getTimeOfAnEvent().setValue("20080805120000");

        return adr.getMessage();
    }
View Full Code Here

        // Populate the PID Segment
        MSA msa = adr.getMSA();
        msa.getAcknowledgementCode().setValue("AA");
        msa.getMessageControlID().setValue("123");

        QRD qrd = adr.getQRD();
        qrd.getQueryDateTime().getTimeOfAnEvent().setValue("20080805120000");

        return adr.getMessage();
    }
View Full Code Here

        assertMockEndpointsSatisfied();

        Message msg = mock.getExchanges().get(0).getIn().getBody(Message.class);
        assertEquals("2.4", msg.getVersion());
        QRD qrd = (QRD) msg.get("QRD");
        assertEquals("0101701234", qrd.getWhoSubjectFilter(0).getIDNumber().getValue());
    }
View Full Code Here

        // Populate the PID Segment
        MSA msa = adr.getMSA();
        msa.getAcknowledgementCode().setValue("AA");
        msa.getMessageControlID().setValue("123");

        QRD qrd = adr.getQRD();
        qrd.getQueryDateTime().getTimeOfAnEvent().setValue("20080805120000");

        return adr.getMessage();
    }
View Full Code Here

                    try {
                        // Parse the HL7 message
                        ca.uhn.hl7v2.model.Message message = pipeParser.parse(body);
                        if (message instanceof QRY_A19) {                        
                            // Print out some details from the QRD
                            QRD qrd = (QRD) message.get("QRD");
                            System.out.println("Query Date/Time : " + qrd.getQueryDateTime().getTimeOfAnEvent().getValue());
                            System.out.println("Query Format Code : " + qrd.getQueryFormatCode().getValue());
                            System.out.println("Query Priority : " + qrd.getQueryPriority().getValue());
                            System.out.println("Query ID : " + qrd. getQueryID().getValue());
                            System.out.println("Deferred Response Type : " + qrd.getDeferredResponseType().getValue());
                            System.out.println("Deferred Response Date/Time : " + qrd.getDeferredResponseDateTime().getTimeOfAnEvent().getValue());
                            System.out.println("Quantity Limited Request : " + qrd.getQuantityLimitedRequest().getQuantity().getValue());
                            System.out.println("Query Results Level : " + qrd.getQueryResultsLevel().getValue());
                            qrd.getQueryID();
                        }
                    } catch (Exception e) {
                        throw e;
                    }
        
View Full Code Here

       
        try {
            //parse the message string into a Message object
            Message message = pipeParser.parse(result);
            if (message instanceof QRY_A19) {
                QRD qrd = (QRD) message.get("QRD");
                ST st = qrd.getQueryID();
                Assert.assertTrue(st.getValue().equals("GetPatient"));
            } else {
                Assert.fail("Message not instance of QRY_A19");
            }
           
View Full Code Here

    /**
     * Creates a new ADT_AXX message with DefaultModelClassFactory.
     */
    public ADT_AXX() {
       this(new DefaultModelClassFactory());
    }
View Full Code Here

        // Helper class
    }

    @Converter
    public static String toString(Message message) throws HL7Exception {
        Parser parser = new PipeParser();
        String encoded = parser.encode(message);
        return encoded;
    }
View Full Code Here

TOP

Related Classes of ca.uhn.hl7v2.model.v22.segment.QRD

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.