use of com.sun.xml.ws.api.policy.ModelTranslator in project metro-jax-ws by eclipse-ee4j.
the class AlternativeSelectorTest method setUp.
@Override
protected void setUp() throws PolicyException {
final PolicySourceModel model = PolicySourceModel.createPolicySourceModel(NamespaceVersion.v1_5, "id", null);
final ModelNode root = model.getRootNode();
final ModelNode alternatives = root.createChildExactlyOneNode();
final ModelNode alternative1 = alternatives.createChildAllNode();
final ModelNode alternative2 = alternatives.createChildAllNode();
final AssertionData assertion1 = AssertionData.createAssertionData(assertion1Name);
alternative1.createChildAssertionNode(assertion1);
final AssertionData assertion2 = AssertionData.createAssertionData(assertion2Name);
alternative2.createChildAssertionNode(assertion2);
final ModelTranslator translator = ModelTranslator.getTranslator();
this.multipleAlternativesPolicy = translator.translate(model);
}
Aggregations