Interface ServerRuntime.CancellableOperation<T>

Type Parameters:
T - independently owned, resource-free result type
Enclosing class:
ServerRuntime
Functional Interface:
This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.

@FunctionalInterface public static interface ServerRuntime.CancellableOperation<T>
Operation executed on this runtime's bounded worker lane.
  • Method Summary

    Modifier and Type
    Method
    Description
    call(CancellationSignal cancellation)
    Computes a result, releasing every acquired resource before returning.
  • Method Details

    • call

      T call(CancellationSignal cancellation) throws Exception
      Computes a result, releasing every acquired resource before returning.
      Parameters:
      cancellation - cooperative cancellation and interruption signal
      Returns:
      resource-free result; a late result may be discarded
      Throws:
      Exception - if execution fails