本文整理了Java中org.fusesource.hawtbuf.Buffer.deepCopy()
方法的一些代码示例,展示了Buffer.deepCopy()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Buffer.deepCopy()
方法的具体详情如下:
包路径:org.fusesource.hawtbuf.Buffer
类名称:Buffer
方法名:deepCopy
暂无
代码示例来源:origin: org.fusesource.hawtbuf/hawtbuf
public Buffer deepCopy(Buffer source) {
return source.deepCopy();
}
代码示例来源:origin: org.apache.activemq/activemq-all
public Buffer deepCopy(Buffer source) {
return source.deepCopy();
}
代码示例来源:origin: org.apache.activemq/activemq-osgi
public Buffer deepCopy(Buffer source) {
return source.deepCopy();
}
代码示例来源:origin: org.apache.activemq/activemq-osgi
public T deepCopy(T source) {
return createBuffer(source.deepCopy().data);
}
代码示例来源:origin: org.fusesource.hawtbuf/hawtbuf
public T deepCopy(T source) {
return createBuffer(source.deepCopy().data);
}
代码示例来源:origin: org.apache.activemq/activemq-all
public T deepCopy(T source) {
return createBuffer(source.deepCopy().data);
}
代码示例来源:origin: org.apache.activemq/activemq-all
@Override
public void parse(ByteBuffer incoming) throws IOException {
int length = Math.min(incoming.remaining(), header.length - header.offset);
incoming.get(header.data, header.offset, length);
header.offset += length;
if (header.offset == AMQP_HEADER_BYTES) {
header.reset();
AmqpHeader amqpHeader = new AmqpHeader(header.deepCopy(), false);
currentParser = initializeFrameLengthParser();
frameSink.onFrame(amqpHeader);
if (incoming.hasRemaining()) {
currentParser.parse(incoming);
}
}
}
代码示例来源:origin: org.apache.activemq/activemq-osgi
@Override
public void parse(ByteBuffer incoming) throws IOException {
int length = Math.min(incoming.remaining(), header.length - header.offset);
incoming.get(header.data, header.offset, length);
header.offset += length;
if (header.offset == AMQP_HEADER_BYTES) {
header.reset();
AmqpHeader amqpHeader = new AmqpHeader(header.deepCopy(), false);
currentParser = initializeFrameLengthParser();
frameSink.onFrame(amqpHeader);
if (incoming.hasRemaining()) {
currentParser.parse(incoming);
}
}
}
代码示例来源:origin: fusesource/stompjms
private void setBytesHeader(AsciiBuffer key, byte[] value) {
if(value==null) {
getHeaderMap().remove(key);
} else {
getHeaderMap().put(key, new Buffer(value).deepCopy().ascii());
}
}
代码示例来源:origin: org.fusesource.stompjms/stompjms-client
private void setBytesHeader(AsciiBuffer key, byte[] value) {
if(value==null) {
getHeaderMap().remove(key);
} else {
getHeaderMap().put(key, new Buffer(value).deepCopy().ascii());
}
}
代码示例来源:origin: org.apache.activemq/activemq-osgi
private void processCommand() throws IOException {
Buffer frameContents = null;
if (currentBuffer == scratch) {
frameContents = scratch.deepCopy();
} else {
frameContents = currentBuffer;
currentBuffer = null;
}
MQTTFrame frame = new MQTTFrame(frameContents).header(header);
frameSink.onFrame(frame);
}
代码示例来源:origin: io.fabric8.ipaas.apps/fabric8mq
private void processCommand() throws IOException {
Buffer frameContents;
if (currentBuffer == scratch) {
frameContents = scratch.deepCopy();
} else {
frameContents = currentBuffer;
currentBuffer = null;
}
MQTTFrame frame = new MQTTFrame(frameContents).header(header);
frameSink.onFrame(frame);
}
代码示例来源:origin: org.apache.activemq/activemq-all
private void processCommand() throws IOException {
Buffer frameContents = null;
if (currentBuffer == scratch) {
frameContents = scratch.deepCopy();
} else {
frameContents = currentBuffer;
currentBuffer = null;
}
MQTTFrame frame = new MQTTFrame(frameContents).header(header);
frameSink.onFrame(frame);
}
代码示例来源:origin: org.apache.activemq/activemq-mqtt
private void processCommand() throws IOException {
Buffer frameContents = null;
if (currentBuffer == scratch) {
frameContents = scratch.deepCopy();
} else {
frameContents = currentBuffer;
currentBuffer = null;
}
MQTTFrame frame = new MQTTFrame(frameContents).header(header);
frameSink.onFrame(frame);
}
代码示例来源:origin: io.fabric8.jube.images.fabric8/fabric8-mq
private void processCommand() throws IOException {
Buffer frameContents;
if (currentBuffer == scratch) {
frameContents = scratch.deepCopy();
} else {
frameContents = currentBuffer;
currentBuffer = null;
}
MQTTFrame frame = new MQTTFrame(frameContents).header(header);
frameSink.onFrame(frame);
}
内容来源于网络,如有侵权,请联系作者删除!