Package io.muserver

Interface DoneCallback


  • public interface DoneCallback
    A callback for async operations that calls when an operation completes.
    • Field Summary

      Fields 
      Modifier and Type Field Description
      static DoneCallback NoOp
      A callback that does nothing on completion.
    • Field Detail

      • NoOp

        static final DoneCallback NoOp
        A callback that does nothing on completion.
    • Method Detail

      • onComplete

        void onComplete​(java.lang.Throwable error)
                 throws java.lang.Exception
        The operation has completed.
        Parameters:
        error - If null, then the operation was a success. Otherwise it failed.
        Throws:
        java.lang.Exception - The result of throwing an exception depends on the operation, and may include actions such as disconnecting the client.