// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License. See License.txt in the project root for license information.
//
// Code generated by Microsoft (R) AutoRest Code Generator.
import Foundation
import azureSwiftRuntime
internal struct UpdateStorageAccountWithAccountParametersData : UpdateStorageAccountWithAccountParametersProtocol {
    public var name: String
    public var properties: UpdateStorageAccountPropertiesProtocol?

        enum CodingKeys: String, CodingKey {case name = "name"
        case properties = "properties"
        }

  public init(name: String)  {
    self.name = name
  }

  public init(from decoder: Decoder) throws {
    let container = try decoder.container(keyedBy: CodingKeys.self)
      self.name = try container.decode(String.self, forKey: .name)
    if container.contains(.properties) {
        self.properties = try container.decode(UpdateStorageAccountPropertiesData?.self, forKey: .properties)
    }
    if var pageDecoder = decoder as? PageDecoder  {
      if pageDecoder.isPagedData,
        let nextLinkName = pageDecoder.nextLinkName {
          pageDecoder.nextLink = try UnknownCodingKey.decodeStringForKey(decoder: decoder, keyForDecode: nextLinkName)
      }
    }
  }

  public func encode(to encoder: Encoder) throws {
    var container = encoder.container(keyedBy: CodingKeys.self)
    try container.encode(self.name, forKey: .name)
    if self.properties != nil {try container.encode(self.properties as! UpdateStorageAccountPropertiesData?, forKey: .properties)}
  }
}

extension DataFactory {
  public static func createUpdateStorageAccountWithAccountParametersProtocol(name: String) -> UpdateStorageAccountWithAccountParametersProtocol {
    return UpdateStorageAccountWithAccountParametersData(name: name)
  }
}


// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License. See License.txt in the project root for license information.
//
// Code generated by Microsoft (R) AutoRest Code Generator.
import Foundation
// AddDataLakeStoreParametersProtocol is the parameters used to add a new Data Lake Store account.
public protocol AddDataLakeStoreParametersProtocol : Codable {
     var properties: AddDataLakeStorePropertiesProtocol? { get set }
}


// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License. See License.txt in the project root for license information.
//
// Code generated by Microsoft (R) AutoRest Code Generator.
import Foundation
// AddDataLakeStorePropertiesProtocol is the Data Lake Store account properties to use when adding a new Data Lake
// Store account.
public protocol AddDataLakeStorePropertiesProtocol : Codable {
     var suffix: String? { get set }
}


// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License. See License.txt in the project root for license information.
//
// Code generated by Microsoft (R) AutoRest Code Generator.
import Foundation
// AddDataLakeStoreWithAccountParametersProtocol is the parameters used to add a new Data Lake Store account while
// creating a new Data Lake Analytics account.
public protocol AddDataLakeStoreWithAccountParametersProtocol : Codable {
     var name: String { get set }
     var properties: AddDataLakeStorePropertiesProtocol? { get set }
}


// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License. See License.txt in the project root for license information.
//
// Code generated by Microsoft (R) AutoRest Code Generator.
import Foundation
// AddStorageAccountParametersProtocol is the parameters used to add a new Azure Storage account.
public protocol AddStorageAccountParametersProtocol : Codable {
     var properties: AddStorageAccountPropertiesProtocol { get set }
}


// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License. See License.txt in the project root for license information.
//
// Code generated by Microsoft (R) AutoRest Code Generator.
import Foundation
// AddStorageAccountPropertiesProtocol is the Azure Storage account properties to use when adding a new Azure Storage
// account.
public protocol AddStorageAccountPropertiesProtocol : Codable {
     var accessKey: String { get set }
     var suffix: String? { get set }
}


// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License. See License.txt in the project root for license information.
//
// Code generated by Microsoft (R) AutoRest Code Generator.
import Foundation
// AddStorageAccountWithAccountParametersProtocol is the parameters used to add a new Azure Storage account while
// creating a new Data Lake Analytics account.
public protocol AddStorageAccountWithAccountParametersProtocol : Codable {
     var name: String { get set }
     var properties: AddStorageAccountPropertiesProtocol { get set }
}


// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License. See License.txt in the project root for license information.
//
// Code generated by Microsoft (R) AutoRest Code Generator.
import Foundation
// CapabilityInformationProtocol is subscription-level properties and limits for Data Lake Analytics.
public protocol CapabilityInformationProtocol : Codable {
     var subscriptionId: String? { get set }
     var state: SubscriptionStateEnum? { get set }
     var maxAccountCount: Int32? { get set }
     var accountCount: Int32? { get set }
     var migrationState: Bool? { get set }
}


// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License. See License.txt in the project root for license information.
//
// Code generated by Microsoft (R) AutoRest Code Generator.
import Foundation
// CheckNameAvailabilityParametersProtocol is data Lake Analytics account name availability check parameters.
public protocol CheckNameAvailabilityParametersProtocol : Codable {
     var name: String { get set }
     var type: String { get set }
}


// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License. See License.txt in the project root for license information.
//
// Code generated by Microsoft (R) AutoRest Code Generator.
import Foundation
// ComputePolicyListResultProtocol is the list of compute policies in the account.
public protocol ComputePolicyListResultProtocol : Codable {
     var value: [ComputePolicyProtocol?]? { get set }
     var _nextLink: String? { get set }
}


// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License. See License.txt in the project root for license information.
//
// Code generated by Microsoft (R) AutoRest Code Generator.
import Foundation
// ComputePolicyPropertiesProtocol is the compute policy properties.
public protocol ComputePolicyPropertiesProtocol : Codable {
     var objectId: String? { get set }
     var objectType: AADObjectTypeEnum? { get set }
     var maxDegreeOfParallelismPerJob: Int32? { get set }
     var minPriorityPerJob: Int32? { get set }
}


// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License. See License.txt in the project root for license information.
//
// Code generated by Microsoft (R) AutoRest Code Generator.
import Foundation
// ComputePolicyProtocol is data Lake Analytics compute policy information.
public protocol ComputePolicyProtocol : SubResourceProtocol {
     var properties: ComputePolicyPropertiesProtocol? { get set }
}


// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License. See License.txt in the project root for license information.
//
// Code generated by Microsoft (R) AutoRest Code Generator.
import Foundation
// CreateComputePolicyWithAccountParametersProtocol is the parameters used to create a new compute policy while
// creating a new Data Lake Analytics account.
public protocol CreateComputePolicyWithAccountParametersProtocol : Codable {
     var name: String { get set }
     var properties: CreateOrUpdateComputePolicyPropertiesProtocol { get set }
}


// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License. See License.txt in the project root for license information.
//
// Code generated by Microsoft (R) AutoRest Code Generator.
import Foundation
// CreateDataLakeAnalyticsAccountParametersProtocol is the parameters to use for creating a Data Lake Analytics
// account.
public protocol CreateDataLakeAnalyticsAccountParametersProtocol : Codable {
     var location: String { get set }
     var tags: [String:String]? { get set }
     var properties: CreateDataLakeAnalyticsAccountPropertiesProtocol { get set }
}


// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License. See License.txt in the project root for license information.
//
// Code generated by Microsoft (R) AutoRest Code Generator.
import Foundation
// CreateDataLakeAnalyticsAccountPropertiesProtocol is
public protocol CreateDataLakeAnalyticsAccountPropertiesProtocol : Codable {
     var defaultDataLakeStoreAccount: String { get set }
     var dataLakeStoreAccounts: [AddDataLakeStoreWithAccountParametersProtocol] { get set }
     var storageAccounts: [AddStorageAccountWithAccountParametersProtocol?]? { get set }
     var computePolicies: [CreateComputePolicyWithAccountParametersProtocol?]? { get set }
     var firewallRules: [CreateFirewallRuleWithAccountParametersProtocol?]? { get set }
     var firewallState: FirewallStateEnum? { get set }
     var firewallAllowAzureIps: FirewallAllowAzureIpsStateEnum? { get set }
     var newTier: TierTypeEnum? { get set }
     var maxJobCount: Int32? { get set }
     var maxDegreeOfParallelism: Int32? { get set }
     var maxDegreeOfParallelismPerJob: Int32? { get set }
     var minPriorityPerJob: Int32? { get set }
     var queryStoreRetention: Int32? { get set }
}


// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License. See License.txt in the project root for license information.
//
// Code generated by Microsoft (R) AutoRest Code Generator.
import Foundation
// CreateFirewallRuleWithAccountParametersProtocol is the parameters used to create a new firewall rule while creating
// a new Data Lake Analytics account.
public protocol CreateFirewallRuleWithAccountParametersProtocol : Codable {
     var name: String { get set }
     var properties: CreateOrUpdateFirewallRulePropertiesProtocol { get set }
}


// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License. See License.txt in the project root for license information.
//
// Code generated by Microsoft (R) AutoRest Code Generator.
import Foundation
// CreateOrUpdateComputePolicyParametersProtocol is the parameters used to create a new compute policy.
public protocol CreateOrUpdateComputePolicyParametersProtocol : Codable {
     var properties: CreateOrUpdateComputePolicyPropertiesProtocol { get set }
}


// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License. See License.txt in the project root for license information.
//
// Code generated by Microsoft (R) AutoRest Code Generator.
import Foundation
// CreateOrUpdateComputePolicyPropertiesProtocol is the compute policy properties to use when creating a new compute
// policy.
public protocol CreateOrUpdateComputePolicyPropertiesProtocol : Codable {
     var objectId: String { get set }
     var objectType: AADObjectTypeEnum { get set }
     var maxDegreeOfParallelismPerJob: Int32? { get set }
     var minPriorityPerJob: Int32? { get set }
}


// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License. See License.txt in the project root for license information.
//
// Code generated by Microsoft (R) AutoRest Code Generator.
import Foundation
// CreateOrUpdateFirewallRuleParametersProtocol is the parameters used to create a new firewall rule.
public protocol CreateOrUpdateFirewallRuleParametersProtocol : Codable {
     var properties: CreateOrUpdateFirewallRulePropertiesProtocol { get set }
}


// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License. See License.txt in the project root for license information.
//
// Code generated by Microsoft (R) AutoRest Code Generator.
import Foundation
// CreateOrUpdateFirewallRulePropertiesProtocol is the firewall rule properties to use when creating a new firewall
// rule.
public protocol CreateOrUpdateFirewallRulePropertiesProtocol : Codable {
     var startIpAddress: String { get set }
     var endIpAddress: String { get set }
}


// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License. See License.txt in the project root for license information.
//
// Code generated by Microsoft (R) AutoRest Code Generator.
import Foundation
// DataLakeAnalyticsAccountBasicProtocol is a Data Lake Analytics account object, containing all information associated
// with the named Data Lake Analytics account.
public protocol DataLakeAnalyticsAccountBasicProtocol : ResourceProtocol {
     var properties: DataLakeAnalyticsAccountPropertiesBasicProtocol? { get set }
}


// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License. See License.txt in the project root for license information.
//
// Code generated by Microsoft (R) AutoRest Code Generator.
import Foundation
// DataLakeAnalyticsAccountListResultProtocol is data Lake Analytics account list information.
public protocol DataLakeAnalyticsAccountListResultProtocol : Codable {
     var value: [DataLakeAnalyticsAccountBasicProtocol?]? { get set }
     var _nextLink: String? { get set }
}


// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License. See License.txt in the project root for license information.
//
// Code generated by Microsoft (R) AutoRest Code Generator.
import Foundation
// DataLakeAnalyticsAccountPropertiesBasicProtocol is the basic account specific properties that are associated with an
// underlying Data Lake Analytics account.
public protocol DataLakeAnalyticsAccountPropertiesBasicProtocol : Codable {
     var accountId: String? { get set }
     var provisioningState: DataLakeAnalyticsAccountStatusEnum? { get set }
     var state: DataLakeAnalyticsAccountStateEnum? { get set }
     var creationTime: Date? { get set }
     var lastModifiedTime: Date? { get set }
     var endpoint: String? { get set }
}


// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License. See License.txt in the project root for license information.
//
// Code generated by Microsoft (R) AutoRest Code Generator.
import Foundation
// DataLakeAnalyticsAccountPropertiesProtocol is the account specific properties that are associated with an underlying
// Data Lake Analytics account. Returned only when retrieving a specific account.
public protocol DataLakeAnalyticsAccountPropertiesProtocol : DataLakeAnalyticsAccountPropertiesBasicProtocol {
     var defaultDataLakeStoreAccount: String? { get set }
     var dataLakeStoreAccounts: [DataLakeStoreAccountInformationProtocol?]? { get set }
     var storageAccounts: [StorageAccountInformationProtocol?]? { get set }
     var computePolicies: [ComputePolicyProtocol?]? { get set }
     var firewallRules: [FirewallRuleProtocol?]? { get set }
     var firewallState: FirewallStateEnum? { get set }
     var firewallAllowAzureIps: FirewallAllowAzureIpsStateEnum? { get set }
     var newTier: TierTypeEnum? { get set }
     var currentTier: TierTypeEnum? { get set }
     var maxJobCount: Int32? { get set }
     var systemMaxJobCount: Int32? { get set }
     var maxDegreeOfParallelism: Int32? { get set }
     var systemMaxDegreeOfParallelism: Int32? { get set }
     var maxDegreeOfParallelismPerJob: Int32? { get set }
     var minPriorityPerJob: Int32? { get set }
     var queryStoreRetention: Int32? { get set }
}


// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License. See License.txt in the project root for license information.
//
// Code generated by Microsoft (R) AutoRest Code Generator.
import Foundation
// DataLakeAnalyticsAccountProtocol is a Data Lake Analytics account object, containing all information associated with
// the named Data Lake Analytics account.
public protocol DataLakeAnalyticsAccountProtocol : ResourceProtocol {
     var properties: DataLakeAnalyticsAccountPropertiesProtocol? { get set }
}


// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License. See License.txt in the project root for license information.
//
// Code generated by Microsoft (R) AutoRest Code Generator.
import Foundation
// DataLakeStoreAccountInformationListResultProtocol is data Lake Store account list information.
public protocol DataLakeStoreAccountInformationListResultProtocol : Codable {
     var value: [DataLakeStoreAccountInformationProtocol?]? { get set }
     var _nextLink: String? { get set }
}


// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License. See License.txt in the project root for license information.
//
// Code generated by Microsoft (R) AutoRest Code Generator.
import Foundation
// DataLakeStoreAccountInformationPropertiesProtocol is the Data Lake Store account properties.
public protocol DataLakeStoreAccountInformationPropertiesProtocol : Codable {
     var suffix: String? { get set }
}


// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License. See License.txt in the project root for license information.
//
// Code generated by Microsoft (R) AutoRest Code Generator.
import Foundation
// DataLakeStoreAccountInformationProtocol is data Lake Store account information.
public protocol DataLakeStoreAccountInformationProtocol : SubResourceProtocol {
     var properties: DataLakeStoreAccountInformationPropertiesProtocol? { get set }
}


// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License. See License.txt in the project root for license information.
//
// Code generated by Microsoft (R) AutoRest Code Generator.
import Foundation
// FirewallRuleListResultProtocol is data Lake Analytics firewall rule list information.
public protocol FirewallRuleListResultProtocol : Codable {
     var value: [FirewallRuleProtocol?]? { get set }
     var _nextLink: String? { get set }
}


// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License. See License.txt in the project root for license information.
//
// Code generated by Microsoft (R) AutoRest Code Generator.
import Foundation
// FirewallRulePropertiesProtocol is the firewall rule properties.
public protocol FirewallRulePropertiesProtocol : Codable {
     var startIpAddress: String? { get set }
     var endIpAddress: String? { get set }
}


// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License. See License.txt in the project root for license information.
//
// Code generated by Microsoft (R) AutoRest Code Generator.
import Foundation
// FirewallRuleProtocol is data Lake Analytics firewall rule information.
public protocol FirewallRuleProtocol : SubResourceProtocol {
     var properties: FirewallRulePropertiesProtocol? { get set }
}


// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License. See License.txt in the project root for license information.
//
// Code generated by Microsoft (R) AutoRest Code Generator.
import Foundation
// NameAvailabilityInformationProtocol is data Lake Analytics account name availability result information.
public protocol NameAvailabilityInformationProtocol : Codable {
     var nameAvailable: Bool? { get set }
     var reason: String? { get set }
     var message: String? { get set }
}


// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License. See License.txt in the project root for license information.
//
// Code generated by Microsoft (R) AutoRest Code Generator.
import Foundation
// OperationDisplayProtocol is the display information for a particular operation.
public protocol OperationDisplayProtocol : Codable {
     var provider: String? { get set }
     var resource: String? { get set }
     var operation: String? { get set }
     var description: String? { get set }
}


// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License. See License.txt in the project root for license information.
//
// Code generated by Microsoft (R) AutoRest Code Generator.
import Foundation
// OperationListResultProtocol is the list of available operations for Data Lake Analytics.
public protocol OperationListResultProtocol : Codable {
     var value: [OperationProtocol?]? { get set }
     var _nextLink: String? { get set }
}


// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License. See License.txt in the project root for license information.
//
// Code generated by Microsoft (R) AutoRest Code Generator.
import Foundation
// OperationProtocol is an available operation for Data Lake Analytics.
public protocol OperationProtocol : Codable {
     var name: String? { get set }
     var display: OperationDisplayProtocol? { get set }
     var origin: OperationOriginEnum? { get set }
}


// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License. See License.txt in the project root for license information.
//
// Code generated by Microsoft (R) AutoRest Code Generator.
import Foundation
// ResourceProtocol is the resource model definition.
public protocol ResourceProtocol : Codable {
     var id: String? { get set }
     var name: String? { get set }
     var type: String? { get set }
     var location: String? { get set }
     var tags: [String:String]? { get set }
}


// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License. See License.txt in the project root for license information.
//
// Code generated by Microsoft (R) AutoRest Code Generator.
import Foundation
// SasTokenInformationListResultProtocol is the SAS response that contains the storage account, container and
// associated SAS token for connection use.
public protocol SasTokenInformationListResultProtocol : Codable {
     var value: [SasTokenInformationProtocol?]? { get set }
     var _nextLink: String? { get set }
}


// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License. See License.txt in the project root for license information.
//
// Code generated by Microsoft (R) AutoRest Code Generator.
import Foundation
// SasTokenInformationProtocol is SAS token information.
public protocol SasTokenInformationProtocol : Codable {
     var accessToken: String? { get set }
}


// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License. See License.txt in the project root for license information.
//
// Code generated by Microsoft (R) AutoRest Code Generator.
import Foundation
// StorageAccountInformationListResultProtocol is azure Storage account list information.
public protocol StorageAccountInformationListResultProtocol : Codable {
     var value: [StorageAccountInformationProtocol?]? { get set }
     var _nextLink: String? { get set }
}


// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License. See License.txt in the project root for license information.
//
// Code generated by Microsoft (R) AutoRest Code Generator.
import Foundation
// StorageAccountInformationPropertiesProtocol is the Azure Storage account properties.
public protocol StorageAccountInformationPropertiesProtocol : Codable {
     var suffix: String? { get set }
}


// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License. See License.txt in the project root for license information.
//
// Code generated by Microsoft (R) AutoRest Code Generator.
import Foundation
// StorageAccountInformationProtocol is azure Storage account information.
public protocol StorageAccountInformationProtocol : SubResourceProtocol {
     var properties: StorageAccountInformationPropertiesProtocol? { get set }
}


// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License. See License.txt in the project root for license information.
//
// Code generated by Microsoft (R) AutoRest Code Generator.
import Foundation
// StorageContainerListResultProtocol is the list of blob containers associated with the storage account attached to
// the Data Lake Analytics account.
public protocol StorageContainerListResultProtocol : Codable {
     var value: [StorageContainerProtocol?]? { get set }
     var _nextLink: String? { get set }
}


// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License. See License.txt in the project root for license information.
//
// Code generated by Microsoft (R) AutoRest Code Generator.
import Foundation
// StorageContainerPropertiesProtocol is azure Storage blob container properties information.
public protocol StorageContainerPropertiesProtocol : Codable {
     var lastModifiedTime: Date? { get set }
}


// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License. See License.txt in the project root for license information.
//
// Code generated by Microsoft (R) AutoRest Code Generator.
import Foundation
// StorageContainerProtocol is azure Storage blob container information.
public protocol StorageContainerProtocol : SubResourceProtocol {
     var properties: StorageContainerPropertiesProtocol? { get set }
}


// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License. See License.txt in the project root for license information.
//
// Code generated by Microsoft (R) AutoRest Code Generator.
import Foundation
// SubResourceProtocol is the resource model definition for a nested resource.
public protocol SubResourceProtocol : Codable {
     var id: String? { get set }
     var name: String? { get set }
     var type: String? { get set }
}


// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License. See License.txt in the project root for license information.
//
// Code generated by Microsoft (R) AutoRest Code Generator.
import Foundation
// UpdateComputePolicyParametersProtocol is the parameters used to update a compute policy.
public protocol UpdateComputePolicyParametersProtocol : Codable {
     var properties: UpdateComputePolicyPropertiesProtocol? { get set }
}


// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License. See License.txt in the project root for license information.
//
// Code generated by Microsoft (R) AutoRest Code Generator.
import Foundation
// UpdateComputePolicyPropertiesProtocol is the compute policy properties to use when updating a compute policy.
public protocol UpdateComputePolicyPropertiesProtocol : Codable {
     var objectId: String? { get set }
     var objectType: AADObjectTypeEnum? { get set }
     var maxDegreeOfParallelismPerJob: Int32? { get set }
     var minPriorityPerJob: Int32? { get set }
}


// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License. See License.txt in the project root for license information.
//
// Code generated by Microsoft (R) AutoRest Code Generator.
import Foundation
// UpdateComputePolicyWithAccountParametersProtocol is the parameters used to update a compute policy while updating a
// Data Lake Analytics account.
public protocol UpdateComputePolicyWithAccountParametersProtocol : Codable {
     var name: String { get set }
     var properties: UpdateComputePolicyPropertiesProtocol? { get set }
}


// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License. See License.txt in the project root for license information.
//
// Code generated by Microsoft (R) AutoRest Code Generator.
import Foundation
// UpdateDataLakeAnalyticsAccountParametersProtocol is the parameters that can be used to update an existing Data Lake
// Analytics account.
public protocol UpdateDataLakeAnalyticsAccountParametersProtocol : Codable {
     var tags: [String:String]? { get set }
     var properties: UpdateDataLakeAnalyticsAccountPropertiesProtocol? { get set }
}


// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License. See License.txt in the project root for license information.
//
// Code generated by Microsoft (R) AutoRest Code Generator.
import Foundation
// UpdateDataLakeAnalyticsAccountPropertiesProtocol is the properties to update that are associated with an underlying
// Data Lake Analytics account.
public protocol UpdateDataLakeAnalyticsAccountPropertiesProtocol : Codable {
     var dataLakeStoreAccounts: [UpdateDataLakeStoreWithAccountParametersProtocol?]? { get set }
     var storageAccounts: [UpdateStorageAccountWithAccountParametersProtocol?]? { get set }
     var computePolicies: [UpdateComputePolicyWithAccountParametersProtocol?]? { get set }
     var firewallRules: [UpdateFirewallRuleWithAccountParametersProtocol?]? { get set }
     var firewallState: FirewallStateEnum? { get set }
     var firewallAllowAzureIps: FirewallAllowAzureIpsStateEnum? { get set }
     var newTier: TierTypeEnum? { get set }
     var maxJobCount: Int32? { get set }
     var maxDegreeOfParallelism: Int32? { get set }
     var maxDegreeOfParallelismPerJob: Int32? { get set }
     var minPriorityPerJob: Int32? { get set }
     var queryStoreRetention: Int32? { get set }
}


// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License. See License.txt in the project root for license information.
//
// Code generated by Microsoft (R) AutoRest Code Generator.
import Foundation
// UpdateDataLakeStorePropertiesProtocol is the Data Lake Store account properties to use when updating a Data Lake
// Store account.
public protocol UpdateDataLakeStorePropertiesProtocol : Codable {
     var suffix: String? { get set }
}


// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License. See License.txt in the project root for license information.
//
// Code generated by Microsoft (R) AutoRest Code Generator.
import Foundation
// UpdateDataLakeStoreWithAccountParametersProtocol is the parameters used to update a Data Lake Store account while
// updating a Data Lake Analytics account.
public protocol UpdateDataLakeStoreWithAccountParametersProtocol : Codable {
     var name: String { get set }
     var properties: UpdateDataLakeStorePropertiesProtocol? { get set }
}


// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License. See License.txt in the project root for license information.
//
// Code generated by Microsoft (R) AutoRest Code Generator.
import Foundation
// UpdateFirewallRuleParametersProtocol is the parameters used to update a firewall rule.
public protocol UpdateFirewallRuleParametersProtocol : Codable {
     var properties: UpdateFirewallRulePropertiesProtocol? { get set }
}


// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License. See License.txt in the project root for license information.
//
// Code generated by Microsoft (R) AutoRest Code Generator.
import Foundation
// UpdateFirewallRulePropertiesProtocol is the firewall rule properties to use when updating a firewall rule.
public protocol UpdateFirewallRulePropertiesProtocol : Codable {
     var startIpAddress: String? { get set }
     var endIpAddress: String? { get set }
}


// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License. See License.txt in the project root for license information.
//
// Code generated by Microsoft (R) AutoRest Code Generator.
import Foundation
// UpdateFirewallRuleWithAccountParametersProtocol is the parameters used to update a firewall rule while updating a
// Data Lake Analytics account.
public protocol UpdateFirewallRuleWithAccountParametersProtocol : Codable {
     var name: String { get set }
     var properties: UpdateFirewallRulePropertiesProtocol? { get set }
}


// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License. See License.txt in the project root for license information.
//
// Code generated by Microsoft (R) AutoRest Code Generator.
import Foundation
// UpdateStorageAccountParametersProtocol is the parameters used to update an Azure Storage account.
public protocol UpdateStorageAccountParametersProtocol : Codable {
     var properties: UpdateStorageAccountPropertiesProtocol? { get set }
}


// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License. See License.txt in the project root for license information.
//
// Code generated by Microsoft (R) AutoRest Code Generator.
import Foundation
// UpdateStorageAccountPropertiesProtocol is the Azure Storage account properties to use when updating an Azure Storage
// account.
public protocol UpdateStorageAccountPropertiesProtocol : Codable {
     var accessKey: String? { get set }
     var suffix: String? { get set }
}


// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License. See License.txt in the project root for license information.
//
// Code generated by Microsoft (R) AutoRest Code Generator.
import Foundation
// UpdateStorageAccountWithAccountParametersProtocol is the parameters used to update an Azure Storage account while
// updating a Data Lake Analytics account.
public protocol UpdateStorageAccountWithAccountParametersProtocol : Codable {
     var name: String { get set }
     var properties: UpdateStorageAccountPropertiesProtocol? { get set }
}


// swift-tools-version:4.0
// The swift-tools-version declares the minimum version of Swift required to build this package.
import PackageDescription
let package = Package(
    name: "datalakestoreaccount",
    products: [
        // Products define the executables and libraries produced by a package, and make them visible to other packages.
        .library(
            name: "datalakestoreaccount",
            targets: ["datalakestoreaccount"]),
    ],
    dependencies: [
        // Dependencies declare other packages that this package depends on.
        .package(url: "https://github.com/Alamofire/Alamofire.git", from: "4.0.10"),
        .package(url: "https://github.com/ReactiveX/RxSwift.git", from: "3.4.2"),
        .package(url: "https://github.com/SwiftyJSON/SwiftyJSON.git", from: "3.1.4"),
        .package(url: "git@github.com:alvadb/autorest-clientruntime-for-swift.git", .branch("master"))
    ],
    targets: [
        // Targets are the basic building blocks of a package. A target can define a module or a test suite.
        // Targets can depend on other targets in this package, and on products in packages which this package depends on.
        .target(
            name: "datalakestoreaccount",
            dependencies: ["Alamofire", "RxSwift", "SwiftyJSON", "azureSwiftRuntime"])
    ]
)


// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License. See License.txt in the project root for license information.
//
// Code generated by Microsoft (R) AutoRest Code Generator.

// Accounts is the creates an Azure Data Lake Store account management client.
import Foundation
import azureSwiftRuntime
extension Commands {
public struct Accounts {
    public static func CheckNameAvailability(subscriptionId: String, location: String, parameters: CheckNameAvailabilityParametersProtocol) -> AccountsCheckNameAvailability {
        return CheckNameAvailabilityCommand(subscriptionId: subscriptionId, location: location, parameters: parameters)
    }
    public static func Create(subscriptionId: String, resourceGroupName: String, accountName: String, parameters: CreateDataLakeStoreAccountParametersProtocol) -> AccountsCreate {
        return CreateCommand(subscriptionId: subscriptionId, resourceGroupName: resourceGroupName, accountName: accountName, parameters: parameters)
    }
    public static func Delete(subscriptionId: String, resourceGroupName: String, accountName: String) -> AccountsDelete {
        return DeleteCommand(subscriptionId: subscriptionId, resourceGroupName: resourceGroupName, accountName: accountName)
    }
    public static func EnableKeyVault(subscriptionId: String, resourceGroupName: String, accountName: String) -> AccountsEnableKeyVault {
        return EnableKeyVaultCommand(subscriptionId: subscriptionId, resourceGroupName: resourceGroupName, accountName: accountName)
    }
    public static func Get(subscriptionId: String, resourceGroupName: String, accountName: String) -> AccountsGet {
        return GetCommand(subscriptionId: subscriptionId, resourceGroupName: resourceGroupName, accountName: accountName)
    }
    public static func List(subscriptionId: String) -> AccountsList {
        return ListCommand(subscriptionId: subscriptionId)
    }
    public static func ListByResourceGroup(subscriptionId: String, resourceGroupName: String) -> AccountsListByResourceGroup {
        return ListByResourceGroupCommand(subscriptionId: subscriptionId, resourceGroupName: resourceGroupName)
    }
    public static func Update(subscriptionId: String, resourceGroupName: String, accountName: String, parameters: UpdateDataLakeStoreAccountParametersProtocol) -> AccountsUpdate {
        return UpdateCommand(subscriptionId: subscriptionId, resourceGroupName: resourceGroupName, accountName: accountName, parameters: parameters)
    }
}
}


import Foundation
import azureSwiftRuntime
public protocol AccountsCheckNameAvailability  {
    var headerParameters: [String: String] { get set }
    var subscriptionId : String { get set }
    var location : String { get set }
    var apiVersion : String { get set }
    var parameters :  CheckNameAvailabilityParametersProtocol?  { get set }
    func execute(client: RuntimeClient,
    completionHandler: @escaping (NameAvailabilityInformationProtocol?, Error?) -> Void) -> Void ;
}

extension Commands.Accounts {
// CheckNameAvailability checks whether the specified account name is available or taken.
    internal class CheckNameAvailabilityCommand : BaseCommand, AccountsCheckNameAvailability {
        public var subscriptionId : String
        public var location : String
        public var apiVersion = "2016-11-01"
    public var parameters :  CheckNameAvailabilityParametersProtocol?

        public init(subscriptionId: String, location: String, parameters: CheckNameAvailabilityParametersProtocol) {
            self.subscriptionId = subscriptionId
            self.location = location
            self.parameters = parameters
            super.init()
            self.method = "Post"
            self.isLongRunningOperation = false
            self.path = "/subscriptions/{subscriptionId}/providers/Microsoft.DataLakeStore/locations/{location}/checkNameAvailability"
            self.headerParameters = ["Content-Type":"application/json; charset=utf-8"]
        }

        public override func preCall()  {
            self.pathParameters["{subscriptionId}"] = String(describing: self.subscriptionId)
            self.pathParameters["{location}"] = String(describing: self.location)
            self.queryParameters["api-version"] = String(describing: self.apiVersion)
            self.body = parameters

        }
        public override func encodeBody() throws -> Data? {
            let contentType = "application/json"
            if let mimeType = MimeType.getType(forStr: contentType) {
                let encoder = try CoderFactory.encoder(for: mimeType)
                let encodedValue = try encoder.encode(parameters as? CheckNameAvailabilityParametersData)
                return encodedValue
            }
            throw DecodeError.unknownMimeType
        }

        public override func returnFunc(data: Data) throws -> Decodable? {
            let contentType = "application/json"
            if let mimeType = MimeType.getType(forStr: contentType) {
                let decoder = try CoderFactory.decoder(for: mimeType)
                let result = try decoder.decode(NameAvailabilityInformationData?.self, from: data)
                return result;
            }
            throw DecodeError.unknownMimeType
        }
        public func execute(client: RuntimeClient,
            completionHandler: @escaping (NameAvailabilityInformationProtocol?, Error?) -> Void) -> Void {
            client.executeAsync(command: self) {
                (result: NameAvailabilityInformationData?, error: Error?) in
                completionHandler(result, error)
            }
        }
    }
}


import Foundation
import azureSwiftRuntime
public protocol AccountsCreate  {
    var headerParameters: [String: String] { get set }
    var subscriptionId : String { get set }
    var resourceGroupName : String { get set }
    var accountName : String { get set }
    var apiVersion : String { get set }
    var parameters :  CreateDataLakeStoreAccountParametersProtocol?  { get set }
    func execute(client: RuntimeClient,
    completionHandler: @escaping (DataLakeStoreAccountProtocol?, Error?) -> Void) -> Void ;
}

extension Commands.Accounts {
// Create creates the specified Data Lake Store account. This method may poll for completion. Polling can be canceled
// by passing the cancel channel argument. The channel will be used to cancel polling and any outstanding HTTP
// requests.
    internal class CreateCommand : BaseCommand, AccountsCreate {
        public var subscriptionId : String
        public var resourceGroupName : String
        public var accountName : String
        public var apiVersion = "2016-11-01"
    public var parameters :  CreateDataLakeStoreAccountParametersProtocol?

        public init(subscriptionId: String, resourceGroupName: String, accountName: String, parameters: CreateDataLakeStoreAccountParametersProtocol) {
            self.subscriptionId = subscriptionId
            self.resourceGroupName = resourceGroupName
            self.accountName = accountName
            self.parameters = parameters
            super.init()
            self.method = "Put"
            self.isLongRunningOperation = true
            self.path = "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataLakeStore/accounts/{accountName}"
            self.headerParameters = ["Content-Type":"application/json; charset=utf-8"]
        }

        public override func preCall()  {
            self.pathParameters["{subscriptionId}"] = String(describing: self.subscriptionId)
            self.pathParameters["{resourceGroupName}"] = String(describing: self.resourceGroupName)
            self.pathParameters["{accountName}"] = String(describing: self.accountName)
            self.queryParameters["api-version"] = String(describing: self.apiVersion)
            self.body = parameters

        }
        public override func encodeBody() throws -> Data? {
            let contentType = "application/json"
            if let mimeType = MimeType.getType(forStr: contentType) {
                let encoder = try CoderFactory.encoder(for: mimeType)
                let encodedValue = try encoder.encode(parameters as? CreateDataLakeStoreAccountParametersData)
                return encodedValue
            }
            throw DecodeError.unknownMimeType
        }

        public override func returnFunc(data: Data) throws -> Decodable? {
            let contentType = "application/json"
            if let mimeType = MimeType.getType(forStr: contentType) {
                let decoder = try CoderFactory.decoder(for: mimeType)
                let result = try decoder.decode(DataLakeStoreAccountData?.self, from: data)
                return result;
            }
            throw DecodeError.unknownMimeType
        }
        public func execute(client: RuntimeClient,
            completionHandler: @escaping (DataLakeStoreAccountProtocol?, Error?) -> Void) -> Void {
            client.executeAsyncLRO(command: self) {
                (result: DataLakeStoreAccountData?, error: Error?) in
                completionHandler(result, error)
            }
        }
    }
}


import Foundation
import azureSwiftRuntime
public protocol AccountsDelete  {
    var headerParameters: [String: String] { get set }
    var subscriptionId : String { get set }
    var resourceGroupName : String { get set }
    var accountName : String { get set }
    var apiVersion : String { get set }
    func execute(client: RuntimeClient,
    completionHandler: @escaping (Error?) -> Void) -> Void;
}

extension Commands.Accounts {
// Delete deletes the specified Data Lake Store account. This method may poll for completion. Polling can be canceled
// by passing the cancel channel argument. The channel will be used to cancel polling and any outstanding HTTP
// requests.
    internal class DeleteCommand : BaseCommand, AccountsDelete {
        public var subscriptionId : String
        public var resourceGroupName : String
        public var accountName : String
        public var apiVersion = "2016-11-01"

        public init(subscriptionId: String, resourceGroupName: String, accountName: String) {
            self.subscriptionId = subscriptionId
            self.resourceGroupName = resourceGroupName
            self.accountName = accountName
            super.init()
            self.method = "Delete"
            self.isLongRunningOperation = true
            self.path = "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataLakeStore/accounts/{accountName}"
            self.headerParameters = ["Content-Type":"application/json; charset=utf-8"]
        }

        public override func preCall()  {
            self.pathParameters["{subscriptionId}"] = String(describing: self.subscriptionId)
            self.pathParameters["{resourceGroupName}"] = String(describing: self.resourceGroupName)
            self.pathParameters["{accountName}"] = String(describing: self.accountName)
            self.queryParameters["api-version"] = String(describing: self.apiVersion)

        }

        public func execute(client: RuntimeClient,
            completionHandler: @escaping (Error?) -> Void) -> Void {
            client.executeAsyncLRO(command: self) {
                (error) in
                completionHandler(error)
            }
        }
    }
}


import Foundation
import azureSwiftRuntime
public protocol AccountsEnableKeyVault  {
    var headerParameters: [String: String] { get set }
    var subscriptionId : String { get set }
    var resourceGroupName : String { get set }
    var accountName : String { get set }
    var apiVersion : String { get set }
    func execute(client: RuntimeClient,
    completionHandler: @escaping (Error?) -> Void) -> Void;
}

extension Commands.Accounts {
// EnableKeyVault attempts to enable a user managed Key Vault for encryption of the specified Data Lake Store account.
    internal class EnableKeyVaultCommand : BaseCommand, AccountsEnableKeyVault {
        public var subscriptionId : String
        public var resourceGroupName : String
        public var accountName : String
        public var apiVersion = "2016-11-01"

        public init(subscriptionId: String, resourceGroupName: String, accountName: String) {
            self.subscriptionId = subscriptionId
            self.resourceGroupName = resourceGroupName
            self.accountName = accountName
            super.init()
            self.method = "Post"
            self.isLongRunningOperation = false
            self.path = "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataLakeStore/accounts/{accountName}/enableKeyVault"
            self.headerParameters = ["Content-Type":"application/json; charset=utf-8"]
        }

        public override func preCall()  {
            self.pathParameters["{subscriptionId}"] = String(describing: self.subscriptionId)
            self.pathParameters["{resourceGroupName}"] = String(describing: self.resourceGroupName)
            self.pathParameters["{accountName}"] = String(describing: self.accountName)
            self.queryParameters["api-version"] = String(describing: self.apiVersion)

        }

        public func execute(client: RuntimeClient,
            completionHandler: @escaping (Error?) -> Void) -> Void {
            client.executeAsync(command: self) {
                (error) in
                completionHandler(error)
            }
        }
    }
}


import Foundation
import azureSwiftRuntime
public protocol AccountsGet  {
    var headerParameters: [String: String] { get set }
    var subscriptionId : String { get set }
    var resourceGroupName : String { get set }
    var accountName : String { get set }
    var apiVersion : String { get set }
    func execute(client: RuntimeClient,
    completionHandler: @escaping (DataLakeStoreAccountProtocol?, Error?) -> Void) -> Void ;
}

extension Commands.Accounts {
// Get gets the specified Data Lake Store account.
    internal class GetCommand : BaseCommand, AccountsGet {
        public var subscriptionId : String
        public var resourceGroupName : String
        public var accountName : String
        public var apiVersion = "2016-11-01"

        public init(subscriptionId: String, resourceGroupName: String, accountName: String) {
            self.subscriptionId = subscriptionId
            self.resourceGroupName = resourceGroupName
            self.accountName = accountName
            super.init()
            self.method = "Get"
            self.isLongRunningOperation = false
            self.path = "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataLakeStore/accounts/{accountName}"
            self.headerParameters = ["Content-Type":"application/json; charset=utf-8"]
        }

        public override func preCall()  {
            self.pathParameters["{subscriptionId}"] = String(describing: self.subscriptionId)
            self.pathParameters["{resourceGroupName}"] = String(describing: self.resourceGroupName)
            self.pathParameters["{accountName}"] = String(describing: self.accountName)
            self.queryParameters["api-version"] = String(describing: self.apiVersion)

        }

        public override func returnFunc(data: Data) throws -> Decodable? {
            let contentType = "application/json"
            if let mimeType = MimeType.getType(forStr: contentType) {
                let decoder = try CoderFactory.decoder(for: mimeType)
                let result = try decoder.decode(DataLakeStoreAccountData?.self, from: data)
                return result;
            }
            throw DecodeError.unknownMimeType
        }
        public func execute(client: RuntimeClient,
            completionHandler: @escaping (DataLakeStoreAccountProtocol?, Error?) -> Void) -> Void {
            client.executeAsync(command: self) {
                (result: DataLakeStoreAccountData?, error: Error?) in
                completionHandler(result, error)
            }
        }
    }
}


import Foundation
import azureSwiftRuntime
public protocol AccountsList  {
    var nextLink: String? { get }
    var hasAdditionalPages : Bool { get }
    var headerParameters: [String: String] { get set }
    var subscriptionId : String { get set }
    var filter : String? { get set }
    var top : Int32? { get set }
    var skip : Int32? { get set }
    var select : String? { get set }
    var orderby : String? { get set }
    var count : Bool? { get set }
    var apiVersion : String { get set }
    func execute(client: RuntimeClient,
    completionHandler: @escaping (DataLakeStoreAccountListResultProtocol?, Error?) -> Void) -> Void ;
}

extension Commands.Accounts {
// List lists the Data Lake Store accounts within the subscription. The response includes a link to the next page of
// results, if any.
    internal class ListCommand : BaseCommand, AccountsList {
        var nextLink: String?
        public var hasAdditionalPages : Bool {
        get {
            return nextLink != nil
        }
    }
        public var subscriptionId : String
        public var filter : String?
        public var top : Int32?
        public var skip : Int32?
        public var select : String?
        public var orderby : String?
        public var count : Bool?
        public var apiVersion = "2016-11-01"

        public init(subscriptionId: String) {
            self.subscriptionId = subscriptionId
            super.init()
            self.method = "Get"
            self.isLongRunningOperation = false
            self.path = "/subscriptions/{subscriptionId}/providers/Microsoft.DataLakeStore/accounts"
            self.headerParameters = ["Content-Type":"application/json; charset=utf-8"]
        }

        public override func preCall()  {
            self.pathParameters["{subscriptionId}"] = String(describing: self.subscriptionId)
            if self.filter != nil { queryParameters["$filter"] = String(describing: self.filter!) }
            if self.top != nil { queryParameters["$top"] = String(describing: self.top!) }
            if self.skip != nil { queryParameters["$skip"] = String(describing: self.skip!) }
            if self.select != nil { queryParameters["$select"] = String(describing: self.select!) }
            if self.orderby != nil { queryParameters["$orderby"] = String(describing: self.orderby!) }
            if self.count != nil { queryParameters["$count"] = String(describing: self.count!) }
            self.queryParameters["api-version"] = String(describing: self.apiVersion)

        }

        public override func returnFunc(data: Data) throws -> Decodable? {
            let contentType = "application/json"
            if let mimeType = MimeType.getType(forStr: contentType) {
                let decoder = try CoderFactory.decoder(for: mimeType)
                if var pageDecoder = decoder as? PageDecoder {
                    pageDecoder.isPagedData = true
                    pageDecoder.nextLinkName = "NextLink"
                }
                let result = try decoder.decode(DataLakeStoreAccountListResultData?.self, from: data)
                if var pageDecoder = decoder as? PageDecoder {
                    self.nextLink = pageDecoder.nextLink
                }
                return result;
            }
            throw DecodeError.unknownMimeType
        }
        public func execute(client: RuntimeClient,
            completionHandler: @escaping (DataLakeStoreAccountListResultProtocol?, Error?) -> Void) -> Void {
            if self.nextLink != nil {
                self.path = nextLink!
                self.nextLink = nil;
                self.pathType = .absolute
            }
            client.executeAsync(command: self) {
                (result: DataLakeStoreAccountListResultData?, error: Error?) in
                completionHandler(result, error)
            }
        }
    }
}


import Foundation
import azureSwiftRuntime
public protocol AccountsListByResourceGroup  {
    var nextLink: String? { get }
    var hasAdditionalPages : Bool { get }
    var headerParameters: [String: String] { get set }
    var subscriptionId : String { get set }
    var resourceGroupName : String { get set }
    var filter : String? { get set }
    var top : Int32? { get set }
    var skip : Int32? { get set }
    var select : String? { get set }
    var orderby : String? { get set }
    var count : Bool? { get set }
    var apiVersion : String { get set }
    func execute(client: RuntimeClient,
    completionHandler: @escaping (DataLakeStoreAccountListResultProtocol?, Error?) -> Void) -> Void ;
}

extension Commands.Accounts {
// ListByResourceGroup lists the Data Lake Store accounts within a specific resource group. The response includes a
// link to the next page of results, if any.
    internal class ListByResourceGroupCommand : BaseCommand, AccountsListByResourceGroup {
        var nextLink: String?
        public var hasAdditionalPages : Bool {
        get {
            return nextLink != nil
        }
    }
        public var subscriptionId : String
        public var resourceGroupName : String
        public var filter : String?
        public var top : Int32?
        public var skip : Int32?
        public var select : String?
        public var orderby : String?
        public var count : Bool?
        public var apiVersion = "2016-11-01"

        public init(subscriptionId: String, resourceGroupName: String) {
            self.subscriptionId = subscriptionId
            self.resourceGroupName = resourceGroupName
            super.init()
            self.method = "Get"
            self.isLongRunningOperation = false
            self.path = "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataLakeStore/accounts"
            self.headerParameters = ["Content-Type":"application/json; charset=utf-8"]
        }

        public override func preCall()  {
            self.pathParameters["{subscriptionId}"] = String(describing: self.subscriptionId)
            self.pathParameters["{resourceGroupName}"] = String(describing: self.resourceGroupName)
            if self.filter != nil { queryParameters["$filter"] = String(describing: self.filter!) }
            if self.top != nil { queryParameters["$top"] = String(describing: self.top!) }
            if self.skip != nil { queryParameters["$skip"] = String(describing: self.skip!) }
            if self.select != nil { queryParameters["$select"] = String(describing: self.select!) }
            if self.orderby != nil { queryParameters["$orderby"] = String(describing: self.orderby!) }
            if self.count != nil { queryParameters["$count"] = String(describing: self.count!) }
            self.queryParameters["api-version"] = String(describing: self.apiVersion)

        }

        public override func returnFunc(data: Data) throws -> Decodable? {
            let contentType = "application/json"
            if let mimeType = MimeType.getType(forStr: contentType) {
                let decoder = try CoderFactory.decoder(for: mimeType)
                if var pageDecoder = decoder as? PageDecoder {
                    pageDecoder.isPagedData = true
                    pageDecoder.nextLinkName = "NextLink"
                }
                let result = try decoder.decode(DataLakeStoreAccountListResultData?.self, from: data)
                if var pageDecoder = decoder as? PageDecoder {
                    self.nextLink = pageDecoder.nextLink
                }
                return result;
            }
            throw DecodeError.unknownMimeType
        }
        public func execute(client: RuntimeClient,
            completionHandler: @escaping (DataLakeStoreAccountListResultProtocol?, Error?) -> Void) -> Void {
            if self.nextLink != nil {
                self.path = nextLink!
                self.nextLink = nil;
                self.pathType = .absolute
            }
            client.executeAsync(command: self) {
                (result: DataLakeStoreAccountListResultData?, error: Error?) in
                completionHandler(result, error)
            }
        }
    }
}


import Foundation
import azureSwiftRuntime
public protocol AccountsUpdate  {
    var headerParameters: [String: String] { get set }
    var subscriptionId : String { get set }
    var resourceGroupName : String { get set }
    var accountName : String { get set }
    var apiVersion : String { get set }
    var parameters :  UpdateDataLakeStoreAccountParametersProtocol?  { get set }
    func execute(client: RuntimeClient,
    completionHandler: @escaping (DataLakeStoreAccountProtocol?, Error?) -> Void) -> Void ;
}

extension Commands.Accounts {
// Update updates the specified Data Lake Store account information. This method may poll for completion. Polling can
// be canceled by passing the cancel channel argument. The channel will be used to cancel polling and any outstanding
// HTTP requests.
    internal class UpdateCommand : BaseCommand, AccountsUpdate {
        public var subscriptionId : String
        public var resourceGroupName : String
        public var accountName : String
        public var apiVersion = "2016-11-01"
    public var parameters :  UpdateDataLakeStoreAccountParametersProtocol?

        public init(subscriptionId: String, resourceGroupName: String, accountName: String, parameters: UpdateDataLakeStoreAccountParametersProtocol) {
            self.subscriptionId = subscriptionId
            self.resourceGroupName = resourceGroupName
            self.accountName = accountName
            self.parameters = parameters
            super.init()
            self.method = "Patch"
            self.isLongRunningOperation = true
            self.path = "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataLakeStore/accounts/{accountName}"
            self.headerParameters = ["Content-Type":"application/json; charset=utf-8"]
        }

        public override func preCall()  {
            self.pathParameters["{subscriptionId}"] = String(describing: self.subscriptionId)
            self.pathParameters["{resourceGroupName}"] = String(describing: self.resourceGroupName)
            self.pathParameters["{accountName}"] = String(describing: self.accountName)
            self.queryParameters["api-version"] = String(describing: self.apiVersion)
            self.body = parameters

        }
        public override func encodeBody() throws -> Data? {
            let contentType = "application/json"
            if let mimeType = MimeType.getType(forStr: contentType) {
                let encoder = try CoderFactory.encoder(for: mimeType)
                let encodedValue = try encoder.encode(parameters as? UpdateDataLakeStoreAccountParametersData)
                return encodedValue
            }
            throw DecodeError.unknownMimeType
        }

        public override func returnFunc(data: Data) throws -> Decodable? {
            let contentType = "application/json"
            if let mimeType = MimeType.getType(forStr: contentType) {
                let decoder = try CoderFactory.decoder(for: mimeType)
                let result = try decoder.decode(DataLakeStoreAccountData?.self, from: data)
                return result;
            }
            throw DecodeError.unknownMimeType
        }
        public func execute(client: RuntimeClient,
            completionHandler: @escaping (DataLakeStoreAccountProtocol?, Error?) -> Void) -> Void {
            client.executeAsyncLRO(command: self) {
                (result: DataLakeStoreAccountData?, error: Error?) in
                completionHandler(result, error)
            }
        }
    }
}


// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License. See License.txt in the project root for license information.
//
// Code generated by Microsoft (R) AutoRest Code Generator.
public class DataFactory {
}
public class Commands {
}


// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License. See License.txt in the project root for license information.
//
// Code generated by Microsoft (R) AutoRest Code Generator.

// FirewallRules is the creates an Azure Data Lake Store account management client.
import Foundation
import azureSwiftRuntime
extension Commands {
public struct FirewallRules {
    public static func CreateOrUpdate(subscriptionId: String, resourceGroupName: String, accountName: String, firewallRuleName: String, parameters: CreateOrUpdateFirewallRuleParametersProtocol) -> FirewallRulesCreateOrUpdate {
        return CreateOrUpdateCommand(subscriptionId: subscriptionId, resourceGroupName: resourceGroupName, accountName: accountName, firewallRuleName: firewallRuleName, parameters: parameters)
    }
    public static func Delete(subscriptionId: String, resourceGroupName: String, accountName: String, firewallRuleName: String) -> FirewallRulesDelete {
        return DeleteCommand(subscriptionId: subscriptionId, resourceGroupName: resourceGroupName, accountName: accountName, firewallRuleName: firewallRuleName)
    }
    public static func Get(subscriptionId: String, resourceGroupName: String, accountName: String, firewallRuleName: String) -> FirewallRulesGet {
        return GetCommand(subscriptionId: subscriptionId, resourceGroupName: resourceGroupName, accountName: accountName, firewallRuleName: firewallRuleName)
    }
    public static func ListByAccount(subscriptionId: String, resourceGroupName: String, accountName: String) -> FirewallRulesListByAccount {
        return ListByAccountCommand(subscriptionId: subscriptionId, resourceGroupName: resourceGroupName, accountName: accountName)
    }
    public static func Update(subscriptionId: String, resourceGroupName: String, accountName: String, firewallRuleName: String) -> FirewallRulesUpdate {
        return UpdateCommand(subscriptionId: subscriptionId, resourceGroupName: resourceGroupName, accountName: accountName, firewallRuleName: firewallRuleName)
    }
}
}


import Foundation
import azureSwiftRuntime
public protocol FirewallRulesCreateOrUpdate  {
    var headerParameters: [String: String] { get set }
    var subscriptionId : String { get set }
    var resourceGroupName : String { get set }
    var accountName : String { get set }
    var firewallRuleName : String { get set }
    var apiVersion : String { get set }
    var parameters :  CreateOrUpdateFirewallRuleParametersProtocol?  { get set }
    func execute(client: RuntimeClient,
    completionHandler: @escaping (FirewallRuleProtocol?, Error?) -> Void) -> Void ;
}

extension Commands.FirewallRules {
// CreateOrUpdate creates or updates the specified firewall rule. During update, the firewall rule with the specified
// name will be replaced with this new firewall rule.
    internal class CreateOrUpdateCommand : BaseCommand, FirewallRulesCreateOrUpdate {
        public var subscriptionId : String
        public var resourceGroupName : String
        public var accountName : String
        public var firewallRuleName : String
        public var apiVersion = "2016-11-01"
    public var parameters :  CreateOrUpdateFirewallRuleParametersProtocol?

        public init(subscriptionId: String, resourceGroupName: String, accountName: String, firewallRuleName: String, parameters: CreateOrUpdateFirewallRuleParametersProtocol) {
            self.subscriptionId = subscriptionId
            self.resourceGroupName = resourceGroupName
            self.accountName = accountName
            self.firewallRuleName = firewallRuleName
            self.parameters = parameters
            super.init()
            self.method = "Put"
            self.isLongRunningOperation = false
            self.path = "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataLakeStore/accounts/{accountName}/firewallRules/{firewallRuleName}"
            self.headerParameters = ["Content-Type":"application/json; charset=utf-8"]
        }

        public override func preCall()  {
            self.pathParameters["{subscriptionId}"] = String(describing: self.subscriptionId)
            self.pathParameters["{resourceGroupName}"] = String(describing: self.resourceGroupName)
            self.pathParameters["{accountName}"] = String(describing: self.accountName)
            self.pathParameters["{firewallRuleName}"] = String(describing: self.firewallRuleName)
            self.queryParameters["api-version"] = String(describing: self.apiVersion)
            self.body = parameters

        }
        public override func encodeBody() throws -> Data? {
            let contentType = "application/json"
            if let mimeType = MimeType.getType(forStr: contentType) {
                let encoder = try CoderFactory.encoder(for: mimeType)
                let encodedValue = try encoder.encode(parameters as? CreateOrUpdateFirewallRuleParametersData)
                return encodedValue
            }
            throw DecodeError.unknownMimeType
        }

        public override func returnFunc(data: Data) throws -> Decodable? {
            let contentType = "application/json"
            if let mimeType = MimeType.getType(forStr: contentType) {
                let decoder = try CoderFactory.decoder(for: mimeType)
                let result = try decoder.decode(FirewallRuleData?.self, from: data)
                return result;
            }
            throw DecodeError.unknownMimeType
        }
        public func execute(client: RuntimeClient,
            completionHandler: @escaping (FirewallRuleProtocol?, Error?) -> Void) -> Void {
            client.executeAsync(command: self) {
                (result: FirewallRuleData?, error: Error?) in
                completionHandler(result, error)
            }
        }
    }
}


import Foundation
import azureSwiftRuntime
public protocol FirewallRulesDelete  {
    var headerParameters: [String: String] { get set }
    var subscriptionId : String { get set }
    var resourceGroupName : String { get set }
    var accountName : String { get set }
    var firewallRuleName : String { get set }
    var apiVersion : String { get set }
    func execute(client: RuntimeClient,
    completionHandler: @escaping (Error?) -> Void) -> Void;
}

extension Commands.FirewallRules {
// Delete deletes the specified firewall rule from the specified Data Lake Store account
    internal class DeleteCommand : BaseCommand, FirewallRulesDelete {
        public var subscriptionId : String
        public var resourceGroupName : String
        public var accountName : String
        public var firewallRuleName : String
        public var apiVersion = "2016-11-01"

        public init(subscriptionId: String, resourceGroupName: String, accountName: String, firewallRuleName: String) {
            self.subscriptionId = subscriptionId
            self.resourceGroupName = resourceGroupName
            self.accountName = accountName
            self.firewallRuleName = firewallRuleName
            super.init()
            self.method = "Delete"
            self.isLongRunningOperation = false
            self.path = "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataLakeStore/accounts/{accountName}/firewallRules/{firewallRuleName}"
            self.headerParameters = ["Content-Type":"application/json; charset=utf-8"]
        }

        public override func preCall()  {
            self.pathParameters["{subscriptionId}"] = String(describing: self.subscriptionId)
            self.pathParameters["{resourceGroupName}"] = String(describing: self.resourceGroupName)
            self.pathParameters["{accountName}"] = String(describing: self.accountName)
            self.pathParameters["{firewallRuleName}"] = String(describing: self.firewallRuleName)
            self.queryParameters["api-version"] = String(describing: self.apiVersion)

        }

        public func execute(client: RuntimeClient,
            completionHandler: @escaping (Error?) -> Void) -> Void {
            client.executeAsync(command: self) {
                (error) in
                completionHandler(error)
            }
        }
    }
}


import Foundation
import azureSwiftRuntime
public protocol FirewallRulesGet  {
    var headerParameters: [String: String] { get set }
    var subscriptionId : String { get set }
    var resourceGroupName : String { get set }
    var accountName : String { get set }
    var firewallRuleName : String { get set }
    var apiVersion : String { get set }
    func execute(client: RuntimeClient,
    completionHandler: @escaping (FirewallRuleProtocol?, Error?) -> Void) -> Void ;
}

extension Commands.FirewallRules {
// Get gets the specified Data Lake Store firewall rule.
    internal class GetCommand : BaseCommand, FirewallRulesGet {
        public var subscriptionId : String
        public var resourceGroupName : String
        public var accountName : String
        public var firewallRuleName : String
        public var apiVersion = "2016-11-01"

        public init(subscriptionId: String, resourceGroupName: String, accountName: String, firewallRuleName: String) {
            self.subscriptionId = subscriptionId
            self.resourceGroupName = resourceGroupName
            self.accountName = accountName
            self.firewallRuleName = firewallRuleName
            super.init()
            self.method = "Get"
            self.isLongRunningOperation = false
            self.path = "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataLakeStore/accounts/{accountName}/firewallRules/{firewallRuleName}"
            self.headerParameters = ["Content-Type":"application/json; charset=utf-8"]
        }

        public override func preCall()  {
            self.pathParameters["{subscriptionId}"] = String(describing: self.subscriptionId)
            self.pathParameters["{resourceGroupName}"] = String(describing: self.resourceGroupName)
            self.pathParameters["{accountName}"] = String(describing: self.accountName)
            self.pathParameters["{firewallRuleName}"] = String(describing: self.firewallRuleName)
            self.queryParameters["api-version"] = String(describing: self.apiVersion)

        }

        public override func returnFunc(data: Data) throws -> Decodable? {
            let contentType = "application/json"
            if let mimeType = MimeType.getType(forStr: contentType) {
                let decoder = try CoderFactory.decoder(for: mimeType)
                let result = try decoder.decode(FirewallRuleData?.self, from: data)
                return result;
            }
            throw DecodeError.unknownMimeType
        }
        public func execute(client: RuntimeClient,
            completionHandler: @escaping (FirewallRuleProtocol?, Error?) -> Void) -> Void {
            client.executeAsync(command: self) {
                (result: FirewallRuleData?, error: Error?) in
                completionHandler(result, error)
            }
        }
    }
}


import Foundation
import azureSwiftRuntime
public protocol FirewallRulesListByAccount  {
    var nextLink: String? { get }
    var hasAdditionalPages : Bool { get }
    var headerParameters: [String: String] { get set }
    var subscriptionId : String { get set }
    var resourceGroupName : String { get set }
    var accountName : String { get set }
    var apiVersion : String { get set }
    func execute(client: RuntimeClient,
    completionHandler: @escaping (FirewallRuleListResultProtocol?, Error?) -> Void) -> Void ;
}

extension Commands.FirewallRules {
// ListByAccount lists the Data Lake Store firewall rules within the specified Data Lake Store account.
    internal class ListByAccountCommand : BaseCommand, FirewallRulesListByAccount {
        var nextLink: String?
        public var hasAdditionalPages : Bool {
        get {
            return nextLink != nil
        }
    }
        public var subscriptionId : String
        public var resourceGroupName : String
        public var accountName : String
        public var apiVersion = "2016-11-01"

        public init(subscriptionId: String, resourceGroupName: String, accountName: String) {
            self.subscriptionId = subscriptionId
            self.resourceGroupName = resourceGroupName
            self.accountName = accountName
            super.init()
            self.method = "Get"
            self.isLongRunningOperation = false
            self.path = "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataLakeStore/accounts/{accountName}/firewallRules"
            self.headerParameters = ["Content-Type":"application/json; charset=utf-8"]
        }

        public override func preCall()  {
            self.pathParameters["{subscriptionId}"] = String(describing: self.subscriptionId)
            self.pathParameters["{resourceGroupName}"] = String(describing: self.resourceGroupName)
            self.pathParameters["{accountName}"] = String(describing: self.accountName)
            self.queryParameters["api-version"] = String(describing: self.apiVersion)

        }

        public override func returnFunc(data: Data) throws -> Decodable? {
            let contentType = "application/json"
            if let mimeType = MimeType.getType(forStr: contentType) {
                let decoder = try CoderFactory.decoder(for: mimeType)
                if var pageDecoder = decoder as? PageDecoder {
                    pageDecoder.isPagedData = true
                    pageDecoder.nextLinkName = "NextLink"
                }
                let result = try decoder.decode(FirewallRuleListResultData?.self, from: data)
                if var pageDecoder = decoder as? PageDecoder {
                    self.nextLink = pageDecoder.nextLink
                }
                return result;
            }
            throw DecodeError.unknownMimeType
        }
        public func execute(client: RuntimeClient,
            completionHandler: @escaping (FirewallRuleListResultProtocol?, Error?) -> Void) -> Void {
            if self.nextLink != nil {
                self.path = nextLink!
                self.nextLink = nil;
                self.pathType = .absolute
            }
            client.executeAsync(command: self) {
                (result: FirewallRuleListResultData?, error: Error?) in
                completionHandler(result, error)
            }
        }
    }
}


import Foundation
import azureSwiftRuntime
public protocol FirewallRulesUpdate  {
    var headerParameters: [String: String] { get set }
    var subscriptionId : String { get set }
    var resourceGroupName : String { get set }
    var accountName : String { get set }
    var firewallRuleName : String { get set }
    var apiVersion : String { get set }
    var parameters :  UpdateFirewallRuleParametersProtocol?  { get set }
    func execute(client: RuntimeClient,
    completionHandler: @escaping (FirewallRuleProtocol?, Error?) -> Void) -> Void ;
}

extension Commands.FirewallRules {
// Update updates the specified firewall rule.
    internal class UpdateCommand : BaseCommand, FirewallRulesUpdate {
        public var subscriptionId : String
        public var resourceGroupName : String
        public var accountName : String
        public var firewallRuleName : String
        public var apiVersion = "2016-11-01"
    public var parameters :  UpdateFirewallRuleParametersProtocol?

        public init(subscriptionId: String, resourceGroupName: String, accountName: String, firewallRuleName: String) {
            self.subscriptionId = subscriptionId
            self.resourceGroupName = resourceGroupName
            self.accountName = accountName
            self.firewallRuleName = firewallRuleName
            super.init()
            self.method = "Patch"
            self.isLongRunningOperation = false
            self.path = "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataLakeStore/accounts/{accountName}/firewallRules/{firewallRuleName}"
            self.headerParameters = ["Content-Type":"application/json; charset=utf-8"]
        }

        public override func preCall()  {
            self.pathParameters["{subscriptionId}"] = String(describing: self.subscriptionId)
            self.pathParameters["{resourceGroupName}"] = String(describing: self.resourceGroupName)
            self.pathParameters["{accountName}"] = String(describing: self.accountName)
            self.pathParameters["{firewallRuleName}"] = String(describing: self.firewallRuleName)
            self.queryParameters["api-version"] = String(describing: self.apiVersion)
            self.body = parameters

        }
        public override func encodeBody() throws -> Data? {
            let contentType = "application/json"
            if let mimeType = MimeType.getType(forStr: contentType) {
                let encoder = try CoderFactory.encoder(for: mimeType)
                let encodedValue = try encoder.encode(parameters as? UpdateFirewallRuleParametersData?)
                return encodedValue
            }
            throw DecodeError.unknownMimeType
        }

        public override func returnFunc(data: Data) throws -> Decodable? {
            let contentType = "application/json"
            if let mimeType = MimeType.getType(forStr: contentType) {
                let decoder = try CoderFactory.decoder(for: mimeType)
                let result = try decoder.decode(FirewallRuleData?.self, from: data)
                return result;
            }
            throw DecodeError.unknownMimeType
        }
        public func execute(client: RuntimeClient,
            completionHandler: @escaping (FirewallRuleProtocol?, Error?) -> Void) -> Void {
            client.executeAsync(command: self) {
                (result: FirewallRuleData?, error: Error?) in
                completionHandler(result, error)
            }
        }
    }
}


// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License. See License.txt in the project root for license information.
//
// Code generated by Microsoft (R) AutoRest Code Generator.

// Locations is the creates an Azure Data Lake Store account management client.
import Foundation
import azureSwiftRuntime
extension Commands {
public struct Locations {
    public static func GetCapability(subscriptionId: String, location: String) -> LocationsGetCapability {
        return GetCapabilityCommand(subscriptionId: subscriptionId, location: location)
    }
}
}


import Foundation
import azureSwiftRuntime
public protocol LocationsGetCapability  {
    var headerParameters: [String: String] { get set }
    var subscriptionId : String { get set }
    var location : String { get set }
    var apiVersion : String { get set }
    func execute(client: RuntimeClient,
    completionHandler: @escaping (CapabilityInformationProtocol?, Error?) -> Void) -> Void ;
}

extension Commands.Locations {
// GetCapability gets subscription-level properties and limits for Data Lake Store specified by resource location.
    internal class GetCapabilityCommand : BaseCommand, LocationsGetCapability {
        public var subscriptionId : String
        public var location : String
        public var apiVersion = "2016-11-01"

        public init(subscriptionId: String, location: String) {
            self.subscriptionId = subscriptionId
            self.location = location
            super.init()
            self.method = "Get"
            self.isLongRunningOperation = false
            self.path = "/subscriptions/{subscriptionId}/providers/Microsoft.DataLakeStore/locations/{location}/capability"
            self.headerParameters = ["Content-Type":"application/json; charset=utf-8"]
        }

        public override func preCall()  {
            self.pathParameters["{subscriptionId}"] = String(describing: self.subscriptionId)
            self.pathParameters["{location}"] = String(describing: self.location)
            self.queryParameters["api-version"] = String(describing: self.apiVersion)

        }

        public override func returnFunc(data: Data) throws -> Decodable? {
            let contentType = "application/json"
            if let mimeType = MimeType.getType(forStr: contentType) {
                let decoder = try CoderFactory.decoder(for: mimeType)
                let result = try decoder.decode(CapabilityInformationData?.self, from: data)
                return result;
            }
            throw DecodeError.unknownMimeType
        }
        public func execute(client: RuntimeClient,
            completionHandler: @escaping (CapabilityInformationProtocol?, Error?) -> Void) -> Void {
            client.executeAsync(command: self) {
                (result: CapabilityInformationData?, error: Error?) in
                completionHandler(result, error)
            }
        }
    }
}


// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License. See License.txt in the project root for license information.
//
// Code generated by Microsoft (R) AutoRest Code Generator.

// Operations is the creates an Azure Data Lake Store account management client.
import Foundation
import azureSwiftRuntime
extension Commands {
public struct Operations {
    public static func List() -> OperationsList {
        return ListCommand()
    }
}
}


import Foundation
import azureSwiftRuntime
public protocol OperationsList  {
    var headerParameters: [String: String] { get set }
    var apiVersion : String { get set }
    func execute(client: RuntimeClient,
    completionHandler: @escaping (OperationListResultProtocol?, Error?) -> Void) -> Void ;
}

extension Commands.Operations {
// List lists all of the available Data Lake Store REST API operations.
    internal class ListCommand : BaseCommand, OperationsList {
        public var apiVersion = "2016-11-01"

    public override init() {
            super.init()
            self.method = "Get"
            self.isLongRunningOperation = false
            self.path = "/providers/Microsoft.DataLakeStore/operations"
            self.headerParameters = ["Content-Type":"application/json; charset=utf-8"]
        }

        public override func preCall()  {
            self.queryParameters["api-version"] = String(describing: self.apiVersion)

        }

        public override func returnFunc(data: Data) throws -> Decodable? {
            let contentType = "application/json"
            if let mimeType = MimeType.getType(forStr: contentType) {
                let decoder = try CoderFactory.decoder(for: mimeType)
                let result = try decoder.decode(OperationListResultData?.self, from: data)
                return result;
            }
            throw DecodeError.unknownMimeType
        }
        public func execute(client: RuntimeClient,
            completionHandler: @escaping (OperationListResultProtocol?, Error?) -> Void) -> Void {
            client.executeAsync(command: self) {
                (result: OperationListResultData?, error: Error?) in
                completionHandler(result, error)
            }
        }
    }
}


// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License. See License.txt in the project root for license information.
//
// Code generated by Microsoft (R) AutoRest Code Generator.

// TrustedIdProviders is the creates an Azure Data Lake Store account management client.
import Foundation
import azureSwiftRuntime
extension Commands {
public struct TrustedIdProviders {
    public static func CreateOrUpdate(subscriptionId: String, resourceGroupName: String, accountName: String, trustedIdProviderName: String, parameters: CreateOrUpdateTrustedIdProviderParametersProtocol) -> TrustedIdProvidersCreateOrUpdate {
        return CreateOrUpdateCommand(subscriptionId: subscriptionId, resourceGroupName: resourceGroupName, accountName: accountName, trustedIdProviderName: trustedIdProviderName, parameters: parameters)
    }
    public static func Delete(subscriptionId: String, resourceGroupName: String, accountName: String, trustedIdProviderName: String) -> TrustedIdProvidersDelete {
        return DeleteCommand(subscriptionId: subscriptionId, resourceGroupName: resourceGroupName, accountName: accountName, trustedIdProviderName: trustedIdProviderName)
    }
    public static func Get(subscriptionId: String, resourceGroupName: String, accountName: String, trustedIdProviderName: String) -> TrustedIdProvidersGet {
        return GetCommand(subscriptionId: subscriptionId, resourceGroupName: resourceGroupName, accountName: accountName, trustedIdProviderName: trustedIdProviderName)
    }
    public static func ListByAccount(subscriptionId: String, resourceGroupName: String, accountName: String) -> TrustedIdProvidersListByAccount {
        return ListByAccountCommand(subscriptionId: subscriptionId, resourceGroupName: resourceGroupName, accountName: accountName)
    }
    public static func Update(subscriptionId: String, resourceGroupName: String, accountName: String, trustedIdProviderName: String) -> TrustedIdProvidersUpdate {
        return UpdateCommand(subscriptionId: subscriptionId, resourceGroupName: resourceGroupName, accountName: accountName, trustedIdProviderName: trustedIdProviderName)
    }
}
}


import Foundation
import azureSwiftRuntime
public protocol TrustedIdProvidersCreateOrUpdate  {
    var headerParameters: [String: String] { get set }
    var subscriptionId : String { get set }
    var resourceGroupName : String { get set }
    var accountName : String { get set }
    var trustedIdProviderName : String { get set }
    var apiVersion : String { get set }
    var parameters :  CreateOrUpdateTrustedIdProviderParametersProtocol?  { get set }
    func execute(client: RuntimeClient,
    completionHandler: @escaping (TrustedIdProviderProtocol?, Error?) -> Void) -> Void ;
}

extension Commands.TrustedIdProviders {
// CreateOrUpdate creates or updates the specified trusted identity provider. During update, the trusted identity
// provider with the specified name will be replaced with this new provider
    internal class CreateOrUpdateCommand : BaseCommand, TrustedIdProvidersCreateOrUpdate {
        public var subscriptionId : String
        public var resourceGroupName : String
        public var accountName : String
        public var trustedIdProviderName : String
        public var apiVersion = "2016-11-01"
    public var parameters :  CreateOrUpdateTrustedIdProviderParametersProtocol?

        public init(subscriptionId: String, resourceGroupName: String, accountName: String, trustedIdProviderName: String, parameters: CreateOrUpdateTrustedIdProviderParametersProtocol) {
            self.subscriptionId = subscriptionId
            self.resourceGroupName = resourceGroupName
            self.accountName = accountName
            self.trustedIdProviderName = trustedIdProviderName
            self.parameters = parameters
            super.init()
            self.method = "Put"
            self.isLongRunningOperation = false
            self.path = "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataLakeStore/accounts/{accountName}/trustedIdProviders/{trustedIdProviderName}"
            self.headerParameters = ["Content-Type":"application/json; charset=utf-8"]
        }

        public override func preCall()  {
            self.pathParameters["{subscriptionId}"] = String(describing: self.subscriptionId)
            self.pathParameters["{resourceGroupName}"] = String(describing: self.resourceGroupName)
            self.pathParameters["{accountName}"] = String(describing: self.accountName)
            self.pathParameters["{trustedIdProviderName}"] = String(describing: self.trustedIdProviderName)
            self.queryParameters["api-version"] = String(describing: self.apiVersion)
            self.body = parameters

        }
        public override func encodeBody() throws -> Data? {
            let contentType = "application/json"
            if let mimeType = MimeType.getType(forStr: contentType) {
                let encoder = try CoderFactory.encoder(for: mimeType)
                let encodedValue = try encoder.encode(parameters as? CreateOrUpdateTrustedIdProviderParametersData)
                return encodedValue
            }
            throw DecodeError.unknownMimeType
        }

        public override func returnFunc(data: Data) throws -> Decodable? {
            let contentType = "application/json"
            if let mimeType = MimeType.getType(forStr: contentType) {
                let decoder = try CoderFactory.decoder(for: mimeType)
                let result = try decoder.decode(TrustedIdProviderData?.self, from: data)
                return result;
            }
            throw DecodeError.unknownMimeType
        }
        public func execute(client: RuntimeClient,
            completionHandler: @escaping (TrustedIdProviderProtocol?, Error?) -> Void) -> Void {
            client.executeAsync(command: self) {
                (result: TrustedIdProviderData?, error: Error?) in
                completionHandler(result, error)
            }
        }
    }
}


import Foundation
import azureSwiftRuntime
public protocol TrustedIdProvidersDelete  {
    var headerParameters: [String: String] { get set }
    var subscriptionId : String { get set }
    var resourceGroupName : String { get set }
    var accountName : String { get set }
    var trustedIdProviderName : String { get set }
    var apiVersion : String { get set }
    func execute(client: RuntimeClient,
    completionHandler: @escaping (Error?) -> Void) -> Void;
}

extension Commands.TrustedIdProviders {
// Delete deletes the specified trusted identity provider from the specified Data Lake Store account
    internal class DeleteCommand : BaseCommand, TrustedIdProvidersDelete {
        public var subscriptionId : String
        public var resourceGroupName : String
        public var accountName : String
        public var trustedIdProviderName : String
        public var apiVersion = "2016-11-01"

        public init(subscriptionId: String, resourceGroupName: String, accountName: String, trustedIdProviderName: String) {
            self.subscriptionId = subscriptionId
            self.resourceGroupName = resourceGroupName
            self.accountName = accountName
            self.trustedIdProviderName = trustedIdProviderName
            super.init()
            self.method = "Delete"
            self.isLongRunningOperation = false
            self.path = "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataLakeStore/accounts/{accountName}/trustedIdProviders/{trustedIdProviderName}"
            self.headerParameters = ["Content-Type":"application/json; charset=utf-8"]
        }

        public override func preCall()  {
            self.pathParameters["{subscriptionId}"] = String(describing: self.subscriptionId)
            self.pathParameters["{resourceGroupName}"] = String(describing: self.resourceGroupName)
            self.pathParameters["{accountName}"] = String(describing: self.accountName)
            self.pathParameters["{trustedIdProviderName}"] = String(describing: self.trustedIdProviderName)
            self.queryParameters["api-version"] = String(describing: self.apiVersion)

        }

        public func execute(client: RuntimeClient,
            completionHandler: @escaping (Error?) -> Void) -> Void {
            client.executeAsync(command: self) {
                (error) in
                completionHandler(error)
            }
        }
    }
}


import Foundation
import azureSwiftRuntime
public protocol TrustedIdProvidersGet  {
    var headerParameters: [String: String] { get set }
    var subscriptionId : String { get set }
    var resourceGroupName : String { get set }
    var accountName : String { get set }
    var trustedIdProviderName : String { get set }
    var apiVersion : String { get set }
    func execute(client: RuntimeClient,
    completionHandler: @escaping (TrustedIdProviderProtocol?, Error?) -> Void) -> Void ;
}

extension Commands.TrustedIdProviders {
// Get gets the specified Data Lake Store trusted identity provider.
    internal class GetCommand : BaseCommand, TrustedIdProvidersGet {
        public var subscriptionId : String
        public var resourceGroupName : String
        public var accountName : String
        public var trustedIdProviderName : String
        public var apiVersion = "2016-11-01"

        public init(subscriptionId: String, resourceGroupName: String, accountName: String, trustedIdProviderName: String) {
            self.subscriptionId = subscriptionId
            self.resourceGroupName = resourceGroupName
            self.accountName = accountName
            self.trustedIdProviderName = trustedIdProviderName
            super.init()
            self.method = "Get"
            self.isLongRunningOperation = false
            self.path = "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/Microsoft.DataLakeStore/accounts/{accountName}/trustedIdProviders/{trustedIdProviderName}"
            self.headerParameters = ["Content-Type":"application/json; charset=utf-8"]
        }

        public override func preCall()  {
            self.pathParameters["{subscriptionId}"] = String(describing: self.subscriptionId)
            self.pathParameters["{resourceGroupName}"] = String(describing: self.resourceGroupName)
            self.pathParameters["{accountName}"] = String(describing: self.accountName)
            self.pathParameters["{trustedIdProviderName}"] = String(describing: self.trustedIdProviderName)
            self.queryParameters["api-version"] = String(describing: self.apiVersion)

        }

        public override func returnFunc(data: Data) throws -> Decodable? {
            let contentType = "application/json"
            if let mimeType = MimeType.getType(forStr: contentType) {
                let decoder = try CoderFactory.decoder(for: mimeType)
                let result = try decoder.decode(TrustedIdProviderData?.self, from: data)
                return result;
            }
            throw DecodeError.unknownMimeType
        }
        public func execute(client: RuntimeClient,
            completionHandler: @escaping (TrustedIdProviderProtocol?, Error?) -> Void) -> Void {
            client.executeAsync(command: self) {
                (result: TrustedIdProviderData?, error: Error?) in
                completionHandler(result, error)
            }
        }
    }
}