Package javax.jms

Examples of javax.jms.StreamMessage.readString()


      assertEquals(new Float(9.0), new Float(sm.readFloat()));
      assertEquals(10, sm.readInt());
      assertEquals(11l, sm.readLong());
      assertEquals("this is an object", sm.readObject());
      assertEquals((short)12, sm.readShort());
      assertEquals("this is a String", sm.readString());
   }


}
View Full Code Here


            //Ok
         }

         try
         {
            received.readString();

            fail("Should throw exception");
         }
         catch (MessageEOFException e)
         {
View Full Code Here

         sender.send(message);

         Message m = receiver.receive(TestConfig.TIMEOUT);
         assertTrue("The message should be an instance of StreamMessage.\n", m instanceof StreamMessage);
         StreamMessage msg = (StreamMessage) m;
         assertEquals("pi", msg.readString());
         assertEquals(3.14159, msg.readDouble(), 0);
      }
      catch (JMSException e)
      {
         fail(e);
View Full Code Here

         sender.send(message);

         Message m = receiver.receive(TestConfig.TIMEOUT);
         assertTrue("The message should be an instance of StreamMessage.\n", m instanceof StreamMessage);
         StreamMessage msg = (StreamMessage) m;
         assertEquals("pi", msg.readString());
         assertEquals(3.14159, msg.readDouble(), 0);
      }
      catch (JMSException e)
      {
         fail(e);
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. 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.