ProjectDefinition.st
changeset 11752 484d542ad43f
parent 11713 7030a140beba
child 11777 000651e1db46
child 17711 39faaaf888b4
equal deleted inserted replaced
11751:1e75c54748ef 11752:484d542ad43f
   101 
   101 
   102     setOfAllPreRequisites := Set new.
   102     setOfAllPreRequisites := Set new.
   103     toAdd := Set new.
   103     toAdd := Set new.
   104     toAdd addAll:self effectivePreRequisites.
   104     toAdd addAll:self effectivePreRequisites.
   105 
   105 
   106     "are subprojects really a prerequisite??
   106     "is a subproject really a prerequisite??
   107      I think, they are not, so this line should be deleted.
   107      No, it works the other way: parent projects are prerequisites of sub projects,
   108      Unfortunately the meaning of 'subproject' has never been defined. SV."
   108      so the following line has been deleted.
   109     toAdd addAll:self effectiveSubProjects.
   109      Unfortunately the meaning of 'subproject' has never been well defined. SV."
       
   110 "/    toAdd addAll:self effectiveSubProjects.
   110 
   111 
   111     [toAdd notEmpty] whileTrue:[
   112     [toAdd notEmpty] whileTrue:[
   112         |aPreRequisiteProjectID def|
   113         |aPreRequisiteProjectID def|
   113 
   114 
   114         aPreRequisiteProjectID := toAdd removeFirst.
   115         aPreRequisiteProjectID := toAdd removeFirst.
   122                 def effectivePreRequisites 
   123                 def effectivePreRequisites 
   123                     select:[:eachSubPreRequisite | (setOfAllPreRequisites includes:eachSubPreRequisite) not]
   124                     select:[:eachSubPreRequisite | (setOfAllPreRequisites includes:eachSubPreRequisite) not]
   124                     thenDo:[:eachSubPreRequisite | 
   125                     thenDo:[:eachSubPreRequisite | 
   125                                 Transcript showCR:(aPreRequisiteProjectID, ' requires ', eachSubPreRequisite).
   126                                 Transcript showCR:(aPreRequisiteProjectID, ' requires ', eachSubPreRequisite).
   126                                 toAdd add:eachSubPreRequisite ].
   127                                 toAdd add:eachSubPreRequisite ].
       
   128 
       
   129                 "but subprojects of our prerequisites are also prerequisites"
   127                 def effectiveSubProjects 
   130                 def effectiveSubProjects 
   128                     select:[:eachSubSubRequisite | (setOfAllPreRequisites includes:eachSubSubRequisite) not]
   131                     select:[:eachSubSubRequisite | (setOfAllPreRequisites includes:eachSubSubRequisite) not]
   129                     thenDo:[:eachSubSubRequisite | 
   132                     thenDo:[:eachSubSubRequisite | 
   130                                 Transcript showCR:(aPreRequisiteProjectID, ' hasSub ', eachSubSubRequisite).
   133                                 Transcript showCR:(aPreRequisiteProjectID, ' hasSub ', eachSubSubRequisite).
   131                                 toAdd add:eachSubSubRequisite ].
   134                                 toAdd add:eachSubSubRequisite ].
  4181 ! !
  4184 ! !
  4182 
  4185 
  4183 !ProjectDefinition class methodsFor:'documentation'!
  4186 !ProjectDefinition class methodsFor:'documentation'!
  4184 
  4187 
  4185 version
  4188 version
  4186     ^ '$Header: /cvs/stx/stx/libbasic/ProjectDefinition.st,v 1.219 2009-05-25 13:46:30 stefan Exp $'
  4189     ^ '$Header: /cvs/stx/stx/libbasic/ProjectDefinition.st,v 1.220 2009-06-08 16:37:44 stefan Exp $'
  4187 ! !
  4190 ! !
  4188 
  4191 
  4189 ProjectDefinition initialize!
  4192 ProjectDefinition initialize!