MCPcopy
hub / github.com/google/guava / asByteSource

Method asByteSource

guava/src/com/google/common/io/MoreFiles.java:84–86  ·  view source on GitHub ↗

Returns a view of the given {@code path} as a {@link ByteSource}. <p>Any {@linkplain OpenOption open options} provided are used when opening streams to the file and may affect the behavior of the returned source and the streams it provides. See {@link StandardOpenOption} for the standard options th

(Path path, OpenOption... options)

Source from the content-addressed store, hash-verified

82 * equivalent to providing the {@link StandardOpenOption#READ READ} option.
83 */
84 public static ByteSource asByteSource(Path path, OpenOption... options) {
85 return new PathByteSource(path, options);
86 }
87
88 private static final class PathByteSource extends
89 ByteSource

Calls

no outgoing calls