Class Paths
- Namespace
- StockSharp.Configuration
- Assembly
- StockSharp.Configuration.dll
System paths.
public static class Paths
- Inheritance
-
Paths
- Inherited Members
Fields
AppDataPath
The path to the settings directory.
public static readonly string AppDataPath
Field Value
AppName
App title.
public static readonly string AppName
Field Value
BackupExt
Backup extension for settings file.
public const string BackupExt = ".bak"
Field Value
CandlePatternsFile
The path to the file with candle patterns.
public static readonly string CandlePatternsFile
Field Value
CompanyPath
The path to directory with all applications.
public static readonly string CompanyPath
Field Value
CompilerCacheDir
The path to the compiler cache directory.
public static readonly string CompilerCacheDir
Field Value
CredentialsFile
The path to the file with credentials.
public static readonly string CredentialsFile
Field Value
CsEx
CS file extension.
public const string CsEx = ".cs"
Field Value
DefaultSettingsExt
Default extension for settings file.
public const string DefaultSettingsExt = ".json"
Field Value
DllEx
Assembly file extension.
public const string DllEx = ".dll"
Field Value
HistoryBeginDate
Begin date of HistoryDataPath.
public static readonly DateTime HistoryBeginDate
Field Value
HistoryDataPath
Sample history data.
public static readonly string HistoryDataPath
Field Value
HistoryEndDate
End date of HistoryDataPath.
public static readonly DateTime HistoryEndDate
Field Value
InstallerConsoleName
Installer console exe name.
public const string InstallerConsoleName = "StockSharp.Installer.Console"
Field Value
InstallerDir
The path to the installer directory.
public static readonly string InstallerDir
Field Value
InstallerInstallationsConfigPath
The path to the installer directory.
public static readonly string InstallerInstallationsConfigPath
Field Value
InstallerUIName
Installer UI exe name.
public const string InstallerUIName = "StockSharp.Installer.UI"
Field Value
JsonEx
JSON file extension.
public const string JsonEx = ".json"
Field Value
LogsDir
The path to the logs directory.
public static readonly string LogsDir
Field Value
PlatformConfigurationFile
The path to the configuration file of platform definition.
public static readonly string PlatformConfigurationFile
Field Value
ProxyConfigurationFile
The path to the configuration file of proxy settings.
public static readonly string ProxyConfigurationFile
Field Value
ReportLogsPath
The path to the settings directory.
public static readonly string ReportLogsPath
Field Value
SecurityExtendedInfo
The path to the directory with securities extended info.
public static readonly string SecurityExtendedInfo
Field Value
SecurityMappingDir
The path to the directory with securities id mapping.
public static readonly string SecurityMappingDir
Field Value
SecurityNativeIdDir
The path to the directory with native security identifiers.
public static readonly string SecurityNativeIdDir
Field Value
SetupName
Setup name.
public const string SetupName = "stocksharp_setup"
Field Value
SnapshotsDir
The path to the directory with snapshots of market data.
public static readonly string SnapshotsDir
Field Value
StorageDir
The path to the directory with market data.
public static readonly string StorageDir
Field Value
TokenBasedEmail
Ecng.ComponentModel.ServerCredentials.Email in case Ecng.ComponentModel.ServerCredentials.Token.
public const string TokenBasedEmail = "x"
Field Value
Properties
AppName2
public static string AppName2 { get; }
Property Value
AppNameWithVersion
App title with version.
public static string AppNameWithVersion { get; }
Property Value
Bot
Bot in Telegram.
public static string Bot { get; }
Property Value
BuildVersion
Build info version.
public static string BuildVersion { get; }
Property Value
Chat
Chat in Telegram.
public static string Chat { get; }
Property Value
Domain
Web site domain.
public static string Domain { get; }
Property Value
EntryAssembly
Entry assembly.
public static Assembly EntryAssembly { get; }
Property Value
InstalledVersion
Installed version of the product.
public static string InstalledVersion { get; }
Property Value
Methods
CreateSerializer<T>(bool)
Create serializer.
public static ISerializer<T> CreateSerializer<T>(bool bom = true)
Parameters
bom
boolSerializer adds UTF8 BOM preamble.
Returns
- ISerializer<T>
Serializer.
Type Parameters
T
Value type.
DeserializeFromString<T>(T, string)
Deserialize value
state from str
.
public static void DeserializeFromString<T>(this T value, string str) where T : IPersistable
Parameters
Type Parameters
T
Type of
value
.
DeserializeOrThrow<T>(string)
Deserialize value from the specified file.
public static T DeserializeOrThrow<T>(this string filePath)
Parameters
filePath
stringFile path.
Returns
- T
Value.
Type Parameters
T
Value type.
DeserializeWithMigration<T>(string)
[Obsolete("Use Deserialize instead.")]
public static T DeserializeWithMigration<T>(this string filePath)
Parameters
filePath
string
Returns
- T
Type Parameters
T
Deserialize<T>(byte[])
Deserialize value from the serialized data.
public static T Deserialize<T>(this byte[] data)
Parameters
data
byte[]Serialized data.
Returns
- T
Value.
Type Parameters
T
Value type.
Deserialize<T>(Stream)
Deserialize value from the serialized data.
public static T Deserialize<T>(this Stream data)
Parameters
data
StreamSerialized data.
Returns
- T
Value.
Type Parameters
T
Value type.
Deserialize<T>(string)
Deserialize value from the specified file.
public static T Deserialize<T>(this string filePath)
Parameters
filePath
stringFile path.
Returns
- T
Value.
Type Parameters
T
Value type.
EnumerateConfigs(string, string)
Returns an files with DefaultSettingsExt extension.
public static IEnumerable<string> EnumerateConfigs(this string path, string filter = "*")
Parameters
path
stringThe relative or absolute path to the directory to search.
filter
stringThe search string to match against the names of files in path.
Returns
- IEnumerable<string>
Files.
GetAppDataPath(string, string)
Get AppDataPath.
public static string GetAppDataPath(string appDataPath, string appName)
Parameters
appDataPath
stringRelative AppDataPath.
appName
string
Returns
GetDocUrl(string)
To create localized url.
public static string GetDocUrl(string docUrl)
Parameters
docUrl
stringHelp topic.
Returns
- string
Localized url.
GetFileName(Guid)
Get file name for the specified id.
public static string GetFileName(this Guid id)
Parameters
id
GuidIdentifier.
Returns
- string
File name.
GetFileNameWithoutExtension(Guid, char?)
Get file name without extension for the specified id.
public static string GetFileNameWithoutExtension(this Guid id, char? by = '_')
Parameters
Returns
- string
File name without extension.
GetHistoryDataPath(string)
Get history data path.
public static string GetHistoryDataPath(string startDir)
Parameters
startDir
stringDirectory.
Returns
- string
History data path.
GetLogoUrl()
Get logo url.
public static string GetLogoUrl()
Returns
- string
Logo url.
GetPageUrl(long, object)
Get page url.
public static string GetPageUrl(long id, object urlPart = null)
Parameters
Returns
- string
Localized url.
GetWebSiteUrl()
Get website url.
public static string GetWebSiteUrl()
Returns
- string
Localized url.
IsConfigExists(string)
Determines the specified config file exists.
public static bool IsConfigExists(this string configFile)
Parameters
configFile
stringConfig file.
Returns
- bool
Check result.
MakeBackup(string)
Make the specified filePath
with BackupExt extension.
public static string MakeBackup(this string filePath)
Parameters
filePath
stringFile path.
Returns
- string
File path.
MoveToBackup(string, string)
Rename the specified file with BackupExt extension.
public static void MoveToBackup(this string filePath, string backupFilePath = null)
Parameters
ResetInstalledVersionCache()
Reset installed version cache so it would be re-generated next time when it's requested.
public static void ResetInstalledVersionCache()
SerializeToString<T>(T, bool)
Serialize value
state into string value.
public static string SerializeToString<T>(this T value, bool bom = true)
Parameters
value
TValue.
bom
boolSerializer adds UTF8 BOM preamble.
Returns
Type Parameters
T
Type of
value
.
Serialize<T>(T, bool)
Serialize value into byte array.
public static byte[] Serialize<T>(this T value, bool bom = true)
Parameters
value
TValue.
bom
boolAdd UTF8 BOM preamble.
Returns
- byte[]
Serialized data.
Type Parameters
T
Value type.
Serialize<T>(T, string, bool)
Serialize value into the specified file.
public static void Serialize<T>(this T value, string filePath, bool bom = true)
Parameters
Type Parameters
T
Value type.
TryBuildDocUrl(string)
Try to build documentation URL.
public static string TryBuildDocUrl(this string urlPart)
Parameters
urlPart
stringURL part.
Returns
- string
Absolute URL.
TryGetInstalledPath(long)
Try get installed path by product id.
public static string TryGetInstalledPath(long productId)
Parameters
productId
longIdentifier.
Returns
- string
Installed path.
TryGetInstalledVersion(string)
Get currently installed version of the product.
public static string TryGetInstalledVersion(string productInstallPath)
Parameters
productInstallPath
stringFile system path to product installation.
Returns
- string
Installed version of the product.