本文整理了Java中org.eclipse.uml2.uml.Operation.setName()
方法的一些代码示例,展示了Operation.setName()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Operation.setName()
方法的具体详情如下:
包路径:org.eclipse.uml2.uml.Operation
类名称:Operation
方法名:setName
暂无
代码示例来源:origin: org.eclipse.uml2/org.eclipse.uml2.uml
getOwnedOperations().add(newOwnedOperation);
if (name != null)
newOwnedOperation.setName(name);
int ownedParameterListSize = 0;
int ownedParameterNamesSize = ownedParameterNames == null
代码示例来源:origin: org.eclipse.uml2/org.eclipse.uml2.uml
getOwnedOperations().add(newOwnedOperation);
if (name != null)
newOwnedOperation.setName(name);
int ownedParameterListSize = 0;
int ownedParameterNamesSize = ownedParameterNames == null
代码示例来源:origin: org.eclipse.uml2/org.eclipse.uml2.uml
getOwnedOperations().add(newOwnedOperation);
if (name != null)
newOwnedOperation.setName(name);
int ownedParameterListSize = 0;
int ownedParameterNamesSize = ownedParameterNames == null
代码示例来源:origin: org.eclipse.uml2/org.eclipse.uml2.uml
getOwnedOperations().add(newOwnedOperation);
if (name != null)
newOwnedOperation.setName(name);
int ownedParameterListSize = 0;
int ownedParameterNamesSize = ownedParameterNames == null
代码示例来源:origin: org.eclipse.ocl/uml
public Operation createOperation(String name, Classifier resultType,
List<String> paramNames, List<Classifier> paramTypes) {
Operation result = UMLFactory.eINSTANCE.createOperation();
result.setName(name);
// OCL can only define query operations
result.setIsQuery(true);
if (resultType != null) {
result.setType(resultType);
}
int i = 0;
for (String pname : paramNames) {
result.createOwnedParameter(pname, paramTypes.get(i++));
}
return result;
}
代码示例来源:origin: org.eclipse.uml2/org.eclipse.uml2.uml
getOwnedOperations(classifier).add(operation);
operation.setName(eOperation.getName());
代码示例来源:origin: org.eclipse.ocl/uml
public Operation defineOperation(Classifier owner, String name,
Classifier type, List<Variable<Classifier, Parameter>> params,
Constraint constraint) {
resetTypeCaches();
Operation result = UMLFactory.eINSTANCE.createOperation();
result.addKeyword(UMLReflection.OCL_HELPER);
result.setName(name);
result.setType(type == null ? getOCLStandardLibrary().getOclVoid()
: type);
result.setIsQuery(true); // OCL can only define queries
for (Variable<Classifier, Parameter> next : params) {
Parameter param = UMLFactory.eINSTANCE.createParameter();
param.setName(next.getName());
param.setType(next.getType() == null ? getOCLStandardLibrary()
.getOclVoid()
: next.getType());
param.setDirection(ParameterDirectionKind.IN_LITERAL);
param.setEffect(ParameterEffectKind.READ_LITERAL);
result.getOwnedParameters().add(param);
}
annotate(result, constraint);
addHelperOperation(owner, result);
return result;
}
内容来源于网络,如有侵权,请联系作者删除!