本文整理了Java中org.mozilla.javascript.tools.shell.Global.readReader()
方法的一些代码示例,展示了Global.readReader()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Global.readReader()
方法的具体详情如下:
包路径:org.mozilla.javascript.tools.shell.Global
类名称:Global
方法名:readReader
暂无
代码示例来源:origin: com.github.tntim96/rhino
private static String readReader(Reader reader)
throws IOException
{
return readReader(reader, 4096);
}
代码示例来源:origin: ro.isdc.wro4j/rhino
private static String readReader(Reader reader)
throws IOException
{
return readReader(reader, 4096);
}
代码示例来源:origin: org.jvnet.hudson/embedded-rhino-debugger
private static String readReader(Reader reader)
throws IOException
{
return readReader(reader, 4096);
}
代码示例来源:origin: com.github.tntim96/rhino
private static InputStream toInputStream(Object value)
throws IOException
{
InputStream is = null;
String s = null;
if (value instanceof Wrapper) {
Object unwrapped = ((Wrapper)value).unwrap();
if (unwrapped instanceof InputStream) {
is = (InputStream)unwrapped;
} else if (unwrapped instanceof byte[]) {
is = new ByteArrayInputStream((byte[])unwrapped);
} else if (unwrapped instanceof Reader) {
s = readReader((Reader)unwrapped);
} else if (unwrapped instanceof char[]) {
s = new String((char[])unwrapped);
}
}
if (is == null) {
if (s == null) { s = ScriptRuntime.toString(value); }
is = new ByteArrayInputStream(s.getBytes());
}
return is;
}
代码示例来源:origin: org.jvnet.hudson/embedded-rhino-debugger
private static InputStream toInputStream(Object value)
throws IOException
{
InputStream is = null;
String s = null;
if (value instanceof Wrapper) {
Object unwrapped = ((Wrapper)value).unwrap();
if (unwrapped instanceof InputStream) {
is = (InputStream)unwrapped;
} else if (unwrapped instanceof byte[]) {
is = new ByteArrayInputStream((byte[])unwrapped);
} else if (unwrapped instanceof Reader) {
s = readReader((Reader)unwrapped);
} else if (unwrapped instanceof char[]) {
s = new String((char[])unwrapped);
}
}
if (is == null) {
if (s == null) { s = ScriptRuntime.toString(value); }
is = new ByteArrayInputStream(s.getBytes());
}
return is;
}
代码示例来源:origin: ro.isdc.wro4j/rhino
private static InputStream toInputStream(Object value)
throws IOException
{
InputStream is = null;
String s = null;
if (value instanceof Wrapper) {
Object unwrapped = ((Wrapper)value).unwrap();
if (unwrapped instanceof InputStream) {
is = (InputStream)unwrapped;
} else if (unwrapped instanceof byte[]) {
is = new ByteArrayInputStream((byte[])unwrapped);
} else if (unwrapped instanceof Reader) {
s = readReader((Reader)unwrapped);
} else if (unwrapped instanceof char[]) {
s = new String((char[])unwrapped);
}
}
if (is == null) {
if (s == null) { s = ScriptRuntime.toString(value); }
is = new ByteArrayInputStream(s.getBytes());
}
return is;
}
代码示例来源:origin: ro.isdc.wro4j/rhino
r = new InputStreamReader(is, charCoding);
return readReader(r, chunkLength);
代码示例来源:origin: org.jvnet.hudson/embedded-rhino-debugger
r = new InputStreamReader(is, charCoding);
return readReader(r, chunkLength);
代码示例来源:origin: com.github.tntim96/rhino
r = new InputStreamReader(is, charCoding);
return readReader(r, chunkLength);
内容来源于网络,如有侵权,请联系作者删除!