DeliveryRule Class

  • java.lang.Object
    • com.azure.resourcemanager.cdn.models.DeliveryRule

public final class DeliveryRule

A rule that specifies a set of actions and conditions.

Constructor Summary

Constructor Description
DeliveryRule()

Creates an instance of DeliveryRule class.

Method Summary

Modifier and Type Method and Description
List<DeliveryRuleAction> actions()

Get the actions property: A list of actions that are executed when all the conditions of a rule are satisfied.

List<DeliveryRuleCondition> conditions()

Get the conditions property: A list of conditions that must be matched for the actions to be executed.

String name()

Get the name property: Name of the rule.

int order()

Get the order property: The order in which the rules are applied for the endpoint.

void validate()

Validates the instance.

DeliveryRule withActions(List<DeliveryRuleAction> actions)

Set the actions property: A list of actions that are executed when all the conditions of a rule are satisfied.

DeliveryRule withConditions(List<DeliveryRuleCondition> conditions)

Set the conditions property: A list of conditions that must be matched for the actions to be executed.

DeliveryRule withName(String name)

Set the name property: Name of the rule.

DeliveryRule withOrder(int order)

Set the order property: The order in which the rules are applied for the endpoint.

Methods inherited from java.lang.Object

Constructor Details

DeliveryRule

public DeliveryRule()

Creates an instance of DeliveryRule class.

Method Details

actions

public List actions()

Get the actions property: A list of actions that are executed when all the conditions of a rule are satisfied.

Returns:

the actions value.

conditions

public List conditions()

Get the conditions property: A list of conditions that must be matched for the actions to be executed.

Returns:

the conditions value.

name

public String name()

Get the name property: Name of the rule.

Returns:

the name value.

order

public int order()

Get the order property: The order in which the rules are applied for the endpoint. Possible values {0,1,2,3,\u2026\u2026\u2026}. A rule with a lesser order will be applied before a rule with a greater order. Rule with order 0 is a special rule. It does not require any condition and actions listed in it will always be applied.

Returns:

the order value.

validate

public void validate()

Validates the instance.

withActions

public DeliveryRule withActions(List actions)

Set the actions property: A list of actions that are executed when all the conditions of a rule are satisfied.

Parameters:

actions - the actions value to set.

Returns:

the DeliveryRule object itself.

withConditions

public DeliveryRule withConditions(List conditions)

Set the conditions property: A list of conditions that must be matched for the actions to be executed.

Parameters:

conditions - the conditions value to set.

Returns:

the DeliveryRule object itself.

withName

public DeliveryRule withName(String name)

Set the name property: Name of the rule.

Parameters:

name - the name value to set.

Returns:

the DeliveryRule object itself.

withOrder

public DeliveryRule withOrder(int order)

Set the order property: The order in which the rules are applied for the endpoint. Possible values {0,1,2,3,\u2026\u2026\u2026}. A rule with a lesser order will be applied before a rule with a greater order. Rule with order 0 is a special rule. It does not require any condition and actions listed in it will always be applied.

Parameters:

order - the order value to set.

Returns:

the DeliveryRule object itself.

Applies to