public PatchGateway ( string resourceGroupName, string dataFactoryName, |
||
resourceGroupName | string | |
dataFactoryName | string | |
gateway | ||
return |
public virtual PSDataFactoryGateway PatchGateway(string resourceGroupName, string dataFactoryName, PSDataFactoryGateway gateway)
{
if (gateway == null)
{
throw new ArgumentNullException("gateway");
}
var response = DataPipelineManagementClient.Gateways.Update(
resourceGroupName, dataFactoryName, new GatewayCreateOrUpdateParameters { Gateway = gateway.ToGatewayDefinition() });
return new PSDataFactoryGateway(response.Gateway);
}
public override void ExecuteCmdlet() { if (ParameterSetName == ByFactoryObject) { if (DataFactory == null) { throw new PSArgumentNullException(string.Format(CultureInfo.InvariantCulture, Resources.DataFactoryArgumentInvalid)); } DataFactoryName = DataFactory.DataFactoryName; ResourceGroupName = DataFactory.ResourceGroupName; } PSDataFactoryGateway gateway = new PSDataFactoryGateway { Description = Description, Name = Name }; PSDataFactoryGateway response = DataFactoryClient.PatchGateway(ResourceGroupName, DataFactoryName, gateway); WriteObject(response); }