Package dev.latvian.mods.klib.io
Interface IOUtils
public interface IOUtils
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final Set<StandardOpenOption> static final Set<StandardOpenOption> -
Method Summary
Static MethodsModifier and TypeMethodDescriptionstatic voidappendBytes(Path path, ByteBuffer buf, long remainingBytes) static voidclearDirectory(Path dir) static voiddeleteRecursively(Path dir) static byte[]static StringgetAttribute(Path file, String attribute) static @Nullable InstantgetCreatedTime(Path path) static @Nullable InstantgetLastAccessedTime(Path path) static @Nullable InstantgetLastModifiedTime(Path path) static longstatic Stringstatic StringpathEndsWith(String suffix) static byte[]static Stringstatic intreadVarInt(DataInput in) static longreadVarLong(DataInput in) static booleansetAttribute(Path file, String attribute, String value) static byte[]toByteArray(io.netty.buffer.ByteBuf buf, boolean release) static voidwriteBytes(DataOutput out, byte[] bytes) static voidwriteBytes(Path path, ByteBuffer buf, long remainingBytes) static voidwriteUTF(DataOutput out, String value) static voidwriteVarInt(DataOutput out, int value) static voidwriteVarLong(DataOutput out, long value)
-
Field Details
-
WRITE_OPEN_OPTIONS
-
APPEND_OPEN_OPTIONS
-
-
Method Details
-
getSize
-
getCreatedTime
-
getLastModifiedTime
-
getLastAccessedTime
-
deleteRecursively
- Throws:
IOException
-
clearDirectory
- Throws:
IOException
-
readVarInt
- Throws:
IOException
-
readVarLong
- Throws:
IOException
-
readBytes
- Throws:
IOException
-
readUTF
- Throws:
IOException
-
writeVarInt
- Throws:
IOException
-
writeVarLong
- Throws:
IOException
-
writeBytes
- Throws:
IOException
-
writeUTF
- Throws:
IOException
-
toByteArray
static byte[] toByteArray(io.netty.buffer.ByteBuf buf, boolean release) -
writeBytes
- Throws:
IOException
-
appendBytes
- Throws:
IOException
-
digest
- Throws:
NoSuchAlgorithmExceptionIOException
-
md5bytes
- Throws:
NoSuchAlgorithmExceptionIOException
-
md5
- Throws:
NoSuchAlgorithmExceptionIOException
-
getAttribute
- Throws:
IOException
-
setAttribute
- Throws:
IOException
-
pathEndsWith
-