TModLoader v1.4.4.9
TModLoader source code documentation
Loading...
Searching...
No Matches
Terraria.Utilities.FileUtilities Class Reference
+ Collaboration diagram for Terraria.Utilities.FileUtilities:

Static Public Member Functions

static bool Exists (string path, bool cloud)
 
static void Delete (string path, bool cloud, bool forceDeleteFile=false)
 
static string GetFullPath (string path, bool cloud)
 
static void Copy (string source, string destination, bool cloud, bool overwrite=true)
 
static void Move (string source, string destination, bool cloud, bool overwrite=true, bool forceDeleteSourceFile=false)
 
static int GetFileSize (string path, bool cloud)
 
static void Read (string path, byte[] buffer, int length, bool cloud)
 
static byte[] ReadAllBytes (string path, bool cloud)
 
static void WriteAllBytes (string path, byte[] data, bool cloud)
 
static void Write (string path, byte[] data, int length, bool cloud)
 
static void RemoveReadOnlyAttribute (string path)
 
static bool MoveToCloud (string localPath, string cloudPath)
 
static bool MoveToLocal (string cloudPath, string localPath)
 
static bool CopyToLocal (string cloudPath, string localPath)
 
static string GetFileName (string path, bool includeExtension=true)
 
static string GetParentFolderPath (string path, bool includeExtension=true)
 
static void CopyFolder (string sourcePath, string destinationPath)
 
static void ProtectedInvoke (Action action)
 
static void CopyExtended (string source, string destination, bool cloud, bool overwriteAlways, bool overwriteOld=true)
 
static void CopyFolderEXT (string sourcePath, string destinationPath, bool isCloud=false, Regex excludeFilter=null, bool overwriteAlways=false, bool overwriteOld=false)
 
static string ConvertToRelativePath (string basePath, string fullPath)
 Converts the full 'path' to remove the base path component. Example: C://My Documents//Help Me I'm Hungry.txt is full 'path' basePath is C://My Documents Thus returns 'Help Me I'm Hungry.txt'.
 
static string string int stabilityLevel[] GetAlternateSavePathFiles (string folderName)
 

Static Public Attributes

static string path
 
static string string message
 

Static Package Functions

static bool WriteTagCompound (string path, bool isCloud, TagCompound tag)
 

Static Private Member Functions

static bool DetermineIfShouldOverwrite (bool overwriteAlways, bool overwriteOld, string source, string destination)
 DEtermines if should overwrite the file at Destination with the file at Source.
 

Static Private Attributes

static Regex FileNameRegex = new Regex("^(?<path>.*[\\\\\\/])?(?:$|(?<fileName>.+?)(?:(?<extension>\\.[^.]*$)|$))", RegexOptions.IgnoreCase | RegexOptions.Compiled)
 

Detailed Description

Definition at line 14 of file FileUtilities.cs.


The documentation for this class was generated from the following file: