private boolean isBindingSupported(QName binding) { if (binding == null) { return false; } // Check if there is a processor StAXArtifactProcessor<?> processor = processors.getProcessor(binding); if (processor == null) { // logger.warning("Mapped binding for binding.sca is not supported: " + binding); return false; } try { if (processor != null) { // Futher check if the provider is present Binding bindingTemplate = createDelegatingBinding(binding); ProviderFactory<?> providerFactory = providerFactories.getProviderFactory(bindingTemplate.getClass()); if (providerFactory == null) { // logger.warning("Mapped binding for binding.sca is not supported: " + binding); processor = null; return false; } } } catch (Throwable e) { throw new ServiceRuntimeException(e); } return true; }
private void addImplementationProvider(RuntimeComponent component, Implementation implementation) { ImplementationProviderFactory providerFactory = (ImplementationProviderFactory)providerFactories.getProviderFactory(implementation.getClass()); if (providerFactory != null) { @SuppressWarnings("unchecked") ImplementationProvider implementationProvider = providerFactory.createImplementationProvider(component, implementation); if (implementationProvider != null) { component.setImplementationProvider(implementationProvider); } } else { throw new IllegalStateException("Provider factory not found for class: " + implementation.getClass() .getName()); } for (PolicyProviderFactory f : providerFactories.getPolicyProviderFactories()) { PolicyProvider policyProvider = f.createImplementationPolicyProvider(component); if (policyProvider != null) { component.addPolicyProvider(policyProvider); } } }
public synchronized List<PolicyProvider> getPolicyProviders() { resolve(); if (policyProviders == null) { policyProviders = new ArrayList<PolicyProvider>(); for (PolicyProviderFactory factory : providerFactories.getPolicyProviderFactories()) { PolicyProvider provider = factory.createReferencePolicyProvider(this); if (provider != null) { policyProviders.add(provider); } } } return policyProviders; }
public synchronized List<PolicyProvider> getPolicyProviders() { resolve(); if (policyProviders == null) { policyProviders = new ArrayList<PolicyProvider>(); for (PolicyProviderFactory factory : providerFactories.getPolicyProviderFactories()) { PolicyProvider provider = factory.createServicePolicyProvider(this); if (provider != null) { policyProviders.add(provider); } } } return policyProviders; }
private boolean isBindingSupported(QName binding) { if (binding == null) { return false; } // Check if there is a processor StAXArtifactProcessor<?> processor = processors.getProcessor(binding); if (processor == null) { // logger.warning("Mapped binding for binding.sca is not supported: " + binding); return false; } try { if (processor != null) { // Futher check if the provider is present Binding bindingTemplate = createDelegatingBinding(binding); ProviderFactory<?> providerFactory = providerFactories.getProviderFactory(bindingTemplate.getClass()); if (providerFactory == null) { // logger.warning("Mapped binding for binding.sca is not supported: " + binding); processor = null; return false; } } } catch (Throwable e) { throw new ServiceRuntimeException(e); } return true; }
public synchronized ServiceBindingProvider getBindingProvider() { resolve(); if (bindingProvider == null) { BindingProviderFactory factory = (BindingProviderFactory)providerFactories.getProviderFactory(getBinding().getClass()); if (factory == null) { throw new ServiceRuntimeException("No provider factory is registered for binding " + getBinding() .getType()); } this.bindingProvider = factory.createServiceBindingProvider(this); } return bindingProvider; }
public synchronized ReferenceBindingProvider getBindingProvider() { resolve(); // For the case that binding.sca is implemented by another binding if (binding == null) { return null; } if (bindingProvider == null) { BindingProviderFactory factory = (BindingProviderFactory)providerFactories.getProviderFactory(getBinding().getClass()); if (factory == null) { throw new ServiceRuntimeException("No provider factory is registered for binding " + getBinding() .getType()); } this.bindingProvider = factory.createReferenceBindingProvider(this); } return bindingProvider; }
(OperationSelectorProviderFactory)providerFactories.getProviderFactory(jmsBinding.getOperationSelector().getClass()); if (this.operationSelectorProviderFactory != null){ this.operationSelectorProvider = operationSelectorProviderFactory.createServiceOperationSelectorProvider(endpoint); (WireFormatProviderFactory)providerFactories.getProviderFactory(jmsBinding.getRequestWireFormat().getClass()); if (this.requestWireFormatProviderFactory != null){ this.requestWireFormatProvider = requestWireFormatProviderFactory.createServiceWireFormatProvider(endpoint); (WireFormatProviderFactory)providerFactories.getProviderFactory(jmsBinding.getResponseWireFormat().getClass()); if (this.responseWireFormatProviderFactory != null){ this.responseWireFormatProvider = responseWireFormatProviderFactory.createServiceWireFormatProvider(endpoint);
(OperationSelectorProviderFactory)providerFactories.getProviderFactory(binding.getOperationSelector() .getClass()); if (osProviderFactory != null) { (WireFormatProviderFactory)providerFactories.getProviderFactory(binding.getRequestWireFormat() .getClass()); if (wfProviderFactory != null) { (WireFormatProviderFactory)providerFactories.getProviderFactory(binding.getResponseWireFormat() .getClass()); if (wfProviderFactory != null) {
(WireFormatProviderFactory)providerFactories.getProviderFactory(jmsBinding.getRequestWireFormat().getClass()); if (this.requestWireFormatProviderFactory != null){ this.requestWireFormatProvider = requestWireFormatProviderFactory.createReferenceWireFormatProvider(endpointReference); (WireFormatProviderFactory)providerFactories.getProviderFactory(jmsBinding.getResponseWireFormat().getClass()); if (this.responseWireFormatProviderFactory != null){ this.responseWireFormatProvider = responseWireFormatProviderFactory.createReferenceWireFormatProvider(endpointReference);
OperationSelectorProviderFactory osProviderFactory = (OperationSelectorProviderFactory) providerFactories.getProviderFactory(binding.getOperationSelector().getClass()); if (osProviderFactory != null) { this.osProvider = osProviderFactory.createServiceOperationSelectorProvider(endpoint); WireFormatProviderFactory wfProviderFactory = (WireFormatProviderFactory) providerFactories.getProviderFactory(binding.getRequestWireFormat().getClass()); if (wfProviderFactory != null) { this.wfProvider = wfProviderFactory.createServiceWireFormatProvider(endpoint);