@@ -0,0 +1,828 @@
+package io.domisum.lib.auxiliumlib.datacontainers;%0A%0Aimport io.domisum.lib.auxiliumlib.annotations.API;%0Aimport lombok.Getter;%0Aimport lombok.RequiredArgsConstructor;%0A%0Aimport java.io.BufferedInputStream;%0Aimport java.io.File;%0Aimport java.io.FileInputStream;%0Aimport java.io.FileNotFoundException;%0Aimport java.io.InputStream;%0Aimport java.io.UncheckedIOException;%0A%0A@RequiredArgsConstructor%0Apublic class KnownLengthInputStream%0A%7B%0A%09%0A%09@Getter%0A%09private final InputStream inputStream;%0A%09@Getter%0A%09private final long length;%0A%09%0A%09%0A%09// INIT%0A%09@API%0A%09public static KnownLengthInputStream ofFile(File file)%0A%09%7B%0A%09%09try%0A%09%09%7B%0A%09%09%09var fis = new FileInputStream(file);%0A%09%09%09var bis = new BufferedInputStream(fis);%0A%09%09%09return new KnownLengthInputStream(bis, file.length());%0A%09%09%7D%0A%09%09catch(FileNotFoundException e)%0A%09%09%7B%0A%09%09%09throw new UncheckedIOException(e);%0A%09%09%7D%0A%09%7D%0A%09%0A%7D%0A

Add KnownLengthInputStream