@Override public void init(ServletConfig servletConfig) throws ServletException { super.init(servletConfig); initialized = true; }
public void init() throws ServletException { super.init(); final JaxWsAnnotationProcessorUtil wsInstance = JaxWsAnnotationProcessorUtil.getInstance(); this.endpoints = wsInstance.getEndpointList(); }
@Override public void init(ServletConfig config) throws ServletException { // get CMIS version String cmisVersionStr = config.getInitParameter(PARAM_CMIS_VERSION); if (cmisVersionStr != null) { try { cmisVersion = CmisVersion.fromValue(cmisVersionStr); } catch (IllegalArgumentException e) { LOG.warn("CMIS version is invalid! Setting it to CMIS 1.0."); cmisVersion = CmisVersion.CMIS_1_0; } } else { LOG.warn("CMIS version is not defined! Setting it to CMIS 1.0."); cmisVersion = CmisVersion.CMIS_1_0; } // initialize the call context handler callContextHandler = AbstractCmisHttpServlet.loadCallContextHandler(config); // set up WSDL and XSD documents docs = new HashMap<String, String>(); String path = (cmisVersion == CmisVersion.CMIS_1_0 ? CMIS10_PATH : CMIS11_PATH); docs.put("wsdl", readFile(config, path + "CMISWS-Service.wsdl.template")); docs.put("core", readFile(config, path + "CMIS-Core.xsd.template")); docs.put("msg", readFile(config, path + "CMIS-Messaging.xsd.template")); // set up CSRF manager csrfManager = new CsrfManager(config); super.init(config); }
@Override public void init(ServletConfig servletConfig) throws ServletException { super.init(servletConfig);
@Override public void init(ServletConfig servletConfig) throws ServletException { super.init(servletConfig);
public CxfPlugin(@Config(defaultValue = "/ws/*", doc = "Path where the CXF plugin will be deployed") String mountPoint, @Config(defaultValue = "BOTH") String schemaValidation, Collection<EndpointCustomizer> endpointCustomizers, Collection<ServiceCustomizer> serviceCustomizers, ServletBuilder servletBuilder) throws ServletException { this.schemaValidation = schemaValidation; this.endpointCustomizers = endpointCustomizers; Bus bus = BusFactory.newInstance().createBus(); ServiceContractResolverRegistry reg = new ServiceContractResolverRegistryImpl(bus); reg.register(new RespiroServiceContractResolver()); CXFNonSpringServlet cxfNonSpringServlet = new CXFNonSpringServlet(); cxfNonSpringServlet.setBus(bus); cxfNonSpringServlet.init(servletBuilder.servletConfig("cxf", new Properties())); cxfFilter = servletBuilder.servlet(cxfNonSpringServlet, mountPoint); endpointBuilder = new DefaultEndpointBuilder(); serviceBuilder = new DefaultServiceBuilder(serviceCustomizers); endpointDeployer = endpointConfigs -> CxfPlugin.this.deployEndpoints(endpointConfigs); }