public static Int32 Init() { try { LogSetup(); #if DEBUG CLR_PSE_PluginLog.SetSourceUseStdOut(true, (int)DEV9LogSources.PluginInterface); //CLR_PSE_PluginLog.SetSourceUseStdOut(true, (int)DEV9LogSources.TCPSession); //Info is defualt CLR_PSE_PluginLog.SetFileLevel(SourceLevels.All); //CLR_PSE_PluginLog.SetSourceLogLevel(SourceLevels.All, (int)DEV9LogSources.ATA); //CLR_PSE_PluginLog.SetSourceLogLevel(SourceLevels.All, (int)DEV9LogSources.TCPSession); CLR_PSE_PluginLog.SetSourceLogLevel(SourceLevels.All, (int)DEV9LogSources.Dev9); CLR_PSE_PluginLog.SetSourceLogLevel(SourceLevels.All, (int)DEV9LogSources.SMAP); #endif ConfigFile.LoadConf(iniFolderPath, "CLR_DEV9.ini"); Log_Info("Config Loaded"); LogInit(); Log_Info("Init"); dev9 = new DEV9.DEV9_State(); Log_Info("Init ok"); return(0); } catch (Exception e) { CLR_PSE_PluginLog.MsgBoxErrorTrapper(e); return(-1); } }
public static Int32 Init() { try { LogSetup(); #if DEBUG CLR_PSE_PluginLog.SetSourceUseStdOut(true, (int)DEV9LogSources.PluginInterface); //CLR_PSE_PluginLog.SetSourceUseStdOut(true, (int)DEV9LogSources.TCPSession); //Info is default CLR_PSE_PluginLog.SetFileLevel(SourceLevels.All); //CLR_PSE_PluginLog.SetSourceLogLevel(SourceLevels.All, (int)DEV9LogSources.ATA); //CLR_PSE_PluginLog.SetSourceLogLevel(SourceLevels.All, (int)DEV9LogSources.TCPSession); CLR_PSE_PluginLog.SetSourceLogLevel(SourceLevels.All, (int)DEV9LogSources.Dev9); CLR_PSE_PluginLog.SetSourceLogLevel(SourceLevels.All, (int)DEV9LogSources.SMAP); #endif ConfigFile.LoadConf(iniFolderPath, "CLR_DEV9.ini"); Log_Info("Config Loaded"); LogInit(); Log_Info("Init"); dev9 = new DEV9.DEV9_State(); Log_Info("Init ok"); hasInit = true; return(0); } catch (Exception e) when(Log_Fatal(e)) { throw; } catch (Exception) when(tryAvoidThrow) { return(-1); } }
public static Int32 Init() { try { LogInit(); Log_Info("Init"); dev9 = new DEV9.DEV9_State(); Log_Info("Init ok"); return 0; } catch (Exception e) { CLR_PSE_PluginLog.MsgBoxError(e); return -1; } }