Class SqlConnectionInfo

java.lang.Object
com.azure.resourcemanager.datamigration.models.ConnectionInfo
com.azure.resourcemanager.datamigration.models.SqlConnectionInfo

public final class SqlConnectionInfo extends ConnectionInfo
Information for connecting to SQL database server.
  • Constructor Details

    • SqlConnectionInfo

      public SqlConnectionInfo()
      Creates an instance of SqlConnectionInfo class.
  • Method Details

    • dataSource

      public String dataSource()
      Get the dataSource property: Data source in the format Protocol:MachineName\SQLServerInstanceName,PortNumber.
      Returns:
      the dataSource value.
    • withDataSource

      public SqlConnectionInfo withDataSource(String dataSource)
      Set the dataSource property: Data source in the format Protocol:MachineName\SQLServerInstanceName,PortNumber.
      Parameters:
      dataSource - the dataSource value to set.
      Returns:
      the SqlConnectionInfo object itself.
    • authentication

      public AuthenticationType authentication()
      Get the authentication property: Authentication type to use for connection.
      Returns:
      the authentication value.
    • withAuthentication

      public SqlConnectionInfo withAuthentication(AuthenticationType authentication)
      Set the authentication property: Authentication type to use for connection.
      Parameters:
      authentication - the authentication value to set.
      Returns:
      the SqlConnectionInfo object itself.
    • encryptConnection

      public Boolean encryptConnection()
      Get the encryptConnection property: Whether to encrypt the connection.
      Returns:
      the encryptConnection value.
    • withEncryptConnection

      public SqlConnectionInfo withEncryptConnection(Boolean encryptConnection)
      Set the encryptConnection property: Whether to encrypt the connection.
      Parameters:
      encryptConnection - the encryptConnection value to set.
      Returns:
      the SqlConnectionInfo object itself.
    • additionalSettings

      public String additionalSettings()
      Get the additionalSettings property: Additional connection settings.
      Returns:
      the additionalSettings value.
    • withAdditionalSettings

      public SqlConnectionInfo withAdditionalSettings(String additionalSettings)
      Set the additionalSettings property: Additional connection settings.
      Parameters:
      additionalSettings - the additionalSettings value to set.
      Returns:
      the SqlConnectionInfo object itself.
    • trustServerCertificate

      public Boolean trustServerCertificate()
      Get the trustServerCertificate property: Whether to trust the server certificate.
      Returns:
      the trustServerCertificate value.
    • withTrustServerCertificate

      public SqlConnectionInfo withTrustServerCertificate(Boolean trustServerCertificate)
      Set the trustServerCertificate property: Whether to trust the server certificate.
      Parameters:
      trustServerCertificate - the trustServerCertificate value to set.
      Returns:
      the SqlConnectionInfo object itself.
    • platform

      public SqlSourcePlatform platform()
      Get the platform property: Server platform type for connection.
      Returns:
      the platform value.
    • withPlatform

      public SqlConnectionInfo withPlatform(SqlSourcePlatform platform)
      Set the platform property: Server platform type for connection.
      Parameters:
      platform - the platform value to set.
      Returns:
      the SqlConnectionInfo object itself.
    • withUsername

      public SqlConnectionInfo withUsername(String username)
      Set the username property: User name.
      Overrides:
      withUsername in class ConnectionInfo
      Parameters:
      username - the username value to set.
      Returns:
      the ConnectionInfo object itself.
    • withPassword

      public SqlConnectionInfo withPassword(String password)
      Set the password property: Password credential.
      Overrides:
      withPassword in class ConnectionInfo
      Parameters:
      password - the password value to set.
      Returns:
      the ConnectionInfo object itself.
    • validate

      public void validate()
      Validates the instance.
      Overrides:
      validate in class ConnectionInfo
      Throws:
      IllegalArgumentException - thrown if the instance is not valid.