<reponame>AlexGhiondea/azure-sdk-for-java
/**
 * 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.
 */

package com.microsoft.azure.management.datafactory.v2018_06_01;

import com.fasterxml.jackson.annotation.JsonProperty;
import com.fasterxml.jackson.annotation.JsonTypeInfo;
import com.fasterxml.jackson.annotation.JsonTypeName;
import com.microsoft.rest.serializer.JsonFlatten;
import com.microsoft.azure.management.datafactory.v2018_06_01.implementation.LinkedServiceInner;

/**
 * Azure File Storage linked service.
 */
@JsonTypeInfo(use = JsonTypeInfo.Id.NAME, include = JsonTypeInfo.As.PROPERTY, property = "type", defaultImpl = AzureFileStorageLinkedService.class)
@JsonTypeName("AzureFileStorage")
@JsonFlatten
public class AzureFileStorageLinkedService extends LinkedServiceInner {
    /**
     * Host name of the server. Type: string (or Expression with resultType
     * string).
     */
    @JsonProperty(value = "typeProperties.host")
    private Object host;

    /**
     * User ID to logon the server. Type: string (or Expression with resultType
     * string).
     */
    @JsonProperty(value = "typeProperties.userId")
    private Object userId;

    /**
     * Password to logon the server.
     */
    @JsonProperty(value = "typeProperties.password")
    private SecretBase password;

    /**
     * The connection string. It is mutually exclusive with sasUri property.
     * Type: string, SecureString or AzureKeyVaultSecretReference.
     */
    @JsonProperty(value = "typeProperties.connectionString")
    private Object connectionString;

    /**
     * The Azure key vault secret reference of accountKey in connection string.
     */
    @JsonProperty(value = "typeProperties.accountKey")
    private AzureKeyVaultSecretReference accountKey;

    /**
     * SAS URI of the Azure File resource. It is mutually exclusive with
     * connectionString property. Type: string, SecureString or
     * AzureKeyVaultSecretReference.
     */
    @JsonProperty(value = "typeProperties.sasUri")
    private Object sasUri;

    /**
     * The Azure key vault secret reference of sasToken in sas uri.
     */
    @JsonProperty(value = "typeProperties.sasToken")
    private AzureKeyVaultSecretReference sasToken;

    /**
     * The azure file share name. It is required when auth with
     * accountKey/sasToken. Type: string (or Expression with resultType
     * string).
     */
    @JsonProperty(value = "typeProperties.fileShare")
    private Object fileShare;

    /**
     * The encrypted credential used for authentication. Credentials are
     * encrypted using the integration runtime credential manager. Type: string
     * (or Expression with resultType string).
     */
    @JsonProperty(value = "typeProperties.encryptedCredential")
    private Object encryptedCredential;

    /**
     * Get host name of the server. Type: string (or Expression with resultType string).
     *
     * @return the host value
     */
    public Object host() {
        return this.host;
    }

    /**
     * Set host name of the server. Type: string (or Expression with resultType string).
     *
     * @param host the host value to set
     * @return the AzureFileStorageLinkedService object itself.
     */
    public AzureFileStorageLinkedService withHost(Object host) {
        this.host = host;
        return this;
    }

    /**
     * Get user ID to logon the server. Type: string (or Expression with resultType string).
     *
     * @return the userId value
     */
    public Object userId() {
        return this.userId;
    }

    /**
     * Set user ID to logon the server. Type: string (or Expression with resultType string).
     *
     * @param userId the userId value to set
     * @return the AzureFileStorageLinkedService object itself.
     */
    public AzureFileStorageLinkedService withUserId(Object userId) {
        this.userId = userId;
        return this;
    }

    /**
     * Get password to logon the server.
     *
     * @return the password value
     */
    public SecretBase password() {
        return this.password;
    }

    /**
     * Set password to logon the server.
     *
     * @param password the password value to set
     * @return the AzureFileStorageLinkedService object itself.
     */
    public AzureFileStorageLinkedService withPassword(SecretBase password) {
        this.password = password;
        return this;
    }

    /**
     * Get the connection string. It is mutually exclusive with sasUri property. Type: string, SecureString or AzureKeyVaultSecretReference.
     *
     * @return the connectionString value
     */
    public Object connectionString() {
        return this.connectionString;
    }

    /**
     * Set the connection string. It is mutually exclusive with sasUri property. Type: string, SecureString or AzureKeyVaultSecretReference.
     *
     * @param connectionString the connectionString value to set
     * @return the AzureFileStorageLinkedService object itself.
     */
    public AzureFileStorageLinkedService withConnectionString(Object connectionString) {
        this.connectionString = connectionString;
        return this;
    }

    /**
     * Get the Azure key vault secret reference of accountKey in connection string.
     *
     * @return the accountKey value
     */
    public AzureKeyVaultSecretReference accountKey() {
        return this.accountKey;
    }

    /**
     * Set the Azure key vault secret reference of accountKey in connection string.
     *
     * @param accountKey the accountKey value to set
     * @return the AzureFileStorageLinkedService object itself.
     */
    public AzureFileStorageLinkedService withAccountKey(AzureKeyVaultSecretReference accountKey) {
        this.accountKey = accountKey;
        return this;
    }

    /**
     * Get sAS URI of the Azure File resource. It is mutually exclusive with connectionString property. Type: string, SecureString or AzureKeyVaultSecretReference.
     *
     * @return the sasUri value
     */
    public Object sasUri() {
        return this.sasUri;
    }

    /**
     * Set sAS URI of the Azure File resource. It is mutually exclusive with connectionString property. Type: string, SecureString or AzureKeyVaultSecretReference.
     *
     * @param sasUri the sasUri value to set
     * @return the AzureFileStorageLinkedService object itself.
     */
    public AzureFileStorageLinkedService withSasUri(Object sasUri) {
        this.sasUri = sasUri;
        return this;
    }

    /**
     * Get the Azure key vault secret reference of sasToken in sas uri.
     *
     * @return the sasToken value
     */
    public AzureKeyVaultSecretReference sasToken() {
        return this.sasToken;
    }

    /**
     * Set the Azure key vault secret reference of sasToken in sas uri.
     *
     * @param sasToken the sasToken value to set
     * @return the AzureFileStorageLinkedService object itself.
     */
    public AzureFileStorageLinkedService withSasToken(AzureKeyVaultSecretReference sasToken) {
        this.sasToken = sasToken;
        return this;
    }

    /**
     * Get the azure file share name. It is required when auth with accountKey/sasToken. Type: string (or Expression with resultType string).
     *
     * @return the fileShare value
     */
    public Object fileShare() {
        return this.fileShare;
    }

    /**
     * Set the azure file share name. It is required when auth with accountKey/sasToken. Type: string (or Expression with resultType string).
     *
     * @param fileShare the fileShare value to set
     * @return the AzureFileStorageLinkedService object itself.
     */
    public AzureFileStorageLinkedService withFileShare(Object fileShare) {
        this.fileShare = fileShare;
        return this;
    }

    /**
     * Get the encrypted credential used for authentication. Credentials are encrypted using the integration runtime credential manager. Type: string (or Expression with resultType string).
     *
     * @return the encryptedCredential value
     */
    public Object encryptedCredential() {
        return this.encryptedCredential;
    }

    /**
     * Set the encrypted credential used for authentication. Credentials are encrypted using the integration runtime credential manager. Type: string (or Expression with resultType string).
     *
     * @param encryptedCredential the encryptedCredential value to set
     * @return the AzureFileStorageLinkedService object itself.
     */
    public AzureFileStorageLinkedService withEncryptedCredential(Object encryptedCredential) {
        this.encryptedCredential = encryptedCredential;
        return this;
    }

}
