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;
}
PSDataFactoryGatewayKey gatewayKey = DataFactoryClient.RegenerateGatewayKey(ResourceGroupName, DataFactoryName, GatewayName);
WriteObject(gatewayKey);
}
}