com.telelogic.rhapsody.core
Interface IRPOperation

All Superinterfaces:
IRPClassifier, IRPInterfaceItem, IRPModelElement, IRPUnit

public interface IRPOperation
extends IRPInterfaceItem

The IRPOperation interface represents operations of classes in Rational Rhapsody models.


Nested Class Summary
 
Nested classes/interfaces inherited from interface com.telelogic.rhapsody.core.IRPModelElement
IRPModelElement.OSLCLink
 
Method Summary
 void createAutoFlowChart()
          Creates a flowchart for the operation.
 void deleteArgument(IRPArgument argument)
          Deletes a specific argument from the operation.
 void deleteFlowchart()
          Deletes the flowchart or activity defined for the operation.
 java.lang.String getBody()
          Returns the body of the operation.
 IRPFlowchart getFlowchart()
          Returns the flowchart or activity defined for the operation.
 java.lang.String getImplementationSignature()
          Returns the signature of the operation as it will appear in the generated code.
 java.lang.String getInitializer()
          For constructors, gets the initializer code that was defined for the operation.
 int getIsAbstract()
          Checks whether the operation was defined as abstract.
 int getIsCgDerived()
          Checks whether the operation is an operation that is automatically generated by Rhapsody.
 int getIsConst()
          For operations in C++ classes, checks whether the operation was defined as a constant member function.
 int getIsCtor()
          Checks whether the operation is a constructor.
 int getIsDtor()
          Checks whether the operation is a destructor.
 int getIsFinal()
          For operations in Java classes, checks whether the operation was defined as final.
 int getIsInline()
          Checks whether the code for the operation will be generated inline.
 int getIsStatic()
          Checks whether the operation was defined as static.
 int getIsTrigger()
          Checks whether the operation was defined as a triggered operation.
 int getIsVirtual()
          For operations in C++ or C# classes, checks whether the operation was defined as virtual.
 IRPClassifier getReturns()
          Gets the return type of the operation.
 java.lang.String getReturnTypeDeclaration()
          If an on-the-fly type is used as the return type of an operation, this method returns the declaration for the type.
 java.lang.String getVisibility()
          Gets the visibility specified for the operation.
 void setBody(java.lang.String body)
          Sets the body of an operation.
 void setFlowchart(IRPFlowchart flowchart)
          Specifies a flowchart or activity for the operation.
 void setInitializer(java.lang.String initializer)
          For constructors, used to specify code for the initializer of the operation.
 void setIsAbstract(int isAbstract)
          Specifies whether an operation should be defined as abstract.
 void setIsConst(int isConst)
          For operations in C++ classes, used to specify whether an operation should be defined as a constant member function.
 void setIsFinal(int isFinal)
          For operations in Java classes, used to specify whether an operation should be defined as final.
 void setIsStatic(int isStatic)
          Specifies whether an operation should be defined as static.
 void setIsVirtual(int isVirtual)
          For operations in C++ or C# classes, used to specify whether an operation should be defined as virtual.
 void setReturns(IRPClassifier returns)
          Specifies the return type of the operation.
 void setReturnTypeDeclaration(java.lang.String newVal)
          Creates an on-the-fly type to use as the return type of the operation, using the declaration that you provide as a parameter.
 void setVisibility(java.lang.String visibility)
          set property visibility
 
Methods inherited from interface com.telelogic.rhapsody.core.IRPInterfaceItem
addArgument, addArgumentBeforePosition, getArguments, getSignature, getSignatureNoArgNames, getSignatureNoArgTypes, matchOnSignature
 
Methods inherited from interface com.telelogic.rhapsody.core.IRPClassifier
addActivityDiagram, addAttribute, addFlowItems, addFlows, addGeneralization, addOperation, addRelation, addRelationTo, addStatechart, addUnidirectionalRelation, addUnidirectionalRelationTo, deleteAttribute, deleteFlowItems, deleteFlows, deleteGeneralization, deleteOperation, deleteRelation, findAttribute, findBaseClassifier, findDerivedClassifier, findGeneralization, findInterfaceItem, findNestedClassifier, findNestedClassifierRecursive, findRelation, findTrigger, getActivityDiagram, getAttributes, getAttributesIncludingBases, getBaseClassifiers, getBehavioralDiagrams, getDerivedClassifiers, getFlowItems, getFlows, getGeneralizations, getInterfaceItems, getInterfaceItemsIncludingBases, getLinks, getNestedClassifiers, getOperations, getPorts, getRelations, getRelationsIncludingBases, getSequenceDiagrams, getSourceArtifacts, getStatechart
 
Methods inherited from interface com.telelogic.rhapsody.core.IRPUnit
copyToAnotherProject, getAddToModelMode, getCMHeader, getCMState, getCurrentDirectory, getFilename, getIncludeInNextLoad, getIsStub, getLanguage, getLastModifiedTime, getNestedSaveUnits, getNestedSaveUnitsCount, getStructureDiagrams, isReadOnly, isReferenceUnit, isSeparateSaveUnit, load, moveToAnotherProjectLeaveAReference, referenceToAnotherProject, save, setCMHeader, setFilename, setIncludeInNextLoad, setLanguage, setReadOnly, setSeparateSaveUnit, setUnitPath, unload
 
Methods inherited from interface com.telelogic.rhapsody.core.IRPModelElement
addAssociation, addDependency, addDependencyBetween, addDependencyTo, addLinkToElement, addNewAggr, addProperty, addRedefines, addRemoteDependencyTo, addSpecificStereotype, addStereotype, becomeTemplateInstantiationOf, changeTo, clone, createOSLCLink, deleteDependency, deleteFromProject, deleteOSLCLink, errorMessage, findElementsByFullName, findNestedElement, findNestedElementRecursive, getAllTags, getAnnotations, getAssociationClasses, getBinaryID, getConstraints, getConstraintsByHim, getControlledFiles, getDecorationStyle, getDependencies, getDescription, getDescriptionHTML, getDescriptionPlainText, getDescriptionRTF, getDisplayName, getDisplayNameRTF, getErrorMessage, getFullPathName, getFullPathNameIn, getGUID, getHyperLinks, getIconFileName, getInterfaceName, getIsExternal, getIsOfMetaClass, getIsShowDisplayName, getIsUnresolved, getLocalTags, getMainDiagram, getMetaClass, getName, getNestedElements, getNestedElementsByMetaClass, getNestedElementsRecursive, getNewTermStereotype, getOfTemplate, getOSLCLinks, getOverlayIconFileName, getOverriddenProperties, getOverriddenPropertiesByPattern, getOwnedDependencies, getOwner, getProject, getPropertyValue, getPropertyValueConditional, getPropertyValueConditionalExplicit, getPropertyValueExplicit, getRedefines, getReferences, getRemoteDependencies, getRemoteURI, getRequirementTraceabilityHandle, getSaveUnit, getStereotype, getStereotypes, getTag, getTemplateParameters, getTi, getToolTipHTML, getUserDefinedMetaClass, hasNestedElements, hasPanelWidget, highLightElement, isATemplate, isDescriptionRTF, isDisplayNameRTF, isModified, isRemote, locateInBrowser, lockOnDesignManager, openFeaturesDialog, removeProperty, removeRedefines, removeStereotype, setDecorationStyle, setDescription, setDescriptionAndHyperlinks, setDescriptionHTML, setDescriptionRTF, setDisplayName, setDisplayNameRTF, setGUID, setIsShowDisplayName, setMainDiagram, setName, setOfTemplate, setOwner, setPropertyValue, setRequirementTraceabilityHandle, setStereotype, setTagContextValue, setTagElementValue, setTagValue, setTi, synchronizeTemplateInstantiation, unlockOnDesignManager
 

Method Detail

createAutoFlowChart

void createAutoFlowChart()
Creates a flowchart for the operation.


deleteArgument

void deleteArgument(IRPArgument argument)
Deletes a specific argument from the operation.

Parameters:
argument - The argument that should be deleted

deleteFlowchart

void deleteFlowchart()
Deletes the flowchart or activity defined for the operation.


getBody

java.lang.String getBody()
Returns the body of the operation.

Returns:
the body of the operation

getFlowchart

IRPFlowchart getFlowchart()
Returns the flowchart or activity defined for the operation.

Returns:
the flowchart or activity defined for the operation

getImplementationSignature

java.lang.String getImplementationSignature()
Returns the signature of the operation as it will appear in the generated code.

Returns:
the signature of the operation as it will appear in the generated code

getInitializer

java.lang.String getInitializer()
For constructors, gets the initializer code that was defined for the operation.

Returns:
the initializer code that was defined for the operation

getIsAbstract

int getIsAbstract()
Checks whether the operation was defined as abstract.

Returns:
1 if the operation was defined as abstract, 0 otherwise

getIsCgDerived

int getIsCgDerived()
Checks whether the operation is an operation that is automatically generated by Rhapsody.

Returns:
1 if the operation is automatically generated by Rhapsody, 0 otherwise

getIsConst

int getIsConst()
For operations in C++ classes, checks whether the operation was defined as a constant member function.

Returns:
1 if the operation was defined as a constant member function, 0 otherwise

getIsCtor

int getIsCtor()
Checks whether the operation is a constructor.

Returns:
1 if the operation is a constructor, 0 otherwise

getIsDtor

int getIsDtor()
Checks whether the operation is a destructor.

Returns:
1 if the operation is a destructor, 0 otherwise

getIsFinal

int getIsFinal()
For operations in Java classes, checks whether the operation was defined as final.

Returns:
1 if the operation was defined as final, 0 otherwise

getIsInline

int getIsInline()
Checks whether the code for the operation will be generated inline.

Returns:
1 if the code for the operation will be generated inline, 0 otherwise

getIsStatic

int getIsStatic()
Checks whether the operation was defined as static.

Returns:
1 if the operation was defined as static, 0 otherwise

getIsTrigger

int getIsTrigger()
Checks whether the operation was defined as a triggered operation.

Returns:
1 if the operation is a triggered operation, 0 otherwise

getIsVirtual

int getIsVirtual()
For operations in C++ or C# classes, checks whether the operation was defined as virtual.

Returns:
1 if the operation was defined as virtual, 0 otherwise

getReturnTypeDeclaration

java.lang.String getReturnTypeDeclaration()
If an on-the-fly type is used as the return type of an operation, this method returns the declaration for the type.

Returns:
the declaration for the return type

getReturns

IRPClassifier getReturns()
Gets the return type of the operation.

Returns:
the return type of the operation

getVisibility

java.lang.String getVisibility()
Gets the visibility specified for the operation.

Returns:
the visibility specified for the operation

setBody

void setBody(java.lang.String body)
Sets the body of an operation.

Parameters:
body - The code to use for the body of the operation. Use \n to represent the line breaks, for example, takePicture.setBody("openShutter();\ncloseShutter();");

setFlowchart

void setFlowchart(IRPFlowchart flowchart)
Specifies a flowchart or activity for the operation.

Parameters:
flowchart - the flowchart or activity to use for the operation

setInitializer

void setInitializer(java.lang.String initializer)
For constructors, used to specify code for the initializer of the operation.

Parameters:
initializer - The code to use for the initializer of the operation

setIsAbstract

void setIsAbstract(int isAbstract)
Specifies whether an operation should be defined as abstract.

Parameters:
isAbstract - Use 1 to specify that the operation should be defined as abstract. Use 0 to specify that the operation should not be defined as abstract.

setIsConst

void setIsConst(int isConst)
For operations in C++ classes, used to specify whether an operation should be defined as a constant member function.

Parameters:
isConst - Use 1 to specify that the operation should be defined as a constant member function. Use 0 to specify that the operation should not be defined as a constant member function.

setIsFinal

void setIsFinal(int isFinal)
For operations in Java classes, used to specify whether an operation should be defined as final.

Parameters:
isFinal - Use 1 to specify that the operation should be defined as final. Use 0 to specify that the operation should not be defined as final.

setIsStatic

void setIsStatic(int isStatic)
Specifies whether an operation should be defined as static.

Parameters:
isStatic - Use 1 to specify that the operation should be defined as static. Use 0 to specify that the operation should not be defined as static.

setIsVirtual

void setIsVirtual(int isVirtual)
For operations in C++ or C# classes, used to specify whether an operation should be defined as virtual.

Parameters:
isVirtual - Use 1 to specify that the operation should be defined as virtual. Use 0 to specify that the operation should not be defined as virtual.

setReturnTypeDeclaration

void setReturnTypeDeclaration(java.lang.String newVal)
Creates an on-the-fly type to use as the return type of the operation, using the declaration that you provide as a parameter.

Parameters:
newVal - The declaration to use for the on-the-fly type that is to be created to use as the return type of the operation

setReturns

void setReturns(IRPClassifier returns)
Specifies the return type of the operation.

Parameters:
returns - the return type to use for the operation

setVisibility

void setVisibility(java.lang.String visibility)
set property visibility

Throws:
RhapsodyRuntimeException