Java Code Examples for org.apache.commons.vfs2.Capability#RANDOM_ACCESS_READ
The following examples show how to use
org.apache.commons.vfs2.Capability#RANDOM_ACCESS_READ .
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: SharedRandomContentInputStream.java From commons-vfs with Apache License 2.0 | 6 votes |
private SharedRandomContentInputStream(final Set<SharedRandomContentInputStream> createdStreams, final FileObject fo, final long fileStart, final long fileEnd, final InputStream is) throws FileSystemException { super(is); if (!fo.getFileSystem().hasCapability(Capability.RANDOM_ACCESS_READ)) { throw new FileSystemException("vfs.util/missing-capability.error", Capability.RANDOM_ACCESS_READ); } this.fo = fo; this.fileStart = fileStart; this.fileEnd = fileEnd; this.createdStreams = createdStreams; synchronized (createdStreams) { createdStreams.add(this); } }
Example 2
Source File: ProviderRandomSetLengthTests.java From commons-vfs with Apache License 2.0 | 4 votes |
/** * Returns the capabilities required by the tests of this test case. */ @Override protected Capability[] getRequiredCaps() { return new Capability[] { Capability.GET_TYPE, Capability.RANDOM_ACCESS_READ, Capability.RANDOM_ACCESS_WRITE, Capability.RANDOM_ACCESS_SET_LENGTH }; }
Example 3
Source File: ProviderRandomReadTests.java From commons-vfs with Apache License 2.0 | 4 votes |
/** * Returns the capabilities required by the tests of this test case. */ @Override protected Capability[] getRequiredCaps() { return new Capability[] { Capability.GET_TYPE, Capability.RANDOM_ACCESS_READ }; }
Example 4
Source File: ProviderRandomReadWriteTests.java From commons-vfs with Apache License 2.0 | 4 votes |
/** * Returns the capabilities required by the tests of this test case. */ @Override protected Capability[] getRequiredCaps() { return new Capability[] { Capability.GET_TYPE, Capability.CREATE, Capability.RANDOM_ACCESS_READ, Capability.RANDOM_ACCESS_WRITE }; }