ClassDescription.st
changeset 9561 558e31b007d5
parent 9527 9b8337afd628
child 9690 8cbd82173e0b
equal deleted inserted replaced
9560:555afa00a3c1 9561:558e31b007d5
   201         UpdateChangeListQuerySignal nameClass:self message:#updateChangeListQuerySignal.
   201         UpdateChangeListQuerySignal nameClass:self message:#updateChangeListQuerySignal.
   202         UpdateChangeListQuerySignal notifierString:'asking if changeList update is wanted'.
   202         UpdateChangeListQuerySignal notifierString:'asking if changeList update is wanted'.
   203         UpdateChangeListQuerySignal handlerBlock:[:ex | ex proceedWith:UpdatingChanges].
   203         UpdateChangeListQuerySignal handlerBlock:[:ex | ex proceedWith:UpdatingChanges].
   204 
   204 
   205         NameSpaceQuerySignal isNil ifTrue:[
   205         NameSpaceQuerySignal isNil ifTrue:[
   206             NameSpaceQuerySignal := QuerySignal new.
   206             "This could be used BEFORE initialize has been invoked - thats why we initialize
   207             NameSpaceQuerySignal nameClass:self message:#nameSpaceQuerySignal.
   207              the class var there."
   208             NameSpaceQuerySignal notifierString:'asking for nameSpace'.
   208             NameSpaceQuerySignal := self nameSpaceQuerySignal
   209             NameSpaceQuerySignal handlerBlock:[:ex | ex proceedWith:Smalltalk defaultNameSpace].
       
   210         ].
   209         ].
   211         UsedNameSpaceQuerySignal isNil ifTrue:[
   210         UsedNameSpaceQuerySignal isNil ifTrue:[
   212             UsedNameSpaceQuerySignal := QuerySignal new.
   211             "This could be used BEFORE initialize has been invoked - thats why we initialize
   213             UsedNameSpaceQuerySignal nameClass:self message:#usedNameSpaceQuerySignal.
   212              the class var there."
   214             UsedNameSpaceQuerySignal notifierString:'asking for used nameSpaced'.
   213             UsedNameSpaceQuerySignal := self usedNameSpaceQuerySignal.
   215         ].
   214         ].
   216 
   215 
   217         CreateNameSpaceQuerySignal := QuerySignal new.
   216         CreateNameSpaceQuerySignal := QuerySignal new.
   218         CreateNameSpaceQuerySignal nameClass:self message:#createNameSpaceQuerySignal.
   217         CreateNameSpaceQuerySignal nameClass:self message:#createNameSpaceQuerySignal.
   219         CreateNameSpaceQuerySignal notifierString:'asking for nameSpace creation'.
   218         CreateNameSpaceQuerySignal notifierString:'asking for nameSpace creation'.
   257      ClassDescription initialize
   256      ClassDescription initialize
   258     "
   257     "
   259 
   258 
   260     "Created: / 02-04-1997 / 17:27:40 / stefan"
   259     "Created: / 02-04-1997 / 17:27:40 / stefan"
   261     "Modified: / 17-03-1999 / 16:52:41 / stefan"
   260     "Modified: / 17-03-1999 / 16:52:41 / stefan"
   262     "Modified: / 05-07-2006 / 17:36:43 / cg"
   261     "Modified: / 17-08-2006 / 14:04:17 / cg"
   263 ! !
   262 ! !
   264 
   263 
   265 !ClassDescription class methodsFor:'Signal constants'!
   264 !ClassDescription class methodsFor:'Signal constants'!
   266 
   265 
   267 changeDefaultApplicationNotificationSignal
   266 changeDefaultApplicationNotificationSignal
   380     ^ ClassDescription::MethodRedefinitionNotification
   379     ^ ClassDescription::MethodRedefinitionNotification
   381 !
   380 !
   382 
   381 
   383 nameSpaceQuerySignal
   382 nameSpaceQuerySignal
   384     "return the signal used as an upQuery for the current nameSpace.
   383     "return the signal used as an upQuery for the current nameSpace.
   385      Will be used when filing in code"
   384      Will be used when filing in code.
       
   385      This could be used BEFORE initialize has been invoked - thats why we do not
       
   386      simply return the class var here."
   386 
   387 
   387     NameSpaceQuerySignal isNil ifTrue:[
   388     NameSpaceQuerySignal isNil ifTrue:[
   388 	NameSpaceQuerySignal := QuerySignal new.
   389         NameSpaceQuerySignal := QuerySignal new.
   389 	NameSpaceQuerySignal nameClass:self message:#nameSpaceQuerySignal.
   390         NameSpaceQuerySignal nameClass:self message:#nameSpaceQuerySignal.
   390 	NameSpaceQuerySignal notifierString:'asking for nameSpace'.
   391         NameSpaceQuerySignal notifierString:'asking for nameSpace'.
   391 	NameSpaceQuerySignal handlerBlock:[:ex | ex proceedWith:Smalltalk defaultNameSpace].
   392         NameSpaceQuerySignal handlerBlock:[:ex | ex proceedWith:Project defaultNameSpace].
   392     ].
   393     ].
   393     ^ NameSpaceQuerySignal
   394     ^ NameSpaceQuerySignal
   394 
   395 
   395     "
   396     "
   396      Transcript showCR:Class nameSpaceQuerySignal raise
   397      Transcript showCR:Class nameSpaceQuerySignal raise
   397     "
   398     "
   398 
   399 
   399     "Modified: 5.11.1996 / 20:08:38 / cg"
   400     "Modified: / 17-08-2006 / 14:03:39 / cg"
   400 !
   401 !
   401 
   402 
   402 packageQuerySignal
   403 packageQuerySignal
   403     "return the signal used as an upQuery for the current packages name.
   404     "return the signal used as an upQuery for the current packages name.
   404      Will be used when filing in code"
   405      Will be used when filing in code"
   462     "Created: / 05-07-2006 / 17:30:52 / cg"
   463     "Created: / 05-07-2006 / 17:30:52 / cg"
   463 !
   464 !
   464 
   465 
   465 usedNameSpaceQuerySignal
   466 usedNameSpaceQuerySignal
   466     "return the signal used as an upQuery for the used nameSpace.
   467     "return the signal used as an upQuery for the used nameSpace.
   467      Will be used when filing in code"
   468      Will be used when filing in code.
       
   469      This could be used BEFORE initialize has been invoked - thats why we do not
       
   470      simply return the class var here."
   468 
   471 
   469     UsedNameSpaceQuerySignal isNil ifTrue:[
   472     UsedNameSpaceQuerySignal isNil ifTrue:[
   470 	UsedNameSpaceQuerySignal := QuerySignal new.
   473         UsedNameSpaceQuerySignal := QuerySignal new.
   471 	UsedNameSpaceQuerySignal nameClass:self message:#usedNameSpaceQuerySignal.
   474         UsedNameSpaceQuerySignal nameClass:self message:#usedNameSpaceQuerySignal.
   472 	UsedNameSpaceQuerySignal notifierString:'asking for used nameSpaced'.
   475         UsedNameSpaceQuerySignal notifierString:'asking for used nameSpaced'.
   473     ].
   476     ].
   474     ^ UsedNameSpaceQuerySignal
   477     ^ UsedNameSpaceQuerySignal
   475 
   478 
   476     "Created: 19.12.1996 / 23:57:27 / cg"
   479     "Created: / 19-12-1996 / 23:57:27 / cg"
       
   480     "Modified: / 17-08-2006 / 14:03:33 / cg"
   477 ! !
   481 ! !
   478 
   482 
   479 !ClassDescription class methodsFor:'accessing-flags'!
   483 !ClassDescription class methodsFor:'accessing-flags'!
   480 
   484 
   481 catchClassRedefinitions
   485 catchClassRedefinitions
  1073                 "if continued, install as usual - and use new package"
  1077                 "if continued, install as usual - and use new package"
  1074             ]
  1078             ]
  1075         ]
  1079         ]
  1076     ].
  1080     ].
  1077 
  1081 
  1078     "/ remember new->old association in the MethodHistory dictionary (if non-nil)
       
  1079 
       
  1080     MethodHistory notNil ifTrue:[
       
  1081         oldMethod notNil ifTrue:[
       
  1082             MethodHistory add:(Array with:#methodChange with:oldMethod with:newMethod).
       
  1083             (MethodHistorySize notNil and:[MethodHistory size > MethodHistorySize]) ifTrue:[
       
  1084                 MethodHistory removeFirst.
       
  1085             ]
       
  1086         ]
       
  1087     ].
       
  1088 
       
  1089     "/ remember in the projects overwritten dictionary
       
  1090 
       
  1091     oldMethod notNil ifTrue:[
       
  1092         oldMethod package ~= newMethod package ifTrue:[
       
  1093             Project notNil ifTrue:[
       
  1094                 "/ allow configurations without Project
       
  1095                 Project rememberOverwrittenMethod:newMethod from:oldMethod
       
  1096             ]
       
  1097         ]
       
  1098     ].
       
  1099 
       
  1100     super addSelector:newSelector withMethod:newMethod.
  1082     super addSelector:newSelector withMethod:newMethod.
  1101     self addChangeRecordForMethod:newMethod fromOld:oldMethod.
  1083     self addChangeRecordForMethod:newMethod fromOld:oldMethod.
  1102 
  1084 
  1103     "Modified: / 9.9.1996 / 22:39:32 / stefan"
  1085     "Modified: / 09-09-1996 / 22:39:32 / stefan"
  1104     "Created: / 4.6.1997 / 14:47:10 / cg"
  1086     "Created: / 04-06-1997 / 14:47:10 / cg"
  1105     "Modified: / 17.6.1998 / 10:41:34 / cg"
  1087     "Modified: / 17-08-2006 / 13:54:00 / cg"
  1106 !
  1088 !
  1107 
  1089 
  1108 basicAddSelector:newSelector withMethod:newMethod
  1090 basicAddSelector:newSelector withMethod:newMethod
  1109     "add the method given by 2nd argument under the selector given by
  1091     "add the method given by 2nd argument under the selector given by
  1110      1st argument to the methodDictionary.
  1092      1st argument to the methodDictionary.
  4012 ! !
  3994 ! !
  4013 
  3995 
  4014 !ClassDescription class methodsFor:'documentation'!
  3996 !ClassDescription class methodsFor:'documentation'!
  4015 
  3997 
  4016 version
  3998 version
  4017     ^ '$Header: /cvs/stx/stx/libbasic/ClassDescription.st,v 1.189 2006-08-11 12:11:39 cg Exp $'
  3999     ^ '$Header: /cvs/stx/stx/libbasic/ClassDescription.st,v 1.190 2006-08-17 14:12:10 cg Exp $'
  4018 ! !
  4000 ! !
  4019 
  4001 
  4020 ClassDescription initialize!
  4002 ClassDescription initialize!
  4021 ClassDescription::MethodRedefinitionNotification initialize!
  4003 ClassDescription::MethodRedefinitionNotification initialize!
  4022 ClassDescription::ClassRedefinitionNotification initialize!
  4004 ClassDescription::ClassRedefinitionNotification initialize!