isOpen method

  1. @override
bool isOpen()

Adds instrumentation to error handling.

  • correlationId (optional) transaction id to trace execution through call chain.
  • name a method name.
  • err an occured error
  • reerror if true - throw error Checks if the component is opened.

Returns true if the component has been opened and false otherwise.

Implementation

// void instrumentError(String? correlationId, String name, err,
//     [bool reerror = false]) {
//   if (err != null) {
//     logger.error(correlationId, err, 'Failed to execute %s method', [name]);
//     counters.incrementOne(name + '.exec_errors');
//     if (reerror != null && reerror == true) {
//       throw err;
//     }
//   }
// }

/// Checks if the component is opened.
///
/// Returns true if the component has been opened and false otherwise.
@override
bool isOpen() {
  return _opened;
}