XMLInputFactory inputFactory = modelFactories.getFactory(XMLInputFactory.class);
XMLOutputFactory outputFactory = modelFactories.getFactory(XMLOutputFactory.class);
StAXArtifactProcessorExtensionPoint artifactExtensionPoint = registry.getExtensionPoint(StAXArtifactProcessorExtensionPoint.class);
StAXArtifactProcessor<Object> extensibleStAXProcessor = new ExtensibleStAXArtifactProcessor(artifactExtensionPoint, inputFactory, outputFactory);
StAXAttributeProcessorExtensionPoint attributeExtensionPoint = registry.getExtensionPoint(StAXAttributeProcessorExtensionPoint.class);
StAXAttributeProcessor<Object> extensibleStAXAttributeProcessor = new ExtensibleStAXAttributeProcessor(attributeExtensionPoint, inputFactory, outputFactory);
WSPolicyProcessor processor = new WSPolicyProcessor(new DefaultExtensionPointRegistry(),
extensibleStAXProcessor,
extensibleStAXAttributeProcessor);