public void init ( final FilterConfig filterConfig ) throws ServletException { // Get the init params Properties props = getFilterInitParameters ( filterConfig ) ; // Extract and parse all required CORS filter properties try { config = new CORSConfiguration ( props ) ; } catch ( CORSConfigurationException e ) { throw new ServletException ( e ) ; } handler = new CORSRequestHandler ( config ) ; }
This method is invoked by the web container to initialise the filter at startup .