本文整理了Java中org.apache.jackrabbit.oak.commons.IOUtils.readString()
方法的一些代码示例,展示了IOUtils.readString()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。IOUtils.readString()
方法的具体详情如下:
包路径:org.apache.jackrabbit.oak.commons.IOUtils
类名称:IOUtils
方法名:readString
[英]Read a String. This will first read the length as 4 bytes, and then the UTF-8 encoded string.
[中]读一个字符串。这将首先读取长度为4字节,然后读取UTF-8编码字符串。
代码示例来源:origin: org.apache.jackrabbit/oak-mk
@Override
public String readStringValue(String key) throws Exception {
if (in == null) {
throw new IllegalStateException("no InputStream provided");
}
return IOUtils.readString(in);
}
代码示例来源:origin: org.apache.jackrabbit/oak-mk
public StringEntry next() {
if (count-- > 0) {
try {
String key = IOUtils.readString(in);
String value = IOUtils.readString(in);
return new StringEntry(key, value);
} catch (IOException e) {
throw new RuntimeException("deserialization failed", e);
}
}
throw new NoSuchElementException();
}
代码示例来源:origin: org.apache.jackrabbit/oak-mk
public BytesEntry next() {
if (count-- > 0) {
try {
String key = IOUtils.readString(in);
byte[] value = IOUtils.readBytes(in);
return new BytesEntry(key, value);
} catch (IOException e) {
throw new RuntimeException("deserialization failed", e);
}
}
throw new NoSuchElementException();
}
代码示例来源:origin: apache/jackrabbit-oak
String t = IOUtils.readString(in);
assertEquals(s, t);
assertEquals(-1, in.read());
IOUtils.readString(in);
fail();
} catch (EOFException e) {
内容来源于网络,如有侵权,请联系作者删除!