C# Class Nexus.Client.ModManagement.ReadMeManager

ファイルを表示 Open project: NexusMods/NexusModManager-4.5 Class Usage Examples

Public Methods

Method Description
CheckModReadMe ( string p_strModName ) : string[]

Check if there's a readme file for the given mod.

CheckReadMeFolder ( ) : bool

Checks if the read me folder is already present, otherwise it tries to create it.

DeleteReadMe ( string p_strFileName ) : void

Deletes the readme file.

GetModReadMe ( string p_strModName, string p_strFileName ) : string

Get the ReadMe file path if it exists.

LoadReadMe ( ) : void

Check if the readme setup file is already present.

ReadMeManager ( string p_strFilePath ) : System

A simple constructor that initializes the ReadMeManager.

ReadVersion ( string p_strReadMePath ) : System.Version

Reads the ReadMe manager version from the given file.

SaveReadMeConfig ( ) : void

Save the data to the category file.

VerifyReadMeFile ( TxFileManager p_tfmFileManager, string p_strArchivePath ) : bool

Verifies if the readme file exists in the archive and saves it to the ReadMe folder.

Protected Methods

Method Description
CreateReadMeArchive ( string p_strArchiveFile, string p_strFilesToCompress ) : bool

Creates the readme files archive for the current mod.

PurgeTempFolder ( ) : void

Removes any file in the ReadMe/Temp folder.

Private Methods

Method Description
GetFileList ( Archive p_arcArchive, bool p_booRecurse ) : List

Retrieves the list of all files in the specified folder.

Method Details

CheckModReadMe() public method

Check if there's a readme file for the given mod.
public CheckModReadMe ( string p_strModName ) : string[]
p_strModName string
return string[]

CheckReadMeFolder() public method

Checks if the read me folder is already present, otherwise it tries to create it.
public CheckReadMeFolder ( ) : bool
return bool

CreateReadMeArchive() protected method

Creates the readme files archive for the current mod.
protected CreateReadMeArchive ( string p_strArchiveFile, string p_strFilesToCompress ) : bool
p_strArchiveFile string The archive name.
p_strFilesToCompress string The list of files to compress.
return bool

DeleteReadMe() public method

Deletes the readme file.
public DeleteReadMe ( string p_strFileName ) : void
p_strFileName string The path where the ReadMe folder should be created.
return void

GetModReadMe() public method

Get the ReadMe file path if it exists.
public GetModReadMe ( string p_strModName, string p_strFileName ) : string
p_strModName string
p_strFileName string The mod file name.
return string

LoadReadMe() public method

Check if the readme setup file is already present.
public LoadReadMe ( ) : void
return void

PurgeTempFolder() protected method

Removes any file in the ReadMe/Temp folder.
protected PurgeTempFolder ( ) : void
return void

ReadMeManager() public method

A simple constructor that initializes the ReadMeManager.
public ReadMeManager ( string p_strFilePath ) : System
p_strFilePath string The path where the ReadMe folder should be created.
return System

ReadVersion() public static method

Reads the ReadMe manager version from the given file.
public static ReadVersion ( string p_strReadMePath ) : System.Version
p_strReadMePath string
return System.Version

SaveReadMeConfig() public method

Save the data to the category file.
public SaveReadMeConfig ( ) : void
return void

VerifyReadMeFile() public method

Verifies if the readme file exists in the archive and saves it to the ReadMe folder.
public VerifyReadMeFile ( TxFileManager p_tfmFileManager, string p_strArchivePath ) : bool
p_tfmFileManager ChinhDo.Transactions.TxFileManager
p_strArchivePath string The path to the mod archive.
return bool