Class LiveReloadServer

    • Method Detail

      • start

        public int start()
                  throws IOException
        Start the livereload server and accept incoming connections.
        Returns:
        the port on which the server is listening
        Throws:
        IOException - in case of I/O errors
      • isStarted

        public boolean isStarted()
        Return if the server has been started.
        Returns:
        true if the server is running
      • getPort

        public int getPort()
        Return the port that the server is listening on.
        Returns:
        the server port
      • triggerReload

        public void triggerReload()
        Trigger livereload of all connected clients.
      • createConnection

        protected org.springframework.boot.devtools.livereload.Connection createConnection​(Socket socket,
                                                                                           InputStream inputStream,
                                                                                           OutputStream outputStream)
                                                                                    throws IOException
        Factory method used to create the Connection.
        Parameters:
        socket - the source socket
        inputStream - the socket input stream
        outputStream - the socket output stream
        Returns:
        a connection
        Throws:
        IOException - in case of I/O errors