OCL 2.0b2 NO IDEA Avatar
  1. OMG Issue

OCL2 — OCL 2: flatten

  • Key: OCL2-2
  • Legacy Issue Number: 5970
  • Status: closed  
  • Source: HL7 ( Mr. Grahame Grieve)
  • Summary:

    quotes from ad/2003-01-07 (v1.6 of OCL 2 proposal):

    Section 1.5.1 says, "the flatten operation is a deep flatten, it
    completely flattens a nested collection of any depth". However the
    formal definition is :

    post: result = if self.type.elementType.oclIsKindOf(CollectionType) then
    self->iterate(c; acc : Set() = Set{} |
    acc->union(c->asSet() ) )
    else
    self
    endif

    From Section 6.5.1 (definition of Set.Flatten). The formal declaration does
    not show that the flatten operation is deep. This discussion is extended in
    Appendix A, which presents an analogous postcondition, but explains that this
    is for a single level only.

    It would seem that the post-condition(s) in section 6.5.1 are wrong?

  • Reported: OCL 2.0b1 — Tue, 22 Apr 2003 04:00 GMT
  • Disposition: Resolved — OCL 2.0b2
  • Disposition Summary:

    No Data Available

  • Updated: Fri, 6 Mar 2015 20:58 GMT