BorderRouter.addPolicyRule()
Method
Declaration
PolicyRuleaddPolicyRule
(
java.lang.String fromInterface,
java.lang.String toInterface,
java.lang.String subject,
boolean firstBorder)
throws ConfigurationException
PolicyRuleaddPolicyRule
(
java.lang.String fromInterface,
java.lang.String toInterface,
java.lang.String[] subjects,
boolean firstBorder)
throws ConfigurationException
Purpose
Add a policy rule for a pair of interfaces.
Remarks
Use the first form to add only one subject. Use the second form to add several subjects with one method call. (The first form calls the second form with an array of one element.)
If a policy rule already exists for the From/To pair, then this method (first form) behaves like PolicyRule.addAllowedSubject()—it attempts to add the new subject to the existing rule.
• | If the subject does not already exist in the rule, then the method adds it. |
• | If the subject already exists in the rule, then the method throws a ConfigurationException; the rule and subject remain unchanged. |
Parameter |
Description |
fromInterface |
Supply the From-Interface for the new policy rule. |
toInterface |
Supply the To-Interface for the new policy rule. |
subject |
Specify a subject for which this rule permits forwarding across the two interfaces. |
subjects |
Specify an array of subjects for which this rule permits forwarding across the two interfaces. |
firstBorder |
When When This property applies to all the subjects that this method adds. It does not affect pre-existing subjects. |
See Also
BorderRouter.removePolicyRule()
For the corresponding browser pages and background information, see Border Routing in