In this example, we will add a generation command and associated task to the Java object language
- Create a new OOM for Java, and then select .
 
- Expand the Generation category, and then right-click the
                    Commands category and select New.
 
- Name the command DoCommand and enter an
                    appropriate template:
 
- Right-click the Tasks category and select
                        New. Name the task Execute, click
                    the Add Commands tool, select DoCommand
                    from the list, and then click OK to add it to the new
                    task:
 
- Click OK to save your changes and return
                    to the model. Then select  to open the Generation dialog, and click the
                        Tasks tab. The new task is listed on the tab under
                    its comment (or its name, if no comment has been provided):