Class CsvNativeIdStorage
- Namespace
- StockSharp.Algo.Storages
- Assembly
- StockSharp.Algo.dll
CSV security native identifier storage.
public sealed class CsvNativeIdStorage : INativeIdStorage
- Inheritance
-
CsvNativeIdStorage
- Implements
- Inherited Members
- Extension Methods
Constructors
CsvNativeIdStorage(string)
Initializes a new instance of the CsvNativeIdStorage.
public CsvNativeIdStorage(string path)
Parameters
pathstringPath to storage.
Properties
DelayAction
The time delayed action.
public DelayAction DelayAction { get; set; }
Property Value
Methods
Clear(string)
Clear storage.
public void Clear(string storageName)
Parameters
storageNamestringStorage name.
Get(string)
Get native security identifiers for storage.
public (SecurityId, object)[] Get(string storageName)
Parameters
storageNamestringStorage name.
Returns
- (SecurityId secId, object nativeId)[]
Security identifiers.
Init()
Initialize the storage.
public IDictionary<string, Exception> Init()
Returns
- IDictionary<string, Exception>
Possible errors with storage names. Empty dictionary means initialization without any issues.
RemoveByNativeId(string, object, bool)
Remove by native identifier.
public bool RemoveByNativeId(string storageName, object nativeId, bool isPersistable)
Parameters
storageNamestringStorage name.
nativeIdobjectNative (internal) trading system security id.
isPersistableboolSave the identifier as a permanent.
Returns
- bool
Operation result.
RemoveBySecurityId(string, SecurityId, bool)
Remove by security identifier.
public bool RemoveBySecurityId(string storageName, SecurityId securityId, bool isPersistable)
Parameters
storageNamestringStorage name.
securityIdSecurityIdSecurity identifier.
isPersistableboolSave the identifier as a permanent.
Returns
- bool
Operation result.
TryAdd(string, SecurityId, object, bool)
Try add native security identifier to storage.
public bool TryAdd(string storageName, SecurityId securityId, object nativeId, bool isPersistable)
Parameters
storageNamestringStorage name.
securityIdSecurityIdSecurity identifier.
nativeIdobjectNative (internal) trading system security id.
isPersistableboolSave the identifier as a permanent.
Returns
TryGetByNativeId(string, object)
Try get security identifier by native identifier.
public SecurityId? TryGetByNativeId(string storageName, object nativeId)
Parameters
Returns
- SecurityId?
Security identifier.
TryGetBySecurityId(string, SecurityId)
Try get native security identifier by identifier.
public object TryGetBySecurityId(string storageName, SecurityId securityId)
Parameters
storageNamestringStorage name.
securityIdSecurityIdSecurity identifier.
Returns
- object
Native (internal) trading system security id.
Events
Added
The new native security identifier added to storage.
public event Action<string, SecurityId, object> Added