Package org.jboss.soa.esb.addressing

Examples of org.jboss.soa.esb.addressing.EPR


    public void test_Serialize_Deserialize()
        throws Exception
    {
        Message msg = MessageFactory.getInstance().getMessage(MessageType.JBOSS_XML);

        EPR epr = new LogicalEPR(new PortReference("logical:a#b"));

        msg.getHeader().getCall().setTo(epr);

        final String xmlRepresentation = XMLMessageUnitTest.msgToXML((MessageImpl)msg) ;

        final MessageImpl nImpl = XMLMessageUnitTest.msgFromXML(xmlRepresentation) ;

        EPR theEpr = nImpl.getHeader().getCall().getTo();

        assertTrue("Expected a Logical EPR", theEpr instanceof LogicalEPR);

        assertEquals("logical:a#b", theEpr.getAddr().getAddress());
    }
View Full Code Here


 
  public void testEPRConstructor ()
  {
    try
    {
      EPR epr = new EPR(new URI("http://localhost"));
      Call call = new Call(epr);
     
      assertEquals(call.getTo().equals(epr), true);
    }
    catch (Exception ex)
View Full Code Here

  {
    Call call = new Call();
   
    try
    {
      EPR epr = new EPR(new URI("http://localhost"));
     
      call.setTo(epr);
     
      assertEquals(call.getTo().equals(epr), true);
    }
View Full Code Here

  {
    Call call = new Call();
   
    try
    {
      EPR epr = new EPR(new URI("http://localhost"));
     
      call.setFrom(epr);
     
      assertEquals(call.getFrom().equals(epr), true);
    }
View Full Code Here

  {
    Call call = new Call();
   
    try
    {
      EPR epr = new EPR(new URI("http://localhost"));
     
      call.setReplyTo(epr);
     
      assertEquals(call.getReplyTo().equals(epr), true);
    }
View Full Code Here

  {
    Call call = new Call();
   
    try
    {
      EPR epr = new EPR(new URI("http://localhost"));
     
      call.setFaultTo(epr);
     
      assertEquals(call.getFaultTo().equals(epr), true);
    }
View Full Code Here

  }
 
  private EPR getEPR(final String uri, final String tag, final String value)
      throws URISyntaxException
  {
            final EPR epr = new EPR(new URI(uri)) ;
            epr.getAddr().addExtension(tag, value) ;
            return epr ;
  }
View Full Code Here

 
  private Logger log = Logger.getLogger( XMLMessageUnitTest.class );
 
  public void testConstructor ()
  {
    EPR epr = new EPR();
   
    log.debug("Default EPR: "+epr);
  }
View Full Code Here

    log.debug("Default EPR: "+epr);
  }
 
  public void testPortReferenceConstructor ()
  {
    EPR epr = new EPR(new PortReference("http://localhost:8080"));
   
    assertEquals(epr.getAddr().getAddress(), "http://localhost:8080");
  }
View Full Code Here

 
  public void testURIConstructor ()
  {
    try
    {
      EPR epr = new EPR(new URI("urn:foo/bar"));
     
      assertEquals(epr.getAddr().getAddress(), "urn:foo/bar");
    }
    catch (Exception ex)
    {
      fail(ex.toString());
    }
View Full Code Here

TOP

Related Classes of org.jboss.soa.esb.addressing.EPR

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.