public RemoteLoader() { Log=(ApplicationLog) AppDomain.CurrentDomain.GetData("AppLog"); Context.RegisterDynamicProperty( new RemoteServerDynamicProperty(AppDomain.CurrentDomain.FriendlyName,Log),null,null); LoadedTypes=new ArrayList(); }
public RemoteServerDynamicMessageSink(string AppName, ApplicationLog Log) { _AppName = AppName; _Log = Log; }
/// <summary> /// NKRemoteServerDynamicProperty constructor. /// </summary> public RemoteServerDynamicProperty(string appName, ApplicationLog log) { _Name = appName; _Log = log; }
public ApplicationBase(string AppName, string BaseDir, ApplicationServer server):base() { _Name=AppName; _BaseDirectory=BaseDir; AppServer=server; SecurityManager=server.SecurityManager; log = new ApplicationLog(_BaseDirectory + AppName + ".app.log"); log.WriteLine("System","Application Started"); _LogCategory.Name = _Name; EnterMethod(); try { SendValue("Application Name", AppName); SendValue("Base Directory", BaseDir); SendValue("Log file", _BaseDirectory + AppName + ".app.log"); SendString("App Started"); } catch(Exception E) { SendError(E); throw; } finally { ExitMethod(); } }
public virtual void Configure(ApplicationServer server, DirectoryInfo BaseDir, XmlDocument ConfigFile) { if (Boolean.Parse(ReadAppSetting(ConfigFile, "Debug", "false"))) { TerWoord.Diagnostics.Destinations.FileDestination TempDest = new TerWoord.Diagnostics.Destinations.FileDestination(); TempDest.LogDirectory = Path.Combine(BaseDir.FullName, "detaillogs"); TempDest.Initialize(); _LogCategory.Destins.Add(TempDest); } EnterMethod(); try { this.AppServer=server; this._BaseDirectory=BaseDir.FullName; SendValue("Base Directory", _BaseDirectory); _Name=ReadAppSetting(ConfigFile,"Application.Name",BaseDir.Name); SendValue("Name", _Name); AppServer=server; SecurityManager=server.SecurityManager; log=new ApplicationLog(_BaseDirectory + Path.DirectorySeparatorChar + "app.log"); SendValue("Log file", _BaseDirectory + Path.DirectorySeparatorChar + "app.log"); log.WriteLine("System","Application Started"); SendString("Application Started"); // Load Roles from Conig File XmlNodeList RoleList=ConfigFile.SelectNodes("/configuration/publishedRoles/role"); if (RoleList.Count!=0) { Roles=new string[RoleList.Count]; int i=0; foreach (XmlElement roleElement in RoleList) { Roles[i]=roleElement.InnerText; i++; } } SendValue("Roles", Roles); } catch(Exception E) { SendError(E); throw; } finally { ExitMethod(); } }
public RemoteServerDynamicMessageSink(string AppName, ApplicationLog Log) { _AppName=AppName; _Log=Log; }
/// <summary> /// NKRemoteServerDynamicProperty constructor. /// </summary> public RemoteServerDynamicProperty (string appName, ApplicationLog log) { _Name=appName; _Log=log; }