ctrlX Data Layer .NET API  4.3.0
Loading...
Searching...
No Matches
DatalayerSystem Class Reference

Provides the implementation for IDatalayerSystem. More...

Inheritance diagram for DatalayerSystem:
IDatalayerSystem INativeDisposable

Public Member Functions

 DatalayerSystem (string ipcPath="")
 Initializes a new instance of the DatalayerSystem class.
 
void Dispose ()
 Dispose the instance.
 
void Start (bool startBroker=false)
 Starts the DatalayerSystem.
 
void Stop ()
 Stops the DatalayerSystem.
 
void Start (bool startBroker)
 Starts the DatalayerSystem.
 
void Stop ()
 Stops the DatalayerSystem.
 

Static Public Attributes

static readonly int DefaultClientPort = 2069
 Gets the default Client port.
 
static readonly int DefaultProviderPort = 2070
 Gets the default Provider port.
 
static readonly string ProtocolSchemeIpc = "ipc://"
 Gets the protocol scheme for IPC communication. Recommended to connect to a DatalayerSystem running on localhost.
 
static readonly string ProtocolSchemeTcp = "tcp://"
 Gets the protocol scheme for TCP communication. Recommended to connect to a DatalayerSystem not running on localhost.
 

Protected Member Functions

virtual void Dispose (bool disposing)
 Disposes the instance.
 

Properties

string BfbsPath [set]
 Sets the binary Flatbuffer path, which contains *.bfbs files.
 
IConverter Converter [get]
 Gets the Converter for Variant to JSON conversions.
 
IFactory Factory [get]
 Gets the Factory to create Clients and Providers.
 
string IpcPath [get]
 Gets the path for interprocess communication.
 
bool IsDisposed [get]
 Gets a value that indicates whether the instance is already disposed and useless.
 
bool IsStarted [get]
 Gets a value that indicates whether the DatalayerSystem is started.
 
- Properties inherited from IDatalayerSystem
string BfbsPath [set]
 Sets the binary Flatbuffer path, which contains *.bfbs files.
 
IConverter Converter [get]
 Gets the Converter for Variant to JSON conversions.
 
IFactory Factory [get]
 Gets the Factory to create Clients and Providers.

Exceptions
ObjectDisposedExceptionCannot access a disposed object.
InvalidOperationExceptionOperation not allowed.

 
string IpcPath [get]
 Gets the interprocess communication path.
 
bool IsStarted [get]
 Checks if the DatalayerSystem is started.
 
- Properties inherited from INativeDisposable
bool IsDisposed [get]
 Checks disposed.
 

Detailed Description

Provides the implementation for IDatalayerSystem.

Definition at line 10 of file DatalayerSystem.cs.

Constructor & Destructor Documentation

◆ DatalayerSystem()

DatalayerSystem ( string  ipcPath = "")
inline

Initializes a new instance of the DatalayerSystem class.

Parameters
ipcPathPath for interprocess communication. Leave empty for automatic detection.
Exceptions
ArgumentNullExceptionArgument cannot be null.

Definition at line 30 of file DatalayerSystem.cs.

Member Function Documentation

◆ Dispose() [1/2]

void Dispose ( )
inline

Dispose the instance.

Definition at line 95 of file DatalayerSystem.cs.

References DatalayerSystem.Dispose().

Referenced by DatalayerSystem.Dispose().

◆ Dispose() [2/2]

virtual void Dispose ( bool  disposing)
inlineprotectedvirtual

Disposes the instance.

Parameters
disposingFalse if called by Finalizer, else true.

Definition at line 67 of file DatalayerSystem.cs.

◆ Start()

void Start ( bool  startBroker = false)
inline

Starts the DatalayerSystem.

Parameters
startBrokerUse true to start a broker. If you are a user of the ctrlX Data Layer, set to false.
Exceptions
ObjectDisposedExceptionCannot access a disposed object.

Example

using var system = new DatalayerSystem();
system.Start(startBroker: false);
Provides the implementation for IDatalayerSystem.

Implements IDatalayerSystem.

Definition at line 267 of file DatalayerSystem.cs.

References DatalayerSystem.IsDisposed.

◆ Stop()

void Stop ( )
inline

Stops the DatalayerSystem.

Exceptions
ObjectDisposedExceptionCannot access a disposed object.

Implements IDatalayerSystem.

Definition at line 285 of file DatalayerSystem.cs.

References DatalayerSystem.IsDisposed.

Member Data Documentation

◆ DefaultClientPort

readonly int DefaultClientPort = 2069
static

Gets the default Client port.

Definition at line 166 of file DatalayerSystem.cs.

◆ DefaultProviderPort

readonly int DefaultProviderPort = 2070
static

Gets the default Provider port.

Definition at line 171 of file DatalayerSystem.cs.

◆ ProtocolSchemeIpc

readonly string ProtocolSchemeIpc = "ipc://"
static

Gets the protocol scheme for IPC communication. Recommended to connect to a DatalayerSystem running on localhost.

Definition at line 183 of file DatalayerSystem.cs.

Referenced by Remote.ToString().

◆ ProtocolSchemeTcp

readonly string ProtocolSchemeTcp = "tcp://"
static

Gets the protocol scheme for TCP communication. Recommended to connect to a DatalayerSystem not running on localhost.

Definition at line 177 of file DatalayerSystem.cs.

Property Documentation

◆ BfbsPath

string BfbsPath
set

Sets the binary Flatbuffer path, which contains *.bfbs files.

Exceptions
ObjectDisposedExceptionCannot access a disposed object.
ArgumentNullExceptionArgument cannot be null.

Implements IDatalayerSystem.

Definition at line 228 of file DatalayerSystem.cs.

◆ Converter

IConverter Converter
get

Gets the Converter for Variant to JSON conversions.

Exceptions
ObjectDisposedExceptionCannot access a disposed object.

Implements IDatalayerSystem.

Definition at line 340 of file DatalayerSystem.cs.

◆ Factory

IFactory Factory
get

Gets the Factory to create Clients and Providers.

Exceptions
ObjectDisposedExceptionCannot access a disposed object.
InvalidOperationExceptionOperation not allowed.

Implements IDatalayerSystem.

Definition at line 309 of file DatalayerSystem.cs.

◆ IpcPath

string IpcPath
get

Gets the path for interprocess communication.

Exceptions
ObjectDisposedExceptionCannot access a disposed object.

Implements IDatalayerSystem.

Definition at line 193 of file DatalayerSystem.cs.

◆ IsDisposed

bool IsDisposed
get

Gets a value that indicates whether the instance is already disposed and useless.

Implements INativeDisposable.

Definition at line 61 of file DatalayerSystem.cs.

Referenced by DatalayerSystem.Start(), and DatalayerSystem.Stop().

◆ IsStarted

bool IsStarted
get

Gets a value that indicates whether the DatalayerSystem is started.

Exceptions
ObjectDisposedExceptionCannot access a disposed object.

Implements IDatalayerSystem.

Definition at line 210 of file DatalayerSystem.cs.


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