Class GlobalSettings
Contains a set of global and required settings, which are in different configuration sources.
Inheritance
Inherited Members
Namespace: Simplic.Base
Assembly: Simplic.Base.dll
Syntax
public static class GlobalSettings
Properties
| Improve this Doc View SourceAppDataPath
Path to the appdata folder, where temporary or not system relevant files are stored
Declaration
public static string AppDataPath { get; }
Property Value
Type | Description |
---|---|
System.String |
ApplicationName
Name of the currently running application using the framework. E.g. Simplic Studio or the Application Server (Shell)
Declaration
public static string ApplicationName { get; set; }
Property Value
Type | Description |
---|---|
System.String |
Arguments
List of arguments with which the hosting process was started
Declaration
public static IDictionary<string, string> Arguments { get; }
Property Value
Type | Description |
---|---|
System.Collections.Generic.IDictionary<System.String, System.String> |
BinDirectoryPath
Additional bin directory path
Declaration
public static string BinDirectoryPath { get; set; }
Property Value
Type | Description |
---|---|
System.String |
ConnectionString
Get the main connection string of the simplic studio / section
Declaration
public static string ConnectionString { get; set; }
Property Value
Type | Description |
---|---|
System.String |
CurrentUserSession
Gets or sets the global user session
Declaration
public static Session.Session CurrentUserSession { get; set; }
Property Value
Type | Description |
---|---|
Session.Session |
DebugLevel
Debug level of the current application instance. Will be removed.
Declaration
[Obsolete("Will be removed. Use Simplic.Log for debug messages/output instead")]
public static int DebugLevel { get; set; }
Property Value
Type | Description |
---|---|
System.Int32 |
IniSection
Ini section which will be used. If the ini section will be set, all values/fields/properties will be resettet
Declaration
public static string IniSection { get; set; }
Property Value
Type | Description |
---|---|
System.String |
MainThread
Instance of the MainThread of the current Application
Declaration
public static Thread MainThread { get; set; }
Property Value
Type | Description |
---|---|
System.Threading.Thread |
MaxMemoryAllocation
Maximum memory the application is allowed to allocate for private memory usage
Declaration
public static ulong MaxMemoryAllocation { get; }
Property Value
Type | Description |
---|---|
System.UInt64 |
MemAllocIsInUse
If set to false, memory allocation will always work
Declaration
public static bool MemAllocIsInUse { get; }
Property Value
Type | Description |
---|---|
System.Boolean |
MinFreeSystemMemory
Minimum of system memory which should be free
Declaration
public static ulong MinFreeSystemMemory { get; }
Property Value
Type | Description |
---|---|
System.UInt64 |
OtherInstanceIsRunning
Returns true, if other simplic studios are running on the same machine
Declaration
public static bool OtherInstanceIsRunning { get; }
Property Value
Type | Description |
---|---|
System.Boolean |
Profile
Profile name
Declaration
public static string Profile { get; set; }
Property Value
Type | Description |
---|---|
System.String |
ServiceName
Gets or sets the service name
Declaration
public static string ServiceName { get; set; }
Property Value
Type | Description |
---|---|
System.String |
SessionId
Unique id of a Simplic Studio / App Server session. A session id will never exists twice
Declaration
public static Guid SessionId { get; }
Property Value
Type | Description |
---|---|
System.Guid |
StudioPath
Path to the applications startup directory (Simplic Studio / App Server path)
Declaration
public static string StudioPath { get; }
Property Value
Type | Description |
---|---|
System.String |
ThemeName
Gets the current theme name
Declaration
public static string ThemeName { get; }
Property Value
Type | Description |
---|---|
System.String |
UseIni
Use ini file
Declaration
public static bool UseIni { get; set; }
Property Value
Type | Description |
---|---|
System.Boolean |
UserConnectionString
Get the user specific connection
Declaration
public static string UserConnectionString { get; set; }
Property Value
Type | Description |
---|---|
System.String |
UserId
Currently logged in and used userid
Declaration
public static int UserId { get; set; }
Property Value
Type | Description |
---|---|
System.Int32 |
UserIsLoggedIn
Returns true, if a user currently logged in in this AppDomain
Declaration
public static bool UserIsLoggedIn { get; set; }
Property Value
Type | Description |
---|---|
System.Boolean |
UserName
Currently logged in user name
Declaration
public static string UserName { get; set; }
Property Value
Type | Description |
---|---|
System.String |
Methods
| Improve this Doc View SourceGetIniInstance()
Get an instance for the Studio.ini IniFileSettings
Declaration
public static Configuration.Ini.IniFileSettings GetIniInstance()
Returns
Type | Description |
---|---|
Configuration.Ini.IniFileSettings | Instance of IniFileSettings using the Studio.ini |
SetPrivateConnectionString(String)
Set connection string private member, so that no writing to the ini file will be affected
Declaration
public static void SetPrivateConnectionString(string newConnectionString)
Parameters
Type | Name | Description |
---|---|---|
System.String | newConnectionString | Connection string |
SetUserConnectionString(String, String)
Set the user connection string with username and password based on the root/default connection string
Declaration
public static void SetUserConnectionString(string UserName, string Password)
Parameters
Type | Name | Description |
---|---|---|
System.String | UserName | Username to set |
System.String | Password | Password to set |