Tabnine Logo
QueryStringDecoder.decodeComponent
Code IndexAdd Tabnine to your IDE (free)

How to use
decodeComponent
method
in
org.jboss.netty.handler.codec.http.QueryStringDecoder

Best Java code snippets using org.jboss.netty.handler.codec.http.QueryStringDecoder.decodeComponent (Showing top 2 results out of 315)

origin: io.netty/netty

/**
 * Decodes a bit of an URL encoded by a browser.
 * <p>
 * This is equivalent to calling {@link #decodeComponent(String, Charset)}
 * with the UTF-8 charset (recommended to comply with RFC 3986, Section 2).
 * @param s The string to decode (can be empty).
 * @return The decoded string, or {@code s} if there's nothing to decode.
 * If the string to decode is {@code null}, returns an empty string.
 * @throws IllegalArgumentException if the string contains a malformed
 * escape sequence.
 */
public static String decodeComponent(final String s) {
  return decodeComponent(s, HttpConstants.DEFAULT_CHARSET);
}
origin: io.netty/netty

if (c == '=' && name == null) {
  if (pos != i) {
    name = decodeComponent(s.substring(pos, i), charset);
    if (!addParam(params, decodeComponent(s.substring(pos, i), charset), "")) {
      return;
    if (!addParam(params, name, decodeComponent(s.substring(pos, i), charset))) {
      return;
  addParam(params, decodeComponent(s.substring(pos, i), charset), "");
} else {                // Yes and this must be the last value.
  addParam(params, name, decodeComponent(s.substring(pos, i), charset));
org.jboss.netty.handler.codec.httpQueryStringDecoderdecodeComponent

Javadoc

Decodes a bit of an URL encoded by a browser.

This is equivalent to calling #decodeComponent(String,Charset)with the UTF-8 charset (recommended to comply with RFC 3986, Section 2).

Popular methods of QueryStringDecoder

  • <init>
    Creates a new decoder that decodes the specified URI encoded in the specified charset.
  • getParameters
    Returns the decoded key-value parameter pairs of the URI.
  • getPath
    Returns the decoded path string of the URI.
  • addParam
  • decodeHexNibble
    Helper to decode half of a hexadecimal number from a string.
  • decodeParams

Popular in Java

  • Making http post requests using okhttp
  • getOriginalFilename (MultipartFile)
    Return the original filename in the client's filesystem.This may contain path information depending
  • putExtra (Intent)
  • compareTo (BigDecimal)
  • GridBagLayout (java.awt)
    The GridBagLayout class is a flexible layout manager that aligns components vertically and horizonta
  • Point (java.awt)
    A point representing a location in (x,y) coordinate space, specified in integer precision.
  • FileWriter (java.io)
    A specialized Writer that writes to a file in the file system. All write requests made by calling me
  • IOException (java.io)
    Signals a general, I/O-related error. Error details may be specified when calling the constructor, a
  • Vector (java.util)
    Vector is an implementation of List, backed by an array and synchronized. All optional operations in
  • Executors (java.util.concurrent)
    Factory and utility methods for Executor, ExecutorService, ScheduledExecutorService, ThreadFactory,
  • Best IntelliJ 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