Class GenerateService.AllocationData

java.lang.Object
jadex.micro.mandelbrot.generate.GenerateService.AllocationData
Enclosing class:
GenerateService

public static class GenerateService.AllocationData extends Object
Handler for a single task allocation.
  • Field Details

    • open

      protected int open
      The counter for open tasks, i.e. number of assigned and unassigned tasks that are not yet finished.
    • retry

      protected boolean retry
      The retry flag, i.e. if failed tasks should be assigned again.
    • user

      protected Object user
      The user data (if any).
    • result

      protected jadex.future.IntermediateFuture result
      The result future.
  • Constructor Details

    • AllocationData

      public AllocationData(int open, boolean retry, Object user)
      Create a new allocation data.
  • Method Details

    • getUserData

      public Object getUserData()
      Get the user data.
      Returns:
      The user data (if any).
    • getResult

      public jadex.future.IntermediateFuture getResult()
      Get the result.
      Returns:
      The intermediate results future.
    • taskFinished

      public void taskFinished(Object result)
      Add an intermediate result.
    • taskFailed

      public void taskFailed(Exception e)
      A task has failed and is not retried.
    • isRetry

      public boolean isRetry()
      Test if the retry flag is set.
      Returns:
      True, if the retry flag is set.
    • setRetry

      public void setRetry(boolean retry)
      Parameters:
      retry - the retry to set