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
path
stringPath to storage.
Properties
DelayAction
The time delayed action.
public DelayAction DelayAction { get; set; }
Property Value
- DelayAction
Methods
Clear(string)
Clear storage.
public void Clear(string storageName)
Parameters
storageName
stringStorage name.
Get(string)
Get native security identifiers for storage.
public (SecurityId, object)[] Get(string storageName)
Parameters
storageName
stringStorage 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
storageName
stringStorage name.
nativeId
objectNative (internal) trading system security id.
isPersistable
boolSave 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
storageName
stringStorage name.
securityId
SecurityIdSecurity identifier.
isPersistable
boolSave 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
storageName
stringStorage name.
securityId
SecurityIdSecurity identifier.
nativeId
objectNative (internal) trading system security id.
isPersistable
boolSave 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
storageName
stringStorage name.
securityId
SecurityIdSecurity 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