congrats Icon
New! Announcing Tabnine Chat Beta
Learn More
Tabnine Logo
ServletWebResponse
Code IndexAdd Tabnine to your IDE (free)

How to use
ServletWebResponse
in
org.apache.wicket.protocol.http.servlet

Best Java code snippets using org.apache.wicket.protocol.http.servlet.ServletWebResponse (Showing top 20 results out of 315)

origin: de.alpharogroup/jaulp-wicket-base

@Override
public String encodeRedirectURL(final CharSequence url)
{
  return isRobot(webRequest) ? url.toString() : super.encodeRedirectURL(url);
}
origin: org.apache.wicket/wicket-core

  @Override
  public void sendRedirect(String url)
  {
    super.sendRedirect(url);
    try
    {
      getContainerResponse().sendRedirect(url);
    }
    catch (IOException e)
    {
      throw new RuntimeException(e);
    }
  }
}
origin: org.onehippo.cms7/hippo-cms-engine

@Override
public void setHeader(final String name, final String value) {
  if (containsCRorLF(value)) {
    throw new IllegalArgumentException("Header value must not contain CR or LF characters");
  }
  super.setHeader(name, value);
}
origin: org.apache.wicket/wicket-core

url = encodeRedirectURL(url);
disableCaching();
  setHeader("Ajax-Location", url);
  setContentType("text/xml;charset=" +
    webRequest.getContainerRequest().getCharacterEncoding());
origin: apache/wicket

@Override
public void addCookie(Cookie cookie)
{
  super.addCookie(cookie);
  cookies.add(cookie);
}
origin: org.apache.wicket/wicket-core

UrlRenderer urlRenderer = getUrlRenderer();
origin: apache/wicket

/**
 * Creates a WebResponse. Subclasses of WebRequest could e.g. encode wicket's default URL and
 * hide the details from the user. A appropriate WebRequest must be implemented and configured
 * to decode the encoded URL.
 * 
 * @param webRequest
 *            the {@link WebRequest} that will handle the current HTTP Servlet request
 * @param httpServletResponse
 *            the current HTTP Servlet response
 * @return a WebResponse object
 */
protected WebResponse newWebResponse(final WebRequest webRequest,
  final HttpServletResponse httpServletResponse)
{
  return new ServletWebResponse((ServletWebRequest)webRequest, httpServletResponse);
}
origin: org.onehippo.cms7/hippo-cms-engine

@Override
public void addHeader(final String name, final String value) {
  if (containsCRorLF(value)) {
    throw new IllegalArgumentException("Header value must not contain CR or LF characters");
  }
  super.addHeader(name, value);
}
origin: de.alpharogroup/jaulp-wicket-base

@Override
public String encodeURL(final CharSequence url)
{
  return isRobot(webRequest) ? url.toString() : super.encodeURL(url);
}
origin: at.molindo/molindo-wicket-utils

@Override
public final String call() {
  // add component to mock page
  MockRenderPage page = new MockRenderPage();
  Component component = newComponent("mock");
  page.add(component);
  // render page
  page.renderPage();
  if (isFailOnStatefulPages() && !page.isPageStateless()) {
    throw new WicketRuntimeException("no stateful components allowed");
  }
  // close response and get output
  WicketUtils.getWebResponse().close();
  return ((MockHttpServletResponse) WicketUtils.getServletWebResponse().getContainerResponse()).getDocument();
}
origin: apache/wicket

url = encodeRedirectURL(url);
disableCaching();
  setHeader("Ajax-Location", url);
  setContentType("text/xml;charset=" +
    webRequest.getContainerRequest().getCharacterEncoding());
origin: org.apache.wicket/wicket-core

@Override
public void addCookie(Cookie cookie)
{
  super.addCookie(cookie);
  cookies.add(cookie);
}
origin: org.apache.wicket/wicket-core

UrlRenderer urlRenderer = getUrlRenderer();
origin: org.apache.wicket/wicket-core

/**
 * Creates a WebResponse. Subclasses of WebRequest could e.g. encode wicket's default URL and
 * hide the details from the user. A appropriate WebRequest must be implemented and configured
 * to decode the encoded URL.
 * 
 * @param webRequest
 *            the {@link WebRequest} that will handle the current HTTP Servlet request
 * @param httpServletResponse
 *            the current HTTP Servlet response
 * @return a WebResponse object
 */
protected WebResponse newWebResponse(final WebRequest webRequest,
  final HttpServletResponse httpServletResponse)
{
  return new ServletWebResponse((ServletWebRequest)webRequest, httpServletResponse);
}
origin: apache/wicket

  @Override
  public void sendRedirect(String url)
  {
    super.sendRedirect(url);
    try
    {
      getContainerResponse().sendRedirect(url);
    }
    catch (IOException e)
    {
      throw new RuntimeException(e);
    }
  }
}
origin: org.apache.wicket/wicket-core

@Override
public void clearCookie(Cookie cookie)
{
  cookie.setMaxAge(0);
  cookie.setValue(null);
  addCookie(cookie);
}
origin: apache/wicket

UrlRenderer urlRenderer = getUrlRenderer();
origin: org.onehippo.cms7/hippo-cms-engine

@Override
public void sendRedirect(String url) {
  Args.notNull(url, "url");
  if (containsCRorLF(url)) {
    throw new IllegalArgumentException("CR or LF detected in redirect URL: possible http response splitting attack");
  }
  if (url.equals("./")) {
    url += "?";
  }
  super.sendRedirect(url);
}
origin: apache/wicket

@Override
public void clearCookie(Cookie cookie)
{
  cookie.setMaxAge(0);
  cookie.setValue(null);
  addCookie(cookie);
}
origin: apache/wicket

UrlRenderer urlRenderer = getUrlRenderer();
org.apache.wicket.protocol.http.servletServletWebResponse

Javadoc

WebResponse that wraps a ServletWebResponse.

Most used methods

  • encodeRedirectURL
  • sendRedirect
  • setHeader
  • <init>
    Construct.
  • addCookie
  • addHeader
  • disableCaching
  • encodeURL
  • getContainerResponse
  • getUrlRenderer
  • setContentType
  • setContentType

Popular in Java

  • Reactive rest calls using spring rest template
  • setScale (BigDecimal)
  • orElseThrow (Optional)
    Return the contained value, if present, otherwise throw an exception to be created by the provided s
  • compareTo (BigDecimal)
  • Color (java.awt)
    The Color class is used to encapsulate colors in the default sRGB color space or colors in arbitrary
  • Component (java.awt)
    A component is an object having a graphical representation that can be displayed on the screen and t
  • List (java.util)
    An ordered collection (also known as a sequence). The user of this interface has precise control ove
  • SortedSet (java.util)
    SortedSet is a Set which iterates over its elements in a sorted order. The order is determined eithe
  • ImageIO (javax.imageio)
  • Servlet (javax.servlet)
    Defines methods that all servlets must implement. A servlet is a small Java program that runs within
  • Top Sublime Text 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