Qorus Integration Engine®  5.0.12_git
OMQ::AbstractConnectionFileHelper Class Referenceabstract

this class is used to parse the connection files in the server and client More...

Public Member Methods

 constructor (*hash< auto > n_defines)
 creates the object and sets the log code reference/closure
 
 parse (string fname, *bool no_path)
 parses the given file
 
abstract string getType ()
 returns the type of connection being managed
 
abstract log (string conn, string fmt)
 log method
 
abstract private parseImpl (string fname, *bool no_path)
 parses the given file
 
abstract private checkKeyValues (string fname, string n, reference h)
 checks the values and types of keys and optionally does transformations
 
int connectionCount ()
 returns the number of connections defined
 
list< auto > list ()
 returns available connections as a list
 
hash< auto > getInfo (string conn, bool with_password=False)
 returns a hash of connection info for the given connection or throws an exception if the connection does not exist More...
 
*hash< auto > getInfo (bool with_password=False)
 returns a hash of connection info keyed by connection name or NOTHING if no connections exist
 

Static Public Member Methods

static private logDefault (string msg)
 the default logging action is to print out the log message to stderr
 

Public Attributes

const DefaultDescription = "<no description provided>"
 default description for connections with no "desc" key
 

Private Member Methods

hash< auto > parseIntern (string fname, *bool no_path)
 parses a connection configuration file More...
 

Detailed Description

this class is used to parse the connection files in the server and client

Member Function Documentation

◆ getInfo()

hash<auto> OMQ::AbstractConnectionFileHelper::getInfo ( string  conn,
bool  with_password = False 
)

returns a hash of connection info for the given connection or throws an exception if the connection does not exist

Exceptions
CONNECTION-ERRORthe given remote connection is not defined

◆ parseIntern()

hash<auto> OMQ::AbstractConnectionFileHelper::parseIntern ( string  fname,
*bool  no_path 
)
private

parses a connection configuration file

warnings (ex: unknown option key) are logged through the log code reference/closure

Parameters
fnamethe file name to parse
no_pathif True, then URI paths are not allowed in the connection URL
Exceptions
CONNECTION-ERRORMissing config file or malformed syntax
FILE-OPEN2-ERRORerror opening configuration file

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