changeset 887 | 9d1780436f5a |
parent 881 | eb44cdaa19af |
child 888 | 14162557b90c |
886:62c66d49077d | 887:9d1780436f5a |
---|---|
13 ClassDescription subclass:#Class |
13 ClassDescription subclass:#Class |
14 instanceVariableNames:'classvars comment subclasses classFilename package revision |
14 instanceVariableNames:'classvars comment subclasses classFilename package revision |
15 history' |
15 history' |
16 classVariableNames:'UpdatingChanges LockChangesFile FileOutErrorSignal |
16 classVariableNames:'UpdatingChanges LockChangesFile FileOutErrorSignal |
17 CatchMethodRedefinitions MethodRedefinitionSignal |
17 CatchMethodRedefinitions MethodRedefinitionSignal |
18 UpdateChangeFileQuerySignal' |
18 UpdateChangeFileQuerySignal DefaultNamespace' |
19 poolDictionaries:'' |
19 poolDictionaries:'' |
20 category:'Kernel-Classes' |
20 category:'Kernel-Classes' |
21 ! |
21 ! |
22 |
22 |
23 !Class class methodsFor:'documentation'! |
23 !Class class methodsFor:'documentation'! |
114 to avoid putting too much junk into the changes-file." |
114 to avoid putting too much junk into the changes-file." |
115 |
115 |
116 UpdatingChanges := true. |
116 UpdatingChanges := true. |
117 LockChangesFile := false. |
117 LockChangesFile := false. |
118 CatchMethodRedefinitions := true. |
118 CatchMethodRedefinitions := true. |
119 DefaultNamespace := Smalltalk. |
|
119 |
120 |
120 FileOutErrorSignal isNil ifTrue:[ |
121 FileOutErrorSignal isNil ifTrue:[ |
121 FileOutErrorSignal := ErrorSignal newSignalMayProceed:false. |
122 FileOutErrorSignal := ErrorSignal newSignalMayProceed:false. |
122 FileOutErrorSignal nameClass:self message:#fileOutErrorSignal. |
123 FileOutErrorSignal nameClass:self message:#fileOutErrorSignal. |
123 FileOutErrorSignal notifierString:'error during fileOut'. |
124 FileOutErrorSignal notifierString:'error during fileOut'. |
502 stream notNil ifTrue:[ |
503 stream notNil ifTrue:[ |
503 stream position:comment. |
504 stream position:comment. |
504 string := String readFrom:stream onError:''. |
505 string := String readFrom:stream onError:''. |
505 stream close. |
506 stream close. |
506 ^ string |
507 ^ string |
507 ] |
508 ]. |
509 ^ nil |
|
508 ] |
510 ] |
509 ]. |
511 ]. |
510 ^ comment |
512 ^ comment |
511 |
513 |
512 " |
514 " |
1099 classInstVars := manager nextObject. |
1101 classInstVars := manager nextObject. |
1100 classInstVars isNil ifTrue:[classInstVars := '']. |
1102 classInstVars isNil ifTrue:[classInstVars := '']. |
1101 |
1103 |
1102 "/ ('create class: ' , name ) printNL. |
1104 "/ ('create class: ' , name ) printNL. |
1103 |
1105 |
1104 newClass := superClass |
1106 newClass := superClass class |
1105 subclass:name asSymbol |
1107 name:name asSymbol |
1106 instanceVariableNames:instvars |
1108 inEnvironment:Smalltalk |
1107 classVariableNames:classvars |
1109 subclassOf:superClass |
1108 poolDictionaries:'' |
1110 instanceVariableNames:instvars |
1109 category:category. |
1111 variable:false |
1112 words:false |
|
1113 pointers:true |
|
1114 classVariableNames:classvars |
|
1115 poolDictionaries:'' |
|
1116 category:category |
|
1117 comment:nil |
|
1118 changed:false |
|
1119 classInstanceVariableNames:classInstVars. |
|
1120 |
|
1121 "/ newClass := superClass |
|
1122 "/ subclass:name asSymbol |
|
1123 "/ instanceVariableNames:instvars |
|
1124 "/ classVariableNames:classvars |
|
1125 "/ poolDictionaries:'' |
|
1126 "/ category:category. |
|
1110 |
1127 |
1111 "/ 'got superName:' print. superclassName printNL. |
1128 "/ 'got superName:' print. superclassName printNL. |
1112 "/ 'got name:' print. name printNL. |
1129 "/ 'got name:' print. name printNL. |
1113 "/ 'got flags: ' print. flags printNL. |
1130 "/ 'got flags: ' print. flags printNL. |
1114 "/ 'got instvars: ' print. instvars printNL. |
1131 "/ 'got instvars: ' print. instvars printNL. |
1150 |
1167 |
1151 superClass isNil ifTrue:[^ nil]. |
1168 superClass isNil ifTrue:[^ nil]. |
1152 newClass isNil ifTrue:[ |
1169 newClass isNil ifTrue:[ |
1153 ^ nil |
1170 ^ nil |
1154 ]. |
1171 ]. |
1155 newClass class instanceVariableNames:classInstVars. |
1172 "/ newClass class instanceVariableNames:classInstVars. |
1156 |
1173 |
1157 newClass selectors:selectors methods:methods. |
1174 newClass selectors:selectors methods:methods. |
1158 newClass class selectors:cselectors methods:cmethods. |
1175 newClass class selectors:cselectors methods:cmethods. |
1159 ^ newClass |
1176 ^ newClass |
1160 |
1177 |
1161 "Modified: 16.1.1996 / 17:03:21 / cg" |
1178 "Modified: 22.1.1996 / 13:22:08 / cg" |
1162 ! ! |
1179 ! ! |
1163 |
1180 |
1164 !Class methodsFor:'c function interfacing'! |
1181 !Class methodsFor:'c function interfacing'! |
1165 |
1182 |
1166 cInterfaceFunction:selector calling:cFunctionNameString args:argTypeArray returning:returnType |
1183 cInterfaceFunction:selector calling:cFunctionNameString args:argTypeArray returning:returnType |
3418 The subclass will have indexed variables if the receiving-class has." |
3435 The subclass will have indexed variables if the receiving-class has." |
3419 |
3436 |
3420 self isVariable ifFalse:[ |
3437 self isVariable ifFalse:[ |
3421 ^ self class |
3438 ^ self class |
3422 name:t |
3439 name:t |
3423 inEnvironment:Smalltalk |
3440 inEnvironment:DefaultNamespace |
3424 subclassOf:self |
3441 subclassOf:self |
3425 instanceVariableNames:f |
3442 instanceVariableNames:f |
3426 variable:false |
3443 variable:false |
3427 words:true |
3444 words:true |
3428 pointers:true |
3445 pointers:true |
3491 ]. |
3508 ]. |
3492 ]. |
3509 ]. |
3493 |
3510 |
3494 ^ self class |
3511 ^ self class |
3495 name:t |
3512 name:t |
3496 inEnvironment:Smalltalk |
3513 inEnvironment:DefaultNamespace |
3497 subclassOf:self |
3514 subclassOf:self |
3498 instanceVariableNames:f |
3515 instanceVariableNames:f |
3499 variable:true |
3516 variable:true |
3500 words:false |
3517 words:false |
3501 pointers:false |
3518 pointers:false |
3518 ]. |
3535 ]. |
3519 ]. |
3536 ]. |
3520 |
3537 |
3521 ^ self class |
3538 ^ self class |
3522 name:t |
3539 name:t |
3523 inEnvironment:Smalltalk |
3540 inEnvironment:DefaultNamespace |
3524 subclassOf:self |
3541 subclassOf:self |
3525 instanceVariableNames:f |
3542 instanceVariableNames:f |
3526 variable:#double |
3543 variable:#double |
3527 words:false |
3544 words:false |
3528 pointers:false |
3545 pointers:false |
3545 ]. |
3562 ]. |
3546 ]. |
3563 ]. |
3547 |
3564 |
3548 ^ self class |
3565 ^ self class |
3549 name:t |
3566 name:t |
3550 inEnvironment:Smalltalk |
3567 inEnvironment:DefaultNamespace |
3551 subclassOf:self |
3568 subclassOf:self |
3552 instanceVariableNames:f |
3569 instanceVariableNames:f |
3553 variable:#float |
3570 variable:#float |
3554 words:false |
3571 words:false |
3555 pointers:false |
3572 pointers:false |
3571 ]. |
3588 ]. |
3572 ]. |
3589 ]. |
3573 |
3590 |
3574 ^ self class |
3591 ^ self class |
3575 name:t |
3592 name:t |
3576 inEnvironment:Smalltalk |
3593 inEnvironment:DefaultNamespace |
3577 subclassOf:self |
3594 subclassOf:self |
3578 instanceVariableNames:f |
3595 instanceVariableNames:f |
3579 variable:#long |
3596 variable:#long |
3580 words:false |
3597 words:false |
3581 pointers:false |
3598 pointers:false |
3597 ] |
3614 ] |
3598 ]. |
3615 ]. |
3599 |
3616 |
3600 ^ self class |
3617 ^ self class |
3601 name:t |
3618 name:t |
3602 inEnvironment:Smalltalk |
3619 inEnvironment:DefaultNamespace |
3603 subclassOf:self |
3620 subclassOf:self |
3604 instanceVariableNames:f |
3621 instanceVariableNames:f |
3605 variable:true |
3622 variable:true |
3606 words:false |
3623 words:false |
3607 pointers:true |
3624 pointers:true |
3623 ]. |
3640 ]. |
3624 ]. |
3641 ]. |
3625 |
3642 |
3626 ^ self class |
3643 ^ self class |
3627 name:t |
3644 name:t |
3628 inEnvironment:Smalltalk |
3645 inEnvironment:DefaultNamespace |
3629 subclassOf:self |
3646 subclassOf:self |
3630 instanceVariableNames:f |
3647 instanceVariableNames:f |
3631 variable:true |
3648 variable:true |
3632 words:true |
3649 words:true |
3633 pointers:false |
3650 pointers:false |
3639 ! ! |
3656 ! ! |
3640 |
3657 |
3641 !Class class methodsFor:'documentation'! |
3658 !Class class methodsFor:'documentation'! |
3642 |
3659 |
3643 version |
3660 version |
3644 ^ '$Header: /cvs/stx/stx/libbasic/Class.st,v 1.119 1996-01-18 00:43:40 cg Exp $' |
3661 ^ '$Header: /cvs/stx/stx/libbasic/Class.st,v 1.120 1996-01-22 13:20:41 cg Exp $' |
3645 ! ! |
3662 ! ! |
3646 Class initialize! |
3663 Class initialize! |