|
49 | 49 | <xsl:with-param name="generalizationConnector" select="."/>
|
50 | 50 | </xsl:call-template>
|
51 | 51 | </xsl:if>
|
| 52 | + <xsl:if test="./source/model/@type = 'ProxyConnector' and ./target/model/@type = 'ProxyConnector'"> |
| 53 | + <xsl:call-template name="generalizationUnidirectionalConnectorsDirection"> |
| 54 | + <xsl:with-param name="generalizationConnector" select="."/> |
| 55 | + </xsl:call-template> |
| 56 | + <xsl:call-template name="generalizationMissingOrInvalidClassGeneralization"> |
| 57 | + <xsl:with-param name="generalizationConnector" select="."/> |
| 58 | + </xsl:call-template> |
| 59 | + </xsl:if> |
52 | 60 | </xsl:variable>
|
53 | 61 | <xsl:if test="boolean($generalizationChecks)">
|
54 | 62 | <xsl:choose>
|
|
258 | 266 | select="f:getTargetConnectorFromGeneralisation($generalizationConnector)"/>
|
259 | 267 | <xsl:variable name="sourceConnector"
|
260 | 268 | select="f:getSourceConnectorFromGeneralisation($generalizationConnector)"/>
|
261 |
| - <xsl:variable name="targetConnectorString" select="fn:concat($targetConnector/source/model/@name,' -> ', $targetConnector/target/model/@name)"/> |
262 |
| - <xsl:variable name="sourceConnectorString" select="fn:concat($sourceConnector/source/model/@name,' -> ', $sourceConnector/target/model/@name)"/> |
| 269 | + <xsl:variable name="targetConnectorString" select="fn:concat($targetConnector/source/model/@name,' -> ', $targetConnector/target/model/@name)"/> |
| 270 | + <xsl:variable name="sourceConnectorString" select="fn:concat($sourceConnector/source/model/@name,' -> ', $sourceConnector/target/model/@name)"/> |
263 | 271 | <xsl:sequence
|
264 | 272 | select="
|
265 | 273 | if (not(f:generalisationConnectorsHasOppositeDirections($generalizationConnector))) then
|
266 | 274 | ()
|
267 | 275 | else
|
268 |
| - f:generateErrorMessage('The unidirectional connectors $connector1$ and $connector2$ associated with the generalisation connector have opposite directions', |
| 276 | + f:generateErrorMessage(fn:concat('The unidirectional connectors ',$targetConnectorString, ' and ', $sourceConnectorString,' associated with the generalisation connector have opposite directions'), |
| 277 | + path($generalizationConnector), |
| 278 | + 'generalisation-connector-unidirectional-connector-direction-8', |
| 279 | + '', |
| 280 | + '' |
| 281 | + )" |
| 282 | + /> |
| 283 | + </xsl:template> |
| 284 | + |
| 285 | + <xd:doc> |
| 286 | + <xd:desc>[generalisation-connector-and-missing-class-generalisation-9] [generalisation-connector-and-class-inheritance-direction-10] - |
| 287 | + Missing class generalisation for two distinct classes related to the connector generalisation or |
| 288 | + connector generalisation and class generalisation relationship direction mismatch |
| 289 | + </xd:desc> |
| 290 | + <xd:param name="generalizationConnector"/> |
| 291 | + </xd:doc> |
| 292 | + |
| 293 | + <xsl:template name="generalizationMissingOrInvalidClassGeneralization"> |
| 294 | + <xsl:param name="generalizationConnector"/> |
| 295 | + <xsl:variable name="targetConnector" |
| 296 | + select="f:getTargetConnectorFromGeneralisation($generalizationConnector)"/> |
| 297 | + <xsl:variable name="sourceConnector" |
| 298 | + select="f:getSourceConnectorFromGeneralisation($generalizationConnector)"/> |
| 299 | + <xsl:variable name="targetConnectorString" select="fn:concat($targetConnector/source/model/@name,' -> ', $targetConnector/target/model/@name)"/> |
| 300 | + <xsl:variable name="sourceConnectorString" select="fn:concat($sourceConnector/source/model/@name,' -> ', $sourceConnector/target/model/@name)"/> |
| 301 | + <xsl:sequence |
| 302 | + select=" |
| 303 | + if (not(f:generalisationMissingOrIncorrect($generalizationConnector))) then |
| 304 | + () |
| 305 | + else |
| 306 | + f:generateErrorMessage(fn:concat('The generalisation between ',$targetConnectorString, ' and ', $sourceConnectorString,' is missing or has invalid direction'), |
269 | 307 | path($generalizationConnector),
|
270 | 308 | 'generalisation-connector-unidirectional-connector-direction-8',
|
271 | 309 | '',
|
|
0 commit comments