IBM Rational Software Modeler
Release 6.0

com.ibm.xtools.transform.uml2.cpp
Class CPPExtendClassRule

java.lang.Object
  extended bycom.ibm.xtools.transform.core.AbstractTransformElement
      extended bycom.ibm.xtools.transform.core.AbstractRule
          extended bycom.ibm.xtools.transform.uml2.cpp.CPPExtendFramework
              extended bycom.ibm.xtools.transform.uml2.cpp.CPPExtendRule
                  extended bycom.ibm.xtools.transform.uml2.cpp.CPPExtendClassifierRule
                      extended bycom.ibm.xtools.transform.uml2.cpp.CPPExtendClassRule
All Implemented Interfaces:
ITransformationItem

public abstract class CPPExtendClassRule
extends CPPExtendClassifierRule

This class provides common functionality for the extensibility of the transformation of UML2 Classes into a C++ code. The source property of the rule context is expected to be a UML2 Class.


Nested Class Summary
 
Nested classes inherited from class com.ibm.xtools.transform.uml2.cpp.CPPExtendClassifierRule
CPPExtendClassifierRule.InheritanceKind, CPPExtendClassifierRule.StdOperationType
 
Constructor Summary
CPPExtendClassRule(String id)
          Constructor.
 
Method Summary
 boolean canAccept(ITransformContext context)
          The implementation of this method filters out contexts with inappropriate source elements, then calls canAcceptExt to provide additional filtering capabilities.
protected  org.eclipse.uml2.Class getSourceClass(ITransformContext context)
          Returns the UML2 class to be processed.
 
Methods inherited from class com.ibm.xtools.transform.uml2.cpp.CPPExtendClassifierRule
addAttribute, addGeneralization, addGeneralization, addInclusion, addInclusion, addOperation, addStandardOperation
 
Methods inherited from class com.ibm.xtools.transform.uml2.cpp.CPPExtendRule
addBodyPrefix, addBodySuffix, addHeaderPrefix, addHeaderSuffix, isNested
 
Methods inherited from class com.ibm.xtools.transform.uml2.cpp.CPPExtendFramework
canAcceptExt, createTarget, createTargetExt
 
Methods inherited from class com.ibm.xtools.transform.core.AbstractRule
execute, findTarget, isSourceConsumed, mapTarget, toString, updateTarget
 
Methods inherited from class com.ibm.xtools.transform.core.AbstractTransformElement
getAcceptCondition, getDescription, getId, getName, getProgressMonitor, setAcceptCondition, setDescription, setId, setName
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

CPPExtendClassRule

public CPPExtendClassRule(String id)
Constructor.

Parameters:
id - A unique identifier for the rule.
Method Detail

canAccept

public final boolean canAccept(ITransformContext context)
Description copied from class: CPPExtendFramework
The implementation of this method filters out contexts with inappropriate source elements, then calls canAcceptExt to provide additional filtering capabilities.

Overrides:
canAccept in class CPPExtendClassifierRule

getSourceClass

protected final org.eclipse.uml2.Class getSourceClass(ITransformContext context)
Returns the UML2 class to be processed. Returns null if the source property is not a UML2 class.

Parameters:
context - The rule execution context.
Returns:
The UML2 class to be processed or null.

IBM Rational Software Modeler
Release 6.0


Guidelines for using Eclipse APIs.

Copyright (c) IBM Corp. and others 2004. All rights reserved.