Examples of writeByte()


Examples of net.timewalker.ffmq3.common.message.BytesMessageImpl.writeByte()

        setDummyProperties(msg);
       
        msg.writeBoolean(true);
        msg.writeUTF("foobar");
        msg.writeChar('c');
        msg.writeByte((byte)1);
        msg.writeShort((short)2);
        msg.writeInt(3);
        msg.writeLong(4);
        msg.writeFloat(1.23f);
        msg.writeDouble(4.56);
View Full Code Here

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

        setDummyProperties(msg);
       
        msg.writeBoolean(true);
        msg.writeString("foobar");
        msg.writeChar('c');
        msg.writeByte((byte)1);
        msg.writeShort((short)2);
        msg.writeInt(3);
        msg.writeLong(4);
        msg.writeFloat(1.23f);
        msg.writeDouble(4.56);
View Full Code Here

Examples of net.timewalker.ffmq3.utils.RawDataBuffer.writeByte()

        RawDataBuffer rawMsg = message.getRawMessage();
        if (rawMsg != null)
            return rawMsg.toByteArray();

        RawDataBuffer buffer = new RawDataBuffer(typicalSize);
        buffer.writeByte(message.getType());
        message.serializeTo(buffer);
       
        return buffer.toByteArray();
    }
   
View Full Code Here

Examples of net.tomp2p.storage.AlternativeCompositeByteBuf.writeByte()

    for (int i = 0; i < len; i += 4) {
      ByteBuf buf = Unpooled.buffer().writeInt(i);
      cbuf.capacity(cbuf.writerIndex()).addComponent(buf)
          .writerIndex(i + 4);
    }
    cbuf.writeByte(1);

    byte[] me = new byte[len];
    cbuf.readBytes(me);
    cbuf.readByte();
View Full Code Here

Examples of org.activeio.PacketData.writeByte()

    }

    private Packet createHeaderPacket(byte type, short requestId) throws IOException {
        ByteArrayPacket header = new ByteArrayPacket(new byte[]{3});
        PacketData data = new PacketData(header);
        data.writeByte(type);
        data.writeShort(requestId);
        header.flip();
        return header;
    }
View Full Code Here

Examples of org.activemq.message.ActiveMQBytesMessage.writeByte()

    }
  }
  public void testReadByte() {
    ActiveMQBytesMessage msg = new ActiveMQBytesMessage();
    try {
      msg.writeByte((byte) 2);
      msg.reset();
      assertTrue(msg.readByte() == 2);
    } catch (JMSException jmsEx) {
      jmsEx.printStackTrace();
      assertTrue(false);
View Full Code Here

Examples of org.activemq.message.ActiveMQStreamMessage.writeByte()

  public void testreadByte()
  {
    ActiveMQStreamMessage msg = new ActiveMQStreamMessage();
    try {
      byte test = (byte)4;
      msg.writeByte(test);
      msg.reset();
      assertTrue(msg.readByte()==test);
      msg.reset();
      assertTrue(msg.readShort()==test);
      msg.reset();
View Full Code Here

Examples of org.apache.activemq.command.ActiveMQBytesMessage.writeByte()

                msg.setConnection(connection);
                try {
                    for (;;) {
                        // Reads a byte from the message stream until the stream
                        // is empty
                        msg.writeByte(bytesMsg.readByte());
                    }
                } catch (MessageEOFException e) {
                    // if an end of message stream as expected
                } catch (JMSException e) {
                }
View Full Code Here

Examples of org.apache.activemq.command.ActiveMQStreamMessage.writeByte()

    public void testreadByte() {
        ActiveMQStreamMessage msg = new ActiveMQStreamMessage();
        try {
            byte test = (byte) 4;
            msg.writeByte(test);
            msg.reset();
            assertTrue(msg.readByte() == test);
            msg.reset();
            assertTrue(msg.readShort() == test);
            msg.reset();
View Full Code Here

Examples of org.apache.activemq.store.kahadb.disk.util.DataByteArrayOutputStream.writeByte()

                Journal.WriteCommand write = wb.writes.getHead();

                // Write an empty batch control record.
                buff.reset();
                buff.writeInt(Journal.BATCH_CONTROL_RECORD_SIZE);
                buff.writeByte(Journal.BATCH_CONTROL_RECORD_TYPE);
                buff.write(Journal.BATCH_CONTROL_RECORD_MAGIC);
                buff.writeInt(0);
                buff.writeLong(0);

                boolean forceToDisk = false;
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.