public DeliveryRuleHttpVersionCondition(HttpVersionMatchCondition properties) { if (properties == null) { throw new ArgumentNullException(nameof(properties)); } Properties = properties; Name = MatchVariable.HttpVersion; }
internal static DeliveryRuleHttpVersionCondition DeserializeDeliveryRuleHttpVersionCondition(JsonElement element) { HttpVersionMatchCondition parameters = default; MatchVariable name = default; foreach (var property in element.EnumerateObject()) { if (property.NameEquals("parameters")) { parameters = HttpVersionMatchCondition.DeserializeHttpVersionMatchCondition(property.Value); continue; } if (property.NameEquals("name")) { name = new MatchVariable(property.Value.GetString()); continue; } } return(new DeliveryRuleHttpVersionCondition(name, parameters)); }
internal DeliveryRuleHttpVersionCondition(MatchVariable name, HttpVersionMatchCondition properties) : base(name) { Properties = properties; Name = name; }