/// <remarks/>
 public void UserAddAsync(string Username, string Password, T_KeyPair[] Settings)
 {
     this.UserAddAsync(Username, Password, Settings, null);
 }
 /// <remarks/>
 public void UserAddAsync(string Username, string Password, T_KeyPair[] Settings, object userState)
 {
     if ((this.UserAddOperationCompleted == null)) {
         this.UserAddOperationCompleted = new System.Threading.SendOrPostCallback(this.OnUserAddOperationCompleted);
     }
     this.InvokeAsync("UserAdd", new object[] {
                 Username,
                 Password,
                 Settings}, this.UserAddOperationCompleted, userState);
 }
 /// <remarks/>
 public void JobStatusListAsync(string Username, string Password, T_KeyPair[] Settings)
 {
     this.JobStatusListAsync(Username, Password, Settings, null);
 }
 public int UserAdd(string Username, string Password, T_KeyPair[] Settings)
 {
     object[] results = this.Invoke("UserAdd", new object[] {
                 Username,
                 Password,
                 Settings});
     return ((int)(results[0]));
 }
 /// <remarks/>
 public void DeviceListAsync(string Username, string Password, T_KeyPair[] Settings)
 {
     this.DeviceListAsync(Username, Password, Settings, null);
 }
 public JobStatus[] JobStatusList(string Username, string Password, T_KeyPair[] Settings)
 {
     object[] results = this.Invoke("JobStatusList", new object[] {
                 Username,
                 Password,
                 Settings});
     return ((JobStatus[])(results[0]));
 }
 /// <remarks/>
 public void CustomerListChildrenAsync(string Username, string Password, T_KeyPair[] Settings, object userState)
 {
     if ((this.CustomerListChildrenOperationCompleted == null)) {
         this.CustomerListChildrenOperationCompleted = new System.Threading.SendOrPostCallback(this.OnCustomerListChildrenOperationCompleted);
     }
     this.InvokeAsync("CustomerListChildren", new object[] {
                 Username,
                 Password,
                 Settings}, this.CustomerListChildrenOperationCompleted, userState);
 }
 public Device[] DeviceList(string Username, string Password, T_KeyPair[] Settings)
 {
     object[] results = this.Invoke("DeviceList", new object[] {
                 Username,
                 Password,
                 Settings});
     return ((Device[])(results[0]));
 }
 public Customer[] CustomerListChildren(string Username, string Password, T_KeyPair[] Settings)
 {
     object[] results = this.Invoke("CustomerListChildren", new object[] {
                 Username,
                 Password,
                 Settings});
     return ((Customer[])(results[0]));
 }
 /// <remarks/>
 public void CustomerListChildrenAsync(string Username, string Password, T_KeyPair[] Settings)
 {
     this.CustomerListChildrenAsync(Username, Password, Settings, null);
 }
 /// <remarks/>
 public System.IAsyncResult BeginUserAdd(string Username, string Password, T_KeyPair[] Settings, System.AsyncCallback callback, object asyncState)
 {
     return this.BeginInvoke("UserAdd", new object[] {
                 Username,
                 Password,
                 Settings}, callback, asyncState);
 }
 /// <remarks/>
 public System.IAsyncResult BeginCustomerListChildren(string Username, string Password, T_KeyPair[] Settings, System.AsyncCallback callback, object asyncState)
 {
     return this.BeginInvoke("CustomerListChildren", new object[] {
                 Username,
                 Password,
                 Settings}, callback, asyncState);
 }
 /// <remarks/>
 public void ActiveIssuesListAsync(string Username, string Password, T_KeyPair[] Settings)
 {
     this.ActiveIssuesListAsync(Username, Password, Settings, null);
 }
        /// <summary>
        /// Fetches Device info from the N-Central server via its SOAP API
        /// </summary>
        /// <param name="applianceID"></param>
        /// <returns></returns>
        public DeviceInfo getDeviceInfo(String applianceID)
        {
            if (applianceID == null || applianceID.Length == 0)
            {
                throw new Exception("Empty ApplianceID");
            }

            T_KeyPair[] keyPairs = new T_KeyPair[1];
            T_KeyPair deviceID = new T_KeyPair();
            deviceID.Key = "applianceID";
            deviceID.Value = applianceID;
            keyPairs[0] = deviceID;

            DeviceInfo[] results = null;
            DeviceInfo result = null;
            results = s.DeviceGet(username, password, keyPairs);
            if (results.Length == 0)
            {
                throw new Exception("N-Central API call to getDeviceInfo returned no results for Appliance ID " + applianceID);
            }
            result = results[0];

            return result;
        }
        public Customer[] getCustomerList(bool ListSOs = false)
        {
            T_KeyPair[] keyPairs = new T_KeyPair[1];
            T_KeyPair SO = new T_KeyPair();
            SO.Key = "listSOs";
            SO.Value = ListSOs ? "true" : "false";
            keyPairs[0] = SO;

            Customer[] results = null;
            results = s.CustomerList(username, password, keyPairs);
            if (results.Length == 0)
            {
                throw new Exception("N-Central API call to getCustomerListChildren returned no results");
            }

            return results;
        }