public override void ExecuteCmdlet()
{
base.ExecuteCmdlet();
if (!string.IsNullOrEmpty(this.Name))
{
var frontendPort =
this.ApplicationGateway.FrontendPorts.First(
resource =>
string.Equals(resource.Name, this.Name, System.StringComparison.CurrentCultureIgnoreCase));
WriteObject(frontendPort);
}
else
{
var frontendPorts = this.ApplicationGateway.FrontendPorts;
WriteObject(frontendPorts, true);
}
}
}