Specify port contracts

Enforcing a specification of a special interface as the contract for a port might seem to be artificial, so the product provides the notion for an implicit contract. An implicit contract means that if the contract is implicit, you can specify a list of provided and required interfaces that are not related to each other, while the contract interface remains implicit (no need to explicitly define a special interface to be the contract for the port in the model).

Working with implicit contracts has pros and cons. If the port is connected to other ports that provide and require only subsets of its provided and required interfaces, it is more natural to work with implicit contracts. However, if the port is connected to another port that is exactly "reversed" (see the check box in the Features window for the port) or if other ports provide and require the same set of interfaces, it makes sense to work with explicit contracts. This is like specifying objects separately from the classes, or objects with implicit classes in the case when only a single object of this type or class exists in the system.


Feedback