Package org.teavm.classlib.java.nio.file
Class TFiles
java.lang.Object
org.teavm.classlib.java.nio.file.TFiles
-
Method Summary
Modifier and TypeMethodDescriptionstatic longcopy(InputStream in, TPath target, TCopyOption... options) static longcopy(TPath source, OutputStream out) static TPathcopy(TPath source, TPath target, TCopyOption... options) static TPathcreateDirectories(TPath dir, TFileAttribute<?>... attrs) static TPathcreateDirectory(TPath dir, TFileAttribute<?>... attrs) static TPathcreateFile(TPath file, TFileAttribute<?>... attrs) static TPathcreateTempDirectory(String prefix, TFileAttribute<?>... attrs) static TPathcreateTempDirectory(TPath dir, String prefix, TFileAttribute<?>... attrs) static TPathcreateTempFile(String prefix, String suffix, TFileAttribute<?>... attrs) static TPathcreateTempFile(TPath dir, String prefix, String suffix, TFileAttribute<?>... attrs) static voidstatic booleandeleteIfExists(TPath path) static booleanexists(TPath path, TLinkOption... options) find(TPath start, int maxDepth, BiPredicate<TPath, TBasicFileAttributes> matcher, TFileVisitOption... options) static TFileTimegetLastModifiedTime(TPath path, TLinkOption... options) static booleanisDirectory(TPath path, TLinkOption... options) static booleanisExecutable(TPath path) static booleanstatic booleanisReadable(TPath path) static booleanisRegularFile(TPath path, TLinkOption... options) static booleanisSameFile(TPath path, TPath path2) static booleanisSymbolicLink(TPath path) static booleanisWritable(TPath path) static longstatic TPathmove(TPath source, TPath target, TCopyOption... options) static BufferedReadernewBufferedReader(TPath path) static BufferedReadernewBufferedReader(TPath path, Charset cs) static BufferedWriternewBufferedWriter(TPath path, Charset cs, TOpenOption... options) static BufferedWriternewBufferedWriter(TPath path, TOpenOption... options) static TDirectoryStream<TPath> newDirectoryStream(TPath dir) static TDirectoryStream<TPath> newDirectoryStream(TPath dir, TDirectoryStream.Filter<? super TPath> filter) static InputStreamnewInputStream(TPath path, TOpenOption... options) static OutputStreamnewOutputStream(TPath path, TOpenOption... options) static booleannotExists(TPath path, TLinkOption... options) static byte[]readAllBytes(TPath path) readAllLines(TPath path) readAllLines(TPath path, Charset cs) static <A extends TBasicFileAttributes>
AreadAttributes(TPath path, Class<A> type, TLinkOption... options) static StringreadString(TPath path) static StringreadString(TPath path, Charset cs) static TPathreadSymbolicLink(TPath link) static longwalk(TPath start, int maxDepth, TFileVisitOption... options) walk(TPath start, TFileVisitOption... options) static TPathwalkFileTree(TPath start, Set<TFileVisitOption> options, int maxDepth, TFileVisitor<? super TPath> visitor) static TPathwalkFileTree(TPath start, TFileVisitor<? super TPath> visitor) static TPathwrite(TPath path, byte[] bytes, TOpenOption... options) static TPathwrite(TPath path, Iterable<? extends CharSequence> lines, Charset cs, TOpenOption... options) static TPathwrite(TPath path, Iterable<? extends CharSequence> lines, TOpenOption... options) static TPathwriteString(TPath path, CharSequence csq, Charset cs, TOpenOption... options) static TPathwriteString(TPath path, CharSequence csq, TOpenOption... options)
-
Method Details
-
newInputStream
- Throws:
IOException
-
newOutputStream
- Throws:
IOException
-
newDirectoryStream
- Throws:
IOException
-
newDirectoryStream
public static TDirectoryStream<TPath> newDirectoryStream(TPath dir, TDirectoryStream.Filter<? super TPath> filter) throws IOException - Throws:
IOException
-
createFile
- Throws:
IOException
-
createDirectory
- Throws:
IOException
-
createDirectories
- Throws:
IOException
-
createTempFile
public static TPath createTempFile(TPath dir, String prefix, String suffix, TFileAttribute<?>... attrs) throws IOException - Throws:
IOException
-
createTempFile
public static TPath createTempFile(String prefix, String suffix, TFileAttribute<?>... attrs) throws IOException - Throws:
IOException
-
createTempDirectory
public static TPath createTempDirectory(TPath dir, String prefix, TFileAttribute<?>... attrs) throws IOException - Throws:
IOException
-
createTempDirectory
public static TPath createTempDirectory(String prefix, TFileAttribute<?>... attrs) throws IOException - Throws:
IOException
-
delete
- Throws:
IOException
-
deleteIfExists
- Throws:
IOException
-
readSymbolicLink
- Throws:
IOException
-
copy
- Throws:
IOException
-
move
- Throws:
IOException
-
isSameFile
- Throws:
IOException
-
mismatch
- Throws:
IOException
-
isHidden
- Throws:
IOException
-
readAttributes
public static <A extends TBasicFileAttributes> A readAttributes(TPath path, Class<A> type, TLinkOption... options) throws IOException - Throws:
IOException
-
isSymbolicLink
-
isDirectory
-
isRegularFile
-
getLastModifiedTime
- Throws:
IOException
-
size
- Throws:
IOException
-
exists
-
notExists
-
isReadable
-
isWritable
-
isExecutable
-
walkFileTree
public static TPath walkFileTree(TPath start, Set<TFileVisitOption> options, int maxDepth, TFileVisitor<? super TPath> visitor) throws IOException - Throws:
IOException
-
walkFileTree
public static TPath walkFileTree(TPath start, TFileVisitor<? super TPath> visitor) throws IOException - Throws:
IOException
-
newBufferedReader
- Throws:
IOException
-
newBufferedReader
- Throws:
IOException
-
newBufferedWriter
public static BufferedWriter newBufferedWriter(TPath path, Charset cs, TOpenOption... options) throws IOException - Throws:
IOException
-
newBufferedWriter
public static BufferedWriter newBufferedWriter(TPath path, TOpenOption... options) throws IOException - Throws:
IOException
-
copy
- Throws:
IOException
-
copy
- Throws:
IOException
-
readAllBytes
- Throws:
IOException
-
readString
- Throws:
IOException
-
readString
- Throws:
IOException
-
readAllLines
- Throws:
IOException
-
readAllLines
- Throws:
IOException
-
write
- Throws:
IOException
-
write
public static TPath write(TPath path, Iterable<? extends CharSequence> lines, Charset cs, TOpenOption... options) throws IOException - Throws:
IOException
-
write
public static TPath write(TPath path, Iterable<? extends CharSequence> lines, TOpenOption... options) throws IOException - Throws:
IOException
-
writeString
public static TPath writeString(TPath path, CharSequence csq, TOpenOption... options) throws IOException - Throws:
IOException
-
writeString
public static TPath writeString(TPath path, CharSequence csq, Charset cs, TOpenOption... options) throws IOException - Throws:
IOException
-
list
- Throws:
IOException
-
walk
public static Stream<TPath> walk(TPath start, int maxDepth, TFileVisitOption... options) throws IOException - Throws:
IOException
-
walk
- Throws:
IOException
-
find
public static Stream<TPath> find(TPath start, int maxDepth, BiPredicate<TPath, TBasicFileAttributes> matcher, TFileVisitOption... options) throws IOException- Throws:
IOException
-
lines
- Throws:
IOException
-
lines
- Throws:
IOException
-