本文整理了Java中org.uberfire.java.nio.IOException
类的一些代码示例,展示了IOException
类的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。IOException
类的具体详情如下:
包路径:org.uberfire.java.nio.IOException
类名称:IOException
暂无
代码示例来源:origin: org.uberfire/vfs-fs
@Override
public void close() throws IOException {
if (isClosed) {
throw new IOException();
}
isClosed = true;
}
代码示例来源:origin: org.jbpm/jbpm-console-ng-business-domain-backend
@Override
public byte[] loadFile( final Path file ) throws FileException {
if (!isActive()) {
return new byte[0];
}
checkNotNull( "file", file );
try {
return getIOService().readAllBytes( file );
} catch ( IOException ex ) {
throw new FileException( ex.getMessage(), ex );
}
}
代码示例来源:origin: org.jbpm/jbpm-console-ng-business-domain-backend
@Override
public byte[] loadFile(Path file) throws FileException {
checkNotNull( "file", file );
try {
return ioService.readAllBytes( file );
} catch ( IOException ex ) {
throw new FileException( ex.getMessage(), ex );
}
}
代码示例来源:origin: org.uberfire/uberfire-nio2-fs
@Override
public void close() throws IOException {
if (isClosed) {
throw new IOException("This stream is closed.");
}
isClosed = true;
}
代码示例来源:origin: kiegroup/appformer
@Override
public void close() throws IOException {
if (isClosed) {
throw new IOException("This stream is closed.");
}
isClosed = true;
}
代码示例来源:origin: org.uberfire/uberfire-nio2-model
@Override
public SeekableByteChannel truncate(final long size) throws IOException {
try {
channel.truncate(size);
return this;
} catch (java.io.IOException e) {
throw new IOException(e);
}
}
代码示例来源:origin: org.uberfire/uberfire-nio2-model
@Override
public void close() throws java.io.IOException {
try {
channel.close();
} catch (java.io.IOException e) {
throw new IOException(e);
}
}
}
代码示例来源:origin: org.uberfire/uberfire-nio2-model
@Override
public long position() throws IOException {
try {
return channel.position();
} catch (java.io.IOException e) {
throw new IOException(e);
}
}
代码示例来源:origin: org.uberfire/uberfire-nio2-model
@Override
public long size() throws IOException {
try {
return channel.size();
} catch (java.io.IOException e) {
throw new IOException(e);
}
}
代码示例来源:origin: org.uberfire/uberfire-nio2-model
@Override
public int read(final ByteBuffer dst) throws java.io.IOException {
try {
return channel.read(dst);
} catch (java.io.IOException e) {
throw new IOException(e);
}
}
代码示例来源:origin: org.uberfire/uberfire-nio2-model
@Override
public SeekableByteChannel position(final long newPosition) throws IOException {
try {
channel.position(newPosition);
return this;
} catch (java.io.IOException e) {
throw new IOException(e);
}
}
代码示例来源:origin: org.uberfire/uberfire-nio2-model
@Override
public int write(final ByteBuffer src) throws java.io.IOException {
try {
return channel.write(src);
} catch (java.io.IOException e) {
throw new IOException(e);
}
}
代码示例来源:origin: kiegroup/appformer
@Override
public long position() throws IOException {
try {
return channel.position();
} catch (java.io.IOException e) {
throw new IOException(e);
}
}
代码示例来源:origin: kiegroup/appformer
@Override
public SeekableByteChannel position(final long newPosition) throws IOException {
try {
channel.position(newPosition);
return this;
} catch (java.io.IOException e) {
throw new IOException(e);
}
}
代码示例来源:origin: kiegroup/appformer
@Override
public SeekableByteChannel truncate(final long size) throws IOException {
try {
channel.truncate(size);
return this;
} catch (java.io.IOException e) {
throw new IOException(e);
}
}
代码示例来源:origin: kiegroup/appformer
@Override
public int read(final ByteBuffer dst) throws java.io.IOException {
try {
return channel.read(dst);
} catch (java.io.IOException e) {
throw new IOException(e);
}
}
代码示例来源:origin: kiegroup/appformer
@Override
public int write(final ByteBuffer src) throws java.io.IOException {
try {
return channel.write(src);
} catch (java.io.IOException e) {
throw new IOException(e);
}
}
代码示例来源:origin: kiegroup/appformer
@Override
public long size() throws IOException {
try {
return channel.size();
} catch (java.io.IOException e) {
throw new IOException(e);
}
}
代码示例来源:origin: kiegroup/appformer
@Override
public void close() throws java.io.IOException {
try {
channel.close();
} catch (java.io.IOException e) {
throw new IOException(e);
}
}
}
代码示例来源:origin: org.uberfire/vfs-api
private static long internalCopy(InputStream in, OutputStream out) {
long read = 0L;
byte[] buf = new byte[BUFFER_SIZE];
int n;
try {
while ((n = in.read(buf)) > 0) {
out.write(buf, 0, n);
read += n;
}
} catch (java.io.IOException e) {
throw new IOException(e);
}
return read;
}
内容来源于网络,如有侵权,请联系作者删除!