io.logspace.agent.shaded.tape.Task Maven / Gradle / Ivy
// Copyright 2012 Square, Inc.
package io.logspace.agent.shaded.tape;
import java.io.Serializable;
/**
* An idempotent task that can be enqueued, persisted (using serialization),
* and executed at a later time.
*
* @param The type of callback.
*/
public interface Task extends Serializable {
/**
* Executes this task. The members of this task instance have been injected
* prior to calling this method.
*
* @param callback to report result to
*/
void execute(T callback);
}