Class ParserUtils


  • public class ParserUtils
    extends java.lang.Object
    • Constructor Summary

      Constructors 
      Constructor Description
      ParserUtils()  
    • Method Summary

      All Methods Static Methods Concrete Methods 
      Modifier and Type Method Description
      static java.lang.String decode​(java.lang.String s)
      Decodes a URL-encoded path string.
      static java.lang.String encode​(java.lang.String s)
      Encodes a URL path string.
      • Methods inherited from class java.lang.Object

        equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • ParserUtils

        public ParserUtils()
    • Method Detail

      • encode

        public static java.lang.String encode​(java.lang.String s)
        Encodes a URL path string. This method is suitable only for URL path strings and is unsuitable for other URL components.
        Parameters:
        s - the string to encode
        Returns:
        the encoded string
      • decode

        public static java.lang.String decode​(java.lang.String s)
        Decodes a URL-encoded path string. For example, an encoded space (%20) is decoded into a normal space (' ') character.
        Parameters:
        String - encoded - the encoded URL string
        Returns:
        String decoded - the decoded string.