org.apache.commons.lang3.concurrent

## Interface Computable<I,O>

- Type Parameters:
    `I` - the type of the input to the calculation
    `O` - the type of the output of the calculation
  All Known Implementing Classes:
    Memoizer

      public interface Computable<I,O>

  Definition of an interface for a wrapper around a calculation that takes a single parameter and returns a result.

  This interface allows for wrapping a calculation into a class so that it maybe passed around an application.

  Since:
    3.6

- - ### Method Summary

    All Methods Instance Methods Abstract Methods
    Modifier and Type | Method and Description
    --- | ---
    `O` | `compute(I arg)` This method carries out the given operation with the provided argument.

- - ### Method Detail

    - #### compute

          O compute(I arg)
             throws InterruptedException

      This method carries out the given operation with the provided argument.
      Parameters:
        `arg` - the argument for the calculation
      Returns:
        the result of the calculation
      Throws:
        `InterruptedException` - thrown if the calculation is interrupted

Copyright © 2001–2018 The Apache Software Foundation. All rights reserved.