Package com.sun.xml.ws.policy
Class PolicyMerger
java.lang.Object
com.sun.xml.ws.policy.PolicyMerger
Merge policies and return the effective policy.
WS-PolicyAttachment defines a merge algorithm for WSDL 1.1 policy attachments.
-
Method Summary
Modifier and TypeMethodDescriptionstatic PolicyMergerFactory method for obtaining thread-safe policy merger instance.merge(Collection<Policy> policies) Takes collection of policies and merges them into a single policy using algorithm described in WS-PolicyAttachment specification.
-
Method Details
-
getMerger
Factory method for obtaining thread-safe policy merger instance.- Returns:
- policy merger instance.
-
merge
Takes collection of policies and merges them into a single policy using algorithm described in WS-PolicyAttachment specification. None of the original policies in the collection are modified in any way. The newly created policy has an ID that is a concatentation of all merged policy IDs.- Parameters:
policies- collection of policies to be merged. The collection must not contain 'null' elements!- Returns:
- merged policy containing combination of policy alternatives stored in all input policies.
If provided collection of policies is
nullor empty, returnsnull. If provided collection of policies contains only single policy, the policy is returned.
-