Class URLFileName

All Implemented Interfaces:
Comparable<FileName>, FileName
Direct Known Subclasses:
UrlFileName

public class URLFileName extends GenericFileName
A file name that represents URL.
  • Constructor Details

  • Method Details

    • getQueryString

      Get the query string.
      Returns:
      the query string part of the filename
    • getPathQuery

      public String getPathQuery()
      Get the path and query string e.g. /path/servlet?param1=true.
      Returns:
      the path and its query string
    • getPathQueryEncoded

      public String getPathQueryEncoded(String charset) throws org.apache.commons.httpclient.URIException, FileSystemException
      Get the path encoded suitable for url like filesystem e.g. (http, webdav).
      Parameters:
      charset - the charset used for the path encoding
      Returns:
      The encoded path.
      Throws:
      org.apache.commons.httpclient.URIException - If an error occurs encoding the URI.
      FileSystemException - If some other error occurs.
    • createName

      public FileName createName(String absPath, FileType type)
      Create a FileName.
      Overrides:
      createName in class GenericFileName
      Parameters:
      absPath - The absolute path.
      type - The FileType.
      Returns:
      The FileName
    • createURI

      protected String createURI()
      Append query string to the uri.
      Overrides:
      createURI in class AbstractFileName
      Returns:
      the uri
    • getURIEncoded

      public String getURIEncoded(String charset) throws FileSystemException, org.apache.commons.httpclient.URIException
      Encode a URI.
      Parameters:
      charset - The character set.
      Returns:
      The encoded URI
      Throws:
      FileSystemException - if some other exception occurs.
      org.apache.commons.httpclient.URIException - if an exception occurs encoding the URI.