Class Handler


  • public class Handler
    extends java.net.URLStreamHandler
    Data URLs handler. "data:[<mediatype>][;base64],<data>"
    • Field Summary

      Fields 
      Modifier and Type Field Description
      static java.lang.String PROTOCOL_HANDLERS_PROPERTY
      property for protocol handlers
    • Constructor Summary

      Constructors 
      Constructor Description
      Handler()  
    • Method Summary

      All Methods Static Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      protected java.net.URLConnection openConnection​(java.net.URL url)  
      protected void parseURL​(java.net.URL url, java.lang.String spec, int start, int end)  
      static void register()
      Register data protocol handler
      protected java.lang.String toExternalForm​(java.net.URL url)  
      • Methods inherited from class java.net.URLStreamHandler

        equals, getDefaultPort, getHostAddress, hashCode, hostsEqual, openConnection, sameFile, setURL, setURL
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Field Detail

      • PROTOCOL_HANDLERS_PROPERTY

        public static final java.lang.String PROTOCOL_HANDLERS_PROPERTY
        property for protocol handlers
        See Also:
        Constant Field Values
    • Constructor Detail

      • Handler

        public Handler()
    • Method Detail

      • register

        public static void register()
        Register data protocol handler
      • openConnection

        protected java.net.URLConnection openConnection​(java.net.URL url)
                                                 throws java.io.IOException
        Specified by:
        openConnection in class java.net.URLStreamHandler
        Throws:
        java.io.IOException
      • parseURL

        protected void parseURL​(java.net.URL url,
                                java.lang.String spec,
                                int start,
                                int end)
                         throws java.lang.SecurityException
        Overrides:
        parseURL in class java.net.URLStreamHandler
        Throws:
        java.lang.SecurityException
      • toExternalForm

        protected java.lang.String toExternalForm​(java.net.URL url)
        Overrides:
        toExternalForm in class java.net.URLStreamHandler