it.tidalwave.util
Class Task<T,E extends Throwable>

Package class diagram package Task
java.lang.Object
  extended by it.tidalwave.util.Task<T,E>

public abstract class Task<T,E extends Throwable>
extends Object

A class which encapsulates a task..

Version:
$Id$
Author:
Fabrizio Giudici
Status: experimental API

Constructor Summary
Task()
          Creates a new Task.
Task(String name)
          Creates a new Task with the given name.
 
Method Summary
abstract  T run()
          The method that must contain the body of the Task.
 String toString()
          
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

Task

public Task()
Creates a new Task.


Task

public Task(@Nonnull
            String name)
Creates a new Task with the given name.

Parameters:
name - the name
Method Detail

run

public abstract T run()
               throws E extends Throwable
The method that must contain the body of the Task.

Throws:
E extends Throwable

toString

@Nonnull
public String toString()

Overrides:
toString in class Object


Copyright © 2009-2011 Tidalwave s.a.s.. All Rights Reserved.