本文整理了Java中org.eclipse.jetty.io.Buffer.capacity()
方法的一些代码示例,展示了Buffer.capacity()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Buffer.capacity()
方法的具体详情如下:
包路径:org.eclipse.jetty.io.Buffer
类名称:Buffer
方法名:capacity
[英]The capacity of the buffer. This is the maximum putIndex that may be set.
[中]缓冲区的容量。这是可以设置的最大索引。
代码示例来源:origin: org.eclipse.jetty.aggregate/jetty-all-server
/**
* @return The {@link Buffer#capacity} of the underlying buffer.
*/
public int capacity()
{
return _buffer.capacity();
}
代码示例来源:origin: org.eclipse.jetty.aggregate/jetty-server
/**
* @return The {@link Buffer#capacity} of the underlying buffer.
*/
public int capacity()
{
return _buffer.capacity();
}
代码示例来源:origin: org.eclipse.jetty.aggregate/jetty-webapp
/**
* @return The {@link Buffer#capacity} of the underlying buffer.
*/
public int capacity()
{
return _buffer.capacity();
}
代码示例来源:origin: org.eclipse.jetty.aggregate/jetty-plus
/**
* @return The {@link Buffer#capacity} of the underlying buffer.
*/
public int capacity()
{
return _buffer.capacity();
}
代码示例来源:origin: org.eclipse.jetty.aggregate/jetty-all-server
public Buffer getBuffer(int size)
{
synchronized(this)
{
if (_header!=null && _header.capacity()==size)
return getHeader();
if (_buffer!=null && _buffer.capacity()==size)
return getBuffer();
return null;
}
}
代码示例来源:origin: org.eclipse.jetty.aggregate/jetty-webapp
public Buffer getBuffer(int size)
{
ThreadBuffers buffers = _buffers.get();
if (buffers._other!=null && buffers._other.capacity()==size)
{
Buffer b=buffers._other;
buffers._other=null;
return b;
}
return newBuffer(size);
}
代码示例来源:origin: org.eclipse.jetty.aggregate/jetty-webapp
public Buffer getBuffer(int size)
{
synchronized(this)
{
if (_header!=null && _header.capacity()==size)
return getHeader();
if (_buffer!=null && _buffer.capacity()==size)
return getBuffer();
return null;
}
}
代码示例来源:origin: org.eclipse.jetty.aggregate/jetty-server
public Buffer getBuffer(int size)
{
ThreadBuffers buffers = _buffers.get();
if (buffers._other!=null && buffers._other.capacity()==size)
{
Buffer b=buffers._other;
buffers._other=null;
return b;
}
return newBuffer(size);
}
代码示例来源:origin: org.eclipse.jetty.aggregate/jetty-server
public Buffer getBuffer(int size)
{
synchronized(this)
{
if (_header!=null && _header.capacity()==size)
return getHeader();
if (_buffer!=null && _buffer.capacity()==size)
return getBuffer();
return null;
}
}
代码示例来源:origin: org.eclipse.jetty.aggregate/jetty-server
/**
* @return Returns the contentBufferSize.
*/
public int getContentBufferSize()
{
if (_buffer==null)
_buffer=_buffers.getBuffer();
return _buffer.capacity();
}
代码示例来源:origin: org.eclipse.jetty/http
/**
* @return Returns the contentBufferSize.
*/
public int getContentBufferSize()
{
if (_buffer==null)
_buffer=_buffers.getBuffer();
return _buffer.capacity();
}
代码示例来源:origin: org.eclipse.jetty.aggregate/jetty-plus
/**
* @return Returns the contentBufferSize.
*/
public int getContentBufferSize()
{
if (_buffer==null)
_buffer=_buffers.getBuffer();
return _buffer.capacity();
}
代码示例来源:origin: org.eclipse.jetty.aggregate/jetty-plus
public Buffer getBuffer(int size)
{
ThreadBuffers buffers = _buffers.get();
if (buffers._other!=null && buffers._other.capacity()==size)
{
Buffer b=buffers._other;
buffers._other=null;
return b;
}
return newBuffer(size);
}
代码示例来源:origin: org.eclipse.jetty.aggregate/jetty-all-server
public Buffer getBuffer(int size)
{
ThreadBuffers buffers = _buffers.get();
if (buffers._other!=null && buffers._other.capacity()==size)
{
Buffer b=buffers._other;
buffers._other=null;
return b;
}
return newBuffer(size);
}
代码示例来源:origin: org.eclipse.jetty.aggregate/jetty-webapp
/**
* @return Returns the contentBufferSize.
*/
public int getContentBufferSize()
{
if (_buffer==null)
_buffer=_buffers.getBuffer();
return _buffer.capacity();
}
代码示例来源:origin: org.eclipse.jetty.aggregate/jetty-all-server
/**
* @return Returns the contentBufferSize.
*/
public int getContentBufferSize()
{
if (_buffer==null)
_buffer=_buffers.getBuffer();
return _buffer.capacity();
}
代码示例来源:origin: org.eclipse.jetty.aggregate/jetty-plus
public Buffer getBuffer(int size)
{
synchronized(this)
{
if (_header!=null && _header.capacity()==size)
return getHeader();
if (_buffer!=null && _buffer.capacity()==size)
return getBuffer();
return null;
}
}
代码示例来源:origin: org.eclipse.jetty.aggregate/jetty-server
/**
* @param contentBufferSize The contentBufferSize to set.
*/
public void increaseContentBufferSize(int contentBufferSize)
{
if (_buffer==null)
_buffer=_buffers.getBuffer();
if (contentBufferSize > _buffer.capacity())
{
Buffer nb = _buffers.getBuffer(contentBufferSize);
nb.put(_buffer);
_buffers.returnBuffer(_buffer);
_buffer = nb;
}
}
代码示例来源:origin: org.eclipse.jetty.aggregate/jetty-plus
/**
* @param contentBufferSize The contentBufferSize to set.
*/
public void increaseContentBufferSize(int contentBufferSize)
{
if (_buffer==null)
_buffer=_buffers.getBuffer();
if (contentBufferSize > _buffer.capacity())
{
Buffer nb = _buffers.getBuffer(contentBufferSize);
nb.put(_buffer);
_buffers.returnBuffer(_buffer);
_buffer = nb;
}
}
代码示例来源:origin: org.eclipse.jetty.aggregate/jetty-all-server
/**
* @param contentBufferSize The contentBufferSize to set.
*/
public void increaseContentBufferSize(int contentBufferSize)
{
if (_buffer==null)
_buffer=_buffers.getBuffer();
if (contentBufferSize > _buffer.capacity())
{
Buffer nb = _buffers.getBuffer(contentBufferSize);
nb.put(_buffer);
_buffers.returnBuffer(_buffer);
_buffer = nb;
}
}
内容来源于网络,如有侵权,请联系作者删除!