com.levigo.util.concurrent.tasks
Class AbstractTask<R>
java.lang.Object
com.levigo.util.concurrent.tasks.AbstractTask<R>
- Type Parameters:
R
- the task's result type
- All Implemented Interfaces:
- Task<R>, Callable<R>
public abstract class AbstractTask<R>
- extends Object
- implements Task<R>
An abstract implementation of a Task
which manages task identity using a key object
supplied at construction time.
Constructor Summary |
protected |
AbstractTask(Object key)
Create a task using the given key and the key's string representation as its name. |
protected |
AbstractTask(Object key,
String name)
Create a task using the given key and name. |
Methods inherited from interface java.util.concurrent.Callable |
call |
AbstractTask
protected AbstractTask(Object key)
- Create a task using the given key and the key's string representation as its name.
- Parameters:
key
-
AbstractTask
protected AbstractTask(Object key,
String name)
- Create a task using the given key and name.
- Parameters:
key
- name
-
equals
public boolean equals(Object obj)
- Overrides:
equals
in class Object
hashCode
public int hashCode()
- Overrides:
hashCode
in class Object
toString
public String toString()
- Overrides:
toString
in class Object
Copyright © 1995-2020 levigo holding gmbh. All Rights Reserved.