本文整理了Java中java.io.BufferedReader.fillBuf()
方法的一些代码示例,展示了BufferedReader.fillBuf()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。BufferedReader.fillBuf()
方法的具体详情如下:
包路径:java.io.BufferedReader
类名称:BufferedReader
方法名:fillBuf
[英]Populates the buffer with data. It is an error to call this method when the buffer still contains data; ie. if pos < end.
[中]用数据填充缓冲区。当缓冲区仍然包含数据时调用此方法是错误的;即,如果位置<结束。
代码示例来源:origin: robovm/robovm
private int readChar() throws IOException {
if (pos < end || fillBuf() != -1) {
return buf[pos++];
}
return -1;
}
代码示例来源:origin: robovm/robovm
/**
* Peeks at the next input character, refilling the buffer if necessary. If
* this character is a newline character ("\n"), it is discarded.
*/
final void chompNewline() throws IOException {
if ((pos != end || fillBuf() != -1) && buf[pos] == '\n') {
++pos;
}
}
代码示例来源:origin: robovm/robovm
pos = end;
while (read < charCount) {
if (fillBuf() == -1) {
return read;
代码示例来源:origin: robovm/robovm
while (true) {
pos = end;
if (fillBuf() == -1) {
代码示例来源:origin: robovm/robovm
if (fillBuf() == -1) {
break; // source is exhausted
代码示例来源:origin: MobiVM/robovm
private int readChar() throws IOException {
if (pos < end || fillBuf() != -1) {
return buf[pos++];
}
return -1;
}
代码示例来源:origin: ibinti/bugvm
private int readChar() throws IOException {
if (pos < end || fillBuf() != -1) {
return buf[pos++];
}
return -1;
}
代码示例来源:origin: ibinti/bugvm
/**
* Peeks at the next input character, refilling the buffer if necessary. If
* this character is a newline character ("\n"), it is discarded.
*/
final void chompNewline() throws IOException {
if ((pos != end || fillBuf() != -1) && buf[pos] == '\n') {
++pos;
}
}
代码示例来源:origin: com.gluonhq/robovm-rt
private int readChar() throws IOException {
if (pos < end || fillBuf() != -1) {
return buf[pos++];
}
return -1;
}
代码示例来源:origin: com.gluonhq/robovm-rt
/**
* Peeks at the next input character, refilling the buffer if necessary. If
* this character is a newline character ("\n"), it is discarded.
*/
final void chompNewline() throws IOException {
if ((pos != end || fillBuf() != -1) && buf[pos] == '\n') {
++pos;
}
}
代码示例来源:origin: MobiVM/robovm
/**
* Peeks at the next input character, refilling the buffer if necessary. If
* this character is a newline character ("\n"), it is discarded.
*/
final void chompNewline() throws IOException {
if ((pos != end || fillBuf() != -1) && buf[pos] == '\n') {
++pos;
}
}
代码示例来源:origin: com.bugvm/bugvm-rt
private int readChar() throws IOException {
if (pos < end || fillBuf() != -1) {
return buf[pos++];
}
return -1;
}
代码示例来源:origin: com.jtransc/jtransc-rt
/**
* Peeks at the next input character, refilling the buffer if necessary. If
* this character is a newline character ("\n"), it is discarded.
*/
final void chompNewline() throws IOException {
if ((pos != end || fillBuf() != -1) && buf[pos] == '\n') {
++pos;
}
}
代码示例来源:origin: com.bugvm/bugvm-rt
/**
* Peeks at the next input character, refilling the buffer if necessary. If
* this character is a newline character ("\n"), it is discarded.
*/
final void chompNewline() throws IOException {
if ((pos != end || fillBuf() != -1) && buf[pos] == '\n') {
++pos;
}
}
代码示例来源:origin: FlexoVM/flexovm
private int readChar() throws IOException {
if (pos < end || fillBuf() != -1) {
return buf[pos++];
}
return -1;
}
代码示例来源:origin: com.mobidevelop.robovm/robovm-rt
private int readChar() throws IOException {
if (pos < end || fillBuf() != -1) {
return buf[pos++];
}
return -1;
}
代码示例来源:origin: com.mobidevelop.robovm/robovm-rt
/**
* Peeks at the next input character, refilling the buffer if necessary. If
* this character is a newline character ("\n"), it is discarded.
*/
final void chompNewline() throws IOException {
if ((pos != end || fillBuf() != -1) && buf[pos] == '\n') {
++pos;
}
}
代码示例来源:origin: com.jtransc/jtransc-rt
private int readChar() throws IOException {
if (pos < end || fillBuf() != -1) {
return buf[pos++];
}
return -1;
}
代码示例来源:origin: FlexoVM/flexovm
/**
* Peeks at the next input character, refilling the buffer if necessary. If
* this character is a newline character ("\n"), it is discarded.
*/
final void chompNewline() throws IOException {
if ((pos != end || fillBuf() != -1) && buf[pos] == '\n') {
++pos;
}
}
代码示例来源:origin: MobiVM/robovm
pos = end;
while (read < charCount) {
if (fillBuf() == -1) {
return read;
内容来源于网络,如有侵权,请联系作者删除!