JavaImplementationFactory javaImplementationFactory = new DefaultJavaImplementationFactory();
modelFactories.addFactory(javaImplementationFactory);
staxProcessors.addArtifactProcessor(new CompositeProcessor(null, factory, policyFactory, staxProcessor));
staxProcessors.addArtifactProcessor(new ComponentTypeProcessor(factory, policyFactory, staxProcessor));
staxProcessors.addArtifactProcessor(new ConstrainingTypeProcessor(factory, policyFactory, staxProcessor));
JavaImplementationProcessor javaProcessor = new JavaImplementationProcessor(modelFactories);
staxProcessors.addArtifactProcessor(javaProcessor);
}