javax.util.concurrent
Interface Identifiable


public interface Identifiable

A tasks submitted to an ManagedExecutorService can optionally implement this interface.

The intent of this interface is to allow management facilities to inspect the task to determine the intent of the task and its state. Implementations should not depend upon any thread execution context and should typically return only readily-available instance data.

Author:
Chris D Johnson

Method Summary
 java.lang.String getIdentityDescription(java.util.Locale locale)
          The description of the identifiable object translated for a given locale.
 java.lang.String getIdentityName()
          The name or ID of the identifiable object.
 

Method Detail

getIdentityName

java.lang.String getIdentityName()
The name or ID of the identifiable object.

Returns:
the name or ID of the identifiable object.

getIdentityDescription

java.lang.String getIdentityDescription(java.util.Locale locale)
The description of the identifiable object translated for a given locale.

Parameters:
locale - the locale to use to generate the description. If null, the default locale will be used.
Returns:
the description of the identifiable object in the specified locale.