Class VirtualFilesystem
- java.lang.Object
-
- net.lax1dude.eaglercraft.v1_8.internal.vfs.VirtualFilesystem
-
public class VirtualFilesystem extends java.lang.ObjectCopyright (c) 2022-2023 LAX1DUDE. All Rights Reserved. WITH THE EXCEPTION OF PATCH FILES, MINIFIED JAVASCRIPT, AND ALL FILES NORMALLY FOUND IN AN UNMODIFIED MINECRAFT RESOURCE PACK, YOU ARE NOT ALLOWED TO SHARE, DISTRIBUTE, OR REPURPOSE ANY FILE USED BY OR PRODUCED BY THE SOFTWARE IN THIS REPOSITORY WITHOUT PRIOR PERMISSION FROM THE PROJECT AUTHOR. NOT FOR COMMERCIAL OR MALICIOUS USE (please read the 'LICENSE' file this repo's root directory for more info)
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description protected static classVirtualFilesystem.AsyncHandlersprotected static classVirtualFilesystem.DatabaseOpenstatic classVirtualFilesystem.VFSFilestatic classVirtualFilesystem.VFSHandleprotected static classVirtualFilesystem.VirtualOutputStream
-
Field Summary
Fields Modifier and Type Field Description java.lang.Stringdatabase
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description voidclose()protected static IDBFactorycreateIDBFactory()static java.lang.StringCRLFtoLF(java.lang.String str)booleandeleteFile(java.lang.String path)intdeleteFiles(java.lang.String prefix)booleanfileExists(java.lang.String path)voidflushCache(long age)VirtualFilesystem.VFSFilegetFile(java.lang.String path)VirtualFilesystem.VFSFilegetFile(java.lang.String path, boolean cache)intiterateFiles(java.lang.String prefix, boolean rw, VFSIterator itr)static java.lang.String[]lines(java.lang.String str)java.util.List<java.lang.String>listFiles(java.lang.String prefix)static VirtualFilesystem.VFSHandleopenVFS(java.lang.String db)booleanrenameFile(java.lang.String oldName, java.lang.String newName, boolean copy)intrenameFiles(java.lang.String oldPrefix, java.lang.String newPrefix, boolean copy)static java.lang.Stringutf8(byte[] str)static byte[]utf8(java.lang.String str)
-
-
-
Method Detail
-
openVFS
public static VirtualFilesystem.VFSHandle openVFS(java.lang.String db)
-
close
public void close()
-
getFile
public VirtualFilesystem.VFSFile getFile(java.lang.String path)
-
getFile
public VirtualFilesystem.VFSFile getFile(java.lang.String path, boolean cache)
-
renameFile
public boolean renameFile(java.lang.String oldName, java.lang.String newName, boolean copy)
-
deleteFile
public boolean deleteFile(java.lang.String path)
-
fileExists
public boolean fileExists(java.lang.String path)
-
listFiles
public java.util.List<java.lang.String> listFiles(java.lang.String prefix)
-
deleteFiles
public int deleteFiles(java.lang.String prefix)
-
iterateFiles
public int iterateFiles(java.lang.String prefix, boolean rw, VFSIterator itr)
-
renameFiles
public int renameFiles(java.lang.String oldPrefix, java.lang.String newPrefix, boolean copy)
-
flushCache
public void flushCache(long age)
-
createIDBFactory
protected static IDBFactory createIDBFactory()
-
utf8
public static byte[] utf8(java.lang.String str)
-
utf8
public static java.lang.String utf8(byte[] str)
-
CRLFtoLF
public static java.lang.String CRLFtoLF(java.lang.String str)
-
lines
public static java.lang.String[] lines(java.lang.String str)
-
-