/*** Generated by streamline 0.10.17 (callbacks) - DO NOT EDIT ***/ var __rt=require('streamline/lib/callbacks/runtime').runtime(__filename, false),__func=__rt.__func,__cb=__rt.__cb; var profile = require("../../../util/profile/index");
















var util = require("util");
var utils = require("../../../util/utils");
var constants = require("./constants");
var $ = utils.getLocaleString;

var NetworkConfig = require("./networkConfig");
var VirtualNetwork = require("./virtualNetwork");
var DnsServer = require("./dnsServer");
var StaticIp = require("./staticIp");
var ReservedIp = require("./reservedIp");
var Nsg = require("./nsg");
var RouteTable = require("./routeTable");
var Subnet = require("./subnet");
var LocalNetwork = require("./localNetwork");
var VpnGateway = require("./vpnGateway");
var AppGateway = require("./appGateway");
var TrafficManager = require("./trafficManager");

exports.init = function(cli) {
  var network = cli.category("network").description($("Commands to manage your networks"));


  network.command("export <file-path>").usage("[options] <file-path>").description($("Export the current network configuration to a file")).option("-s, --subscription <id>", $("the subscription id")).execute(function __1(filePath, options, _) { var networkManagementClient, networkConfig; var __frame = { name: "__1", line: 44 }; return __func(_, this, arguments, __1, 2, __frame, function __$__1() {




      networkManagementClient = createNetworkManagementClient(options);
      networkConfig = new NetworkConfig(cli, networkManagementClient);
      return networkConfig.export(filePath, options, __cb(_, __frame, 3, 20, function __$__1() { _(); }, true)); }); });


  network.command("import <file-path>").usage("[options] <file-path>").description($("Set the network configuration from a file")).option("-s, --subscription <id>", $("the subscription id")).execute(function __2(filePath, options, _) { var networkManagementClient, networkConfig; var __frame = { name: "__2", line: 54 }; return __func(_, this, arguments, __2, 2, __frame, function __$__2() {




      networkManagementClient = createNetworkManagementClient(options);
      networkConfig = new NetworkConfig(cli, networkManagementClient);
      return networkConfig.import(filePath, options, __cb(_, __frame, 3, 20, function __$__2() { _(); }, true)); }); });


  var dnsServer = network.category("dns-server").description($("Commands to manage your DNS servers"));


  dnsServer.command("list").usage("[options]").description($("List DNS servers registered in network")).option("-s, --subscription <id>", $("the subscription id")).execute(function __3(options, _) { var networkManagementClient, dnsServer; var __frame = { name: "__3", line: 67 }; return __func(_, this, arguments, __3, 1, __frame, function __$__3() {




      networkManagementClient = createNetworkManagementClient(options);
      dnsServer = new DnsServer(cli, networkManagementClient);
      return dnsServer.list(options, __cb(_, __frame, 3, 16, function __$__3() { _(); }, true)); }); });


  dnsServer.command("register [dns-ip]").usage("[options] <dns-ip>").description($("Register a DNS server with network")).option("-p, --dns-ip <dns-ip>", $("the IP address of the DNS server")).option("-i, --dns-id <dns-id>", $("the name identifier of the DNS server")).option("-s, --subscription <id>", $("the subscription id")).execute(function __4(dnsIp, options, _) { var networkManagementClient, dnsServer; var __frame = { name: "__4", line: 79 }; return __func(_, this, arguments, __4, 2, __frame, function __$__4() {






      return cli.interaction.promptIfNotGiven($("DNS IP: "), dnsIp, __cb(_, __frame, 1, 30, function ___(__0, __1) { dnsIp = __1;

        networkManagementClient = createNetworkManagementClient(options);
        dnsServer = new DnsServer(cli, networkManagementClient);
        return dnsServer.register(dnsIp, options, __cb(_, __frame, 5, 16, function __$__4() { _(); }, true)); }, true)); }); });


  dnsServer.command("unregister [dns-ip]").usage("[options] <dns-ip>").description($("Unregister a DNS server registered in the current network")).option("-p, --dns-ip <dns-ip>", $("the IP address of the DNS server")).option("-i, --dns-id <dns-id>", $("the name identifier of the DNS server")).option("-q, --quiet", $("quiet mode, do not ask for unregister confirmation")).option("-s, --subscription <id>", $("the subscription id")).execute(function __5(dnsIp, options, _) { var networkManagementClient, dnsServer; var __frame = { name: "__5", line: 94 }; return __func(_, this, arguments, __5, 2, __frame, function __$__5() {







      networkManagementClient = createNetworkManagementClient(options);
      dnsServer = new DnsServer(cli, networkManagementClient);
      return dnsServer.unregister(dnsIp, options, __cb(_, __frame, 3, 16, function __$__5() { _(); }, true)); }); });


  var vnet = network.category("vnet").description($("Commands to manage your virtual networks"));


  vnet.command("create [vnet]").usage("[options] <vnet>").description($("Create a virtual network")).option("--vnet <vnet>", $("the name of the virtual network")).option("-e, --address-space <ipv4>", $("the address space for the virtual network")).option("-m, --max-vm-count <number>", $("the maximum number of VMs in the address space")).option("-i, --cidr <number>", $("the address space network mask in CIDR format")).option("-p, --subnet-start-ip <ipv4>", $("the start IP address of subnet")).option("-n, --subnet-name <name>", $("the name for the subnet")).option("-c, --subnet-vm-count <number>", $("the maximum number of VMs in the subnet")).option("-r, --subnet-cidr <number>", $("the subnet network mask in CIDR format")).option("-l, --location <name>", $("the location")).option("-f, --create-new-affinity-group", $("creates a new affinity group at the location specified in --location")).option("-a, --affinity-group <name>", $("the affinity group")).option("-d, --dns-server-id <dns-id>", $("the name identifier of the DNS server")).option("-s, --subscription <id>", $("the subscription id")).execute(function __6(vnet, options, _) { var managementClient, networkManagementClient, virtualNetwork; var __frame = { name: "__6", line: 119 }; return __func(_, this, arguments, __6, 2, __frame, function __$__6() {
















      return cli.interaction.promptIfNotGiven($("Virtual network name: "), vnet, __cb(_, __frame, 1, 29, function ___(__0, __1) { vnet = __1;

        managementClient = createManagementClient(options);
        networkManagementClient = createNetworkManagementClient(options);
        virtualNetwork = new VirtualNetwork(cli, managementClient, networkManagementClient);
        return virtualNetwork.create(vnet, options, __cb(_, __frame, 6, 21, function __$__6() { _(); }, true)); }, true)); }); });


  vnet.command("list").usage("[options]").description($("List your virtual networks")).option("-s, --subscription <id>", $("the subscription id")).execute(function __7(options, _) { var managementClient, networkManagementClient, virtualNetwork; var __frame = { name: "__7", line: 132 }; return __func(_, this, arguments, __7, 1, __frame, function __$__7() {




      managementClient = createManagementClient(options);
      networkManagementClient = createNetworkManagementClient(options);
      virtualNetwork = new VirtualNetwork(cli, managementClient, networkManagementClient);
      return virtualNetwork.list(options, __cb(_, __frame, 4, 21, function __$__7() { _(); }, true)); }); });


  vnet.command("show [vnet]").usage("<vnet> [options]").description($("Show details about a virtual network")).option("--vnet <vnet>", $("the name of the virtual network")).option("-s, --subscription <id>", $("the subscription id")).execute(function __8(vnet, options, _) { var managementClient, networkManagementClient, virtualNetwork; var __frame = { name: "__8", line: 144 }; return __func(_, this, arguments, __8, 2, __frame, function __$__8() {





      return cli.interaction.promptIfNotGiven($("Virtual network name: "), vnet, __cb(_, __frame, 1, 29, function ___(__0, __1) { vnet = __1;

        managementClient = createManagementClient(options);
        networkManagementClient = createNetworkManagementClient(options);
        virtualNetwork = new VirtualNetwork(cli, managementClient, networkManagementClient);
        return virtualNetwork.show(vnet, options, __cb(_, __frame, 6, 21, function __$__8() { _(); }, true)); }, true)); }); });


  vnet.command("delete [vnet]").usage("[options] <vnet>").description($("Delete a virtual network")).option("--vnet <vnet>", $("the name of the virtual network")).option("-q, --quiet", $("quiet mode, do not ask for delete confirmation")).option("-s, --subscription <id>", $("the subscription id")).execute(function __9(vnet, options, _) { var managementClient, networkManagementClient, virtualNetwork; var __frame = { name: "__9", line: 159 }; return __func(_, this, arguments, __9, 2, __frame, function __$__9() {






      return cli.interaction.promptIfNotGiven($("Virtual network name: "), vnet, __cb(_, __frame, 1, 29, function ___(__0, __1) { vnet = __1;

        managementClient = createManagementClient(options);
        networkManagementClient = createNetworkManagementClient(options);
        virtualNetwork = new VirtualNetwork(cli, managementClient, networkManagementClient);
        return virtualNetwork.delete(vnet, options, __cb(_, __frame, 6, 21, function __$__9() { _(); }, true)); }, true)); }); });


  var vnetLocalNetwork = vnet.category("local-network").description($("Commands to manage association between virtual network and local network"));


  vnetLocalNetwork.command("add [name] [local-network-name]").usage("[options] <name> <local-network-name>").description($("Associate a local network with a virtual network")).option("-n, --name <name>", $("the name of the virtual network")).option("-l, --local-network-name <local-network-name>", $("the name of the local network")).option("-s, --subscription <id>", $("the subscription id")).execute(function __10(virtualNetworkName, localNetworkName, options, _) { var networkManagementClient, localNetwork; var __frame = { name: "__10", line: 177 }; return __func(_, this, arguments, __10, 3, __frame, function __$__10() {






      return cli.interaction.promptIfNotGiven($("Virtual network name: "), virtualNetworkName, __cb(_, __frame, 1, 43, function ___(__0, __1) { virtualNetworkName = __1;
        return cli.interaction.promptIfNotGiven($("Local network name: "), localNetworkName, __cb(_, __frame, 2, 41, function ___(__0, __2) { localNetworkName = __2;

          networkManagementClient = createNetworkManagementClient(options);
          localNetwork = new LocalNetwork(cli, networkManagementClient);
          return localNetwork.addAssociation(virtualNetworkName, localNetworkName, options, __cb(_, __frame, 6, 19, function __$__10() { _(); }, true)); }, true)); }, true)); }); });


  vnetLocalNetwork.command("remove [name] [local-network-name]").usage("[options] <name> <local-network-name>").description($("Remove association between a local network and a virtual network")).option("-n, --name <name>", $("the name of the virtual network")).option("-l, --local-network-name <local-network-name>", $("the name of the local network")).option("-s, --subscription <id>", $("the subscription id")).execute(function __11(virtualNetworkName, localNetworkName, options, _) { var networkManagementClient, localNetwork; var __frame = { name: "__11", line: 192 }; return __func(_, this, arguments, __11, 3, __frame, function __$__11() {






      return cli.interaction.promptIfNotGiven($("Virtual network name: "), virtualNetworkName, __cb(_, __frame, 1, 43, function ___(__0, __1) { virtualNetworkName = __1;
        return cli.interaction.promptIfNotGiven($("Local network name: "), localNetworkName, __cb(_, __frame, 2, 41, function ___(__0, __2) { localNetworkName = __2;

          networkManagementClient = createNetworkManagementClient(options);
          localNetwork = new LocalNetwork(cli, networkManagementClient);
          return localNetwork.removeAssociation(virtualNetworkName, localNetworkName, options, __cb(_, __frame, 6, 19, function __$__11() { _(); }, true)); }, true)); }, true)); }); });


  var staticIP = vnet.category("static-ip").description($("Commands to manage your virtual network static IP addresses"));


  staticIP.command("check [vnet] [ip-address]").usage("[options] <vnet> <ip-address>").description($("Check the availability of a static IP address")).option("-s, --subscription <id>", $("the subscription id")).execute(function __12(vnet, ipAddress, options, _) { var networkManagementClient, staticIP; var __frame = { name: "__12", line: 208 }; return __func(_, this, arguments, __12, 3, __frame, function __$__12() {




      return cli.interaction.promptIfNotGiven($("Virtual network name: "), vnet, __cb(_, __frame, 1, 29, function ___(__0, __1) { vnet = __1;
        return cli.interaction.promptIfNotGiven($("Static IP address: "), ipAddress, __cb(_, __frame, 2, 34, function ___(__0, __2) { ipAddress = __2;

          networkManagementClient = createNetworkManagementClient(options);
          staticIP = new StaticIp(cli, networkManagementClient);
          return staticIP.check(vnet, ipAddress, options, __cb(_, __frame, 6, 15, function __$__12() { _(); }, true)); }, true)); }, true)); }); });


  var reservedIP = network.category("reserved-ip").description($("Commands to manage your reserved public virtual IP addresses"));


  reservedIP.command("create <name> <location>").usage("[options] <name> <location>").description($("Create a reserved IP address")).option("-e, --label <label>", $("the reserved IP address label")).option("-s, --subscription <id>", $("the subscription id")).execute(function __13(name, location, options, _) { var networkManagementClient, reservedIp; var __frame = { name: "__13", line: 225 }; return __func(_, this, arguments, __13, 3, __frame, function __$__13() {





      networkManagementClient = createNetworkManagementClient(options);
      reservedIp = new ReservedIp(cli, networkManagementClient);
      return reservedIp.create(name, location, options, __cb(_, __frame, 3, 17, function __$__13() { _(); }, true)); }); });


  reservedIP.command("list").usage("[options]").description($("List your reserved IP addresses")).option("-s, --subscription <id>", $("the subscription id")).execute(function __14(options, _) { var networkManagementClient, reservedIp; var __frame = { name: "__14", line: 235 }; return __func(_, this, arguments, __14, 1, __frame, function __$__14() {




      networkManagementClient = createNetworkManagementClient(options);
      reservedIp = new ReservedIp(cli, networkManagementClient);
      return reservedIp.list(options, __cb(_, __frame, 3, 17, function __$__14() { _(); }, true)); }); });


  reservedIP.command("show <name>").usage("[options] <name>").description($("Show details about a reserved IP address")).option("-s, --subscription <id>", $("the subscription id")).execute(function __15(name, options, _) { var networkManagementClient, reservedIp; var __frame = { name: "__15", line: 245 }; return __func(_, this, arguments, __15, 2, __frame, function __$__15() {




      networkManagementClient = createNetworkManagementClient(options);
      reservedIp = new ReservedIp(cli, networkManagementClient);
      return reservedIp.show(name, options, __cb(_, __frame, 3, 17, function __$__15() { _(); }, true)); }); });


  reservedIP.command("delete <name>").usage("[options] <name>").description($("Delete a reserved IP address")).option("-q, --quiet", $("quiet mode, do not ask for delete confirmation")).option("-s, --subscription <id>", $("the subscription id")).execute(function __16(name, options, _) { var networkManagementClient, reservedIp; var __frame = { name: "__16", line: 256 }; return __func(_, this, arguments, __16, 2, __frame, function __$__16() {





      networkManagementClient = createNetworkManagementClient(options);
      reservedIp = new ReservedIp(cli, networkManagementClient);
      return reservedIp.delete(name, options, __cb(_, __frame, 3, 17, function __$__16() { _(); }, true)); }); });


  var nsg = network.category("nsg").description($("Commands to manage network security groups"));


  nsg.command("create [name] [location]").description($("Create a network security group")).usage("[options] <name> <location>").option("-n, --name <name>", $("the name of the network security group")).option("-l, --location <location>", $("the location")).option("-b, --label <label>", $("the label of the network security group")).option("-s, --subscription <subscription>", $("the subscription identifier")).execute(function __17(name, location, options, _) { var networkManagementClient, nsg; var __frame = { name: "__17", line: 272 }; return __func(_, this, arguments, __17, 3, __frame, function __$__17() {







      return cli.interaction.promptIfNotGiven($("Network security group name: "), name, __cb(_, __frame, 1, 29, function ___(__0, __1) { name = __1;
        return cli.interaction.promptIfNotGiven($("Location: "), location, __cb(_, __frame, 2, 33, function ___(__0, __2) { location = __2;

          networkManagementClient = createNetworkManagementClient(options);
          nsg = new Nsg(cli, networkManagementClient);
          return nsg.create(name, location, options, __cb(_, __frame, 6, 10, function __$__17() { _(); }, true)); }, true)); }, true)); }); });


  nsg.command("list").usage("[options]").description($("List network security groups")).option("-s, --subscription <id>", $("the subscription id")).execute(function __18(options, _) { var networkManagementClient, nsg; var __frame = { name: "__18", line: 285 }; return __func(_, this, arguments, __18, 1, __frame, function __$__18() {




      networkManagementClient = createNetworkManagementClient(options);
      nsg = new Nsg(cli, networkManagementClient);
      return nsg.list(options, __cb(_, __frame, 3, 10, function __$__18() { _(); }, true)); }); });


  nsg.command("show [name]").description($("Show the details about a network security group")).usage("[options] <name>").option("-n, --name <name>", $("the name of the network security group")).option("-s, --subscription <subscription>", $("the subscription identifier")).execute(function __19(name, options, _) { var networkManagementClient, nsg; var __frame = { name: "__19", line: 296 }; return __func(_, this, arguments, __19, 2, __frame, function __$__19() {





      return cli.interaction.promptIfNotGiven($("Network security group name: "), name, __cb(_, __frame, 1, 29, function ___(__0, __1) { name = __1;

        networkManagementClient = createNetworkManagementClient(options);
        nsg = new Nsg(cli, networkManagementClient);
        return nsg.show(name, options, __cb(_, __frame, 5, 10, function __$__19() { _(); }, true)); }, true)); }); });


  nsg.command("delete [name]").description($("Delete a network security group")).usage("[options] <name>").option("-n, --name <name>", $("the name of the network security group")).option("-q, --quiet", $("quiet mode, do not ask for delete confirmation")).option("-s, --subscription <subscription>", $("the subscription identifier")).execute(function __20(name, options, _) { var networkManagementClient, nsg; var __frame = { name: "__20", line: 310 }; return __func(_, this, arguments, __20, 2, __frame, function __$__20() {






      return cli.interaction.promptIfNotGiven($("Network security group name: "), name, __cb(_, __frame, 1, 29, function ___(__0, __1) { name = __1;

        networkManagementClient = createNetworkManagementClient(options);
        nsg = new Nsg(cli, networkManagementClient);
        return nsg.delete(name, options, __cb(_, __frame, 5, 10, function __$__20() { _(); }, true)); }, true)); }); });


  var nsgRule = nsg.category("rule").description($("Commands to manage network security group rules"));


  nsgRule.command("create [nsg-name] [name]").usage("[options] <nsg-name> <name>").description($("Create a network security group rule")).option("-a, --nsg-name <nsg-name>", $("the name of the network security group")).option("-n, --name <name>", $("the name of the rule")).option("-p, --protocol <protocol>", $("the protocol")).option("-f, --source-address-prefix <source-address-prefix>", $("the source address prefix")).option("-o, --source-port-range <source-port-range>", $("the source port range")).option("-e, --destination-address-prefix <destination-address-prefix>", $("the destination address prefix")).option("-u, --destination-port-range <destination-port-range>", $("the destination port range")).option("-c, --action <action>", $("the action mode [Allow, Deny]")).option("-y, --priority <priority>", $("the priority")).option("-r, --type <type>", $("the type")).option("-s, --subscription <id>", $("the subscription id")).execute(function __21(nsgName, ruleName, options, _) { var networkManagementClient, nsg; var __frame = { name: "__21", line: 335 }; return __func(_, this, arguments, __21, 3, __frame, function __$__21() {














      return cli.interaction.promptIfNotGiven($("Network security group name: "), nsgName, __cb(_, __frame, 1, 32, function ___(__0, __1) { nsgName = __1;
        return cli.interaction.promptIfNotGiven($("Rule name: "), ruleName, __cb(_, __frame, 2, 33, function ___(__0, __2) { ruleName = __2;

          networkManagementClient = createNetworkManagementClient(options);
          nsg = new Nsg(cli, networkManagementClient);
          return nsg.createRule(nsgName, ruleName, options, __cb(_, __frame, 6, 10, function __$__21() { _(); }, true)); }, true)); }, true)); }); });


  nsgRule.command("set [nsg-name] [name]").usage("[options] <nsg-name> <name>").description($("Set a network security group rule")).option("-a, --nsg-name <nsg-name>", $("the name of the network security group")).option("-n, --name <name>", $("the name of the rule")).option("-p, --protocol <protocol>", $("the protocol")).option("-f, --source-address-prefix <source-address-prefix>", $("the source address prefix")).option("-o, --source-port-range <source-port-range>", $("the source port range")).option("-e, --destination-address-prefix <destination-address-prefix>", $("the destination address prefix")).option("-u, --destination-port-range <destination-port-range>", $("the destination port range")).option("-c, --action <action>", $("the action mode [Allow, Deny]")).option("-y, --priority <priority>", $("the priority")).option("-r, --type <type>", $("the type")).option("-s, --subscription <id>", $("the subscription id")).execute(function __22(nsgName, ruleName, options, _) { var networkManagementClient, nsg; var __frame = { name: "__22", line: 358 }; return __func(_, this, arguments, __22, 3, __frame, function __$__22() {














      return cli.interaction.promptIfNotGiven($("Network security group name: "), nsgName, __cb(_, __frame, 1, 32, function ___(__0, __1) { nsgName = __1;
        return cli.interaction.promptIfNotGiven($("Rule name: "), ruleName, __cb(_, __frame, 2, 33, function ___(__0, __2) { ruleName = __2;

          networkManagementClient = createNetworkManagementClient(options);
          nsg = new Nsg(cli, networkManagementClient);
          return nsg.setRule(nsgName, ruleName, options, __cb(_, __frame, 6, 10, function __$__22() { _(); }, true)); }, true)); }, true)); }); });


  nsgRule.command("list [nsg-name]").usage("[options] <nsg-name>").description($("List rules in a network security group")).option("-a, --nsg-name <nsg-name>", $("the name of the network security group")).option("-s, --subscription <id>", $("the subscription id")).execute(function __23(nsgName, options, _) { var networkManagementClient, nsg; var __frame = { name: "__23", line: 372 }; return __func(_, this, arguments, __23, 2, __frame, function __$__23() {





      return cli.interaction.promptIfNotGiven($("Network security group name: "), nsgName, __cb(_, __frame, 1, 32, function ___(__0, __1) { nsgName = __1;

        networkManagementClient = createNetworkManagementClient(options);
        nsg = new Nsg(cli, networkManagementClient);
        return nsg.listRules(nsgName, options, __cb(_, __frame, 5, 10, function __$__23() { _(); }, true)); }, true)); }); });


  nsgRule.command("show [nsg-name] [name]").usage("[options] <nsg-name> <name>").description($("Show rule in a network security group")).option("-a, --nsg-name <nsg-name>", $("the name of the network security group")).option("-n, --name <name>", $("the name of the rule")).option("-s, --subscription <id>", $("the subscription id")).execute(function __24(nsgName, ruleName, options, _) { var networkManagementClient, nsg; var __frame = { name: "__24", line: 386 }; return __func(_, this, arguments, __24, 3, __frame, function __$__24() {






      return cli.interaction.promptIfNotGiven($("Network security group name: "), nsgName, __cb(_, __frame, 1, 32, function ___(__0, __1) { nsgName = __1;
        return cli.interaction.promptIfNotGiven($("Rule name: "), ruleName, __cb(_, __frame, 2, 33, function ___(__0, __2) { ruleName = __2;

          networkManagementClient = createNetworkManagementClient(options);
          nsg = new Nsg(cli, networkManagementClient);
          return nsg.showRule(nsgName, ruleName, options, __cb(_, __frame, 6, 10, function __$__24() { _(); }, true)); }, true)); }, true)); }); });


  nsgRule.command("delete [nsg-name] [name]").usage("[options] <nsg-name> <name>").description($("Delete a network security group rule")).option("-a, --nsg-name <nsg-name>", $("the name of the network security group")).option("-n, --name <name>", $("the name of the rule")).option("-q, --quiet", $("quiet mode, do not ask for delete confirmation")).option("-s, --subscription <id>", $("the subscription id")).execute(function __25(nsgName, ruleName, options, _) { var networkManagementClient, nsg; var __frame = { name: "__25", line: 402 }; return __func(_, this, arguments, __25, 3, __frame, function __$__25() {







      return cli.interaction.promptIfNotGiven($("Network security group name: "), nsgName, __cb(_, __frame, 1, 32, function ___(__0, __1) { nsgName = __1;
        return cli.interaction.promptIfNotGiven($("Rule name: "), ruleName, __cb(_, __frame, 2, 33, function ___(__0, __2) { ruleName = __2;

          networkManagementClient = createNetworkManagementClient(options);
          nsg = new Nsg(cli, networkManagementClient);
          return nsg.deleteRule(nsgName, ruleName, options, __cb(_, __frame, 6, 10, function __$__25() { _(); }, true)); }, true)); }, true)); }); });


  var nsgSubnet = nsg.category("subnet").description("Commands to manage network security group of subnet");


  nsgSubnet.command("add [nsg-name] [vnet-name] [subnet-name]").usage("[options] <nsg-name> <vnet-name> <subnet-name>").description("Associate a network security group with a subnet").option("-a, --nsg-name <nsg-name>", $("the name of the network security group")).option("-n, --vnet-name <vnet-name>", $("the name of the virtual network")).option("-n, --subnet-name <subnet-name>", $("the name of the virtual network subnet")).option("-s, --subscription <id>", $("the subscription id")).execute(function __26(nsgName, vnetName, subnetName, options, _) { var networkManagementClient, subnet; var __frame = { name: "__26", line: 421 }; return __func(_, this, arguments, __26, 4, __frame, function __$__26() {







      return cli.interaction.promptIfNotGiven($("Network Security group name: "), nsgName, __cb(_, __frame, 1, 32, function ___(__0, __1) { nsgName = __1;
        return cli.interaction.promptIfNotGiven($("Virtual network name: "), vnetName, __cb(_, __frame, 2, 33, function ___(__0, __2) { vnetName = __2;
          return cli.interaction.promptIfNotGiven($("Virtual network subnet name: "), subnetName, __cb(_, __frame, 3, 35, function ___(__0, __3) { subnetName = __3;

            networkManagementClient = createNetworkManagementClient(options);
            subnet = new Subnet(cli, networkManagementClient);
            return subnet.addNsg(nsgName, vnetName, subnetName, options, __cb(_, __frame, 7, 13, function __$__26() { _(); }, true)); }, true)); }, true)); }, true)); }); });


  nsgSubnet.command("remove [nsg-name] [vnet-name] [subnet-name]").usage("[options] <nsg-name> <vnet-name> <subnet-name>").description("Remove association between a network security group and subnet").option("-a, --nsg-name <nsg-name>", $("the name of the network security group")).option("-n, --vnet-name <vnet-name>", $("the name of the virtual network")).option("-n, --subnet-name <subnet-name>", $("the name of the virtual network subnet")).option("-q, --quiet", $("quiet mode, do not ask for delete confirmation")).option("-s, --subscription <id>", $("the subscription id")).execute(function __27(nsgName, vnetName, subnetName, options, _) { var networkManagementClient, subnet; var __frame = { name: "__27", line: 439 }; return __func(_, this, arguments, __27, 4, __frame, function __$__27() {








      return cli.interaction.promptIfNotGiven($("Network Security group name: "), nsgName, __cb(_, __frame, 1, 32, function ___(__0, __1) { nsgName = __1;
        return cli.interaction.promptIfNotGiven($("Virtual network name: "), vnetName, __cb(_, __frame, 2, 33, function ___(__0, __2) { vnetName = __2;
          return cli.interaction.promptIfNotGiven($("Virtual network subnet name: "), subnetName, __cb(_, __frame, 3, 35, function ___(__0, __3) { subnetName = __3;

            networkManagementClient = createNetworkManagementClient(options);
            subnet = new Subnet(cli, networkManagementClient);
            return subnet.removeNsg(nsgName, vnetName, subnetName, options, __cb(_, __frame, 7, 13, function __$__27() { _(); }, true)); }, true)); }, true)); }, true)); }); });


  var subnet = vnet.category("subnet").description($("Commands to manage your virtual network subnets"));


  subnet.command("create [vnet-name] [name]").usage("[options] <vnet-name> <name>").description($("Create a virtual network subnet")).option("-t, --vnet-name <vnet-name>", $("the name of the virtual network")).option("-n, --name <name>", $("the name of the subnet")).option("-a, --address-prefix <address-prefix>", $("the address prefix")).option("-o, --network-security-group-name <network-security-group-name>", $("the network security group name")).option("-s, --subscription <id>", $("the subscription id")).execute(function __28(vnetName, name, options, _) { var networkManagementClient, subnet; var __frame = { name: "__28", line: 460 }; return __func(_, this, arguments, __28, 3, __frame, function __$__28() {








      return cli.interaction.promptIfNotGiven($("Virtual network name: "), vnetName, __cb(_, __frame, 1, 33, function ___(__0, __1) { vnetName = __1;
        return cli.interaction.promptIfNotGiven($("Subnet name: "), name, __cb(_, __frame, 2, 29, function ___(__0, __2) { name = __2;
          return cli.interaction.promptIfNotGiven($("Address prefix: "), options.addressPrefix, __cb(_, __frame, 3, 46, function ___(__0, __3) { options.addressPrefix = __3;

            networkManagementClient = createNetworkManagementClient(options);
            subnet = new Subnet(cli, networkManagementClient);
            return subnet.create(vnetName, name, options, __cb(_, __frame, 7, 13, function __$__28() { _(); }, true)); }, true)); }, true)); }, true)); }); });


  subnet.command("set [vnet-name] [name]").usage("[options] <vnet-name> <name>").description($("Set a virtual network subnet")).option("-t, --vnet-name <vnet-name>", $("the name of the virtual network")).option("-n, --name <name>", $("the name of the subnet")).option("-a, --address-prefix <address-prefix>", $("the address prefix")).option("-s, --subscription <id>", $("the subscription id")).execute(function __29(vnetName, name, options, _) { var networkManagementClient, subnet; var __frame = { name: "__29", line: 477 }; return __func(_, this, arguments, __29, 3, __frame, function __$__29() {







      return cli.interaction.promptIfNotGiven($("Virtual network name: "), vnetName, __cb(_, __frame, 1, 33, function ___(__0, __1) { vnetName = __1;
        return cli.interaction.promptIfNotGiven($("Subnet name: "), name, __cb(_, __frame, 2, 29, function ___(__0, __2) { name = __2;

          networkManagementClient = createNetworkManagementClient(options);
          subnet = new Subnet(cli, networkManagementClient);
          return subnet.set(vnetName, name, options, __cb(_, __frame, 6, 13, function __$__29() { _(); }, true)); }, true)); }, true)); }); });


  subnet.command("list [vnet-name]").usage("[options] <vnet-name>").description($("Get all subnets in a virtual network")).option("-e, --vnet-name <vnet-name>", $("the name of the virtual network")).option("-s, --subscription <id>", $("the subscription id")).execute(function __30(vnetName, options, _) { var networkManagementClient, subnet; var __frame = { name: "__30", line: 491 }; return __func(_, this, arguments, __30, 2, __frame, function __$__30() {





      return cli.interaction.promptIfNotGiven($("Virtual network name: "), vnetName, __cb(_, __frame, 1, 33, function ___(__0, __1) { vnetName = __1;

        networkManagementClient = createNetworkManagementClient(options);
        subnet = new Subnet(cli, networkManagementClient);
        return subnet.list(vnetName, options, __cb(_, __frame, 5, 13, function __$__30() { _(); }, true)); }, true)); }); });


  subnet.command("show [vnet-name] [name]").usage("[options] <vnet-name>").description($("Show a details about subnet in a virtual network")).option("-e, --vnet-name <vnet-name>", $("the name of the virtual network")).option("-n, --name <name>", $("the name of the subnet")).option("-s, --subscription <id>", $("the subscription id")).execute(function __31(vnetName, name, options, _) { var networkManagementClient, subnet; var __frame = { name: "__31", line: 505 }; return __func(_, this, arguments, __31, 3, __frame, function __$__31() {






      return cli.interaction.promptIfNotGiven($("Virtual network name: "), vnetName, __cb(_, __frame, 1, 33, function ___(__0, __1) { vnetName = __1;
        return cli.interaction.promptIfNotGiven($("Virtual network subnet name: "), name, __cb(_, __frame, 2, 29, function ___(__0, __2) { name = __2;

          networkManagementClient = createNetworkManagementClient(options);
          subnet = new Subnet(cli, networkManagementClient);
          return subnet.show(vnetName, name, options, __cb(_, __frame, 6, 13, function __$__31() { _(); }, true)); }, true)); }, true)); }); });


  subnet.command("delete [vnet-name] [name]").usage("[options] <vnet-name> <name>").description($("Delete a virtual network subnet")).option("-e, --vnet-name <vnet-name>", $("the name of the virtual network")).option("-n, --name <name>", $("the name of the subnet")).option("-q, --quiet", $("quiet mode, do not ask for delete confirmation")).option("-s, --subscription <id>", $("the subscription id")).execute(function __32(vnetName, name, options, _) { var networkManagementClient, subnet; var __frame = { name: "__32", line: 521 }; return __func(_, this, arguments, __32, 3, __frame, function __$__32() {







      return cli.interaction.promptIfNotGiven($("Virtual network name: "), vnetName, __cb(_, __frame, 1, 33, function ___(__0, __1) { vnetName = __1;
        return cli.interaction.promptIfNotGiven($("Subnet name: "), name, __cb(_, __frame, 2, 29, function ___(__0, __2) { name = __2;

          networkManagementClient = createNetworkManagementClient(options);
          subnet = new Subnet(cli, networkManagementClient);
          return subnet.delete(vnetName, name, options, __cb(_, __frame, 6, 13, function __$__32() { _(); }, true)); }, true)); }, true)); }); });


  var subnetRouteTable = subnet.category("route-table").description($("Commands to manage subnet Route Tables"));


  subnetRouteTable.command("add [vnet-name] [subnet-name] [route-table-name]").usage("[options] <vnet-name> <subnet-name> <route-table-name>").description($("Add Route Table to a subnet")).option("-t, --vnet-name <vnet-name>", $("the name of the virtual network")).option("-n, --subnet-name <subnet-name>", $("the name of the subnet")).option("-r, --route-table-name <route-table-name>", $("the name of the Route Table that needs to be applied to the subnet")).option("-s, --subscription <id>", $("the subscription id")).execute(function __33(vnetName, subnetName, routeTableName, options, _) { var networkManagementClient, routeTable; var __frame = { name: "__33", line: 540 }; return __func(_, this, arguments, __33, 4, __frame, function __$__33() {







      return cli.interaction.promptIfNotGiven($("Virtual network name: "), vnetName, __cb(_, __frame, 1, 33, function ___(__0, __1) { vnetName = __1;
        return cli.interaction.promptIfNotGiven($("Subnet name: "), subnetName, __cb(_, __frame, 2, 35, function ___(__0, __2) { subnetName = __2;
          return cli.interaction.promptIfNotGiven($("Route Table name: "), routeTableName, __cb(_, __frame, 3, 39, function ___(__0, __3) { routeTableName = __3;

            networkManagementClient = createNetworkManagementClient(options);
            routeTable = new RouteTable(cli, networkManagementClient);
            return routeTable.addRouteTableToSubnet(vnetName, subnetName, routeTableName, options, __cb(_, __frame, 7, 17, function __$__33() { _(); }, true)); }, true)); }, true)); }, true)); }); });


  subnetRouteTable.command("delete [vnet-name] [subnet-name] [route-table-name]").usage("[options] <vnet-name> <subnet-name> <route-table-name>").description($("Remove Route Table from a subnet")).option("-t, --vnet-name <vnet-name>", $("the name of the virtual network")).option("-n, --subnet-name <subnet-name>", $("the name of the subnet")).option("-r, --route-table-name <route-table-name>", $("the name of the Route Table that needs to be applied to the subnet")).option("-q, --quiet", $("quiet mode, do not ask for delete confirmation")).option("-s, --subscription <id>", $("the subscription id")).execute(function __34(vnetName, subnetName, routeTableName, options, _) { var networkManagementClient, routeTable; var __frame = { name: "__34", line: 558 }; return __func(_, this, arguments, __34, 4, __frame, function __$__34() {








      return cli.interaction.promptIfNotGiven($("Virtual network name: "), vnetName, __cb(_, __frame, 1, 33, function ___(__0, __1) { vnetName = __1;
        return cli.interaction.promptIfNotGiven($("Subnet name: "), subnetName, __cb(_, __frame, 2, 35, function ___(__0, __2) { subnetName = __2;
          return cli.interaction.promptIfNotGiven($("Route Table name: "), routeTableName, __cb(_, __frame, 3, 39, function ___(__0, __3) { routeTableName = __3;

            networkManagementClient = createNetworkManagementClient(options);
            routeTable = new RouteTable(cli, networkManagementClient);
            return routeTable.deleteRouteTableFromSubnet(vnetName, subnetName, routeTableName, options, __cb(_, __frame, 7, 17, function __$__34() { _(); }, true)); }, true)); }, true)); }, true)); }); });


  subnetRouteTable.command("show [vnet-name] [subnet-name]").usage("[options] <vnet-name> <subnet-name>").description($("Get Route Table for a subnet")).option("-t, --vnet-name <vnet-name>", $("the name of the virtual network")).option("-n, --subnet-name <subnet-name>", $("the name of the subnet")).option("-d, --detailed", util.format($(("get full details of the Route Table, without this flag only" + "\n     Route Table name will be shown")))).option("-s, --subscription <id>", $("the subscription id")).execute(function __35(vnetName, subnetName, routeTableName, options, _) { var networkManagementClient, routeTable; var __frame = { name: "__35", line: 576 }; return __func(_, this, arguments, __35, 4, __frame, function __$__35() {








      return cli.interaction.promptIfNotGiven($("Virtual network name: "), vnetName, __cb(_, __frame, 1, 33, function ___(__0, __1) { vnetName = __1;
        return cli.interaction.promptIfNotGiven($("Subnet name: "), subnetName, __cb(_, __frame, 2, 35, function ___(__0, __2) { subnetName = __2;

          networkManagementClient = createNetworkManagementClient(options);
          routeTable = new RouteTable(cli, networkManagementClient);
          return routeTable.showRouteTableForSubnet(vnetName, subnetName, options, __cb(_, __frame, 6, 17, function __$__35() { _(); }, true)); }, true)); }, true)); }); });


  var localNetwork = network.category("local-network").description($("Commands to manage local network"));


  localNetwork.command("create [name] [address-prefixes]").description($("Create a local network")).usage("[options] <name> <address-prefixes>").option("-n, --name <name>", $("the name of the local network")).option("-a, --address-prefixes <address-prefixes>", $("the comma separated list of address prefixes")).option("-w, --vpn-gateway-address <vpn-gateway-address>", $("the  VPN Gateway address")).option("-s, --subscription <subscription>", $("the subscription identifier")).execute(function __36(name, addressPrefixes, options, _) { var networkManagementClient, localNetwork; var __frame = { name: "__36", line: 595 }; return __func(_, this, arguments, __36, 3, __frame, function __$__36() {







      return cli.interaction.promptIfNotGiven($("Local network name: "), name, __cb(_, __frame, 1, 29, function ___(__0, __1) { name = __1;
        return cli.interaction.promptIfNotGiven($("Address prefixes: "), addressPrefixes, __cb(_, __frame, 2, 40, function ___(__0, __2) { addressPrefixes = __2;

          networkManagementClient = createNetworkManagementClient(options);
          localNetwork = new LocalNetwork(cli, networkManagementClient);
          return localNetwork.create(name, addressPrefixes, options, __cb(_, __frame, 6, 19, function __$__36() { _(); }, true)); }, true)); }, true)); }); });


  localNetwork.command("set [name]").description($("Set a local network")).usage("[options] <name>").option("-n, --name <name>", $("the name of the local network")).option("-a, --address-prefixes <address-prefixes>", $("the comma separated list of address prefixes")).option("-w, --vpn-gateway-address <vpn-gateway-address>", $("the  VPN Gateway address")).option("-s, --subscription <subscription>", $("the subscription identifier")).execute(function __37(name, options, _) { var networkManagementClient, localNetwork; var __frame = { name: "__37", line: 611 }; return __func(_, this, arguments, __37, 2, __frame, function __$__37() {







      return cli.interaction.promptIfNotGiven($("Local network name: "), name, __cb(_, __frame, 1, 29, function ___(__0, __1) { name = __1;

        networkManagementClient = createNetworkManagementClient(options);
        localNetwork = new LocalNetwork(cli, networkManagementClient);
        return localNetwork.set(name, options, __cb(_, __frame, 5, 19, function __$__37() { _(); }, true)); }, true)); }); });


  localNetwork.command("list").usage("[options]").description($("Get all local networks")).option("-s, --subscription <id>", $("the subscription id")).execute(function __38(options, _) { var networkManagementClient, localNetwork; var __frame = { name: "__38", line: 623 }; return __func(_, this, arguments, __38, 1, __frame, function __$__38() {




      networkManagementClient = createNetworkManagementClient(options);
      localNetwork = new LocalNetwork(cli, networkManagementClient);
      return localNetwork.list(options, __cb(_, __frame, 3, 19, function __$__38() { _(); }, true)); }); });


  localNetwork.command("show [name]").usage("[options]").description($("Get a local network")).option("-n, --name <name>", $("the name of the local network")).option("-s, --subscription <id>", $("the subscription id")).execute(function __39(name, options, _) { var networkManagementClient, localNetwork; var __frame = { name: "__39", line: 634 }; return __func(_, this, arguments, __39, 2, __frame, function __$__39() {





      return cli.interaction.promptIfNotGiven($("Local network name: "), name, __cb(_, __frame, 1, 29, function ___(__0, __1) { name = __1;

        networkManagementClient = createNetworkManagementClient(options);
        localNetwork = new LocalNetwork(cli, networkManagementClient);
        return localNetwork.show(name, options, __cb(_, __frame, 5, 19, function __$__39() { _(); }, true)); }, true)); }); });


  localNetwork.command("delete [name]").usage("[options] <name>").description($("Delete a local network")).option("-n, --name <name>", $("the name of the local network")).option("-q, --quiet", $("quiet mode, do not ask for delete confirmation")).option("-s, --subscription <id>", $("the subscription id")).execute(function __40(name, options, _) { var networkManagementClient, localNetwork; var __frame = { name: "__40", line: 648 }; return __func(_, this, arguments, __40, 2, __frame, function __$__40() {






      return cli.interaction.promptIfNotGiven($("Local network name: "), name, __cb(_, __frame, 1, 29, function ___(__0, __1) { name = __1;

        networkManagementClient = createNetworkManagementClient(options);
        localNetwork = new LocalNetwork(cli, networkManagementClient);
        return localNetwork.delete(name, options, __cb(_, __frame, 5, 19, function __$__40() { _(); }, true)); }, true)); }); });


  var vpnGateway = network.category("vpn-gateway").description($("Commands to manage VPN Gateways"));


  vpnGateway.command("create [vnet-name]").description($("Create a virtual network gateway")).usage("[options] <vnet-name>").option("-n, --vnet-name <vnet-name>", $("the name of the virtual network")).option("-t, --type <type>", util.format($((("the gateway type, valid values are:" + "\n       [%s],") + "\n       default is StaticRouting")), constants.vpnGateway.type)).option("-k, --sku <sku>", util.format($((("the gateway SKU, valid values are:" + "\n       [%s],") + "\n       default is Default")), constants.vpnGateway.sku)).option("-s, --subscription <subscription>", $("the subscription identifier")).execute(function __41(vnetName, options, _) { var networkManagementClient, vpnGateway; var __frame = { name: "__41", line: 670 }; return __func(_, this, arguments, __41, 2, __frame, function __$__41() {











      return cli.interaction.promptIfNotGiven($("Virtual network name: "), vnetName, __cb(_, __frame, 1, 33, function ___(__0, __1) { vnetName = __1;

        networkManagementClient = createNetworkManagementClient(options);
        vpnGateway = new VpnGateway(cli, networkManagementClient);
        return vpnGateway.create(vnetName, options, __cb(_, __frame, 5, 17, function __$__41() { _(); }, true)); }, true)); }); });


  vpnGateway.command("show [vnet-name]").description($("Get a virtual network gateway")).usage("[options] <vnet-name>").option("-n, --vnet-name <vnet-name>", $("the name of the virtual network")).option("-s, --subscription <subscription>", $("the subscription identifier")).execute(function __42(vnetName, options, _) { var networkManagementClient, vpnGateway; var __frame = { name: "__42", line: 683 }; return __func(_, this, arguments, __42, 2, __frame, function __$__42() {





      return cli.interaction.promptIfNotGiven($("Virtual network name: "), vnetName, __cb(_, __frame, 1, 33, function ___(__0, __1) { vnetName = __1;

        networkManagementClient = createNetworkManagementClient(options);
        vpnGateway = new VpnGateway(cli, networkManagementClient);
        return vpnGateway.show(vnetName, options, __cb(_, __frame, 5, 17, function __$__42() { _(); }, true)); }, true)); }); });


  vpnGateway.command("delete [vnet-name]").description($("Delete a virtual network gateway")).usage("[options] <vnet-name>").option("-n, --vnet-name <vnet-name>", $("the name of the virtual network")).option("-q, --quiet", $("quiet mode, do not ask for delete confirmation")).option("-s, --subscription <subscription>", $("the subscription identifier")).execute(function __43(vnetName, options, _) { var networkManagementClient, vpnGateway; var __frame = { name: "__43", line: 697 }; return __func(_, this, arguments, __43, 2, __frame, function __$__43() {






      return cli.interaction.promptIfNotGiven($("Virtual network name: "), vnetName, __cb(_, __frame, 1, 33, function ___(__0, __1) { vnetName = __1;

        networkManagementClient = createNetworkManagementClient(options);
        vpnGateway = new VpnGateway(cli, networkManagementClient);
        return vpnGateway.delete(vnetName, options, __cb(_, __frame, 5, 17, function __$__43() { _(); }, true)); }, true)); }); });


  vpnGateway.command("resize [vnet-name] [sku]").description($("Resize a virtual network gateway")).usage("[options] <vnet-name> <sku>").option("-n, --vnet-name <vnet-name>", $("the name of the virtual network")).option("-k, --sku <sku>", $(("the SKU that the existing gateway will be resized to," + "\n       valid values are [Default or HighPerformance]"))).option("-s, --subscription <subscription>", $("the subscription identifier")).execute(function __44(vnetName, sku, options, _) { var networkManagementClient, vpnGateway; var __frame = { name: "__44", line: 712 }; return __func(_, this, arguments, __44, 3, __frame, function __$__44() {







      return cli.interaction.promptIfNotGiven($("Virtual network name: "), vnetName, __cb(_, __frame, 1, 33, function ___(__0, __1) { vnetName = __1;
        return cli.interaction.promptIfNotGiven($("SKU: "), sku, __cb(_, __frame, 2, 28, function ___(__0, __2) { sku = __2;

          networkManagementClient = createNetworkManagementClient(options);
          vpnGateway = new VpnGateway(cli, networkManagementClient);
          return vpnGateway.resize(vnetName, sku, options, __cb(_, __frame, 6, 17, function __$__44() { _(); }, true)); }, true)); }, true)); }); });


  vpnGateway.command("reset [vnet-name]").description($("Reset a virtual network gateway")).usage("[options] <vnet-name>").option("-n, --vnet-name <vnet-name>", $("the name of the virtual network")).option("-s, --subscription <subscription>", $("the subscription identifier")).execute(function __45(vnetName, options, _) { var networkManagementClient, vpnGateway; var __frame = { name: "__45", line: 726 }; return __func(_, this, arguments, __45, 2, __frame, function __$__45() {





      return cli.interaction.promptIfNotGiven($("Virtual network name: "), vnetName, __cb(_, __frame, 1, 33, function ___(__0, __1) { vnetName = __1;

        networkManagementClient = createNetworkManagementClient(options);
        vpnGateway = new VpnGateway(cli, networkManagementClient);
        return vpnGateway.reset(vnetName, options, __cb(_, __frame, 5, 17, function __$__45() { _(); }, true)); }, true)); }); });


  var vpnDefaultSite = vpnGateway.category("default-site").description($("Commands to manage VPN Gateway default site"));


  vpnDefaultSite.command("set [vnet-name] [site-name]").description($("Set local network default site for a virtual network gateway")).usage("[options] <vnet-name> <site-name>").option("-n, --vnet-name <vnet-name>", $("the name of the virtual network")).option("-k, --site-name <site-name>", $("the local network default site for this virtual network gateway")).option("-s, --subscription <subscription>", $("the subscription identifier")).execute(function __46(vnetName, siteName, options, _) { var networkManagementClient, vpnGateway; var __frame = { name: "__46", line: 743 }; return __func(_, this, arguments, __46, 3, __frame, function __$__46() {






      return cli.interaction.promptIfNotGiven($("Virtual network name: "), vnetName, __cb(_, __frame, 1, 33, function ___(__0, __1) { vnetName = __1;
        return cli.interaction.promptIfNotGiven($("Site name: "), siteName, __cb(_, __frame, 2, 33, function ___(__0, __2) { siteName = __2;

          networkManagementClient = createNetworkManagementClient(options);
          vpnGateway = new VpnGateway(cli, networkManagementClient);
          return vpnGateway.setDefaultSite(vnetName, siteName, options, __cb(_, __frame, 6, 17, function __$__46() { _(); }, true)); }, true)); }, true)); }); });


  vpnDefaultSite.command("remove [vnet-name]").description($("Remove local network default site configured in a virtual network gateway")).usage("[options] <vnet-name>").option("-n, --vnet-name <vnet-name>", $("the name of the virtual network")).option("-s, --subscription <subscription>", $("the subscription identifier")).execute(function __47(vnetName, options, _) { var networkManagementClient, vpnGateway; var __frame = { name: "__47", line: 757 }; return __func(_, this, arguments, __47, 2, __frame, function __$__47() {





      return cli.interaction.promptIfNotGiven($("Virtual network name: "), vnetName, __cb(_, __frame, 1, 33, function ___(__0, __1) { vnetName = __1;

        networkManagementClient = createNetworkManagementClient(options);
        vpnGateway = new VpnGateway(cli, networkManagementClient);
        return vpnGateway.removeDefaultSite(vnetName, options, __cb(_, __frame, 5, 17, function __$__47() { _(); }, true)); }, true)); }); });


  var vpnSharedKey = vpnGateway.category("shared-key").description($("Commands to manage VPN Gateway shared key"));


  vpnSharedKey.command("set [vnet-name] [key-value]").usage("[options] <vnet-name> <key-value>").description($("Set shared key used by virtual network gateway to connect to local network site")).option("-n, --vnet-name <vnet-name>", $("the name of the virtual network")).option("-t, --site-name <site-name>", $("the name of the local network site, if not specified then default local network site will be used.")).option("-k, --key-value <key-value>", $("the shared key value")).option("-s, --subscription <id>", $("the subscription id")).execute(function __48(vnetName, keyValue, options, _) { var networkManagementClient, vpnGateway; var __frame = { name: "__48", line: 775 }; return __func(_, this, arguments, __48, 3, __frame, function __$__48() {







      return cli.interaction.promptIfNotGiven($("Virtual network name: "), vnetName, __cb(_, __frame, 1, 33, function ___(__0, __1) { vnetName = __1;
        return cli.interaction.promptIfNotGiven($("Shared key value: "), keyValue, __cb(_, __frame, 2, 33, function ___(__0, __2) { keyValue = __2;

          networkManagementClient = createNetworkManagementClient(options);
          vpnGateway = new VpnGateway(cli, networkManagementClient);
          return vpnGateway.setSharedKey(vnetName, keyValue, options, __cb(_, __frame, 6, 17, function __$__48() { _(); }, true)); }, true)); }, true)); }); });


  vpnSharedKey.command("reset [vnet-name] [key-length]").usage("[options] <vnet-name> <key-length>").description($("Reset shared key used by virtual network gateway to connect to local network site")).option("-n, --vnet-name <vnet-name>", $("the name of the virtual network")).option("-t, --site-name <site-name>", $("the name of the local network site, if not specified then default local network site will be used.")).option("-l, --key-length <key-length>", $("the number of characters in the shared key, the key length must be between 1 and 128 characters.")).option("-s, --subscription <id>", $("the subscription id")).execute(function __49(vnetName, keyLength, options, _) { var networkManagementClient, vpnGateway; var __frame = { name: "__49", line: 791 }; return __func(_, this, arguments, __49, 3, __frame, function __$__49() {







      return cli.interaction.promptIfNotGiven($("Virtual network name: "), vnetName, __cb(_, __frame, 1, 33, function ___(__0, __1) { vnetName = __1;
        return cli.interaction.promptIfNotGiven($("Key length: "), keyLength, __cb(_, __frame, 2, 34, function ___(__0, __2) { keyLength = __2;

          networkManagementClient = createNetworkManagementClient(options);
          vpnGateway = new VpnGateway(cli, networkManagementClient);
          return vpnGateway.resetSharedKey(vnetName, keyLength, options, __cb(_, __frame, 6, 17, function __$__49() { _(); }, true)); }, true)); }, true)); }); });


  var vpnConnection = vpnGateway.category("connection").description($("Commands to manage VPN Gateway connection"));


  vpnConnection.command("list [vnet-name]").description($("Get all local network connections that can be accessed through a virtual network gateway")).usage("[options] <vnet-name>").option("-n, --vnet-name <vnet-name>", $("the name of the virtual network")).option("-s, --subscription <subscription>", $("the subscription identifier")).execute(function __50(vnetName, options, _) { var networkManagementClient, vpnGateway; var __frame = { name: "__50", line: 808 }; return __func(_, this, arguments, __50, 2, __frame, function __$__50() {





      return cli.interaction.promptIfNotGiven($("Virtual network name: "), vnetName, __cb(_, __frame, 1, 33, function ___(__0, __1) { vnetName = __1;

        networkManagementClient = createNetworkManagementClient(options);
        vpnGateway = new VpnGateway(cli, networkManagementClient);
        return vpnGateway.listConnections(vnetName, options, __cb(_, __frame, 5, 17, function __$__50() { _(); }, true)); }, true)); }); });


  var vpnDevice = vpnGateway.category("device").description($("Commands to manage VPN Gateway device"));


  vpnDevice.command("list").usage("[options]").description($("Get all supported `on premise network devices` that can connect to the gateway")).option("-s, --subscription <id>", $("the subscription id")).execute(function __51(options, _) { var networkManagementClient, vpnGateway; var __frame = { name: "__51", line: 823 }; return __func(_, this, arguments, __51, 1, __frame, function __$__51() {




      networkManagementClient = createNetworkManagementClient(options);
      vpnGateway = new VpnGateway(cli, networkManagementClient);
      return vpnGateway.listDevices(options, __cb(_, __frame, 3, 17, function __$__51() { _(); }, true)); }); });


  vpnDevice.command("get-script [vnet-name]").usage("[options] <vnet-name>").description($("Get script to configure local VPN device to connect to the virtual network gateway")).option("-n, --vnet-name <vnet-name>", $("the name of the virtual network")).option("-o, --vendor <vendor>", $("the vendor of the VPN device")).option("-p, --platform <platform>", $("the platform of the VPN device")).option("-f, --os-family <os-family>", $("the OS family of the VPN device")).option("-s, --subscription <id>", $("the subscription id")).execute(function __52(vnetName, options, _) { var networkManagementClient, vpnGateway; var __frame = { name: "__52", line: 837 }; return __func(_, this, arguments, __52, 2, __frame, function __$__52() {








      return cli.interaction.promptIfNotGiven($("Virtual network name: "), vnetName, __cb(_, __frame, 1, 33, function ___(__0, __1) { vnetName = __1;
        return cli.interaction.promptIfNotGiven($("Vendor: "), options.vendor, __cb(_, __frame, 2, 39, function ___(__0, __2) { options.vendor = __2;
          return cli.interaction.promptIfNotGiven($("Platform: "), options.platform, __cb(_, __frame, 3, 41, function ___(__0, __3) { options.platform = __3;
            return cli.interaction.promptIfNotGiven($("OS family: "), options.osFamily, __cb(_, __frame, 4, 42, function ___(__0, __4) { options.osFaimily = __4;

              networkManagementClient = createNetworkManagementClient(options);
              vpnGateway = new VpnGateway(cli, networkManagementClient);
              return vpnGateway.getDeviceScript(vnetName, options, __cb(_, __frame, 8, 17, function __$__52() { _(); }, true)); }, true)); }, true)); }, true)); }, true)); }); });


  var vpnDiagnostics = vpnGateway.category("diagnostics").description($("Commands to manage VPN Gateway diagnostics session"));


  vpnDiagnostics.command("start [vnet-name]").usage("[options] <vnet-name>").description($("Start a new diagnostics session in a virtual network gateway")).option("-n, --vnet-name <vnet-name>", $("the name of the virtual network")).option("-d, --duration <duration>", $("duration in seconds to perform the diagnostics capture, possible values are between 1 and 300")).option("-a, --storage-account-name <storage-account-name>", $("the name of the storage account where the captured diagnostics data is to be stored.")).option("-k, --storage-account-key <storage-account-key>", $("the key of the storage account that is specified through --storage-account-name parameter")).option("-c, --container-name <container-name>", $("the name of the container in the storage account where the captured diagnostics data is stored, default is gatewaypublicdiagnostics")).option("-s, --subscription <id>", $("the subscription id")).execute(function __53(vnetName, options, _) { var networkManagementClient, vpnGateway; var __frame = { name: "__53", line: 860 }; return __func(_, this, arguments, __53, 2, __frame, function __$__53() {









      return cli.interaction.promptIfNotGiven($("Virtual network name: "), vnetName, __cb(_, __frame, 1, 33, function ___(__0, __1) { vnetName = __1;
        return cli.interaction.promptIfNotGiven($("Capture duration in seconds: "), options.duration, __cb(_, __frame, 2, 41, function ___(__0, __2) { options.duration = __2;
          return cli.interaction.promptIfNotGiven($("Storage account name: "), options.storageAccountName, __cb(_, __frame, 3, 51, function ___(__0, __3) { options.storageAccountName = __3;
            return cli.interaction.promptIfNotGiven($("Storage account key: "), options.storageAccountKey, __cb(_, __frame, 4, 50, function ___(__0, __4) { options.storageAccountKey = __4;
              return cli.interaction.promptIfNotGiven($("Storage container name: "), options.containerName, __cb(_, __frame, 5, 46, function ___(__0, __5) { options.containerName = __5;

                networkManagementClient = createNetworkManagementClient(options);
                vpnGateway = new VpnGateway(cli, networkManagementClient);
                return vpnGateway.startDiagnosticsSession(vnetName, options, __cb(_, __frame, 9, 17, function __$__53() { _(); }, true)); }, true)); }, true)); }, true)); }, true)); }, true)); }); });


  vpnDiagnostics.command("stop [vnet-name]").usage("[options] <vnet-name>").description($("Stop current diagnostics session in a virtual network gateway")).option("-n, --vnet-name <vnet-name>", $("the name of the virtual network")).option("-s, --subscription <id>", $("the subscription id")).execute(function __54(vnetName, options, _) { var networkManagementClient, vpnGateway; var __frame = { name: "__54", line: 877 }; return __func(_, this, arguments, __54, 2, __frame, function __$__54() {





      return cli.interaction.promptIfNotGiven($("Virtual network name: "), vnetName, __cb(_, __frame, 1, 33, function ___(__0, __1) { vnetName = __1;

        networkManagementClient = createNetworkManagementClient(options);
        vpnGateway = new VpnGateway(cli, networkManagementClient);
        return vpnGateway.stopDiagnosticsSession(vnetName, options, __cb(_, __frame, 5, 17, function __$__54() { _(); }, true)); }, true)); }); });


  vpnDiagnostics.command("get [vnet-name]").usage("[options] <vnet-name>").description($("Get current diagnostics session in a virtual network gateway")).option("-n, --vnet-name <vnet-name>", $("the name of the virtual network")).option("-s, --subscription <id>", $("the subscription id")).execute(function __55(vnetName, options, _) { var networkManagementClient, vpnGateway; var __frame = { name: "__55", line: 890 }; return __func(_, this, arguments, __55, 2, __frame, function __$__55() {





      return cli.interaction.promptIfNotGiven($("Virtual network name: "), vnetName, __cb(_, __frame, 1, 33, function ___(__0, __1) { vnetName = __1;

        networkManagementClient = createNetworkManagementClient(options);
        vpnGateway = new VpnGateway(cli, networkManagementClient);
        return vpnGateway.getDiagnosticsSession(vnetName, options, __cb(_, __frame, 5, 17, function __$__55() { _(); }, true)); }, true)); }); });


  var routeTable = network.category("route-table").description($("Commands to manage Route Table"));


  routeTable.command("create [name] [location]").description($("Create a Route Table")).usage("[options] <name> <location>").option("-n, --name <name>", $("the name of the Route Table")).option("-l, --location <location>", $("the location, this must be same as the location of the virtual network containing the subnet(s) on which this Route Table needs to be applied")).option("-b, --label <label>", $("the label for the Route Table")).option("-s, --subscription <subscription>", $("the subscription identifier")).execute(function __56(name, location, options, _) { var networkManagementClient, routeTable; var __frame = { name: "__56", line: 908 }; return __func(_, this, arguments, __56, 3, __frame, function __$__56() {







      return cli.interaction.promptIfNotGiven($("Route Table name: "), name, __cb(_, __frame, 1, 29, function ___(__0, __1) { name = __1;
        return cli.interaction.promptIfNotGiven($("Location: "), location, __cb(_, __frame, 2, 33, function ___(__0, __2) { location = __2;

          networkManagementClient = createNetworkManagementClient(options);
          routeTable = new RouteTable(cli, networkManagementClient);
          return routeTable.create(name, location, options, __cb(_, __frame, 6, 17, function __$__56() { _(); }, true)); }, true)); }, true)); }); });


  routeTable.command("show [name]").description($("Get a Route Table")).usage("[options] <name>").option("-n, --name <name>", $("the name of the Route Table")).option("-s, --subscription <subscription>", $("the subscription identifier")).execute(function __57(name, options, _) { var networkManagementClient, routeTable; var __frame = { name: "__57", line: 922 }; return __func(_, this, arguments, __57, 2, __frame, function __$__57() {





      return cli.interaction.promptIfNotGiven($("Route Table name: "), name, __cb(_, __frame, 1, 29, function ___(__0, __1) { name = __1;

        networkManagementClient = createNetworkManagementClient(options);
        routeTable = new RouteTable(cli, networkManagementClient);
        return routeTable.show(name, options, __cb(_, __frame, 5, 17, function __$__57() { _(); }, true)); }, true)); }); });


  routeTable.command("list").description($("Get all Route Tables")).usage("[options]").option("-s, --subscription <subscription>", $("the subscription identifier")).execute(function __58(options, _) { var networkManagementClient, routeTable; var __frame = { name: "__58", line: 934 }; return __func(_, this, arguments, __58, 1, __frame, function __$__58() {




      networkManagementClient = createNetworkManagementClient(options);
      routeTable = new RouteTable(cli, networkManagementClient);
      return routeTable.list(options, __cb(_, __frame, 3, 17, function __$__58() { _(); }, true)); }); });


  routeTable.command("delete [name]").description($("Delete a Route Table")).usage("[options] <name>").option("-n, --name <name>", $("the name of the Route Table")).option("-q, --quiet", $("quiet mode, do not ask for delete confirmation")).option("-s, --subscription <subscription>", $("the subscription identifier")).execute(function __59(name, options, _) { var networkManagementClient, routeTable; var __frame = { name: "__59", line: 946 }; return __func(_, this, arguments, __59, 2, __frame, function __$__59() {






      return cli.interaction.promptIfNotGiven($("Route Table name: "), name, __cb(_, __frame, 1, 29, function ___(__0, __1) { name = __1;

        networkManagementClient = createNetworkManagementClient(options);
        routeTable = new RouteTable(cli, networkManagementClient);
        return routeTable.delete(name, options, __cb(_, __frame, 5, 17, function __$__59() { _(); }, true)); }, true)); }); });


  var route = routeTable.category("route").description($("Commands to manage Route Table routes"));


  route.command("set [route-table-name] [name] [address-prefix] [next-hop-type]").description($("Set route in a Route Table")).usage("[options] <route-table-name> <name> <address-prefix> <next-hop-type>").option("-r, --route-table-name <route-table-name>", $("the name of the Route Table")).option("-n, --name <name>", $("the name of the route")).option("-a, --address-prefix <address-prefix>", $("the route address prefix e.g. 0.0.0.0/0")).option("-t, --next-hop-type <next-hop-type>", util.format($(("the route next hop type, valid values are:" + "\n       [%s]")), constants.route.nextHopType)).option("-p, --next-hop-ip-address <next-hop-ip-address>", $(("the route next hop ip addresses, this parameter is valid" + "\n       only for next hop type VirtualAppliance"))).option("-s, --subscription <subscription>", $("the subscription identifier")).execute(function __60(routeTableName, name, addressPrefix, nextHopType, options, _) { var networkManagementClient, routeTable; var __frame = { name: "__60", line: 968 }; return __func(_, this, arguments, __60, 5, __frame, function __$__60() {











      return cli.interaction.promptIfNotGiven($("Route Table name: "), routeTableName, __cb(_, __frame, 1, 39, function ___(__0, __1) { routeTableName = __1;
        return cli.interaction.promptIfNotGiven($("Route name: "), name, __cb(_, __frame, 2, 29, function ___(__0, __2) { name = __2;
          return cli.interaction.promptIfNotGiven($("Address prefix: "), addressPrefix, __cb(_, __frame, 3, 38, function ___(__0, __3) { addressPrefix = __3;
            return cli.interaction.promptIfNotGiven($("Next hop type: "), nextHopType, __cb(_, __frame, 4, 36, function ___(__0, __4) { nextHopType = __4;

              networkManagementClient = createNetworkManagementClient(options);
              routeTable = new RouteTable(cli, networkManagementClient);
              return routeTable.setRoute(routeTableName, name, addressPrefix, nextHopType, options, __cb(_, __frame, 8, 17, function __$__60() { _(); }, true)); }, true)); }, true)); }, true)); }, true)); }); });


  route.command("delete [route-table-name] [name]").description($("Delete route from a Route Table")).usage("[options] <route-table-name> <name>").option("-r, --route-table-name <route-table-name>", $("the name of the Route Table")).option("-n, --name <name>", $("the name of the route")).option("-q, --quiet", $("quiet mode, do not ask for delete confirmation")).option("-s, --subscription <subscription>", $("the subscription identifier")).execute(function __61(routeTableName, name, options, _) { var networkManagementClient, routeTable; var __frame = { name: "__61", line: 986 }; return __func(_, this, arguments, __61, 3, __frame, function __$__61() {







      return cli.interaction.promptIfNotGiven($("Route Table name: "), routeTableName, __cb(_, __frame, 1, 39, function ___(__0, __1) { routeTableName = __1;
        return cli.interaction.promptIfNotGiven($("Route name: "), name, __cb(_, __frame, 2, 29, function ___(__0, __2) { name = __2;

          networkManagementClient = createNetworkManagementClient(options);
          routeTable = new RouteTable(cli, networkManagementClient);
          return routeTable.deleteRoute(routeTableName, name, options, __cb(_, __frame, 6, 17, function __$__61() { _(); }, true)); }, true)); }, true)); }); });


  var appGateway = network.category("application-gateway").description("Commands to manage Application Gateway");


  appGateway.command("create [name] [vnet-name] [subnet-name]").description($("Create an Application Gateway")).usage("[options] <name> <vnet-name> <subnet-name>").option("-n, --name <name>", $("the name of the Application Gateway")).option("-e, --vnet-name <vnet-name>", $("the name of the virtual network Application Gateway should be deployed in")).option("-t, --subnet-name <subnet-name>", $("the name of subnet which exists in same vnet")).option("-c, --instance-count <instance-count>", $("the number of instances")).option("-z, --gateway-size <gateway-size>", util.format($("size of the Application Gateway, valid values are [%s]"), constants.appGateway.sizes)).option("-d, --description <description>", $("the description for the Application Gateway")).option("-s, --subscription <subscription>", $("the subscription identifier")).execute(function __62(name, vnetName, subnetName, options, _) { var networkManagementClient, appGateway; var __frame = { name: "__62", line: 1008 }; return __func(_, this, arguments, __62, 4, __frame, function __$__62() {










      return cli.interaction.promptIfNotGiven($("Application Gateway name: "), name, __cb(_, __frame, 1, 29, function ___(__0, __1) { name = __1;
        return cli.interaction.promptIfNotGiven($("Virtual network name: "), vnetName, __cb(_, __frame, 2, 41, function ___(__0, __2) { options.vnetName = __2;
          return cli.interaction.promptIfNotGiven($("Subnet name: "), subnetName, __cb(_, __frame, 3, 43, function ___(__0, __3) { options.subnetName = __3;

            networkManagementClient = createNetworkManagementClient(options);
            appGateway = new AppGateway(cli, networkManagementClient);
            return appGateway.create(name, options, __cb(_, __frame, 7, 17, function __$__62() { _(); }, true)); }, true)); }, true)); }, true)); }); });


  appGateway.command("set [name]").description($("Set an Application Gateway")).usage("[options] <name>").option("-n, --name <name>", $("the name of the Application Gateway")).option("-e, --vnet-name <vnet-name>", $("the name of the virtual network Application Gateway should be deployed in")).option("-t, --subnet-name <subnet-name>", $("the name of subnet which exists in same vnet")).option("-c, --instance-count <instance-count>", $("the number of instances")).option("-z, --gateway-size <gateway-size>", util.format($("size of the Application Gateway, valid values are [%s]"), constants.appGateway.sizes)).option("-d, --description <description>", $("the description for the Application Gateway")).option("-s, --subscription <subscription>", $("the subscription identifier")).execute(function __63(name, options, _) { var networkManagementClient, appGateway; var __frame = { name: "__63", line: 1028 }; return __func(_, this, arguments, __63, 2, __frame, function __$__63() {










      return cli.interaction.promptIfNotGiven($("Application Gateway name: "), name, __cb(_, __frame, 1, 29, function ___(__0, __1) { name = __1;

        networkManagementClient = createNetworkManagementClient(options);
        appGateway = new AppGateway(cli, networkManagementClient);
        return appGateway.set(name, options, __cb(_, __frame, 5, 17, function __$__63() { _(); }, true)); }, true)); }); });


  appGateway.command("list").description($("Get all Application Gateways")).usage("[options]").option("-s, --subscription <subscription>", $("the subscription identifier")).execute(function __64(options, _) { var networkManagementClient, appGateway; var __frame = { name: "__64", line: 1040 }; return __func(_, this, arguments, __64, 1, __frame, function __$__64() {




      networkManagementClient = createNetworkManagementClient(options);
      appGateway = new AppGateway(cli, networkManagementClient);
      return appGateway.list(options, __cb(_, __frame, 3, 17, function __$__64() { _(); }, true)); }); });


  appGateway.command("show [name]").description($("Get an Application Gateway")).usage("[options] <name>").option("-n, --name <name>", $("the name of the Application Gateway")).option("-s, --subscription <subscription>", $("the subscription identifier")).execute(function __65(name, options, _) { var networkManagementClient, appGateway; var __frame = { name: "__65", line: 1051 }; return __func(_, this, arguments, __65, 2, __frame, function __$__65() {





      return cli.interaction.promptIfNotGiven($("Application Gateway name: "), name, __cb(_, __frame, 1, 29, function ___(__0, __1) { name = __1;

        networkManagementClient = createNetworkManagementClient(options);
        appGateway = new AppGateway(cli, networkManagementClient);
        return appGateway.show(name, options, __cb(_, __frame, 5, 17, function __$__65() { _(); }, true)); }, true)); }); });


  appGateway.command("delete [name]").description($("Delete an Application Gateway")).usage("[options] <name>").option("-n, --name <name>", $("the name of the Application Gateway")).option("-q, --quiet", $("quiet mode, do not ask for delete confirmation")).option("-s, --subscription <subscription>", $("the subscription identifier")).execute(function __66(name, options, _) { var networkManagementClient, appGateway; var __frame = { name: "__66", line: 1065 }; return __func(_, this, arguments, __66, 2, __frame, function __$__66() {






      return cli.interaction.promptIfNotGiven($("Application Gateway name: "), name, __cb(_, __frame, 1, 29, function ___(__0, __1) { name = __1;

        networkManagementClient = createNetworkManagementClient(options);
        appGateway = new AppGateway(cli, networkManagementClient);
        return appGateway.delete(name, options, __cb(_, __frame, 5, 17, function __$__66() { _(); }, true)); }, true)); }); });


  appGateway.command("start [name]").description($("Start an Application Gateway")).usage("[options] <name>").option("-n, --name <name>", $("the name of the Application Gateway")).option("-s, --subscription <subscription>", $("the subscription identifier")).execute(function __67(name, options, _) { var networkManagementClient, appGateway; var __frame = { name: "__67", line: 1078 }; return __func(_, this, arguments, __67, 2, __frame, function __$__67() {





      return cli.interaction.promptIfNotGiven($("Application Gateway name: "), name, __cb(_, __frame, 1, 29, function ___(__0, __1) { name = __1;

        networkManagementClient = createNetworkManagementClient(options);
        appGateway = new AppGateway(cli, networkManagementClient);
        return appGateway.start(name, options, __cb(_, __frame, 5, 17, function __$__67() { _(); }, true)); }, true)); }); });


  appGateway.command("stop [name]").description($("Stop an Application Gateway")).usage("[options] <name>").option("-n, --name <name>", $("the name of the Application Gateway")).option("-s, --subscription <subscription>", $("the subscription identifier")).execute(function __68(name, options, _) { var networkManagementClient, appGateway; var __frame = { name: "__68", line: 1091 }; return __func(_, this, arguments, __68, 2, __frame, function __$__68() {





      return cli.interaction.promptIfNotGiven($("Application Gateway name: "), name, __cb(_, __frame, 1, 29, function ___(__0, __1) { name = __1;

        networkManagementClient = createNetworkManagementClient(options);
        appGateway = new AppGateway(cli, networkManagementClient);
        return appGateway.stop(name, options, __cb(_, __frame, 5, 17, function __$__68() { _(); }, true)); }, true)); }); });


  var appGatewayConfig = appGateway.category("config").description("Commands to manage Application Gateway configuration");


  appGatewayConfig.command("show [name]").description($("Get an Application Gateway configuration")).usage("[options] <name>").option("-n, --name <name>", $("the name of the Application Gateway")).option("-s, --subscription <subscription>", $("the subscription identifier")).execute(function __69(name, options, _) { var networkManagementClient, appGateway; var __frame = { name: "__69", line: 1107 }; return __func(_, this, arguments, __69, 2, __frame, function __$__69() {





      return cli.interaction.promptIfNotGiven($("Application Gateway name: "), name, __cb(_, __frame, 1, 29, function ___(__0, __1) { name = __1;

        networkManagementClient = createNetworkManagementClient(options);
        appGateway = new AppGateway(cli, networkManagementClient);
        return appGateway.showConfig(name, options, __cb(_, __frame, 5, 17, function __$__69() { _(); }, true)); }, true)); }); });


  appGatewayConfig.command("export [name] [export-to-file]").description($("Export Application Gateway configuration to a file")).usage("[options] <name> <file-path>").option("-n, --name <name>", $("the name of the Application Gateway")).option("-t, --export-to-file <export-to-file>", $("the path to the file where configuration needs to be exported")).option("-s, --subscription <subscription>", $("the subscription identifier")).execute(function __70(name, exportToFile, options, _) { var networkManagementClient, appGateway; var __frame = { name: "__70", line: 1121 }; return __func(_, this, arguments, __70, 3, __frame, function __$__70() {






      return cli.interaction.promptIfNotGiven($("Application Gateway name: "), name, __cb(_, __frame, 1, 29, function ___(__0, __1) { name = __1;
        return cli.interaction.promptIfNotGiven($("File path: "), exportToFile, __cb(_, __frame, 2, 37, function ___(__0, __2) { exportToFile = __2;

          networkManagementClient = createNetworkManagementClient(options);
          appGateway = new AppGateway(cli, networkManagementClient);
          return appGateway.exportConfig(name, exportToFile, options, __cb(_, __frame, 6, 17, function __$__70() { _(); }, true)); }, true)); }, true)); }); });


  appGatewayConfig.command("import [name] [import-from-file]").description($("Import Application Gateway configuration from a file")).usage("[options] <name> <import-from-file>").option("-n, --name <name>", $("the name of the Application Gateway")).option("-t, --import-from-file <import-from-file>", $("the path to the configuration file")).option("-s, --subscription <subscription>", $("the subscription identifier")).execute(function __71(name, importFromFile, options, _) { var networkManagementClient, appGateway; var __frame = { name: "__71", line: 1136 }; return __func(_, this, arguments, __71, 3, __frame, function __$__71() {






      return cli.interaction.promptIfNotGiven($("Application Gateway name: "), name, __cb(_, __frame, 1, 29, function ___(__0, __1) { name = __1;
        return cli.interaction.promptIfNotGiven($("Import from file: "), importFromFile, __cb(_, __frame, 2, 39, function ___(__0, __2) { importFromFile = __2;

          networkManagementClient = createNetworkManagementClient(options);
          appGateway = new AppGateway(cli, networkManagementClient);
          return appGateway.importConfig(name, importFromFile, options, __cb(_, __frame, 6, 17, function __$__71() { _(); }, true)); }, true)); }, true)); }); });


  var appGatewayAddressPool = appGateway.category("address-pool").description($("Commands to manage Application Gateway backend address pool"));


  appGatewayAddressPool.command("add [gateway-name] [name]").description($("Add a backend address pool to an Application Gateway")).usage("[options] <gateway-name> <name>").option("-w, --gateway-name <gateway-name>", $("the name of the Application Gateway")).option("-n, --name <name>", $("the name of the backend address pool")).option("-r, --servers <servers>", $(("comma separated list of IP addresses or DNS names" + "\n     corresponding to backend servers"))).option("-s, --subscription <subscription>", $("the subscription identifier")).execute(function __72(gatewayName, name, options, _) { var networkManagementClient, appGateway; var __frame = { name: "__72", line: 1156 }; return __func(_, this, arguments, __72, 3, __frame, function __$__72() {








      return cli.interaction.promptIfNotGiven($("Application Gateway name: "), gatewayName, __cb(_, __frame, 1, 36, function ___(__0, __1) { gatewayName = __1;
        return cli.interaction.promptIfNotGiven($("Backend address pool name: "), name, __cb(_, __frame, 2, 29, function ___(__0, __2) { name = __2;
          return cli.interaction.promptIfNotGiven($("List of IP addresses or DNS names: "), options.servers, __cb(_, __frame, 3, 40, function ___(__0, __3) { options.servers = __3;

            networkManagementClient = createNetworkManagementClient(options);
            appGateway = new AppGateway(cli, networkManagementClient);
            return appGateway.addBackendAddressPool(gatewayName, name, options, __cb(_, __frame, 7, 17, function __$__72() { _(); }, true)); }, true)); }, true)); }, true)); }); });


  appGatewayAddressPool.command("remove [gateway-name] [name]").description($("Remove a backend address pool from an Application Gateway")).usage("[options] <gateway-name> <name>").option("-w, --gateway-name <gateway-name>", $("the name of the Application Gateway")).option("-n, --name <name>", $("the name of the backend address pool")).option("-q, --quiet", $("quiet mode, do not ask for unregister confirmation")).option("-s, --subscription <subscription>", $("the subscription identifier")).execute(function __73(gatewayName, name, options, _) { var networkManagementClient, appGateway; var __frame = { name: "__73", line: 1173 }; return __func(_, this, arguments, __73, 3, __frame, function __$__73() {







      return cli.interaction.promptIfNotGiven($("Application Gateway name: "), gatewayName, __cb(_, __frame, 1, 36, function ___(__0, __1) { gatewayName = __1;
        return cli.interaction.promptIfNotGiven($("Backend address pool name: "), name, __cb(_, __frame, 2, 29, function ___(__0, __2) { name = __2;

          networkManagementClient = createNetworkManagementClient(options);
          appGateway = new AppGateway(cli, networkManagementClient);
          return appGateway.removeBackendAddressPool(gatewayName, name, options, __cb(_, __frame, 6, 17, function __$__73() { _(); }, true)); }, true)); }, true)); }); });


  var appGatewayHttpSettings = appGateway.category("http-settings").description($("Commands to manage Application Gateway http settings"));


  appGatewayHttpSettings.command("add [gateway-name] [name]").description($("Add a backend address pool to an Application Gateway")).usage("[options] <gateway-name> <name>").option("-w, --gateway-name <gateway-name>", $("the name of the Application Gateway")).option("-n, --name <name>", $("the name of the HTTP settings")).option("-p, --protocol <protocol>", util.format($("the protocol, valid value is [%s]"), constants.appGateway.settings.protocol)).option("-o, --port <port>", util.format($("the port, valid range is"), utils.toRange(constants.appGateway.settings.port))).option("-c, --cookie-based-affinity <cookie-based-affinity>", util.format($((("Enable or disable cookie based affinity, valid values are" + "\n     [%s],") + "\n     default value is Disabled")), constants.appGateway.settings.affinity)).option("-s, --subscription <subscription>", $("the subscription identifier")).execute(function __74(gatewayName, name, options, _) { var networkManagementClient, appGateway; var __frame = { name: "__74", line: 1198 }; return __func(_, this, arguments, __74, 3, __frame, function __$__74() {













      return cli.interaction.promptIfNotGiven($("Application Gateway name: "), gatewayName, __cb(_, __frame, 1, 36, function ___(__0, __1) { gatewayName = __1;
        return cli.interaction.promptIfNotGiven($("Http settings name: "), name, __cb(_, __frame, 2, 29, function ___(__0, __2) { name = __2;
          return cli.interaction.promptIfNotGiven($("Port: "), options.port, __cb(_, __frame, 3, 37, function ___(__0, __3) { options.port = __3;

            networkManagementClient = createNetworkManagementClient(options);
            appGateway = new AppGateway(cli, networkManagementClient);
            return appGateway.addHttpSettings(gatewayName, name, options, __cb(_, __frame, 7, 17, function __$__74() { _(); }, true)); }, true)); }, true)); }, true)); }); });


  appGatewayHttpSettings.command("remove [gateway-name] [name]").description($("Remove a backend address pool to an Application Gateway")).usage("[options] <gateway-name> <name>").option("-w, --gateway-name <gateway-name>", $("the name of the Application Gateway")).option("-n, --name <name>", $("the name of the HTTP settings")).option("-q, --quiet", $("quiet mode, do not ask for unregister confirmation")).option("-s, --subscription <subscription>", $("the subscription identifier")).execute(function __75(gatewayName, name, options, _) { var networkManagementClient, appGateway; var __frame = { name: "__75", line: 1215 }; return __func(_, this, arguments, __75, 3, __frame, function __$__75() {







      return cli.interaction.promptIfNotGiven($("Application Gateway name: "), gatewayName, __cb(_, __frame, 1, 36, function ___(__0, __1) { gatewayName = __1;
        return cli.interaction.promptIfNotGiven($("Http settings name: "), name, __cb(_, __frame, 2, 29, function ___(__0, __2) { name = __2;

          networkManagementClient = createNetworkManagementClient(options);
          appGateway = new AppGateway(cli, networkManagementClient);
          return appGateway.removeHttpSettings(gatewayName, name, options, __cb(_, __frame, 6, 17, function __$__75() { _(); }, true)); }, true)); }, true)); }); });


  var appGatewayFrontendIp = appGateway.category("frontend-ip").description($("Commands to manage Application Gateway frontend ip"));


  appGatewayFrontendIp.command("add [gateway-name] [name]").description($("Add a frontend ip configuration to an Application Gateway")).usage("[options] <gateway-name> <name>").option("-w, --gateway-name <gateway-name>", $("the name of the Application Gateway")).option("-n, --name <name>", $("the name of the frontend IP configuration")).option("-t, --type <type>", util.format($("the type, supported values are [%s], default value is Private"), constants.appGateway.ip.type)).option("-i, --static-ip-address <static-ip-address>", $("the static IP address")).option("-s, --subscription <subscription>", $("the subscription identifier")).execute(function __76(gatewayName, name, options, _) { var networkManagementClient, appGateway; var __frame = { name: "__76", line: 1236 }; return __func(_, this, arguments, __76, 3, __frame, function __$__76() {









      return cli.interaction.promptIfNotGiven($("Application Gateway name: "), gatewayName, __cb(_, __frame, 1, 36, function ___(__0, __1) { gatewayName = __1;
        return cli.interaction.promptIfNotGiven($("Frontend IP name: "), name, __cb(_, __frame, 2, 29, function ___(__0, __2) { name = __2;
          return cli.interaction.promptIfNotGiven($("Static IP address: "), options.staticIpAddress, __cb(_, __frame, 3, 48, function ___(__0, __3) { options.staticIpAddress = __3;

            networkManagementClient = createNetworkManagementClient(options);
            appGateway = new AppGateway(cli, networkManagementClient);
            return appGateway.addFrontendIp(gatewayName, name, options, __cb(_, __frame, 7, 17, function __$__76() { _(); }, true)); }, true)); }, true)); }, true)); }); });


  appGatewayFrontendIp.command("remove [gateway-name] [name]").description($("Remove a frontend ip configuration from an Application Gateway")).usage("[options] <gateway-name> <name>").option("-w, --gateway-name <gateway-name>", $("the name of the Application Gateway")).option("-n, --name <name>", $("the name of the frontend IP configuration")).option("-q, --quiet", $("quiet mode, do not ask for delete confirmation")).option("-s, --subscription <subscription>", $("the subscription identifier")).execute(function __77(gatewayName, name, options, _) { var networkManagementClient, appGateway; var __frame = { name: "__77", line: 1253 }; return __func(_, this, arguments, __77, 3, __frame, function __$__77() {







      return cli.interaction.promptIfNotGiven($("Application Gateway name: "), gatewayName, __cb(_, __frame, 1, 36, function ___(__0, __1) { gatewayName = __1;
        return cli.interaction.promptIfNotGiven($("Frontend IP name: "), name, __cb(_, __frame, 2, 29, function ___(__0, __2) { name = __2;

          networkManagementClient = createNetworkManagementClient(options);
          appGateway = new AppGateway(cli, networkManagementClient);
          return appGateway.removeFrontendIp(gatewayName, name, options, __cb(_, __frame, 6, 17, function __$__77() { _(); }, true)); }, true)); }, true)); }); });


  var appGatewayFrontendPort = appGateway.category("frontend-port").description("Commands to manage Application Gateway frontend port");


  appGatewayFrontendPort.command("add [gateway-name] [name] [port]").description($("Add a frontend port to an Application Gateway")).usage("[options] <gateway-name> <name> <port>").option("-w, --gateway-name <gateway-name>", $("the name of the Application Gateway")).option("-n, --name <name>", $("the name of the frontend port")).option("-o, --port <port>", $("the port")).option("-s, --subscription <subscription>", $("the subscription identifier")).execute(function __78(gatewayName, name, port, options, _) { var networkManagementClient, appGateway; var __frame = { name: "__78", line: 1272 }; return __func(_, this, arguments, __78, 4, __frame, function __$__78() {







      return cli.interaction.promptIfNotGiven($("Application Gateway name: "), gatewayName, __cb(_, __frame, 1, 36, function ___(__0, __1) { gatewayName = __1;
        return cli.interaction.promptIfNotGiven($("Frontend port name: "), name, __cb(_, __frame, 2, 29, function ___(__0, __2) { name = __2;
          return cli.interaction.promptIfNotGiven($("Frontend port: "), port, __cb(_, __frame, 3, 29, function ___(__0, __3) { port = __3;

            networkManagementClient = createNetworkManagementClient(options);
            appGateway = new AppGateway(cli, networkManagementClient);
            return appGateway.addFrontendPort(gatewayName, name, port, options, __cb(_, __frame, 7, 17, function __$__78() { _(); }, true)); }, true)); }, true)); }, true)); }); });


  appGatewayFrontendPort.command("remove [gateway-name] [name]").description($("Remove a frontend port from an Application Gateway")).usage("[options] <gateway-name> <name>").option("-w, --gateway-name <gateway-name>", $("the name of the Application Gateway")).option("-n, --name <name>", $("the name of the frontend port")).option("-q, --quiet", $("quiet mode, do not ask for delete confirmation")).option("-s, --subscription <subscription>", $("the subscription identifier")).execute(function __79(gatewayName, name, options, _) { var networkManagementClient, appGateway; var __frame = { name: "__79", line: 1289 }; return __func(_, this, arguments, __79, 3, __frame, function __$__79() {







      return cli.interaction.promptIfNotGiven($("Application Gateway name: "), gatewayName, __cb(_, __frame, 1, 36, function ___(__0, __1) { gatewayName = __1;
        return cli.interaction.promptIfNotGiven($("Frontend port name: "), name, __cb(_, __frame, 2, 29, function ___(__0, __2) { name = __2;

          networkManagementClient = createNetworkManagementClient(options);
          appGateway = new AppGateway(cli, networkManagementClient);
          return appGateway.removeFrontendPort(gatewayName, name, options, __cb(_, __frame, 6, 17, function __$__79() { _(); }, true)); }, true)); }, true)); }); });


  var appGatewayHttpListener = appGateway.category("http-listener").description("Commands to manage Application Gateway http listener");


  appGatewayHttpListener.command("add [gateway-name] [name] [frontend-port-name]").description($("Add a http listener to an Application Gateway")).usage("[options] <gateway-name> <name> <frontend-port-name>").option("-w, --gateway-name <gateway-name>", $("the name of the Application Gateway")).option("-n, --name <name>", $("the name of the HTTP listener")).option("-i, --frontend-ip-name <frontend-ip-name>", $("the name of an existing frontend ip configuration")).option("-p, --frontend-port-name <frontend-port-name>", $("the name of an existing frontend port")).option("-t, --protocol <protocol>", $("the protocol, supported values are [Http, Https], default is Http")).option("-c, --ssl-cert <ssl-cert>", $("the name of an existing SSL certificate, this parameter is required when --protocol is Https")).option("-s, --subscription <subscription>", $("the subscription identifier")).execute(function __80(gatewayName, name, frontendPortName, options, _) { var networkManagementClient, appGateway; var __frame = { name: "__80", line: 1311 }; return __func(_, this, arguments, __80, 4, __frame, function __$__80() {










      return cli.interaction.promptIfNotGiven($("Application Gateway name: "), gatewayName, __cb(_, __frame, 1, 36, function ___(__0, __1) { gatewayName = __1;
        return cli.interaction.promptIfNotGiven($("The HTTP listener name: "), name, __cb(_, __frame, 2, 29, function ___(__0, __2) { name = __2;
          return cli.interaction.promptIfNotGiven($("Frontend port name: "), frontendPortName, __cb(_, __frame, 3, 41, function ___(__0, __3) { frontendPortName = __3;

            networkManagementClient = createNetworkManagementClient(options);
            appGateway = new AppGateway(cli, networkManagementClient);
            return appGateway.addHttpListener(gatewayName, name, frontendPortName, options, __cb(_, __frame, 7, 17, function __$__80() { _(); }, true)); }, true)); }, true)); }, true)); }); });


  appGatewayHttpListener.command("remove [gateway-name] [name]").description($("Remove a http listener from an Application Gateway")).usage("[options] <gateway-name> <name>").option("-w, --gateway-name <gateway-name>", $("the name of the Application Gateway")).option("-n, --name <name>", $("the name of the HTTP listener")).option("-q, --quiet", $("quiet mode, do not ask for delete confirmation")).option("-s, --subscription <subscription>", $("the subscription identifier")).execute(function __81(gatewayName, name, options, _) { var networkManagementClient, appGateway; var __frame = { name: "__81", line: 1328 }; return __func(_, this, arguments, __81, 3, __frame, function __$__81() {







      return cli.interaction.promptIfNotGiven($("Application Gateway name: "), gatewayName, __cb(_, __frame, 1, 36, function ___(__0, __1) { gatewayName = __1;
        return cli.interaction.promptIfNotGiven($("Frontend port name: "), name, __cb(_, __frame, 2, 29, function ___(__0, __2) { name = __2;

          networkManagementClient = createNetworkManagementClient(options);
          appGateway = new AppGateway(cli, networkManagementClient);
          return appGateway.removeHttpListener(gatewayName, name, options, __cb(_, __frame, 6, 17, function __$__81() { _(); }, true)); }, true)); }, true)); }); });


  var appGatewayBalancingRule = appGateway.category("lb-rule").description("Commands to manage Application Gateway load balancing rule");


  appGatewayBalancingRule.command("add [gateway-name] [name] [http-settings] [http-listener] [address-pool]").description($("Add a load balancing rule to an Application Gateway")).usage("[options] <gateway-name> <name> <http-settings> <http-listener> <address-pool>").option("-w, --gateway-name <gateway-name>", $("the name of the Application Gateway")).option("-n, --name <name>", $("the name of the load balancing rule")).option("-i, --http-settings <http-settings>", $("the name of an existing backend HTTP settings")).option("-l, --http-listener <http-listener>", $("the name of an existing HTTP listener")).option("-p, --address-pool <address-pool>", $("the name of an existing backend address pool")).option("-t, --type <type>", $("the type, default is \"Basic\"")).option("-s, --subscription <subscription>", $("the subscription identifier")).execute(function __82(gatewayName, name, httpSettings, httpListener, addressPool, options, _) { var networkManagementClient, appGateway; var __frame = { name: "__82", line: 1350 }; return __func(_, this, arguments, __82, 6, __frame, function __$__82() {










      return cli.interaction.promptIfNotGiven($("Application Gateway name: "), gatewayName, __cb(_, __frame, 1, 36, function ___(__0, __1) { gatewayName = __1;
        return cli.interaction.promptIfNotGiven($("Frontend port name: "), name, __cb(_, __frame, 2, 29, function ___(__0, __2) { name = __2;
          return cli.interaction.promptIfNotGiven($("HTTP settings name: "), httpSettings, __cb(_, __frame, 3, 37, function ___(__0, __3) { httpSettings = __3;
            return cli.interaction.promptIfNotGiven($("HTTP listener name: "), httpListener, __cb(_, __frame, 4, 37, function ___(__0, __4) { httpListener = __4;
              return cli.interaction.promptIfNotGiven($("The address pool name: "), addressPool, __cb(_, __frame, 5, 36, function ___(__0, __5) { addressPool = __5;

                networkManagementClient = createNetworkManagementClient(options);
                appGateway = new AppGateway(cli, networkManagementClient);
                return appGateway.addLoadBalancingRule(gatewayName, name, httpSettings, httpListener, addressPool, options, __cb(_, __frame, 9, 17, function __$__82() { _(); }, true)); }, true)); }, true)); }, true)); }, true)); }, true)); }); });


  appGatewayBalancingRule.command("remove [gateway-name] [name]").description($("Remove a load balancing rule from an Application Gateway")).usage("[options] <gateway-name> <name>").option("-w, --gateway-name <gateway-name>", $("the name of the Application Gateway")).option("-n, --name <name>", $("the name of the load balancing rule")).option("-q, --quiet", $("quiet mode, do not ask for delete confirmation")).option("-s, --subscription <subscription>", $("the subscription identifier")).execute(function __83(gatewayName, name, options, _) { var networkManagementClient, appGateway; var __frame = { name: "__83", line: 1369 }; return __func(_, this, arguments, __83, 3, __frame, function __$__83() {







      return cli.interaction.promptIfNotGiven($("Application Gateway name: "), gatewayName, __cb(_, __frame, 1, 36, function ___(__0, __1) { gatewayName = __1;
        return cli.interaction.promptIfNotGiven($("Frontend port name: "), name, __cb(_, __frame, 2, 29, function ___(__0, __2) { name = __2;

          networkManagementClient = createNetworkManagementClient(options);
          appGateway = new AppGateway(cli, networkManagementClient);
          return appGateway.removeLoadBalancingRule(gatewayName, name, options, __cb(_, __frame, 6, 17, function __$__83() { _(); }, true)); }, true)); }, true)); }); });


  var appGatewaySslCert = appGateway.category("ssl-cert").description($("Commands to manage Application Gateway SSL certificates"));


  appGatewaySslCert.command("add [name] [cert-name]").description($("Add Application Gateway SSL certificate")).usage("[options] <name> <cert-name>").option("-n, --name <name>", $("the name of the Application Gateway")).option("-c, --cert-name <cert-name>", $("the name of the certificate")).option("-t, --cert-file <cert-file>", $("the path to the certificate")).option("-p, --password <password>", $("the certificate password")).option("-s, --subscription <subscription>", $("the subscription identifier")).execute(function __84(name, certName, options, _) { var networkManagementClient, appGateway; var __frame = { name: "__84", line: 1389 }; return __func(_, this, arguments, __84, 3, __frame, function __$__84() {








      return cli.interaction.promptIfNotGiven($("Application Gateway name: "), name, __cb(_, __frame, 1, 29, function ___(__0, __1) { name = __1;
        return cli.interaction.promptIfNotGiven($("Certificate name: "), certName, __cb(_, __frame, 2, 33, function ___(__0, __2) { certName = __2;
          return cli.interaction.promptIfNotGiven($("Certificate file path: "), options.certFile, __cb(_, __frame, 3, 41, function ___(__0, __3) { options.certFile = __3;
            return cli.interaction.promptIfNotGiven($("Certificate password: "), options.password, __cb(_, __frame, 4, 41, function ___(__0, __4) { options.password = __4;

              networkManagementClient = createNetworkManagementClient(options);
              appGateway = new AppGateway(cli, networkManagementClient);
              return appGateway.addSsl(name, certName, options, __cb(_, __frame, 8, 17, function __$__84() { _(); }, true)); }, true)); }, true)); }, true)); }, true)); }); });


  appGatewaySslCert.command("remove [name] [cert-name]").description($("Remove Application Gateway SSL certificate")).usage("[options] <name> <cert-name>").option("-n, --name <name>", $("the name of the Application Gateway")).option("-c, --cert-name <cert-name>", $("the name of the certificate")).option("-q, --quiet", $("quiet mode, do not ask for delete confirmation")).option("-s, --subscription <subscription>", $("the subscription identifier")).execute(function __85(name, certName, options, _) { var networkManagementClient, appGateway; var __frame = { name: "__85", line: 1407 }; return __func(_, this, arguments, __85, 3, __frame, function __$__85() {







      return cli.interaction.promptIfNotGiven($("Application Gateway name: "), name, __cb(_, __frame, 1, 29, function ___(__0, __1) { name = __1;
        return cli.interaction.promptIfNotGiven($("Certificate name: "), certName, __cb(_, __frame, 2, 33, function ___(__0, __2) { certName = __2;

          networkManagementClient = createNetworkManagementClient(options);
          appGateway = new AppGateway(cli, networkManagementClient);
          return appGateway.removeSsl(name, certName, options, __cb(_, __frame, 6, 17, function __$__85() { _(); }, true)); }, true)); }, true)); }); });


  var trafficManager = network.category("traffic-manager").description($("Commands to manage Traffic Manager"));


  var trafficManagerProfile = trafficManager.category("profile").description($("Commands to manage Traffic Manager profile"));


  trafficManagerProfile.command("create [name]").description($("Create a Traffic Manager profile")).usage("[options] <name>").option("-n, --name <name>", $("the name of the Traffic Manager profile")).option("-d, --domain-name <domain-name>", $(("the profile DNS name" + "\n   Example: foobar.trafficmanager.net"))).option("-m, --load-balancing-method <load-balancing-method>", util.format($(("the load balancing method to use to distribute connection." + "\n   Valid values are [%s]")), constants.trafficManager.loadBalancingMethods)).option("-o, --monitor-port <monitor-port>", util.format($(("the port used to monitor endpoint health." + "\n   Valid range is %s inclusive")), utils.toRange(constants.trafficManager.ports))).option("-p, --monitor-protocol <monitor-protocol>", util.format($(("the protocol to use to monitor endpoint health." + "\n   Valid values are [%s]")), constants.trafficManager.protocols)).option("-r, --monitor-relative-path <monitor-relative-path>", $("the path relative to the endpoint domain name to probe for health state. Must start with a forward slash \"/\".")).option("-t, --ttl <ttl>", $("the DNS Time-to-Live (TTL) that informs the Local DNS resolvers how long to cache DNS entries")).option("-s, --subscription <subscription>", $("the subscription identifier")).execute(function __86(name, options, _) { var trafficManagerManagementClient, trafficManager; var __frame = { name: "__86", line: 1436 }; return __func(_, this, arguments, __86, 2, __frame, function __$__86() {














      return cli.interaction.promptIfNotGiven($("Profile name: "), name, __cb(_, __frame, 1, 29, function ___(__0, __1) { name = __1;
        return cli.interaction.promptIfNotGiven($("Profile domain name: "), options.domainName, __cb(_, __frame, 2, 43, function ___(__0, __2) { options.domainName = __2;
          return cli.interaction.promptIfNotGiven($("Path relative to the endpoint domain name to probe for health state: "), options.monitorRelativePath, __cb(_, __frame, 3, 52, function ___(__0, __3) { options.monitorRelativePath = __3;

            trafficManagerManagementClient = createTrafficManagerManagementClient(options);
            trafficManager = new TrafficManager(cli, trafficManagerManagementClient);
            return trafficManager.createProfile(name, options, __cb(_, __frame, 7, 21, function __$__86() { _(); }, true)); }, true)); }, true)); }, true)); }); });


  trafficManagerProfile.command("set [name]").description($("Set a Traffic Manager profile")).usage("[options] <name>").option("-n, --name <name>", $("the name of the Traffic Manager profile")).option("-m, --load-balancing-method <load-balancing-method>", util.format($(("the load balancing method to use to distribute connection." + "\n   Valid values are [%s]")), constants.trafficManager.loadBalancingMethods)).option("-o, --monitor-port <monitor-port>", util.format($(("the port used to monitor endpoint health." + "\n   Valid range is %s inclusive")), utils.toRange(constants.trafficManager.ports))).option("-p, --monitor-protocol <monitor-protocol>", util.format($(("the protocol to use to monitor endpoint health." + "\n   Valid values are [%s]")), constants.trafficManager.protocols)).option("-r, --monitor-relative-path <monitor-relative-path>", $("the path relative to the endpoint domain name to probe for health state. Must start with a forward slash \"/\".")).option("-t, --ttl <ttl>", $("the DNS Time-to-Live (TTL) that informs the Local DNS resolvers how long to cache DNS entries")).option("-s, --subscription <subscription>", $("the subscription identifier")).execute(function __87(name, options, _) { var trafficManagerManagementClient, trafficManager; var __frame = { name: "__87", line: 1459 }; return __func(_, this, arguments, __87, 2, __frame, function __$__87() {













      return cli.interaction.promptIfNotGiven($("Traffic Manager name: "), name, __cb(_, __frame, 1, 29, function ___(__0, __1) { name = __1;

        trafficManagerManagementClient = createTrafficManagerManagementClient(options);
        trafficManager = new TrafficManager(cli, trafficManagerManagementClient);
        return trafficManager.setProfile(name, options, __cb(_, __frame, 5, 21, function __$__87() { _(); }, true)); }, true)); }); });


  trafficManagerProfile.command("show [name]").description($("Get a Traffic Manager profile")).usage("[options] <name>").option("-n, --name <name>", $("the name of the Traffic Manager profile")).option("-s, --subscription <subscription>", $("the subscription identifier")).execute(function __88(name, options, _) { var trafficManagerManagementClient, trafficManager; var __frame = { name: "__88", line: 1472 }; return __func(_, this, arguments, __88, 2, __frame, function __$__88() {





      return cli.interaction.promptIfNotGiven($("Traffic Manager name: "), name, __cb(_, __frame, 1, 29, function ___(__0, __1) { name = __1;

        trafficManagerManagementClient = createTrafficManagerManagementClient(options);
        trafficManager = new TrafficManager(cli, trafficManagerManagementClient);
        return trafficManager.showProfile(name, options, __cb(_, __frame, 5, 21, function __$__88() { _(); }, true)); }, true)); }); });


  trafficManagerProfile.command("list").description($("Get all Traffic Manager profiles")).usage("[options]").option("-s, --subscription <subscription>", $("the subscription identifier")).execute(function __89(options, _) { var trafficManagerManagementClient, trafficManager; var __frame = { name: "__89", line: 1484 }; return __func(_, this, arguments, __89, 1, __frame, function __$__89() {




      trafficManagerManagementClient = createTrafficManagerManagementClient(options);
      trafficManager = new TrafficManager(cli, trafficManagerManagementClient);
      return trafficManager.listProfiles(options, __cb(_, __frame, 3, 21, function __$__89() { _(); }, true)); }); });


  trafficManagerProfile.command("delete [name]").usage("[options] <name>").description($("Delete a Traffic Manager profile")).option("-n, --name <name>", $("the name of the Traffic Manager")).option("-q, --quiet", $("quiet mode, do not ask for delete confirmation")).option("-s, --subscription <subscription>", $("the subscription identifier")).execute(function __90(name, options, _) { var trafficManagerManagementClient, trafficManager; var __frame = { name: "__90", line: 1496 }; return __func(_, this, arguments, __90, 2, __frame, function __$__90() {






      return cli.interaction.promptIfNotGiven($("Traffic Manager profile name: "), name, __cb(_, __frame, 1, 29, function ___(__0, __1) { name = __1;

        trafficManagerManagementClient = createTrafficManagerManagementClient(options);
        trafficManager = new TrafficManager(cli, trafficManagerManagementClient);
        return trafficManager.deleteProfile(name, options, __cb(_, __frame, 5, 21, function __$__90() { _(); }, true)); }, true)); }); });


  trafficManagerProfile.command("enable [name]").description($("Enable a Traffic Manager profile")).usage("[options] <name>").option("-n, --name <name>", $("the name of the Traffic Manager")).option("-s, --subscription <subscription>", $("the subscription identifier")).execute(function __91(name, options, _) { var trafficManagerManagementClient, trafficManager; var __frame = { name: "__91", line: 1509 }; return __func(_, this, arguments, __91, 2, __frame, function __$__91() {





      return cli.interaction.promptIfNotGiven($("Traffic Manager profile name: "), name, __cb(_, __frame, 1, 29, function ___(__0, __1) { name = __1;

        trafficManagerManagementClient = createTrafficManagerManagementClient(options);
        trafficManager = new TrafficManager(cli, trafficManagerManagementClient);
        return trafficManager.enableProfile(name, options, __cb(_, __frame, 5, 21, function __$__91() { _(); }, true)); }, true)); }); });


  trafficManagerProfile.command("disable [name]").description($("Disable a Traffic Manager profile")).usage("[options] <name>").option("-n, --name <name>", $("the name of the Traffic Manager")).option("-s, --subscription <subscription>", $("the subscription identifier")).execute(function __92(name, options, _) { var trafficManagerManagementClient, trafficManager; var __frame = { name: "__92", line: 1522 }; return __func(_, this, arguments, __92, 2, __frame, function __$__92() {





      return cli.interaction.promptIfNotGiven($("Traffic Manager profile name: "), name, __cb(_, __frame, 1, 29, function ___(__0, __1) { name = __1;

        trafficManagerManagementClient = createTrafficManagerManagementClient(options);
        trafficManager = new TrafficManager(cli, trafficManagerManagementClient);
        return trafficManager.disableProfile(name, options, __cb(_, __frame, 5, 21, function __$__92() { _(); }, true)); }, true)); }); });


  var trafficManagerEndpoint = trafficManagerProfile.category("endpoint").description($("Commands to manage Traffic Manager profile endpoint"));


  trafficManagerEndpoint.command("create [profile-name] [name] [type]").description($("Create an endpoint in a Traffic Manager profile")).usage("[options] <profile-name> <name> <type>").option("-p, --profile-name <profile-name>", $("the name of the profile")).option("-n, --name <name>", $("the endpoint domain name")).option("-y, --type <type>", util.format($("the endpoint type, valid values are: %s"), constants.trafficManager.endpoints.types)).option("-l, --endpoint-location <endpoint-location>", $((("the location of the endpoint. Required when profile load-balancing" + "\n     method is set to Performance and endpoint type is set to ") + "\n     Any or TrafficManager. Specifies the name of the Azure region"))).option("-u, --endpoint-status <endpoint-status>", util.format($("the endpoint status, valid values are: %s Default is Enabled"), constants.trafficManager.endpoints.statuses)).option("-w, --weight <weight>", $("the endpoint weight used in the load balancing algorithm")).option("-e, --min-child-endpoint <min-child-endpoint>", $("the minimum number of child endpoints, can be specified when Type is set to TrafficManager")).option("-s, --subscription <subscription>", $("the subscription identifier")).execute(function __93(profileName, name, type, options, _) { var trafficManagerManagementClient, trafficManager; var __frame = { name: "__93", line: 1548 }; return __func(_, this, arguments, __93, 4, __frame, function __$__93() {















      return cli.interaction.promptIfNotGiven($("Traffic Manager profile name: "), profileName, __cb(_, __frame, 1, 36, function ___(__0, __1) { profileName = __1;
        return cli.interaction.promptIfNotGiven($("The endpoint domain name: "), name, __cb(_, __frame, 2, 29, function ___(__0, __2) { name = __2;
          return cli.interaction.promptIfNotGiven($("The endpoint type: "), type, __cb(_, __frame, 3, 29, function ___(__0, __3) { type = __3;

            trafficManagerManagementClient = createTrafficManagerManagementClient(options);
            trafficManager = new TrafficManager(cli, trafficManagerManagementClient);
            return trafficManager.createEndpoint(profileName, name, type, options, __cb(_, __frame, 7, 21, function __$__93() { _(); }, true)); }, true)); }, true)); }, true)); }); });


  trafficManagerEndpoint.command("set [profile-name] [name]").description($("Set an endpoint in a Traffic Manager profile")).usage("[options] <profile-name> <name>").option("-p, --profile-name <profile-name>", $("the name of the profile")).option("-n, --name <name>", $("the endpoint domain name")).option("-y, --type <type>", util.format($("the endpoint type, valid values are: %s"), constants.trafficManager.endpoints.types)).option("-l, --endpoint-location <endpoint-location>", $((("the location of the endpoint. Required when profile load-balancing" + "\n     method is set to Performance and endpoint type is set to ") + "\n     Any or TrafficManager. Specifies the name of the Azure region"))).option("-u, --endpoint-status <endpoint-status>", util.format($("the endpoint status, valid values are: %s Default is Enabled"), constants.trafficManager.endpoints.statuses)).option("-w, --weight <weight>", $("the endpoint weight used in the load balancing algorithm")).option("-e, --min-child-endpoint <min-child-endpoint>", $("the minimum number of child endpoints, can be specified when Type is set to TrafficManager")).option("-s, --subscription <subscription>", $("the subscription identifier")).execute(function __94(profileName, name, options, _) { var trafficManagerManagementClient, trafficManager; var __frame = { name: "__94", line: 1573 }; return __func(_, this, arguments, __94, 3, __frame, function __$__94() {















      return cli.interaction.promptIfNotGiven($("Traffic Manager profile name: "), profileName, __cb(_, __frame, 1, 36, function ___(__0, __1) { profileName = __1;
        return cli.interaction.promptIfNotGiven($("The endpoint domain name: "), name, __cb(_, __frame, 2, 29, function ___(__0, __2) { name = __2;

          trafficManagerManagementClient = createTrafficManagerManagementClient(options);
          trafficManager = new TrafficManager(cli, trafficManagerManagementClient);
          return trafficManager.setEndpoint(profileName, name, options, __cb(_, __frame, 6, 21, function __$__94() { _(); }, true)); }, true)); }, true)); }); });


  trafficManagerEndpoint.command("delete [profile-name] [name]").description($("Delete an endpoint from a Traffic Manager profile")).usage("[options] <profile-name> <name>").option("-p, --profile-name <profile-name>", $("the name of the profile")).option("-n, --name <name>", $("the endpoint domain name")).option("-q, --quiet", $("quiet mode, do not ask for delete confirmation")).option("-s, --subscription <subscription>", $("the subscription identifier")).execute(function __95(profileName, name, options, _) { var trafficManagerManagementClient, trafficManager; var __frame = { name: "__95", line: 1589 }; return __func(_, this, arguments, __95, 3, __frame, function __$__95() {







      return cli.interaction.promptIfNotGiven($("Traffic Manager profile name: "), profileName, __cb(_, __frame, 1, 36, function ___(__0, __1) { profileName = __1;
        return cli.interaction.promptIfNotGiven($("The endpoint domain name: "), name, __cb(_, __frame, 2, 29, function ___(__0, __2) { name = __2;

          trafficManagerManagementClient = createTrafficManagerManagementClient(options);
          trafficManager = new TrafficManager(cli, trafficManagerManagementClient);
          return trafficManager.deleteEndpoint(profileName, name, options, __cb(_, __frame, 6, 21, function __$__95() { _(); }, true)); }, true)); }, true)); }); });


  function createNetworkManagementClient(options) {
    var subscription = profile.current.getSubscription(options.subscription);
    return utils.createNetworkClient(subscription); };


  function createTrafficManagerManagementClient(options) {
    var subscription = profile.current.getSubscription(options.subscription);
    return utils.createTrafficManagerClient(subscription); };


  function createManagementClient(options) {
    var subscription = profile.current.getSubscription(options.subscription);
    return utils.createManagementClient(subscription); };};
