Skip to content

Commit d1eb8f7

Browse files
committed
ST6RI-831 Changed "item flow" to flow in some comments and names.
1 parent f669790 commit d1eb8f7

4 files changed

Lines changed: 35 additions & 35 deletions

File tree

org.omg.kerml.xtext/src/org/omg/kerml/xtext/validation/KerMLValidator.xtend

Lines changed: 23 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -319,17 +319,17 @@ class KerMLValidator extends AbstractKerMLValidator {
319319
public static val INVALID_OPERATOR_EXPRESSION_BRACKET_OPERATOR = "validateOperatorExpressionBracketOperator_"
320320
public static val INVALID_OPERATOR_EXPRESSION_BRACKET_OPERATOR_MSG = "Use #(...) for indexing"
321321

322-
public static val INVALID_ITEM_FLOW_ITEM_FEATURE = "validateItemFlowItemFeature"
323-
public static val INVALID_ITEM_FLOW_ITEM_FEATURE_MSG = "Only one item feature is allowed"
324-
325-
public static val INVALID_ITEM_FLOW_END_OWNING_TYPE = "validateItemFlowEndOwningType"
326-
public static val INVALID_ITEM_FLOW_END_OWNING_TYPE_MSG = "Item flow end not allowed"
327-
public static val INVALID_ITEM_FLOW_END_NESTED_FEATURE = "validateItemFlowEndNestedFeature"
328-
public static val INVALID_ITEM_FLOW_END_NESTED_FEATURE_MSG = "Item flow end must have a nested input or output feature"
329-
public static val INVALID_ITEM_FLOW_END_SUBSETTING = 'validateItemFlowEndSubsetting'
330-
public static val INVALID_ITEM_FLOW_END_SUBSETTING_MSG = "Cannot identify item flow end (use dot notation)"
331-
public static val INVALID_ITEM_FLOW_END_IMPLICIT_SUBSETTING = "validateItemFlowEndImplicitSubsetting"
332-
public static val INVALID_ITEM_FLOW_END_IMPLICIT_SUBSETTING_MSG = "Flow ends should use dot notation"
322+
public static val INVALID_FLOW_ITEM_FEATURE = "validateFlowItemFeature"
323+
public static val INVALID_FLOW_ITEM_FEATURE_MSG = "Only one item feature is allowed"
324+
325+
public static val INVALID_FLOW_END_OWNING_TYPE = "validateFlowEndOwningType"
326+
public static val INVALID_FLOW_END_OWNING_TYPE_MSG = "Flow end not allowed"
327+
public static val INVALID_FLOW_END_NESTED_FEATURE = "validateFlowEndNestedFeature"
328+
public static val INVALID_FLOW_END_NESTED_FEATURE_MSG = "Flow end must have a nested input or output feature"
329+
public static val INVALID_FLOW_END_SUBSETTING = "validateFlowEndSubsetting"
330+
public static val INVALID_FLOW_END_SUBSETTING_MSG = "Cannot identify flow end (use dot notation)"
331+
public static val INVALID_FLOW_END_IMPLICIT_SUBSETTING = "validateFlowEndImplicitSubsetting"
332+
public static val INVALID_FLOW_END_IMPLICIT_SUBSETTING_MSG = "Flow ends should use dot notation"
333333

334334
public static val INVALID_FEATURE_VALUE_IS_INITIAL = "validateFeatureValueIsInitial"
335335
public static val INVALID_FEATURE_VALUE_IS_INITIAL_MSG = "Initialized feature must be variable"
@@ -1247,33 +1247,33 @@ class KerMLValidator extends AbstractKerMLValidator {
12471247
// }
12481248

12491249
@Check
1250-
def checkItemFlow(Flow flow) {
1251-
// validateItemFlowItemFeature
1250+
def checkFlow(Flow flow) {
1251+
// validateFlowItemFeature
12521252
val items = flow.ownedFeature.filter[f | f instanceof PayloadFeature]
1253-
checkAtMostOne(items, INVALID_ITEM_FLOW_ITEM_FEATURE_MSG, null, INVALID_ITEM_FLOW_ITEM_FEATURE)
1253+
checkAtMostOne(items, INVALID_FLOW_ITEM_FEATURE_MSG, null, INVALID_FLOW_ITEM_FEATURE)
12541254
}
12551255

12561256
@Check
1257-
def checkItemFlowEnd(FlowEnd flowEnd) {
1258-
// validateItemFlowEndIsEnd is automatically satisfied
1257+
def checkFlowEnd(FlowEnd flowEnd) {
1258+
// validateFlowEndIsEnd is automatically satisfied
12591259

1260-
// validateItemFlowEndNestedFeature
1260+
// validateFlowEndNestedFeature
12611261
if (flowEnd.ownedFeature.size != 1) {
1262-
error(INVALID_ITEM_FLOW_END_NESTED_FEATURE_MSG, flowEnd, null, INVALID_ITEM_FLOW_END_NESTED_FEATURE)
1262+
error(INVALID_FLOW_END_NESTED_FEATURE_MSG, flowEnd, null, INVALID_FLOW_END_NESTED_FEATURE)
12631263
}
12641264

1265-
// validateItemFlowEndOwningType
1265+
// validateFlowEndOwningType
12661266
if (!(flowEnd.owningType instanceof Flow)) {
1267-
error(INVALID_ITEM_FLOW_END_OWNING_TYPE_MSG, flowEnd, null, INVALID_ITEM_FLOW_END_OWNING_TYPE)
1267+
error(INVALID_FLOW_END_OWNING_TYPE_MSG, flowEnd, null, INVALID_FLOW_END_OWNING_TYPE)
12681268
}
12691269

1270-
// TODO: Add validateItemFlowEndSubsetting? validateItemFlowEndImplicitSubsetting?
1270+
// TODO: Add validateFlowEndSubsetting? validateFlowEndImplicitSubsetting?
12711271
if (FeatureUtil.getSubsettedNotRedefinedFeaturesOf(flowEnd).isEmpty) {
1272-
error(INVALID_ITEM_FLOW_END_SUBSETTING_MSG, flowEnd, null, INVALID_ITEM_FLOW_END_SUBSETTING)
1272+
error(INVALID_FLOW_END_SUBSETTING_MSG, flowEnd, null, INVALID_FLOW_END_SUBSETTING)
12731273
} else if (flowEnd.ownedSubsetting.isEmpty) {
12741274
val features = flowEnd.ownedFeature
12751275
if (!features.isEmpty && !features.get(0).ownedRedefinition.isEmpty) {
1276-
warning(INVALID_ITEM_FLOW_END_IMPLICIT_SUBSETTING_MSG, flowEnd, null, INVALID_ITEM_FLOW_END_IMPLICIT_SUBSETTING)
1276+
warning(INVALID_FLOW_END_IMPLICIT_SUBSETTING_MSG, flowEnd, null, INVALID_FLOW_END_IMPLICIT_SUBSETTING)
12771277
}
12781278
}
12791279
}

org.omg.sysml/src/org/omg/sysml/delegate/setting/Flow_flowEnd_SettingDelegate.java

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -36,12 +36,12 @@ public Flow_flowEnd_SettingDelegate(EStructuralFeature eStructuralFeature) {
3636

3737
@Override
3838
protected EList<FlowEnd> basicGet(InternalEObject owner) {
39-
EList<FlowEnd> itemFlows = new NonNotifyingEObjectEList<>(FlowEnd.class, owner, eStructuralFeature.getFeatureID());
39+
EList<FlowEnd> flowEnds = new NonNotifyingEObjectEList<>(FlowEnd.class, owner, eStructuralFeature.getFeatureID());
4040
super.basicGet(owner).stream().
4141
filter(FlowEnd.class::isInstance).
4242
map(FlowEnd.class::cast).
43-
forEachOrdered(itemFlows::add);
44-
return itemFlows;
43+
forEachOrdered(flowEnds::add);
44+
return flowEnds;
4545
}
4646

4747
}

org.omg.sysml/src/org/omg/sysml/delegate/setting/Flow_payloadType_SettingDelegate.java

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -38,15 +38,15 @@ public Flow_payloadType_SettingDelegate(EStructuralFeature eStructuralFeature) {
3838

3939
@Override
4040
protected EList<Classifier> basicGet(InternalEObject owner) {
41-
EList<Classifier> itemType = new NonNotifyingEObjectEList<>(Classifier.class, owner, eStructuralFeature.getFeatureID());
42-
PayloadFeature itemFeature = ((Flow)owner).getPayloadFeature();
43-
if (itemFeature != null) {
44-
itemFeature.getType().stream().
41+
EList<Classifier> payloadType = new NonNotifyingEObjectEList<>(Classifier.class, owner, eStructuralFeature.getFeatureID());
42+
PayloadFeature payloadFeature = ((Flow)owner).getPayloadFeature();
43+
if (payloadFeature != null) {
44+
payloadFeature.getType().stream().
4545
filter(Classifier.class::isInstance).
4646
map(Classifier.class::cast).
47-
forEachOrdered(itemType::add);
47+
forEachOrdered(payloadType::add);
4848
}
49-
return itemType;
49+
return payloadType;
5050
}
5151

5252
}

org.omg.sysml/src/org/omg/sysml/delegate/setting/Usage_directedUsage_SettingDelegate.java

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -36,11 +36,11 @@ public Usage_directedUsage_SettingDelegate(EStructuralFeature eStructuralFeature
3636

3737
@Override
3838
protected EList<?> basicGet(InternalEObject owner) {
39-
EList<Usage> flows = new NonNotifyingEObjectEList<>(Usage.class, owner, eStructuralFeature.getFeatureID());
39+
EList<Usage> directedUsages = new NonNotifyingEObjectEList<>(Usage.class, owner, eStructuralFeature.getFeatureID());
4040
((Usage)owner).getUsage().stream().
4141
filter(usage->usage.getDirection() != null).
42-
forEachOrdered(flows::add);
43-
return flows;
42+
forEachOrdered(directedUsages::add);
43+
return directedUsages;
4444
}
4545

4646
}

0 commit comments

Comments
 (0)