org.apache.activemq.util.ByteArrayOutputStream.checkCapacity()方法的使用及代码示例

x33g5p2x  于2022-01-17 转载在 其他  
字(2.0k)|赞(0)|评价(0)|浏览(126)

本文整理了Java中org.apache.activemq.util.ByteArrayOutputStream.checkCapacity()方法的一些代码示例,展示了ByteArrayOutputStream.checkCapacity()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。ByteArrayOutputStream.checkCapacity()方法的具体详情如下:
包路径:org.apache.activemq.util.ByteArrayOutputStream
类名称:ByteArrayOutputStream
方法名:checkCapacity

ByteArrayOutputStream.checkCapacity介绍

[英]Ensures the the buffer has at least the minimumCapacity specified.
[中]确保缓冲区至少具有指定的最小容量。

代码示例

代码示例来源:origin: apache/activemq

public void write(int b) {
  int newsize = size + 1;
  checkCapacity(newsize);
  buffer[size] = (byte) b;
  size = newsize;
}

代码示例来源:origin: apache/activemq

public void write(byte b[], int off, int len) {
  int newsize = size + len;
  checkCapacity(newsize);
  System.arraycopy(b, off, buffer, size, len);
  size = newsize;
}

代码示例来源:origin: org.apache.activemq/activemq-all

public void write(int b) {
  int newsize = size + 1;
  checkCapacity(newsize);
  buffer[size] = (byte) b;
  size = newsize;
}

代码示例来源:origin: org.apache.activemq/activemq-client

public void write(int b) {
  int newsize = size + 1;
  checkCapacity(newsize);
  buffer[size] = (byte) b;
  size = newsize;
}

代码示例来源:origin: org.apache.activemq/activemq-osgi

public void write(int b) {
  int newsize = size + 1;
  checkCapacity(newsize);
  buffer[size] = (byte) b;
  size = newsize;
}

代码示例来源:origin: pierre/meteo

public void write(int b) {
  int newsize = size + 1;
  checkCapacity(newsize);
  buffer[size] = (byte) b;
  size = newsize;
}

代码示例来源:origin: org.apache.activemq/activemq-client

public void write(byte b[], int off, int len) {
  int newsize = size + len;
  checkCapacity(newsize);
  System.arraycopy(b, off, buffer, size, len);
  size = newsize;
}

代码示例来源:origin: org.apache.activemq/activemq-osgi

public void write(byte b[], int off, int len) {
  int newsize = size + len;
  checkCapacity(newsize);
  System.arraycopy(b, off, buffer, size, len);
  size = newsize;
}

代码示例来源:origin: org.apache.activemq/activemq-all

public void write(byte b[], int off, int len) {
  int newsize = size + len;
  checkCapacity(newsize);
  System.arraycopy(b, off, buffer, size, len);
  size = newsize;
}

代码示例来源:origin: pierre/meteo

public void write(byte b[], int off, int len) {
  int newsize = size + len;
  checkCapacity(newsize);
  System.arraycopy(b, off, buffer, size, len);
  size = newsize;
}

相关文章