* of the implementation is not dictated by the hard coded configuration of the
* model. This build runs before the policy builders where this information is used
* TODO - can we get this code into the actual impl modules itself. Move this builder?
*/
List<DefaultIntent> defaultIntents = ((DefaultingPolicySubject)binding).getDefaultIntents();
DefaultIntent defaultIntent = policyFactory.createDefaultIntent();
Definitions systemDefinitions = context.getDefinitions();
if (systemDefinitions != null){
BindingType bindingType = systemDefinitions.getBindingType(binding.getType());
for (Intent mayProvideIntent : bindingType.getMayProvidedIntents()){
if (mayProvideIntent.getName().getLocalPart().equals("SOAP.v1_1")){
defaultIntent.setIntent(mayProvideIntent);
}
if (mayProvideIntent.getName().getLocalPart().equals("SOAP.v1_2")){
defaultIntent.getMutuallyExclusiveIntents().add(mayProvideIntent);
}
}
defaultIntents.add(defaultIntent);
}