Defining a Runnable’s Task
In addition to being distinguished by their dispatching behavior, the runnable object can also be identified according to the mechanism used to define its “task” or “work.” Some runnables accept a functor object for execution, while others accept and execute other runnables objects.