public class SPGlobal
extends java.lang.Object
Modifier and Type | Class and Description |
---|---|
static class |
SPGlobal.Language |
Modifier and Type | Field and Description |
---|---|
static boolean |
debugBSAimport
Displays information about BSA importing
|
static boolean |
debugModMerge
Print messages concerning the merging of two plugins.
Prints to the sync log |
static boolean |
debugNIFimport
Displays information about NIF importing
|
static boolean |
debugStream
Turns off messages about which record is currently being streamed.
|
static boolean |
debugStringPairing
Prints messages about records pairing strings with external STRINGS
files.
Prints to the sync log |
static SPGlobal.Language |
language
Skyproc will import and embed the language given by SPGlobal.language
every time a patch is created.
|
static java.lang.String |
pathToData
Path to the Data/ folder to look for plugins to import/export.
By default, this is set to "../../", meaning the patch has to be in a subfolder of "Data/". |
static java.lang.String |
pathToInternalFiles
A default path to "internal files".
|
static java.lang.String |
pluginListBackupPath
The path from the .jar location to create/look for the file used to
remember where the plugins.txt file is if the program cannot locate it
automatically.
|
static java.lang.String |
pluginsListPath
Path and filename to look for the active plugins file.
"/Skyrim/plugins.txt" by default. |
Constructor and Description |
---|
SPGlobal() |
Modifier and Type | Method and Description |
---|---|
static void |
addModToSkip(ModListing m) |
static void |
addModToSkip(java.lang.String s) |
static void |
addModToWhiteList(ModListing m)
Adds a mod to the white list.
|
static void |
addModToWhiteList(java.lang.String s)
Adds a mod to the white list.
|
static void |
closeDebug()
Closes all logs.
|
static void |
createGlobalLog()
Initializes the Debug Logs in a "SkyProcDebug/" folder, and allows you to
print messages to them.
Do this step early in your program. |
static void |
createGlobalLog(java.lang.String path)
Initializes the Debug Logs in a path + "SkyProcDebug/" folder, and allows
you to print messages to them.
Do this step early in your program. |
static void |
flush()
Flushes the Debug buffers to the files.
|
static SPDatabase |
getDB() |
static Mod |
getGlobalPatch() |
static java.lang.String |
getLoadOrderTxt() |
static java.io.File |
getMyDocumentsSkyrimFolder()
Returns the My Documents Skyrim folder where the ini's are located.
|
static java.lang.String |
getPluginsTxt()
Returns the plugins.txt file that contains load order information.
|
static java.io.File |
getSkyProcDocuments()
Returns a File path to the SkyProc Documents folder.
|
static java.lang.String |
getSkyrimAppData() |
static java.io.File |
getSkyrimINI()
Returns the Skyrim.ini file in the My Documents folder.
|
static boolean |
isModToSkip(ModListing m) |
static boolean |
isModToSkip(java.lang.String name) |
static boolean |
isWhiteListed(ModListing m) |
static boolean |
isWhiteListed(java.lang.String name) |
static void |
log(java.lang.String header,
java.lang.String... print)
Prints a message to the asynchronous log.
|
static void |
logBlocked(java.lang.String header,
java.lang.String reason,
MajorRecord m)
Logs a specific record as blocked in the "Blocked Records.txt" log.
|
static void |
logError(java.lang.String header,
java.lang.String... print)
A special function that simply prints to both the debug overview and the
asynchronous log for easy location in either place.
|
static void |
logException(java.lang.Throwable e)
Used for printing exception stack data to the debug overview log.
|
static boolean |
logging() |
static void |
logging(java.lang.Boolean on) |
static boolean |
loggingAsync() |
static void |
loggingAsync(java.lang.Boolean on)
Turns the LLogger async log on/off.
|
static boolean |
loggingSync() |
static void |
loggingSync(java.lang.Boolean on) |
static void |
logMain(java.lang.String header,
java.lang.String... print)
Logs a message to the Debug Overview file.
|
static void |
logSpecial(java.lang.Enum e,
java.lang.String header,
java.lang.String... print)
Logs to a specially created log that was previously created using
newSpecialLog().
|
static void |
newLog(java.lang.String fileName)
Creates a new asynchronous log.
|
static void |
newSpecialLog(java.lang.Enum e,
java.lang.String logName)
Creates a new special log with any enum value as the key.
|
static java.lang.String |
pathToDebug()
Returns the path to the debug folder.
|
static boolean |
queryMajor(FormID query)
Querys the Global Database and returns whether the FormID exists.
NOTE: it is recommended you use the version that only searches in specific GRUPs for speed reasons. |
static boolean |
queryMajor(FormID query,
GRUP_TYPE... grup_types)
Querys the Global Database and returns whether the FormID exists.
|
static void |
redirectSystemOutStream()
Redirects System.out to the asynchronous log stream.
|
static void |
setGlobalPatch(Mod patch)
Creating your patch ahead of time, and setting it as the Global Patch
will prevent it from being imported by getActiveMods() and getAllMods()
|
static void |
setNoModsAfter(boolean on) |
static void |
setStreamMode(boolean on) |
static void |
setSUMerrorMessage(java.lang.String message)
Lets you set the message to display when an error occurs that causes the
program to stop prematurely.
|
static boolean |
shouldImport(ModListing m)
True if not blacklisted and if white listed (if there are any white listings)
|
static boolean |
shouldImport(java.lang.String name)
True if not blacklisted and if white listed (if there are any white listings)
|
public static java.lang.String pluginsListPath
public static java.lang.String pathToData
public static java.lang.String pathToInternalFiles
public static SPGlobal.Language language
public static java.lang.String pluginListBackupPath
public static boolean debugStream
public static boolean debugBSAimport
public static boolean debugNIFimport
public static boolean debugStringPairing
public static boolean debugModMerge
public static java.io.File getSkyProcDocuments() throws java.io.FileNotFoundException, java.io.IOException
java.io.FileNotFoundException
java.io.IOException
public static SPDatabase getDB()
public static void setGlobalPatch(Mod patch)
patch
- Mod to set as the global patch.public static Mod getGlobalPatch()
public static void addModToSkip(ModListing m)
m
- Mod to skip when importing.public static void addModToSkip(java.lang.String s)
s
- public static boolean isModToSkip(ModListing m)
m
- public static boolean isModToSkip(java.lang.String name)
name
- public static boolean isWhiteListed(ModListing m)
m
- public static boolean isWhiteListed(java.lang.String name)
name
- public static boolean shouldImport(ModListing m)
m
- public static boolean shouldImport(java.lang.String name)
name
- public static void addModToWhiteList(ModListing m)
m
- public static void addModToWhiteList(java.lang.String s)
s
- public static boolean queryMajor(FormID query)
query
- FormID to look for.public static boolean queryMajor(FormID query, GRUP_TYPE... grup_types)
query
- FormID to look for.grup_types
- GRUPs to look in.public static java.io.File getMyDocumentsSkyrimFolder() throws java.io.FileNotFoundException, java.io.IOException
java.io.FileNotFoundException
java.io.IOException
public static java.io.File getSkyrimINI() throws java.io.FileNotFoundException, java.io.IOException
java.io.FileNotFoundException
java.io.IOException
public static java.lang.String getSkyrimAppData() throws java.io.IOException
java.io.IOException
public static java.lang.String getPluginsTxt() throws java.io.FileNotFoundException, java.io.IOException
java.io.FileNotFoundException
java.io.IOException
public static java.lang.String getLoadOrderTxt() throws java.io.IOException
java.io.IOException
public static void setStreamMode(boolean on)
on
- True if you want data to be streamed on demand; False if you
want it to all be imported at once.public static void setNoModsAfter(boolean on)
on
- True if you want the patcher to ignore mods that come after it
in the load order.public static void setSUMerrorMessage(java.lang.String message)
message
- public static void createGlobalLog()
public static void createGlobalLog(java.lang.String path)
path
- The path to create the "SkyProcDebug/" folder.public static void logMain(java.lang.String header, java.lang.String... print)
header
- print
- public static void logBlocked(java.lang.String header, java.lang.String reason, MajorRecord m)
header
- reason
- Reason for blocking the record.m
- Record that was blocked.public static boolean logging()
public static void logging(java.lang.Boolean on)
on
- Turns the logger on/off.public static boolean loggingSync()
public static void loggingSync(java.lang.Boolean on)
on
- Turns the logger on/off.public static void loggingAsync(java.lang.Boolean on)
on
- public static boolean loggingAsync()
public static void flush()
public static void logError(java.lang.String header, java.lang.String... print)
header
- print
- public static void logException(java.lang.Throwable e)
e
- Exception to print.public static void logSpecial(java.lang.Enum e, java.lang.String header, java.lang.String... print)
e
- The enum you defined to symbolize the "key" to the special log.header
- print
- public static void newSpecialLog(java.lang.Enum e, java.lang.String logName)
e
- Any enum you define to symbolize the "key" to the special log.logName
- public static void log(java.lang.String header, java.lang.String... print)
header
- print
- public static void newLog(java.lang.String fileName)
fileName
- Name of the log.public static void redirectSystemOutStream() throws java.io.FileNotFoundException, java.io.IOException
java.io.FileNotFoundException
java.io.IOException
public static void closeDebug()
public static java.lang.String pathToDebug()