Data Mining and Semantic Web services(6)

2021-09-24 15:11

{irreflexive}

+reviews

+managers0..n

Employee

0..n

1

+reviewed by

{asymmetric}

Employee

+managed by

Figure 7. Notation for irreflexive and asymmetric

constraints on reflexive associations

+rbA

+ra

R{acyclic}

Figure 8. Reflexive relationship with acyclic constraint

The following OCL expression captures disjoint const-raint between subclasses B and C of super class A:

context A

inv: B Æ forAll(b:B|

C Æ forAll(c:C|b.self<>c.self))

int}

UML does not provide built-in constraints for ref-lexive associations, except possibility to specify them as textual constraints in chosen language. As in other cases, for graphical notation we add corresponding tags to reflexive association relationships (Figure 7): “Irreflexive“, “Asymmetric“, “Acyclic“, “Intransi-tive“, “Symmetric“, and “Antisymmetric“. Before de-fining OCL expression for acyclic constraint on refle-xive relationship (the general case is represented in Figure 8) we have to introduce the transitive closure operation 0:

6. Integrity constraints on sets of objects

Equality constraint is used for groups of optional relationships or attributes. If used between two or more relationships it specifies equal dependency bet-ween them. This means that if class instance partici-pates in one relation, so it must participate in all other relationships constrained by this constraint; instances participating only in one relation could not exist 0, 0, 0, 0, 0. Analogously, equality constraint between attributes indicates that if one of attributes has value other attributes constrained by this constraint also must do so. UML specifies equality constraint as textual constraint in a note for class. Figure 9 presents suggested extension of UML graphical notation for equality constraints. Tagged value {equn} is proposed to mark optional attributes or relationships constrained by equality constraint. Equality constraint on group of optional attributes c1,…, cn of object type A can be defined by OCL expression:

context A

Figure 6. Notation for integrity constraints on generalization

relationship

Reflexive associations often have constraints. There are six types of constraints for reflexive rela-tionship analyzed in 0 (where they are named as “ring constraints”):

“Irreflexive” constraint prevents an instance from participating on both sides of a relationship at the same time, i.e., any instance of class A cannot have association with itself. “Asymmetric” constraint

Abstract. Integrity constraints are incident part of conceptual models, including part of semantics of problem domain. Analysis of the most important methods of conceptual modelling has revealed that none of them analyze the complete set of integrity const

Representation of Integrity Constraints in Conceptual Models inv: (self.c1.isUndefined() implies self.c2.isUndefined() … and self.ci.isUndefined() … and .isUndefined())) and

(self.c2.isUndefined() implies self.c1.isUndefined() and Self.c3.isUndefined() … and self.ci.isUndefined() … and .isUndefined()) … and

(self.ci.isUndefined() implies self.c1.isUndefined() and

Self.ci-1.isUndefined() … and self.ci+1.isUndefined() … and .isUndefined()) … and

(.isUndefined() implies self.c1.isUndefined() and self.ci.isUndefined() … and -1.isUndefined()) or

<<subset>>

(not(self.c1.isUndefined()) implies not(self.c2.isUndefined()) … and not(self.ci.isUndefined()) … and not(.isUndefined())) and

(not(self.c2.isUndefined()) implies not(self.c1.isUndefined()) and not(self.c3.isUndefined()) … and not(self.ci.isUndefined()) … and not(.isUndefined())) … and

(not(self.ci.isUndefined()) implies not(self.c1.isUndefined()) and not(self.ci-1.isUndefined()) …and not(self.ci+1.isUndefined()) …and not(.isUndefined())) … and

(not(.isUndefined()) implies (not(self.c1.isUndefined()) and not(self.ci.isUndefined()) …and not(-1.isUndefined()))

Employee

firstName{subset1}lastName{set1}address[0..1]{equ1}countryCode{R1}{equ1}personalCode{I1;EU1}passportNo[0..1]{D1}

socialSecurityNo[0..1]{D1}sex

birthday/age

+performerR2+performs1

Task

0..nname

{OR}

performer{R2}

+inspector+inspectsinspector{R3}

0..n1R3

Figure 9. Example of notation of integrity constraints on set of objects

Subset constraint between two relationships indi-cates that set of class instances participating in both

relationships is subset of class instances participating in one relationship 0, 0, 0, 0, 0. In other words, an instance of class must participate in one relationship before it can participate in another relationship. Analogously subset constraint can be defined on optional attributes. UML allows to specify subset constraints between associations by attaching the tagged value "{subset}" to the dependency arrow bet-ween the associations 0, 0 (for unification of representation, we rename “constraint label” used in original source with value of tag, defined by stereo-type of constrained element). Direction of the arrow is from subset to set. However UML does not provide a graphic notation for subset constraints defined by attributes. To present these subset constraints graphi-cally we introduce reflexive dependency for class with tag {subset} and tagged values {setn}/{subsetn} for attributes (groups of attributes) defining subset constraint on set of instances (Fig. 9). Let have object A with subset constraint on attributes v1,…,vn mar-ked with tag {subsetn} and p1,…, p2 marked with tag {setn}. This means that the set of object A

Data Mining and Semantic Web services(6).doc 将本文的Word文档下载到电脑 下载失败或者文档不完整,请联系客服人员解决!

下一篇:充分发挥先进典型在企业文化建设中的作用

相关阅读
本类排行
× 注册会员免费下载(下载后可以自由复制和排版)

马上注册会员

注:下载文档有可能“只有目录或者内容不全”等情况,请下载之前注意辨别,如果您已付费且无法下载或内容有问题,请联系我们协助你处理。
微信: QQ: