Examples of writeUTF()


Examples of java.io.ObjectOutputStream.writeUTF()

        if (swimlaneContextInstance != null) {
            Map<String, String> swimlaneActors = swimlaneContextInstance.getSwimlaneActors();
            stream.writeInt(swimlaneActors.size());
            for (Map.Entry<String, String> entry : swimlaneActors.entrySet()) {
                stream.writeUTF(entry.getKey());
                stream.writeUTF(entry.getValue());
            }
        } else {
            stream.writeInt(0);
        }
       
View Full Code Here

Examples of java.io.ObjectOutputStream.writeUTF()

               
        stream.writeInt(notNullValues.size());
        for (String key : keys) {
            Object object = variables.get(key);
            if(object != null){
                stream.writeUTF(key);
                int index = context.objectMarshallingStrategyStore.getStrategy(object);
                stream.writeInt(index);
                ObjectMarshallingStrategy strategy = context.objectMarshallingStrategyStore.getStrategy(index);
                if(strategy.accept(object)){
                    strategy.write(stream, object);
View Full Code Here

Examples of java.io.ObjectOutputStream.writeUTF()

        HostConfiguration hostConfig = hostGroup.getHostByName(hostname);
        String webAppPrefix = inControl.readUTF();
        WebAppConfiguration webAppConfig = hostConfig.getWebAppByURI(webAppPrefix);
        ObjectOutputStream outData = new ObjectOutputStream(out);
        if (webAppConfig == null) {
            outData.writeUTF(ClusterSessionSearch.SESSION_NOT_FOUND);
        } else {
            WinstoneSession session = webAppConfig.getSessionById(sessionId, true);
            if (session != null) {
                outData.writeUTF(ClusterSessionSearch.SESSION_FOUND);
                outData.writeObject(session);
View Full Code Here

Examples of java.io.ObjectOutputStream.writeUTF()

        if (webAppConfig == null) {
            outData.writeUTF(ClusterSessionSearch.SESSION_NOT_FOUND);
        } else {
            WinstoneSession session = webAppConfig.getSessionById(sessionId, true);
            if (session != null) {
                outData.writeUTF(ClusterSessionSearch.SESSION_FOUND);
                outData.writeObject(session);
                outData.flush();
                if (inControl.readUTF().equals(
                        ClusterSessionSearch.SESSION_RECEIVED))
                    session.passivate();
View Full Code Here

Examples of java.io.ObjectOutputStream.writeUTF()

                        ClusterSessionSearch.SESSION_RECEIVED))
                    session.passivate();
                Logger.log(Logger.DEBUG, CLUSTER_RESOURCES,
                        "SimpleCluster.SessionTransferredTo", ipPortSender);
            } else {
                outData.writeUTF(ClusterSessionSearch.SESSION_NOT_FOUND);
            }
        }
        outData.close();
        inControl.close();
    }
View Full Code Here

Examples of java.io.ObjectOutputStream.writeUTF()

        outData.writeInt(relevantClusterNodes.size());
        outData.flush();
        for (Iterator i = relevantClusterNodes.iterator(); i.hasNext();) {
            String ipPort = (String) i.next();
            if (!ipPort.equals(ipPortSender))
                outData.writeUTF(ipPort);
            outData.flush();
        }
        outData.close();
        inControl.close();
    }
View Full Code Here

Examples of java.io.ObjectOutputStream.writeUTF()

            Socket socket = new Socket(host, Integer.parseInt(port));
            socket.setSoTimeout(TIMEOUT);
            OutputStream out = socket.getOutputStream();
            out.write(Launcher.RELOAD_TYPE);
            ObjectOutputStream objOut = new ObjectOutputStream(out);
            objOut.writeUTF(host);
            objOut.writeUTF(webappName);
            objOut.close();
            out.close();
            Logger.log(Logger.INFO, TOOLS_RESOURCES, "WinstoneControl.ReloadOK",
                    new String[] { host, port });
View Full Code Here

Examples of java.io.RandomAccessFile.writeUTF()

     */
    public void test_readUTF() throws IOException {
        // Test for method java.lang.String java.io.RandomAccessFile.readUTF()

        RandomAccessFile raf = new java.io.RandomAccessFile(fileName, "rw");
        raf.writeUTF(unihw);
        raf.seek(0);
        assertEquals("Incorrect utf string read", unihw, raf.readUTF());
        raf.close();
    }

View Full Code Here

Examples of javax.jms.BytesMessage.writeUTF()

      sent.writeInt(314159);
      sent.writeLong(3141592653589793238L);
      sent.writeDouble(3.1415926535897932384626433832795);
      sent.writeFloat(3.141f);
      sent.writeObject("31415926535897932384626433832795");
      sent.writeUTF("31415926535897932384626433832795");

      BytesMessage recv = (BytesMessage) sendRecMsg(sent);
      log.debug("recv: "+recv);
      assertTrue("Boolean == true", recv.readBoolean() == true);
      assertTrue("Byte == 1", recv.readByte() == 1);
View Full Code Here

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

    {
        BytesMessageImpl msg = new BytesMessageImpl();
        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);
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.