LinkProvider(List<String> args, String prefix, { bool isRequester: false, String command: "link", bool isResponder: true, Map<String, dynamic> defaultNodes, Map<String, dynamic> nodes, Map<String, Function> profiles, NodeProvider provider, bool enableHttp: true, bool encodePrettyJson: false, bool autoInitialize: true, bool strictOptions: false, bool exitOnFailure: true, bool loadNodesJson: true, bool strictTls: false, String defaultLogLevel: "INFO", bool savePrivateKey: true, Requester overrideRequester, Responder overrideResponder, NodeProvider nodeProvider, Map linkData, Map<String, String> commandLineOptions })

Create a Link Provider. args are the command-line arguments to pass in. prefix is the link name. isRequester specifies if you are a requester or not. isResponder specifies if you a responder or not. command is the command name for this link. Both defaultNodes and nodes specify the default nodes to initialize if a nodes.json is not present. profiles specify the profiles for this link. provider is a node provider. If it is not specified, one will be created for you. enableHttp toggles whether to enable HTTP fallbacks. encodePrettyJson specifies whether to encode pretty JSON files when writing the nodes.json autoInitialize specifies whether to initialize the link inside the constructor. strictOptions toggles allowing trailing options in the argument parser. exitOnFailure toggles exiting when the link fails. loadNodesJson specifies whether to load the nodes.json file or not. strictTls specifies if a link to a secure broker should fail, if the TLS Certificate is bad. defaultLogLevel specifies the default log level. nodeProvider is the same as provider. It is provided for backwards compatibility. commandLineOptions specifies a map of an option name to a default value, for use in expanding the command parameters.

Source

LinkProvider(
    this.args,
    this.prefix,
    {
      this.isRequester: false,
      this.command: "link",
      this.isResponder: true,
      this.defaultNodes,
      Map<String, dynamic> nodes,
      this.profiles,
      this.provider,
      this.enableHttp: true,
      this.encodePrettyJson: false,
      bool autoInitialize: true,
      this.strictOptions: false,
      this.exitOnFailure: true,
      this.loadNodesJson: true,
      this.strictTls: false,
      this.defaultLogLevel: "INFO",
      this.savePrivateKey: true,
      this.overrideRequester,
      this.overrideResponder,
      NodeProvider nodeProvider, // For Backwards Compatibility
      this.linkData,
      Map<String, String> commandLineOptions
    }) {
  exitOnFailure = Zone.current["dslink.runtime.config"] is! Map;

  if (nodeProvider != null) {
    provider = nodeProvider;
  }

  if (nodes != null) {
    defaultNodes = nodes;
  }

  if (commandLineOptions != null) {
    for (String key in commandLineOptions.keys) {
      addCommandLineOption(key, commandLineOptions[key]);
    }
  }

  if (autoInitialize) {
    init();
  }
}