Lean  $LEAN_TAG$
QuantConnect.Interfaces.IObjectStore Interface Reference

Provides object storage for data persistence. More...

Inheritance diagram for QuantConnect.Interfaces.IObjectStore:
[legend]

Public Member Functions

void Initialize (int userId, int projectId, string userToken, Controls controls)
 Initializes the object store More...
 
bool ContainsKey (string path)
 Determines whether the store contains data for the specified path More...
 
byte[] ReadBytes (string path)
 Returns the object data for the specified key More...
 
bool SaveBytes (string path, byte[] contents)
 Saves the object data for the specified path More...
 
bool Delete (string path)
 Deletes the object data for the specified path More...
 
string GetFilePath (string path)
 Returns the file path for the specified path More...
 
void Clear ()
 Will clear the object store state cache. This is useful when the object store is used concurrently by nodes which want to share information More...
 

Properties

ICollection< string > Keys [get]
 Returns the file paths present in the object store. This is specially useful not to load the object store into memory More...
 

Events

EventHandler< ObjectStoreErrorRaisedEventArgsErrorRaised
 Event raised each time there's an error More...
 

Detailed Description

Provides object storage for data persistence.

Definition at line 27 of file IObjectStore.cs.

Member Function Documentation

◆ Initialize()

void QuantConnect.Interfaces.IObjectStore.Initialize ( int  userId,
int  projectId,
string  userToken,
Controls  controls 
)

Initializes the object store

Parameters
userIdThe user id
projectIdThe project id
userTokenThe user token
controlsThe job controls instance

Implemented in QuantConnect.Lean.Engine.Storage.LocalObjectStore, and QuantConnect.Storage.ObjectStore.

Here is the caller graph for this function:

◆ ContainsKey()

bool QuantConnect.Interfaces.IObjectStore.ContainsKey ( string  path)

Determines whether the store contains data for the specified path

Parameters
pathThe object path
Returns
True if the key was found

Implemented in QuantConnect.Lean.Engine.Storage.LocalObjectStore, and QuantConnect.Storage.ObjectStore.

◆ ReadBytes()

byte [] QuantConnect.Interfaces.IObjectStore.ReadBytes ( string  path)

Returns the object data for the specified key

Parameters
pathThe object key
Returns
A byte array containing the data

Implemented in QuantConnect.Lean.Engine.Storage.LocalObjectStore, and QuantConnect.Storage.ObjectStore.

◆ SaveBytes()

bool QuantConnect.Interfaces.IObjectStore.SaveBytes ( string  path,
byte[]  contents 
)

Saves the object data for the specified path

Parameters
pathThe object path
contentsThe object data
Returns
True if the save operation was successful

Implemented in QuantConnect.Lean.Engine.Storage.LocalObjectStore, and QuantConnect.Storage.ObjectStore.

◆ Delete()

bool QuantConnect.Interfaces.IObjectStore.Delete ( string  path)

Deletes the object data for the specified path

Parameters
pathThe object path
Returns
True if the delete operation was successful

Implemented in QuantConnect.Lean.Engine.Storage.LocalObjectStore, and QuantConnect.Storage.ObjectStore.

◆ GetFilePath()

string QuantConnect.Interfaces.IObjectStore.GetFilePath ( string  path)

Returns the file path for the specified path

Parameters
pathThe object path
Returns
The path for the file

Implemented in QuantConnect.Lean.Engine.Storage.LocalObjectStore, and QuantConnect.Storage.ObjectStore.

◆ Clear()

void QuantConnect.Interfaces.IObjectStore.Clear ( )

Will clear the object store state cache. This is useful when the object store is used concurrently by nodes which want to share information

Implemented in QuantConnect.Lean.Engine.Storage.LocalObjectStore, and QuantConnect.Storage.ObjectStore.

Property Documentation

◆ Keys

ICollection<string> QuantConnect.Interfaces.IObjectStore.Keys
get

Returns the file paths present in the object store. This is specially useful not to load the object store into memory

Definition at line 82 of file IObjectStore.cs.

Event Documentation

◆ ErrorRaised

EventHandler<ObjectStoreErrorRaisedEventArgs> QuantConnect.Interfaces.IObjectStore.ErrorRaised

Event raised each time there's an error

Definition at line 32 of file IObjectStore.cs.


The documentation for this interface was generated from the following file: