Examples of writeInt()


Examples of org.jboss.as.protocol.mgmt.FlushableDataOutput.writeInt()

                        final int size = entry.initialize();
                        try {
                            final FlushableDataOutput output = context.writeMessage(response);
                            try {
                                output.writeByte(ModelControllerProtocol.PARAM_INPUTSTREAM_LENGTH);
                                output.writeInt(size);
                                output.writeByte(ModelControllerProtocol.PARAM_INPUTSTREAM_CONTENTS);
                                entry.copyStream(output);
                                output.writeByte(ManagementProtocol.RESPONSE_END);
                                output.close();
                            } finally {
View Full Code Here

Examples of org.jboss.invocation.MarshalledValueOutputStream.writeInt()

   private void initializeStateTransfer(OutputStream baos) throws IOException
   {
      MarshalledValueOutputStream out = new MarshalledValueOutputStream(baos);
      out.writeShort(STATE_TRANSFER_VERSION);
      // Write a placeholder for the 3 sizes we'll merge in later
      out.writeInt(0);
      out.writeInt(0);
      out.writeInt(0);
      out.close();
   }
View Full Code Here

Examples of org.jboss.jms.message.JBossBytesMessage.writeInt()

      m.writeByte(randByte().byteValue());
      m.writeBytes(randByteArray(500));
      m.writeChar(randChar().charValue());
      m.writeDouble(randDouble().doubleValue());
      m.writeFloat(randFloat().floatValue());
      m.writeInt(randInt().intValue());
      m.writeLong(randLong().longValue());     
      m.writeShort(randShort().shortValue());
      m.writeUTF(randString(1000));

      return m;     
View Full Code Here

Examples of org.jboss.jms.message.JBossStreamMessage.writeInt()

      m.writeByte(randByte().byteValue());
      m.writeBytes(randByteArray(500));
      m.writeChar(randChar().charValue());
      m.writeDouble(randDouble().doubleValue());
      m.writeFloat(randFloat().floatValue());
      m.writeInt(randInt().intValue());
      m.writeLong(randLong().longValue());
      m.writeShort(randShort().shortValue());
      m.writeString(randString(1000));
      return m;     
   }
View Full Code Here

Examples of org.jboss.marshalling.Marshaller.writeInt()

            }

            final Marshaller marshaller = getMarshaller();
            marshaller.start(createByteOutput(output));
            marshaller.writeByte(StandaloneClientProtocol.PARAM_APPLY_UPDATES_RESULT_COUNT);
            marshaller.writeInt(results.size());
            for(ResultHandler<?, Void> result : results) {
                marshaller.writeByte(StandaloneClientProtocol.PARAM_APPLY_UPDATE_RESULT);
                if(result.failure != null) {
                    marshaller.writeByte(StandaloneClientProtocol.PARAM_APPLY_UPDATE_RESULT_EXCEPTION);
                    marshaller.writeObject(result.failure);
View Full Code Here

Examples of org.jboss.marshalling.SimpleDataOutput.writeInt()

            FileOutputStream outputStream = null;
            try {
                outputStream = FOSAction.open(file);
                SimpleDataOutput output = new SimpleDataOutput(Marshalling.createByteOutput(outputStream));
                int version = this.passivationManager.getCurrentMarshallingVersion();
                output.writeInt(version);
                MarshallingConfiguration config = this.passivationManager.getMarshallingConfiguration(version);
                Marshaller marshaller = this.marshallerFactory.createMarshaller(config);
                marshaller.start(output);
                try {
                    marshaller.writeObject(obj);
View Full Code Here

Examples of org.jboss.netty.buffer.BigEndianHeapChannelBuffer.writeInt()

                .setQuestioner("Chen Shuo")
                .addQuestion("Running?")
                .build();
        ChannelBuffer buf = (ChannelBuffer) encoder.encode(null, null, query);
        ChannelBuffer buf2 = new BigEndianHeapChannelBuffer(buf.readableBytes() + 8);
        buf2.writeInt(123);
        buf2.writeBytes(buf);

        buf2.readInt();
        ProtobufDecoder decoder = new ProtobufDecoder();
        decoder.addMessageType(Query.getDefaultInstance());
View Full Code Here

Examples of org.jboss.netty.buffer.ChannelBuffer.writeInt()

    this.dataOut = null;
   
    // now build the wire contents.
    ChannelBuffer buffer = ChannelBuffers.directBuffer(len+5);
    buffer.writeByte((byte)this.messageType);
    buffer.writeInt(len+4);
    buffer.writeBytes(buff);
    Channels.write(this.ctx, this.message.getFuture(), buffer, this.message.getRemoteAddress());
  }

  private static void trace(String... msg) {
View Full Code Here

Examples of org.jboss.remoting3.jmx.protocol.CancellableDataOutputStream.writeInt()

    private void writeHeader(final Channel channel) throws IOException {
        CancellableDataOutputStream dos = new CancellableDataOutputStream(channel.writeMessage());
        try {
            dos.writeBytes("JMX");
            byte[] versions = Versions.getSupportedVersions();
            dos.writeInt(versions.length);
            dos.write(versions);
            if (Version.isSnapshot()) {
                dos.write(SNAPSHOT);
            } else {
                dos.write(STABLE);
View Full Code Here

Examples of org.jboss.remotingjmx.protocol.CancellableDataOutputStream.writeInt()

            try {
                dos.writeBytes(JMX);
                dos.writeByte(0x00);
                String remotingJMXVersion = Version.getVersionString();
                byte[] versionBytes = remotingJMXVersion.getBytes("UTF-8");
                dos.writeInt(versionBytes.length);
                dos.write(versionBytes);
            } catch (IOException e) {
                dos.cancel();
                throw e;
            } finally {
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.