Project.st
changeset 5150 d7f854b5ede8
parent 5126 3395d5b1c464
child 5151 f242e78be683
--- a/Project.st	Fri Dec 24 01:45:48 1999 +0100
+++ b/Project.st	Tue Dec 28 15:03:48 1999 +0100
@@ -13,22 +13,22 @@
 Object subclass:#Project
 	instanceVariableNames:'name changeSet views directoryName properties packageName
 		repositoryDirectory repositoryModule overwrittenMethods
-		subProjects prerequisites isLoaded'
+		subProjects prerequisites isLoaded changedClasses'
 	classVariableNames:'CurrentProject SystemProject NextSequential AllProjects
 		LoadedProjects'
 	poolDictionaries:''
 	category:'System-Support'
 !
 
-Object subclass:#MethodInfo
-	instanceVariableNames:'conditionForInclusion methodName className fileName'
+Object subclass:#ClassInfo
+	instanceVariableNames:'conditionForInclusion className classFileName'
 	classVariableNames:''
 	poolDictionaries:''
 	privateIn:Project
 !
 
-Object subclass:#ClassInfo
-	instanceVariableNames:'conditionForInclusion className classFileName'
+Object subclass:#MethodInfo
+	instanceVariableNames:'conditionForInclusion methodName className fileName'
 	classVariableNames:''
 	poolDictionaries:''
 	privateIn:Project
@@ -416,12 +416,11 @@
 addClassDefinitionChangeFor:aClass
     "add a class-def-change for aClass to the current project"
 
-    |p c|
+    |p|
 
     p := CurrentProject.
-    (p notNil 
-    and:[(c := p changeSet) notNil]) ifTrue:[
-	c addClassDefinitionChangeFor:aClass 
+    p notNil ifTrue:[
+        p addClassDefinitionChangeFor:aClass 
     ]
 
     "Created: 3.12.1995 / 13:44:58 / cg"
@@ -431,36 +430,33 @@
 addMethodCategoryChange:aMethod category:newCategory in:aClass
     "add a method-category-change for aMethod in aClass to the current project"
 
-    |p c|
+    |p|
 
     p := CurrentProject.
-    (p notNil 
-    and:[(c := p changeSet) notNil]) ifTrue:[
-	c addMethodCategoryChange:aMethod category:newCategory in:aClass 
+    p notNil ifTrue:[
+        p addMethodCategoryChange:aMethod category:newCategory in:aClass 
     ]
 !
 
 addMethodChange:aMethod in:aClass
     "add a method change in aClass to the current project"
 
-    |p c|
+    |p|
 
     p := CurrentProject.
-    (p notNil 
-    and:[(c := p changeSet) notNil]) ifTrue:[
-	c addMethodChange:aMethod in:aClass 
-    ]
+    p notNil ifTrue:[
+        p addMethodChange:aMethod in:aClass 
+    ].
 !
 
 addMethodPrivacyChange:aMethod in:aClass
     "add a privacy change for aMethod in aClass to the current project"
 
-    |p c|
+    |p|
 
     p := CurrentProject.
-    (p notNil 
-    and:[(c := p changeSet) notNil]) ifTrue:[
-	c addMethodPrivacyChange:aMethod in:aClass 
+    p notNil ifTrue:[
+        p addMethodPrivacyChange:aMethod in:aClass 
     ]
 
     "Modified: 27.8.1995 / 22:48:17 / claus"
@@ -469,48 +465,44 @@
 addPrimitiveDefinitionsChangeFor:aClass
     "add a primitiveDef change for aClass to the current project"
 
-    |p c|
+    |p|
 
     p := CurrentProject.
-    (p notNil 
-    and:[(c := p changeSet) notNil]) ifTrue:[
-	c addPrimitiveDefinitionsChangeFor:aClass 
+    p notNil ifTrue:[
+        p addPrimitiveDefinitionsChangeFor:aClass 
     ]
 !
 
 addPrimitiveFunctionsChangeFor:aClass
     "add a primitiveFuncs change for aClass to the current project"
 
-    |p c|
+    |p|
 
     p := CurrentProject.
-    (p notNil 
-    and:[(c := p changeSet) notNil]) ifTrue:[
-	c addPrimitiveFunctionsChangeFor:aClass 
+    p notNil ifTrue:[
+        p addPrimitiveFunctionsChangeFor:aClass 
     ]
 !
 
 addPrimitiveVariablesChangeFor:aClass
     "add a primitiveVars change for aClass to the current project"
 
-    |p c|
+    |p|
 
     p := CurrentProject.
-    (p notNil 
-    and:[(c := p changeSet) notNil]) ifTrue:[
-	c addPrimitiveVariablesChangeFor:aClass 
+    p notNil ifTrue:[
+        p addPrimitiveVariablesChangeFor:aClass 
     ]
 !
 
 addRemoveSelectorChange:aSelector in:aClass
     "add a method-remove change in aClass to the current project"
 
-    |p c|
+    |p|
 
     p := CurrentProject.
-    (p notNil 
-    and:[(c := p changeSet) notNil]) ifTrue:[
-	c addRemoveSelectorChange:aSelector in:aClass 
+    p notNil ifTrue:[
+        p addRemoveSelectorChange:aSelector in:aClass 
     ]
 
     "Created: / 16.2.1998 / 12:45:10 / cg"
@@ -586,6 +578,14 @@
     "Modified: 27.1.1997 / 11:59:02 / cg"
 !
 
+changedClasses
+    ^  changedClasses ifNil:[changedClasses := IdentitySet new].
+
+    "
+     self new changedClasses
+    "
+!
+
 defaultNameSpace
     "return the defaultNameSpace of this project.
      New classes will (if not specified by a directive) be installed
@@ -858,6 +858,96 @@
 
 !Project methodsFor:'changes'!
 
+addClassDefinitionChangeFor:aClass
+    "add a class-def-change for aClass to the current project"
+
+    |changeSet|
+
+    (changeSet := self changeSet) notNil ifTrue:[
+        changeSet addClassDefinitionChangeFor:aClass 
+    ].
+    self changedClasses add:aClass
+!
+
+addMethodCategoryChange:aMethod category:newCategory in:aClass
+    "add a method-category-change for aMethod in aClass to the current project"
+
+    |changeSet|
+
+    (changeSet := self changeSet) notNil ifTrue:[
+        changeSet addMethodCategoryChange:aMethod category:newCategory in:aClass 
+    ].
+    self changedClasses add:aClass
+
+!
+
+addMethodChange:aMethod in:aClass
+    "add a method change in aClass to the current project"
+
+    |changeSet|
+
+    (changeSet := self changeSet) notNil ifTrue:[
+        changeSet addMethodChange:aMethod in:aClass 
+    ].
+    self changedClasses add:aClass
+
+!
+
+addMethodPrivacyChange:aMethod in:aClass
+    "add a privacy change for aMethod in aClass to the current project"
+
+    |changeSet|
+
+    (changeSet := self changeSet) notNil ifTrue:[
+        changeSet addMethodPrivacyChange:aMethod in:aClass 
+    ].
+    self changedClasses add:aClass
+!
+
+addPrimitiveDefinitionsChangeFor:aClass
+    "add a primitiveDef change for aClass to the current project"
+
+    |changeSet|
+
+    (changeSet := self changeSet) notNil ifTrue:[
+        changeSet addPrimitiveDefinitionsChangeFor:aClass 
+    ].
+    self changedClasses add:aClass
+!
+
+addPrimitiveFunctionsChangeFor:aClass
+    "add a primitiveFuncs change for aClass to the current project"
+
+    |changeSet|
+
+    (changeSet := self changeSet) notNil ifTrue:[
+        changeSet addPrimitiveFunctionsChangeFor:aClass 
+    ].
+    self changedClasses add:aClass
+!
+
+addPrimitiveVariablesChangeFor:aClass
+    "add a primitiveVars change for aClass to the current project"
+
+    |changeSet|
+
+    (changeSet := self changeSet) notNil ifTrue:[
+        changeSet addPrimitiveVariablesChangeFor:aClass 
+    ].
+    self changedClasses add:aClass
+!
+
+addRemoveSelectorChange:aSelector in:aClass
+    "add a method-remove change in aClass to the current project"
+
+    |changeSet|
+
+    (changeSet := self changeSet) notNil ifTrue:[
+        changeSet addRemoveSelectorChange:aSelector in:aClass 
+    ].
+    self changedClasses add:aClass
+!
+
 rememberOverwrittenMethod:newMethod from:oldMethod
     "this is sent whenever a method is installed, which overwrites
      an existing method from a different package.
@@ -3226,6 +3316,56 @@
     "Modified: 14.2.1997 / 15:38:47 / cg"
 ! !
 
+!Project::ClassInfo methodsFor:'accessing'!
+
+classFileName
+    "return the value of the instance variable 'classFileName' (automatically generated)"
+
+    ^ classFileName!
+
+classFileName:something
+    "set the value of the instance variable 'classFileName' (automatically generated)"
+
+    classFileName := something.!
+
+className
+    "return the value of the instance variable 'className' (automatically generated)"
+
+    ^ className!
+
+className:something
+    "set the value of the instance variable 'className' (automatically generated)"
+
+    className := something.!
+
+conditionForInclusion
+    "return the value of the instance variable 'conditionForInclusion' (automatically generated)"
+
+    ^ conditionForInclusion!
+
+conditionForInclusion:something
+    "set the value of the instance variable 'conditionForInclusion' (automatically generated)"
+
+    conditionForInclusion := something.! !
+
+!Project::ClassInfo methodsFor:'printing & storing'!
+
+displayString
+    ^ 'ClassInfo: ' , className
+! !
+
+!Project::ClassInfo methodsFor:'queries'!
+
+theClass
+    |cls|
+
+    cls := Smalltalk classNamed:className.
+    cls isNil ifTrue:[ ^ nil].
+    ^ cls
+
+    "Created: / 26.9.1999 / 13:39:00 / cg"
+! !
+
 !Project::MethodInfo methodsFor:'accessing'!
 
 className
@@ -3295,59 +3435,9 @@
     "Created: / 26.9.1999 / 13:39:07 / cg"
 ! !
 
-!Project::ClassInfo methodsFor:'accessing'!
-
-classFileName
-    "return the value of the instance variable 'classFileName' (automatically generated)"
-
-    ^ classFileName!
-
-classFileName:something
-    "set the value of the instance variable 'classFileName' (automatically generated)"
-
-    classFileName := something.!
-
-className
-    "return the value of the instance variable 'className' (automatically generated)"
-
-    ^ className!
-
-className:something
-    "set the value of the instance variable 'className' (automatically generated)"
-
-    className := something.!
-
-conditionForInclusion
-    "return the value of the instance variable 'conditionForInclusion' (automatically generated)"
-
-    ^ conditionForInclusion!
-
-conditionForInclusion:something
-    "set the value of the instance variable 'conditionForInclusion' (automatically generated)"
-
-    conditionForInclusion := something.! !
-
-!Project::ClassInfo methodsFor:'printing & storing'!
-
-displayString
-    ^ 'ClassInfo: ' , className
-! !
-
-!Project::ClassInfo methodsFor:'queries'!
-
-theClass
-    |cls|
-
-    cls := Smalltalk classNamed:className.
-    cls isNil ifTrue:[ ^ nil].
-    ^ cls
-
-    "Created: / 26.9.1999 / 13:39:00 / cg"
-! !
-
 !Project class methodsFor:'documentation'!
 
 version
-    ^ '$Header: /cvs/stx/stx/libbasic/Project.st,v 1.131 1999-12-20 21:11:04 cg Exp $'
+    ^ '$Header: /cvs/stx/stx/libbasic/Project.st,v 1.132 1999-12-28 14:03:48 cg Exp $'
 ! !
 Project initialize!