AsnaConfigHelper class | QSYS API Reference Guide

Provides helper functions and properties for accessing IAsnaConfig properties encoded in JSON configuration texts.

Namespace: ASNA.Extensions.Configuration Assembly: ASNA.QSys.DataGate.Client.dll

Inheritance: Object

Properties

Type Name Description
String DefaultConfigFilePath Gets the suggested full path name for a “default” configurationfile.

Methods

Signature Description
LoadFromJson(Stream) Returns an instance of IAsnaConfig, given a stream.
LoadFromJson(String) Returns an instance of IAsnaConfig, given a path to aJSON-encoded file.
TryLoadFromDefaultFile(IAsnaConfig&) Gets a configuration from the default file.

IAsnaConfig LoadFromJson(Stream jsonStream)

Returns an instance of IAsnaConfig, given a stream.

IAsnaConfig LoadFromJson(Stream jsonStream)

Parameters

Type Parameter name Description
Stream jsonStream The input Stream.

Returns

Type Description
IAsnaConfig IAsnaConfig

IAsnaConfig LoadFromJson(string jsonFilePath)

Returns an instance of IAsnaConfig, given a path to aJSON-encoded file.

IAsnaConfig LoadFromJson(string jsonFilePath)

Parameters

Type Parameter name Description
String jsonFilePath  

Returns

Type Description
IAsnaConfig  

bool TryLoadFromDefaultFile(IAsnaConfig& config)

Gets a configuration from the default file.

bool TryLoadFromDefaultFile(IAsnaConfig& config)

Parameters

Type Parameter name Description
IAsnaConfig& config An IAsnaConfig instance, if the default configuration file named by DefaultConfigFilePath is found, loaded, and parsed. Otherwise, null.

Returns

Type Description
Boolean true if a configuration is loaded from thedefault config file; otherwise false.