Class JobTarget
- java.lang.Object
-
- com.azure.resourcemanager.sql.models.JobTarget
-
public final class JobTarget extends Object
A job target, for example a specific database or a container of databases that is evaluated during job execution.
-
-
Constructor Summary
Constructors Constructor Description JobTarget()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description StringdatabaseName()Get the databaseName property: The target database name.StringelasticPoolName()Get the elasticPoolName property: The target elastic pool name.JobTargetGroupMembershipTypemembershipType()Get the membershipType property: Whether the target is included or excluded from the group.StringrefreshCredential()Get the refreshCredential property: The resource ID of the credential that is used during job execution to connect to the target and determine the list of databases inside the target.StringserverName()Get the serverName property: The target server name.StringshardMapName()Get the shardMapName property: The target shard map.JobTargetTypetype()Get the type property: The target type.voidvalidate()Validates the instance.JobTargetwithDatabaseName(String databaseName)Set the databaseName property: The target database name.JobTargetwithElasticPoolName(String elasticPoolName)Set the elasticPoolName property: The target elastic pool name.JobTargetwithMembershipType(JobTargetGroupMembershipType membershipType)Set the membershipType property: Whether the target is included or excluded from the group.JobTargetwithRefreshCredential(String refreshCredential)Set the refreshCredential property: The resource ID of the credential that is used during job execution to connect to the target and determine the list of databases inside the target.JobTargetwithServerName(String serverName)Set the serverName property: The target server name.JobTargetwithShardMapName(String shardMapName)Set the shardMapName property: The target shard map.JobTargetwithType(JobTargetType type)Set the type property: The target type.
-
-
-
Method Detail
-
membershipType
public JobTargetGroupMembershipType membershipType()
Get the membershipType property: Whether the target is included or excluded from the group.- Returns:
- the membershipType value.
-
withMembershipType
public JobTarget withMembershipType(JobTargetGroupMembershipType membershipType)
Set the membershipType property: Whether the target is included or excluded from the group.- Parameters:
membershipType- the membershipType value to set.- Returns:
- the JobTarget object itself.
-
type
public JobTargetType type()
Get the type property: The target type.- Returns:
- the type value.
-
withType
public JobTarget withType(JobTargetType type)
Set the type property: The target type.- Parameters:
type- the type value to set.- Returns:
- the JobTarget object itself.
-
serverName
public String serverName()
Get the serverName property: The target server name.- Returns:
- the serverName value.
-
withServerName
public JobTarget withServerName(String serverName)
Set the serverName property: The target server name.- Parameters:
serverName- the serverName value to set.- Returns:
- the JobTarget object itself.
-
databaseName
public String databaseName()
Get the databaseName property: The target database name.- Returns:
- the databaseName value.
-
withDatabaseName
public JobTarget withDatabaseName(String databaseName)
Set the databaseName property: The target database name.- Parameters:
databaseName- the databaseName value to set.- Returns:
- the JobTarget object itself.
-
elasticPoolName
public String elasticPoolName()
Get the elasticPoolName property: The target elastic pool name.- Returns:
- the elasticPoolName value.
-
withElasticPoolName
public JobTarget withElasticPoolName(String elasticPoolName)
Set the elasticPoolName property: The target elastic pool name.- Parameters:
elasticPoolName- the elasticPoolName value to set.- Returns:
- the JobTarget object itself.
-
shardMapName
public String shardMapName()
Get the shardMapName property: The target shard map.- Returns:
- the shardMapName value.
-
withShardMapName
public JobTarget withShardMapName(String shardMapName)
Set the shardMapName property: The target shard map.- Parameters:
shardMapName- the shardMapName value to set.- Returns:
- the JobTarget object itself.
-
refreshCredential
public String refreshCredential()
Get the refreshCredential property: The resource ID of the credential that is used during job execution to connect to the target and determine the list of databases inside the target.- Returns:
- the refreshCredential value.
-
withRefreshCredential
public JobTarget withRefreshCredential(String refreshCredential)
Set the refreshCredential property: The resource ID of the credential that is used during job execution to connect to the target and determine the list of databases inside the target.- Parameters:
refreshCredential- the refreshCredential value to set.- Returns:
- the JobTarget object itself.
-
validate
public void validate()
Validates the instance.- Throws:
IllegalArgumentException- thrown if the instance is not valid.
-
-