smartinspectpython.siloadconnectionsexception

Module: siloadconnectionsexception.py

Revision History

Date Version Description
2023/05/30 3.0.0.0 Initial Version.

@export
class SILoadConnectionsException(builtins.Exception):

Used to report errors concerning the SmartInspect.LoadConnections method.

This exception is used to report errors concerning the SmartInspect.LoadConnections method. This method is able to load a SmartInspect.Connections from a file. Therefore errors can occur when trying to load a connections string from an inexistent file or when the file can not be opened for reading, for example.

If such an error occurs, an instance of this class will be passed to the SmartInspect.Error event. Please note, that, if a connections string can be read correctly, but is found to be invalid then this exception type will not be used. The SmartInspect.LoadConnections method will use the SIInvalidConnectionsException exception instead.

Threadsafety:

This class is not guaranteed to be thread-safe.

SILoadConnectionsException(message, fileName: str, *args, **kwargs)

Initializes a new instance of the class.

Arguments:
  • message (Any): The exception message.
  • fileName (str): The filename that contained the connections string.
FileName: str

Gets the FileName property value.

The name of the file which caused this exception while trying to load the connections string from it.