constructor(graph, options = {}) {
    super();
    this.options = options;
    // Processes contains all the instantiated components for this network
    /** @type {Object<string, NetworkProcess>} */
    this.processes = {};
    // Connections contains all the socket connections in the network
    /** @type {Array<internalSocket.InternalSocket>} */
    this.connections = [];
    // Initials contains all Initial Information Packets (IIPs)
    /** @type {Array<NetworkIIP>} */
    this.initials = [];
    /** @type {Array<NetworkIIP>} */
    this.nextInitials = [];
    // Container to hold sockets that will be sending default data.
    /** @type {Array<import("./InternalSocket").InternalSocket>} */
    this.defaults = [];
    // The Graph this network is instantiated with
    this.graph = graph;
    this.started = false;
    this.stopped = true;
    this.debug = true;
    this.asyncDelivery = options.asyncDelivery || false;
    /** @type {Array<NetworkEvent>} */
    this.eventBuffer = [];

    // On Node.js we default the baseDir for component loading to
    // the current working directory
    if (graph.properties.baseDir && !options.baseDir) {
      deprecated('Passing baseDir via Graph properties is deprecated, pass via Network options instead');
    }
    this.baseDir = null;
    if (!isBrowser()) {
      this.baseDir = options.baseDir || graph.properties.baseDir || process.cwd();
    // On browser we default the baseDir to the Component loading
    // root
    } else {
      this.baseDir = options.baseDir || graph.properties.baseDir || '/';
    }

    // As most NoFlo networks are long-running processes, the
    // network coordinator marks down the start-up time. This
    // way we can calculate the uptime of the network.
    /** @type {Date | null} */
    this.startupDate = null;

    // Initialize a Component Loader for the network
    if (options.componentLoader) {
      /** @type {ComponentLoader} */
      this.loader = options.componentLoader;
    } else if (graph.properties.componentLoader) {
      deprecated('Passing componentLoader via Graph properties is deprecated, pass via Network options instead');
      /** @type {ComponentLoader} */
      this.loader = graph.properties.componentLoader;
    } else {
      /** @type {ComponentLoader} */
      this.loader = new ComponentLoader(this.baseDir, this.options);
    }

    // Enable Flowtrace for this network, when available
    this.flowtraceName = null;
    this.setFlowtrace(options.flowtrace || false, null);
  }
All NoFlo networks are instantiated with a graph. Upon instantiation
they will load all the needed components, instantiate them, and
set up the defined connections and IIPs.

@param {import("fbp-graph").Graph} graph - Graph definition to build a Network for
@param {NetworkOptions} options - Network options