本文整理汇总了Java中org.simpleframework.util.buffer.Buffer类的典型用法代码示例。如果您正苦于以下问题:Java Buffer类的具体用法?Java Buffer怎么用?Java Buffer使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。
Buffer类属于org.simpleframework.util.buffer包,在下文中一共展示了Buffer类的8个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: allocate
import org.simpleframework.util.buffer.Buffer; //导入依赖的package包/类
public Buffer allocate() {
return buffer;
}
示例2: getBuffer
import org.simpleframework.util.buffer.Buffer; //导入依赖的package包/类
public Buffer getBuffer() {
return buffer;
}
示例3: allocate
import org.simpleframework.util.buffer.Buffer; //导入依赖的package包/类
public Buffer allocate() throws IOException {
return new BufferQueue(queue);
}
示例4: append
import org.simpleframework.util.buffer.Buffer; //导入依赖的package包/类
public Buffer append(byte[] array) throws IOException {
if(array.length > 0) {
queue.write(array);
}
return this;
}
示例5: BufferPart
import org.simpleframework.util.buffer.Buffer; //导入依赖的package包/类
/**
* Constructor for the <code>BufferPart</code> object. This is
* used to create a part from a multipart body. Each part will
* contain the headers associated with it as well as the body.
*
* @param segment this holds the headers for the part
* @param buffer this represents the body for the part
*/
public BufferPart(Segment segment, Buffer buffer) {
this.body = new BufferBody(buffer);
this.segment = segment;
}
示例6: BufferBody
import org.simpleframework.util.buffer.Buffer; //导入依赖的package包/类
/**
* Constructor for the <code>BufferBody</code> object. This is
* used to create a body that represents a HTTP payload. The
* body enables the payload to be either read in a stream or
* as an encoded string. Also the attachments are available.
*
* @param buffer this is the buffer representing the body
*/
public BufferBody(Buffer buffer) {
this(buffer, null);
}
示例7: BufferPart
import org.simpleframework.util.buffer.Buffer; //导入依赖的package包/类
/**
* Constructor for the <code>BufferPart</code> object. This is used to
* create a part from a multipart body. Each part will contain the headers
* associated with it as well as the body.
*
* @param segment
* this holds the headers for the part
* @param buffer
* this represents the body for the part
*/
public BufferPart(Segment segment, Buffer buffer) {
this.body = new BufferBody(buffer);
this.segment = segment;
}
示例8: BufferBody
import org.simpleframework.util.buffer.Buffer; //导入依赖的package包/类
/**
* Constructor for the <code>BufferBody</code> object. This is used to
* create a body that represents a HTTP payload. The body enables the
* payload to be either read in a stream or as an encoded string. Also the
* attachments are available.
*
* @param buffer
* this is the buffer representing the body
*/
public BufferBody(Buffer buffer) {
this(buffer, null);
}