Class JCOReflector
- java.lang.Object
-
- org.mases.jcobridge.netreflection.JCOReflector
-
public class JCOReflector extends java.lang.ObjectMain class to manageJCOReflectorfeatures
-
-
Constructor Summary
Constructors Constructor Description JCOReflector()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static java.lang.String[]getCommandLineArgs()Get command-line argumentsstatic booleangetConsoleLog()Get console logstatic booleangetDebug()Get Debug statestatic booleangetInitialized()Return ifJCOReflectoris initializedstatic booleangetInstanceByAssembly()Get InstanceByAssembly statestatic java.lang.StringgetLogFilename()Get Logging filenamestatic booleangetLogging()Get Logging statestatic booleangetUseFullAssemblyName()Get UseFullAssemblyName statestatic voidinit(java.lang.String[] args)InitializeJCOReflectorruntimestatic booleaninitRT(java.lang.String pathToUse)Invoke this method to initialize JCOBridge runtime to a user defined folderstatic booleaninitTempRT()Invoke this method to initialize JCOBridge runtime to a temporary folderstatic voidregisterPath(java.lang.String path)Register search path within the enginestatic voidsetCommandLineArgs(java.lang.String[] args)Set command-line argumentsstatic voidsetConsoleLog(boolean isConsoleLog)Set console logstatic voidsetDebug(boolean isDebug)Set Debug statestatic voidsetInstanceByAssembly(boolean isMultiInstance)SetJCOBridgeinstance by assembly statestatic voidsetLogFilename(java.lang.String loggingFilename)Set Logging filenamestatic voidsetLogging(boolean isLogging)Set Logging statestatic voidsetUseFullAssemblyName(boolean useFullname)Set UseFullAssemblyName statestatic voidwriteLog(java.lang.String msg)Write a string to JCOReflector logstatic voidwriteLog(java.lang.String format, java.lang.Object... args)Write a log to JCOReflector logstatic voidwriteLog(java.lang.Throwable t)Write exception to JCOReflector log
-
-
-
Method Detail
-
getInitialized
public static boolean getInitialized()
Return ifJCOReflectoris initialized- Returns:
- true if
JCOReflectoris initialized
-
getLogging
public static boolean getLogging()
Get Logging state- Returns:
- the logging state
-
setLogging
public static void setLogging(boolean isLogging)
Set Logging state- Parameters:
isLogging- the new logging state
-
getLogFilename
public static java.lang.String getLogFilename()
Get Logging filename- Returns:
- the log filename
-
setLogFilename
public static void setLogFilename(java.lang.String loggingFilename)
Set Logging filenameIf the logging operations are started on a
JCOBridgeinstance, it is not possible to change the name during runtime.- Parameters:
loggingFilename- the new log filename
-
getUseFullAssemblyName
public static boolean getUseFullAssemblyName()
Get UseFullAssemblyName state- Returns:
- the UseFullAssemblyName state
-
setUseFullAssemblyName
public static void setUseFullAssemblyName(boolean useFullname)
Set UseFullAssemblyName stateSet only on startup
- Parameters:
useFullname- the new UseFullAssemblyName state
-
getDebug
public static boolean getDebug()
Get Debug state- Returns:
- the debug state
-
setDebug
public static void setDebug(boolean isDebug)
Set Debug state- Parameters:
isDebug- the new debug state
-
getConsoleLog
public static boolean getConsoleLog()
Get console log- Returns:
- the console log state
-
setConsoleLog
public static void setConsoleLog(boolean isConsoleLog)
Set console log- Parameters:
isConsoleLog- the new console log state
-
getInstanceByAssembly
public static boolean getInstanceByAssembly()
Get InstanceByAssembly state- Returns:
- the
JCOBridgestate
-
setInstanceByAssembly
public static void setInstanceByAssembly(boolean isMultiInstance)
SetJCOBridgeinstance by assembly stateIt can be applied only before any operation
- Parameters:
isMultiInstance- the new InstanceByAssembly state
-
getCommandLineArgs
public static java.lang.String[] getCommandLineArgs()
Get command-line arguments- Returns:
- the command-line arguments
-
setCommandLineArgs
public static void setCommandLineArgs(java.lang.String[] args)
Set command-line argumentsIt can be applied only before any operation
- Parameters:
args- the command-line arguments
-
registerPath
public static void registerPath(java.lang.String path)
Register search path within the engineIt can be applied only before any operation
- Parameters:
path- the path to register
-
writeLog
public static void writeLog(java.lang.Throwable t)
Write exception to JCOReflector log- Parameters:
t-Throwableto log
-
writeLog
public static void writeLog(java.lang.String format, java.lang.Object... args)Write a log to JCOReflector log- Parameters:
format- formatStringto logargs- format arguments
-
writeLog
public static void writeLog(java.lang.String msg)
Write a string to JCOReflector log- Parameters:
msg- message to log
-
init
public static void init(java.lang.String[] args)
InitializeJCOReflectorruntime- Parameters:
args- command-line arguments
-
initTempRT
public static boolean initTempRT()
Invoke this method to initialize JCOBridge runtime to a temporary folder- Returns:
- true if the runtime was initialized, otherwise see JCOReflector.log to check possible error conditions
-
initRT
public static boolean initRT(java.lang.String pathToUse)
Invoke this method to initialize JCOBridge runtime to a user defined folder- Parameters:
pathToUse- The user defined path used for JCOBridge runtime- Returns:
- true if the runtime was initialized, otherwise see JCOReflector.log to check possible error conditions
-
-