Examples of buffer()


Examples of org.apache.lucene.analysis.tokenattributes.CharTermAttribute.buffer()

        if ( termsAtSamePosition == null ) {
          termsAtSamePosition = new ArrayList<Term>();
          termsPerPosition.put( position, termsAtSamePosition );
        }

        String termString = new String( termAttribute.buffer(), 0, termAttribute.length() );
        termsAtSamePosition.add( new Term( fieldName, termString ) );
        if ( termsAtSamePosition.size() > 1 ) {
          isMultiPhrase = true;
        }
      }
View Full Code Here

Examples of org.apache.qpid.transport.codec.BBEncoder.buffer()

            {
                encoder.writeStruct32(header);
            }

        }
        ByteBuffer buf = encoder.buffer();
        return buf;
    }

    public int writeToBuffer(int offsetInMetaData, ByteBuffer dest)
    {
View Full Code Here

Examples of org.apache.qpid.transport.codec.BBEncoder.buffer()

        {
            cmd.encode(encoder);
        }


        _content = encoder.buffer();
    }

    public String getRoutingKey()
    {
        return _routingKey;
View Full Code Here

Examples of org.fusesource.hawtbuf.Buffer.buffer()

        // array copy.
        final Buffer command = baos.toBuffer();


        // Update the field size.
        BufferEditor editor = command.buffer().bigEndianEditor();
        editor.writeInt(command.length);
        handler.lastRequestSize = command.length;

        queue().execute(new Runnable() {
            public void run() {
View Full Code Here

Examples of org.geomajas.gwt.client.spatial.Bbox.buffer()

      Bbox targetMaxBounds = getOverviewMaxBounds();

      MapView mapView = getMapModel().getMapView();

      // Set the maxBounds on this map as well:
      mapView.setMaxBounds(targetMaxBounds.buffer(targetMaxBounds.getWidth()));

      // apply buffer
      if (maxExtentIncreasePercentage > 0) {
        targetMaxBounds = targetMaxBounds
            .buffer(targetMaxBounds.getWidth() * maxExtentIncreasePercentage / 100);
View Full Code Here

Examples of org.geomajas.gwt.client.spatial.Bbox.buffer()

      // Set the maxBounds on this map as well:
      mapView.setMaxBounds(targetMaxBounds.buffer(targetMaxBounds.getWidth()));

      // apply buffer
      if (maxExtentIncreasePercentage > 0) {
        targetMaxBounds = targetMaxBounds
            .buffer(targetMaxBounds.getWidth() * maxExtentIncreasePercentage / 100);
      }

      // Then apply the map extent:
      mapView.applyBounds(targetMaxBounds, MapView.ZoomOption.LEVEL_FIT);
View Full Code Here

Examples of org.hypertable.thrift.SerializedCellsWriter.buffer()

                writer.add(key, _columnFamily, entry.getKey(),
                        SerializedCellsFlag.AUTO_ASSIGN,
                        ByteBuffer.wrap(entry.getValue().toArray()));           
            }
            connection.mutator_set_cells_serialized(mutator,
                    writer.buffer(), true);
            connection.mutator_close(mutator);
        } catch (ClientException e) {
            if (_debug) {
                System.err.println("Error doing set: " + e.message);
            }
View Full Code Here

Examples of org.jboss.netty.buffer.ChannelBufferOutputStream.buffer()

        oout.writeObject(e.getMessage());
        ExternalizeUtil.writeCollection(oout, oout.getReferences());
        oout.flush();
        oout.close();

        ChannelBuffer encoded = bout.buffer();
        encoded.setInt(0, encoded.writerIndex() - 4);
        write(ctx, e.getFuture(), encoded, e.getRemoteAddress());
    for (InputStream is : oout.getStreams()) {
      Channels.write(ctx.getChannel(), new AnonymousChunkedStream(new BufferedInputStream(is, CHUNK_SIZE)));
    }
View Full Code Here

Examples of org.jboss.netty.buffer.ChannelBufferOutputStream.buffer()

        //add a END_OF_BATCH indicator
        ControlMessage.EOB_MESSAGE.write(bout);

        bout.close();

        return bout.buffer();
    }

    /**
     * write a TaskMessage into a stream
     *
 
View Full Code Here

Examples of org.jboss.netty.buffer.ChannelBufferOutputStream.buffer()

        ObjectOutputStream oout = new CompactObjectOutputStream(bout);
        oout.writeObject(msg);
        oout.flush();
        oout.close();

        ChannelBuffer encoded = bout.buffer();
        encoded.setInt(0, encoded.writerIndex() - 4);
        return encoded;
    }
}
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.