GetServer() 공개 메소드

Gets a server in a resource group
public GetServer ( string resourceGroupName, string serverName ) : Microsoft.Azure.Commands.Sql.Server.Model.AzureSqlServerModel
resourceGroupName string The name of the resource group
serverName string The name of the server
리턴 Microsoft.Azure.Commands.Sql.Server.Model.AzureSqlServerModel
 /// <summary>
 /// Gets the Location of the server.
 /// </summary>
 /// <param name="resourceGroupName">The resource group the server is in</param>
 /// <param name="serverName">The name of the server</param>
 /// <returns></returns>
 public string GetServerLocation(string resourceGroupName, string serverName)
 {
     AzureSqlServerAdapter serverAdapter = new AzureSqlServerAdapter(Profile, _subscription);
     var server = serverAdapter.GetServer(resourceGroupName, serverName);
     return server.Location;
 }
 /// <summary>
 /// Gets the Location of the server.
 /// </summary>
 /// <param name="resourceGroupName">The resource group the server is in</param>
 /// <param name="serverName">The name of the server</param>
 /// <returns></returns>
 public string GetServerLocation(string resourceGroupName, string serverName)
 {
     AzureSqlServerAdapter serverAdapter = new AzureSqlServerAdapter(Context);
     var server = serverAdapter.GetServer(resourceGroupName, serverName);
     return server.Location;
 }