Examples of markAsReadOnly()


Examples of net.timewalker.ffmq3.common.message.StreamMessageImpl.markAsReadOnly()

    assertEquals("1.23",msg.readString());
   
    // Bytes
    msg = new StreamMessageImpl();
    msg.writeFloat(1.23f);
    msg.markAsReadOnly();
    try { msg.readBytes(new byte[1]); fail("Should have failed"); } catch (MessageFormatException e) { /* OK */  }
    assertEquals(1.23f,msg.readFloat(),0);
  }
 
  public void testDoubleConversion() throws Exception
View Full Code Here

Examples of net.timewalker.ffmq3.common.message.StreamMessageImpl.markAsReadOnly()

    StreamMessageImpl msg;
   
    // Boolean
    msg = new StreamMessageImpl();
    msg.writeDouble(1.23);
    msg.markAsReadOnly();
    try { msg.readBoolean(); fail("Should have failed"); } catch (MessageFormatException e) { /* OK */  }
    assertEquals(1.23,msg.readDouble(),0);
   
    // Byte
    msg = new StreamMessageImpl();
View Full Code Here

Examples of net.timewalker.ffmq3.common.message.StreamMessageImpl.markAsReadOnly()

    assertEquals(1.23,msg.readDouble(),0);
   
    // Byte
    msg = new StreamMessageImpl();
    msg.writeDouble(1.23);
    msg.markAsReadOnly();
    try { msg.readByte(); fail("Should have failed"); } catch (MessageFormatException e) { /* OK */  }
    assertEquals(1.23,msg.readDouble(),0);
   
    // Short
    msg = new StreamMessageImpl();
View Full Code Here

Examples of net.timewalker.ffmq3.common.message.StreamMessageImpl.markAsReadOnly()

    assertEquals(1.23,msg.readDouble(),0);
   
    // Short
    msg = new StreamMessageImpl();
    msg.writeDouble(1.23);
    msg.markAsReadOnly();
    try { msg.readShort(); fail("Should have failed"); } catch (MessageFormatException e) { /* OK */  }
    assertEquals(1.23,msg.readDouble(),0);
   
    // Char
    msg = new StreamMessageImpl();
View Full Code Here

Examples of net.timewalker.ffmq3.common.message.StreamMessageImpl.markAsReadOnly()

    assertEquals(1.23,msg.readDouble(),0);
   
    // Char
    msg = new StreamMessageImpl();
    msg.writeDouble(1.23);
    msg.markAsReadOnly();
    try { msg.readChar(); fail("Should have failed"); } catch (MessageFormatException e) { /* OK */  }
    assertEquals(1.23,msg.readDouble(),0);
   
    // Int
    msg = new StreamMessageImpl();
View Full Code Here

Examples of net.timewalker.ffmq3.common.message.StreamMessageImpl.markAsReadOnly()

    assertEquals(1.23,msg.readDouble(),0);
   
    // Int
    msg = new StreamMessageImpl();
    msg.writeDouble(1.23);
    msg.markAsReadOnly();
    try { msg.readInt(); fail("Should have failed"); } catch (MessageFormatException e) { /* OK */ }
    assertEquals(1.23,msg.readDouble(),0);
   
    // Long
    msg = new StreamMessageImpl();
View Full Code Here

Examples of net.timewalker.ffmq3.common.message.StreamMessageImpl.markAsReadOnly()

    assertEquals(1.23,msg.readDouble(),0);
   
    // Long
    msg = new StreamMessageImpl();
    msg.writeDouble(1.23);
    msg.markAsReadOnly();
    try { msg.readLong(); fail("Should have failed"); } catch (MessageFormatException e) { /* OK */ }
    assertEquals(1.23,msg.readDouble(),0);
   
    // Float
    msg = new StreamMessageImpl();
View Full Code Here

Examples of net.timewalker.ffmq3.common.message.StreamMessageImpl.markAsReadOnly()

    assertEquals(1.23,msg.readDouble(),0);
   
    // Float
    msg = new StreamMessageImpl();
    msg.writeDouble(1.23);
    msg.markAsReadOnly();
    try { msg.readFloat(); fail("Should have failed"); } catch (MessageFormatException e) { /* OK */ }
    assertEquals(1.23,msg.readDouble(),0);
   
    // Double
    msg = new StreamMessageImpl();
View Full Code Here

Examples of net.timewalker.ffmq3.common.message.StreamMessageImpl.markAsReadOnly()

    assertEquals(1.23,msg.readDouble(),0);
   
    // Double
    msg = new StreamMessageImpl();
    msg.writeDouble(1.23);
    msg.markAsReadOnly();
    assertEquals(1.23,msg.readDouble(),0.0000001);
   
    // String
    msg = new StreamMessageImpl();
    msg.writeDouble(1.23);
View Full Code Here

Examples of net.timewalker.ffmq3.common.message.StreamMessageImpl.markAsReadOnly()

    assertEquals(1.23,msg.readDouble(),0.0000001);
   
    // String
    msg = new StreamMessageImpl();
    msg.writeDouble(1.23);
    msg.markAsReadOnly();
    assertEquals("1.23",msg.readString());
   
    // Bytes
    msg = new StreamMessageImpl();
    msg.writeDouble(1.23);
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.