public SysOp(BBS bbs, BBSDataCore bbsDataCore) { _bbs = bbs; _bbsDataCore = bbsDataCore; Userid = _bbs.CurrentUser.Id; Columns = _bbs.terminalType.Columns(); }
public UDBases(BBS bbs, BBSDataCore bbsDataCore) { _bbs = bbs; _bbsDataCore = bbsDataCore; Current_Area = -1; //Current_Parent_Area = -1; _bbs.SendFileForTermType("udbase_entry_root", true); CMD_List(); }
public PFiles(BBS bbs, BBSDataCore bbsDataCore) { _bbs = bbs; _bbsDataCore = bbsDataCore; _bbs.CurrentArea = "PFiles"; _currentPFileArea = null; _bbs.SendFileForTermType("pfile_entry_root", false); CmdList(); }
public MessageBases(BBS bbs, BBSDataCore bbsDataCore) { _bbs = bbs; _bbsDataCore = bbsDataCore; Current_Area = -1; //Current_Parent_Area = -1; _bbs.SendFileForTermType("messagebase_entry_root", true); CMD_List(); RecalculatePath(); }
public static void Main(string[] args) { Console.Clear(); Console.WriteLine("SixNet BBS, Starting up..."); _bbsDatabaseConfiguration = BBSDatabaseConfiguration.LoadConfig("./"); if (_bbsDatabaseConfiguration == null) { Console.WriteLine("Run setup utility first."); return; } _connectionString = BBSDatabaseConfiguration.BuildConnectionString(_bbsDatabaseConfiguration); LoggingAPI.Init("./Logs/"); if (BBSDatabaseConfiguration.IsDatabaseSetup(_connectionString)) { Console.WriteLine("Database configured."); _core = new BBSDataCore(_connectionString); } else { Console.WriteLine("Database not configured - run setup utility."); return; } var config = _core.GetBBSConfig(); LoggingAPI.LogEntry("Software started."); try { quitFlag = false; BBSServer bbsServer = new BBSServer(_connectionString, config.BBSPort, "BBS Server"); bbsServer.Start(); while (!quitFlag) { Thread.Sleep(100); if (Console.KeyAvailable) { if (Console.ReadKey().Key == ConsoleKey.Q) { quitFlag = true; bbsServer.Stop(); break; } } } } catch (Exception e) { LoggingAPI.Error(e); } finally { LoggingAPI.LogEntry("Software shutdown."); LoggingAPI.FlushQueue(); } }
//private readonly bool _slackEnabled; //private readonly SlackIntegration _slackIntegration; public BBS(IBBSHost bbsHost, StateObject stateObject, string ConnectionString) { connectionTimestamp = DateTime.Now; _bbsDataCore = new BBSDataCore(ConnectionString); _bbsHost = bbsHost; base._stateObject = stateObject; messageQueueTimer.Enabled = false; messageQueueTimer.Interval = 100; messageQueueTimer.Elapsed += new System.Timers.ElapsedEventHandler(MessageQueueTimer_Elapsed); _remoteAddress = stateObject.RemoteAddress; //_slackEnabled = (_dataInterface.GetUserDefinedField(0, "SLACKENABLED") == "1"); //if (_slackEnabled) _slackIntegration = new SlackIntegration(_dataInterface); LoggingAPI.SysLogEntry(_remoteAddress + ": User Connected"); }
public News(BBS bbs, BBSDataCore bbsDataCore) { _bbs = bbs; _bbsDataCore = bbsDataCore; }
public GraffitiWall(BBS bbs, BBSDataCore bbsDataCore) { _bbs = bbs; _bbsDataCore = bbsDataCore; _bbs.currentArea = "Graffiti Wall"; }
public LastTen(BBS bbs, BBSDataCore bbsDataCore) { _bbs = bbs; _bbsDataCore = bbsDataCore; }
public Main(BBS bbs, BBSDataCore bbsDataCore) { _bbs = bbs; _bbsDataCore = bbsDataCore; _bbsConfig = bbsDataCore.GetBBSConfig(); }
private static void MainMenu() { _exitFlag = false; while (!_exitFlag) { Console.Clear(); Console.WriteLine("SixNet Setup Utility"); Divider(); if (BBSDatabaseConfiguration.IsDatabaseSetup(_connectionString)) { Console.WriteLine("Database configured."); _core = new BBSDataCore(_connectionString); } else { Console.WriteLine("Database not configured."); } Divider(); Console.WriteLine("1. Configure Database"); if (BBSDatabaseConfiguration.IsDatabaseSetup(_connectionString)) { Console.WriteLine("2. Configure BBS"); Console.WriteLine("3. Setup Message Bases"); Console.WriteLine("4. Setup UD Bases"); Console.WriteLine("5. Setup GFile Areas"); Console.WriteLine("6. Setup PFile Areas"); Console.WriteLine("S. Save Configuration"); } Console.WriteLine("X. Exit"); var selection = Input("Select", ""); switch (selection.ToUpper()) { case "1": SetupDatabase(); break; case "2": SetupBBS(); break; case "5": SetupGFileAreas(); break; case "6": SetupPFileAreas(); break; case "S": BBSDatabaseConfiguration.SaveConfig(_basePath, _bbsDatabaseConfiguration); break; case "X": _exitFlag = true; break; default: break; } } }
public Login(BBS bbs, BBSDataCore bbsDataCore) { _bbs = bbs; _bbsDataCore = bbsDataCore; }