Examples of ZInputStream


Examples of bm.core.zlib.ZInputStream

        {
            //log.debug( "loadRecord( " + recordId + " )" );
            final byte[] data = rs.getRecord( recordId );
            final ByteArrayInputStream bais = new ByteArrayInputStream( data );
            final SerializerInputStream in = new SerializerInputStream(
                    useCompression() ? (InputStream) new ZInputStream( bais ) : bais
            );
            if( currentRecord == null )
            {
                currentRecord = new Record( recordId, info.multiplexer );
            }
View Full Code Here

Examples of bm.core.zlib.ZInputStream

            throws SerializationException, RecordStoreFullException,
                   RSException, IOException
    {
        final Log log = Util.log;

        ZInputStream zis = null;
        SerializerInputStream in = null;
        try
        {
            zis = new ZInputStream( is );
            in = new SerializerInputStream( zis );

            final int       order           = in.readInt(); // ToDo: should do something with this?
            final byte      type            = in.readByte();
            final boolean   caseSensitive   = in.readBoolean();
View Full Code Here

Examples of com.jcraft.jzlib.ZInputStream

                                connection.startCompression();
                                Log.debug("LocalOutgoingServerSession: OS - Stream compression was successful with " + hostname);
                                // Stream compression was successful so initiate a new stream
                                connection.deliverRawText(openingStream.toString());
                                // Reset the parser to use stream compression over TLS
                                ZInputStream in = new ZInputStream(
                                        connection.getTLSStreamHandler().getInputStream());
                                in.setFlushMode(JZlib.Z_PARTIAL_FLUSH);
                                xpp.setInput(new InputStreamReader(in, CHARSET));
                                // Skip the opening stream sent by the server
                                for (int eventType = xpp.getEventType(); eventType != XmlPullParser.START_TAG;)
                                {
                                    eventType = xpp.next();
View Full Code Here

Examples of com.jcraft.jzlib.ZInputStream

        boolean answer = super.compressClient(doc);
        if (answer) {
            XmlPullParser xpp = socketReader.reader.getXPPParser();
            // Reset the parser since a new stream header has been sent from the client
            if (socketReader.connection.getTLSStreamHandler() == null) {
                ZInputStream in = new ZInputStream(
                        ServerTrafficCounter.wrapInputStream(socket.getInputStream()));
                in.setFlushMode(JZlib.Z_PARTIAL_FLUSH);
                xpp.setInput(new InputStreamReader(in, CHARSET));
            }
            else {
                ZInputStream in = new ZInputStream(
                        socketReader.connection.getTLSStreamHandler().getInputStream());
                in.setFlushMode(JZlib.Z_PARTIAL_FLUSH);
                xpp.setInput(new InputStreamReader(in, CHARSET));
            }
        }
        return answer;
    }
View Full Code Here

Examples of nu.fw.jeti.plugins.compression.jcraft.jzlib.ZInputStream

    return zOut;
  }
 
  public static InputStream getCompressedInputStream(InputStream in)
  {
    ZInputStream zIn = new ZInputStream(in);
    zIn.setFlushMode(JZlib.Z_PARTIAL_FLUSH);
    return zIn;
  }
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.