Commands are implemented by extending the class TargetableCommandImpl, which implements the TargetableCommand interface. The TargetableCommandImpl class is an abstract class that provides some implementations for some of the methods in the TargetableCommand interface (for example, setting return values) and declares additional methods that the application itself must implement (for example, how to execute the command).
... import java.lang.reflect.*; import com.ibm.websphere.command.*; public class MyCommandImpl extends TargetableCommandImpl implements MyCommand { // Set instance variables here ... // Implement methods in the MyCommand interface ... // Implement methods in the CompensableCommand interface ... // Implement abstract methods in the TargetableCommandImpl class ... }