private void ResetAll() { applicationRuleCollection = null; natRuleCollection = null; networkRuleCollection = null; ipConfiguration = null; applicationRule = null; natRule = null; networkRule = null; }
private AzureFirewallImpl DefineAzureFirewallNatRuleCollection(string name) { natRuleCollection = new AzureFirewallNatRuleCollectionInner { Name = name }; if (Inner.NatRuleCollections == null) { Inner.NatRuleCollections = new List <AzureFirewallNatRuleCollectionInner>(); } return(this); }
AzureFirewall.Definition.IWithCreate IInDefinition <AzureFirewall.Definition.IWithCreate> .Attach() { if (applicationRuleCollection != null) { Inner.ApplicationRuleCollections.Add(applicationRuleCollection); applicationRuleCollection = null; } else if (natRuleCollection != null) { Inner.NatRuleCollections.Add(natRuleCollection); natRuleCollection = null; } else if (networkRuleCollection != null) { Inner.NetworkRuleCollections.Add(networkRuleCollection); networkRuleCollection = null; } else if (ipConfiguration != null) { Inner.IpConfigurations.Add(ipConfiguration); ipConfiguration = null; } return(this); }