Tabnine Logo
ServletConfigImpl
Code IndexAdd Tabnine to your IDE (free)

How to use
ServletConfigImpl
in
ro.polak.http.servlet.impl

Best Java code snippets using ro.polak.http.servlet.impl.ServletConfigImpl (Showing top 3 results out of 315)

origin: piotrpolak/android-http-server

  @Test
  public void shouldWorkSetterAndGetter() {
    ServletContextImpl servletContextImpl = mock(ServletContextImpl.class);
    ServletConfigImpl servletConfigImpl = new ServletConfigImpl(servletContextImpl);
    assertThat(servletConfigImpl.getServletContext(), is(not(nullValue())));
  }
}
origin: piotrpolak/android-http-server

@Test
public void shouldProvideContextAfterInitialization() throws ServletException {
  HttpServlet httpServlet = new SampleServlet();
  ServletContext servletContext = mock(ServletContext.class);
  ServletConfig servletConfig = new ServletConfigImpl(servletContext);
  httpServlet.init(servletConfig);
  assertThat(httpServlet.getServletInfo(), is(""));
  assertThat(httpServlet.getServletContext(), is(equalTo(servletContext)));
  httpServlet.destroy();
}
origin: piotrpolak/android-http-server

/**
 * {@inheritDoc}
 */
@Override
public void load(final String path,
         final HttpServletRequestImpl request,
         final HttpServletResponseImpl response) throws IOException {
  ServletContextImpl servletContext = servletContextHelper.getResolvedContext(servletContexts, path);
  Objects.requireNonNull(servletContext);
  ServletMapping servletMapping = servletContextHelper.getResolvedServletMapping(servletContext, path);
  request.setServletContext(servletContext);
  Servlet servlet = getServlet(servletMapping, new ServletConfigImpl(servletContext));
  response.setStatus(HttpServletResponse.STATUS_OK);
  try {
    FilterChainImpl filterChain = getFilterChain(path, servletContext, servlet);
    filterChain.doFilter(request, response);
    terminate(request, response);
  } catch (ServletException | FilterInitializationException e) {
    throw new UnexpectedSituationException(e);
  }
}
ro.polak.http.servlet.implServletConfigImpl

Javadoc

Servlet config implementation.

Most used methods

  • <init>
    Default constructor.
  • getServletContext

Popular in Java

  • Making http post requests using okhttp
  • onRequestPermissionsResult (Fragment)
  • compareTo (BigDecimal)
  • startActivity (Activity)
  • Arrays (java.util)
    This class contains various methods for manipulating arrays (such as sorting and searching). This cl
  • Comparator (java.util)
    A Comparator is used to compare two objects to determine their ordering with respect to each other.
  • Deque (java.util)
    A linear collection that supports element insertion and removal at both ends. The name deque is shor
  • PriorityQueue (java.util)
    A PriorityQueue holds elements on a priority heap, which orders the elements according to their natu
  • Executors (java.util.concurrent)
    Factory and utility methods for Executor, ExecutorService, ScheduledExecutorService, ThreadFactory,
  • XPath (javax.xml.xpath)
    XPath provides access to the XPath evaluation environment and expressions. Evaluation of XPath Expr
  • Top PhpStorm plugins
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now