author | Claus Gittinger <cg@exept.de> |
Mon, 03 Mar 1997 13:08:06 +0100 | |
changeset 2435 | 08f60d7c2c11 |
parent 2365 | 407104ea10db |
child 2451 | d019db46e488 |
permissions | -rw-r--r-- |
1 | 1 |
" |
2 |
COPYRIGHT (c) 1993 by Claus Gittinger |
|
155 | 3 |
All Rights Reserved |
1 | 4 |
|
5 |
This software is furnished under a license and may be used |
|
6 |
only in accordance with the terms of that license and with the |
|
7 |
inclusion of the above copyright notice. This software may not |
|
8 |
be provided or otherwise made available to, or used by, any |
|
9 |
other person. No title to or ownership of the software is |
|
10 |
hereby transferred. |
|
11 |
" |
|
12 |
||
13 |
Behavior subclass:#ClassDescription |
|
1091 | 14 |
instanceVariableNames:'name category instvars primitiveSpec signature' |
15 |
classVariableNames:'' |
|
16 |
poolDictionaries:'' |
|
17 |
category:'Kernel-Classes' |
|
1 | 18 |
! |
19 |
||
1740 | 20 |
!ClassDescription class methodsFor:'documentation'! |
1 | 21 |
|
88 | 22 |
copyright |
23 |
" |
|
24 |
COPYRIGHT (c) 1993 by Claus Gittinger |
|
155 | 25 |
All Rights Reserved |
88 | 26 |
|
27 |
This software is furnished under a license and may be used |
|
28 |
only in accordance with the terms of that license and with the |
|
29 |
inclusion of the above copyright notice. This software may not |
|
30 |
be provided or otherwise made available to, or used by, any |
|
31 |
other person. No title to or ownership of the software is |
|
32 |
hereby transferred. |
|
33 |
" |
|
34 |
! |
|
35 |
||
68 | 36 |
documentation |
37 |
" |
|
38 |
this class has been added for ST-80 compatibility only. |
|
39 |
All class stuff used to be in Behavior and Class - but, to be |
|
356 | 40 |
able to file in some PD code, it became nescessary to add C'Description |
41 |
in between it. |
|
88 | 42 |
ClassDescription adds some descriptive information to the basic |
43 |
Behavior class. |
|
1 | 44 |
|
1292 | 45 |
[Instance variables:] |
46 |
||
47 |
name <Symbol> the classes name |
|
68 | 48 |
|
1292 | 49 |
category <String | Symbol> the classes category |
905 | 50 |
|
1292 | 51 |
instvars <String> the names of the instance variables |
905 | 52 |
|
1292 | 53 |
primitiveSpec <Array | nil> describes primitiveIncludes, primitiveFunctions etc. |
905 | 54 |
|
1292 | 55 |
signature <SmallInteger> the classes signature (used to detect obsolete |
56 |
or changed classes with binaryStorage) |
|
57 |
This is filled in lazy - i.e. upon the first signature query. |
|
58 |
||
59 |
[author:] |
|
60 |
Claus Gittinger |
|
1669 | 61 |
|
62 |
[see also:] |
|
63 |
Behavior Class Metaclass |
|
68 | 64 |
" |
65 |
! ! |
|
1 | 66 |
|
1740 | 67 |
!ClassDescription class methodsFor:'instance creation'! |
356 | 68 |
|
69 |
new |
|
70 |
"creates and returns a new class. |
|
71 |
Redefined to give the new class at least some name info" |
|
72 |
||
73 |
|newClass| |
|
74 |
||
75 |
newClass := super new. |
|
76 |
newClass setName:('some' , self name). |
|
77 |
^ newClass |
|
78 |
! ! |
|
79 |
||
1740 | 80 |
!ClassDescription class methodsFor:'queries'! |
1179
3e0f32177af4
allow subclasses of Class to be changed
Claus Gittinger <cg@exept.de>
parents:
1091
diff
changeset
|
81 |
|
3e0f32177af4
allow subclasses of Class to be changed
Claus Gittinger <cg@exept.de>
parents:
1091
diff
changeset
|
82 |
isBuiltInClass |
1266 | 83 |
"return true if this class is known by the run-time-system. |
84 |
Here, true is returned for myself, false for subclasses." |
|
85 |
||
1179
3e0f32177af4
allow subclasses of Class to be changed
Claus Gittinger <cg@exept.de>
parents:
1091
diff
changeset
|
86 |
^ self == ClassDescription class or:[self == ClassDescription] |
3e0f32177af4
allow subclasses of Class to be changed
Claus Gittinger <cg@exept.de>
parents:
1091
diff
changeset
|
87 |
|
3e0f32177af4
allow subclasses of Class to be changed
Claus Gittinger <cg@exept.de>
parents:
1091
diff
changeset
|
88 |
"Created: 15.4.1996 / 17:16:59 / cg" |
1266 | 89 |
"Modified: 23.4.1996 / 15:56:54 / cg" |
1179
3e0f32177af4
allow subclasses of Class to be changed
Claus Gittinger <cg@exept.de>
parents:
1091
diff
changeset
|
90 |
! ! |
3e0f32177af4
allow subclasses of Class to be changed
Claus Gittinger <cg@exept.de>
parents:
1091
diff
changeset
|
91 |
|
1 | 92 |
!ClassDescription methodsFor:'accessing'! |
93 |
||
94 |
category |
|
77 | 95 |
"return the category of the class. |
96 |
The returned value may be a string or symbol." |
|
1 | 97 |
|
1760 | 98 |
|owner| |
99 |
||
100 |
(owner := self owningClass) notNil ifTrue:[^ owner category]. |
|
1 | 101 |
^ category |
77 | 102 |
|
103 |
" |
|
104 |
Point category |
|
105 |
Dictionary category |
|
106 |
" |
|
1760 | 107 |
|
108 |
"Modified: 15.10.1996 / 21:20:01 / cg" |
|
1 | 109 |
! |
110 |
||
111 |
category:aStringOrSymbol |
|
77 | 112 |
"set the category of the class to be the argument, aStringOrSymbol" |
1 | 113 |
|
249 | 114 |
aStringOrSymbol isNil ifTrue:[ |
115 |
category := aStringOrSymbol |
|
116 |
] ifFalse:[ |
|
117 |
category := aStringOrSymbol asSymbol |
|
118 |
] |
|
328 | 119 |
! |
120 |
||
620 | 121 |
instVarAtOffset:index |
122 |
"return the name of the instance variable at index" |
|
123 |
||
124 |
^ self allInstanceVariableNames at:index |
|
125 |
! |
|
126 |
||
127 |
instVarNames |
|
128 |
"return a collection of the instance variable name-strings" |
|
129 |
||
130 |
instvars isNil ifTrue:[ |
|
131 |
^ OrderedCollection new |
|
132 |
]. |
|
133 |
^ instvars asCollectionOfWords |
|
134 |
||
135 |
" |
|
136 |
Point instVarNames |
|
137 |
" |
|
138 |
! |
|
139 |
||
140 |
instVarOffsetOf:aVariableName |
|
141 |
"return the index (as used in instVarAt:/instVarAt:put:) of a named instance |
|
142 |
variable. The returned number is 1..instSize for valid variable names, nil for |
|
143 |
illegal names." |
|
144 |
||
145 |
^ self allInstVarNames indexOf:aVariableName ifAbsent:nil |
|
146 |
! |
|
147 |
||
148 |
instanceVariableOffsets |
|
149 |
"returns a dictionary containing the instance variable index |
|
150 |
for each instVar name" |
|
151 |
||
152 |
|dict index| |
|
153 |
||
154 |
index := 0. dict := Dictionary new. |
|
155 |
self allInstVarNames do:[:nm | index := index + 1. dict at:nm put:index]. |
|
156 |
^ dict |
|
157 |
||
158 |
" |
|
159 |
Point instanceVariableOffsets |
|
160 |
GraphicsContext instanceVariableOffsets |
|
161 |
" |
|
162 |
! |
|
163 |
||
164 |
instanceVariableString |
|
165 |
"return a string of the instance variable names" |
|
166 |
||
167 |
instvars isNil ifTrue:[^ '']. |
|
168 |
^ instvars |
|
169 |
||
170 |
" |
|
171 |
Point instanceVariableString |
|
172 |
" |
|
173 |
! |
|
174 |
||
175 |
name |
|
176 |
"return the name of the class. In the current implementation, |
|
177 |
this returns a string, but will be changed to Symbol soon." |
|
178 |
||
179 |
^ name |
|
180 |
! |
|
181 |
||
328 | 182 |
organization |
183 |
"for ST80 compatibility; |
|
184 |
read the documentation in ClassOrganizer for more info." |
|
185 |
||
186 |
^ ClassOrganizer for:self |
|
1 | 187 |
! ! |
10 | 188 |
|
92 | 189 |
!ClassDescription methodsFor:'printing & storing'! |
68 | 190 |
|
191 |
displayString |
|
293 | 192 |
"return a string for display in inspectors" |
193 |
||
194 |
|nm more| |
|
68 | 195 |
|
1652 | 196 |
(category = 'obsolete' |
197 |
or:[category = '* obsolete *']) ifTrue:[ |
|
198 |
"add obsolete - to make life easier ..." |
|
199 |
more := ' (obsolete)' |
|
68 | 200 |
]. |
1652 | 201 |
(category = 'removed' |
202 |
or:[category = '* removed *']) ifTrue:[ |
|
203 |
"add removed - to make life easier ..." |
|
204 |
more := ' (removed)' |
|
155 | 205 |
]. |
293 | 206 |
|
1745 | 207 |
self isPrivate ifTrue:[ |
1757 | 208 |
nm := self nameWithoutPrefix. |
1745 | 209 |
more := ' (private in ' , self owningClass name , ')'. |
210 |
] ifFalse:[ |
|
211 |
nm := self name. |
|
212 |
]. |
|
293 | 213 |
more isNil ifTrue:[^ nm]. |
1652 | 214 |
^ nm , more |
215 |
||
1757 | 216 |
"Modified: 15.10.1996 / 20:01:30 / cg" |
1091 | 217 |
! |
218 |
||
219 |
isObsolete |
|
220 |
"return true, if the receiver is obsolete |
|
221 |
(i.e. has been replaced by a different class or was removed, |
|
222 |
but is still referenced by instanced)" |
|
223 |
||
1652 | 224 |
^ category = 'obsolete' |
225 |
or:[category = 'removed' |
|
226 |
or:[category = '* removed *' |
|
227 |
or:[category = '* obsolete *']]] |
|
228 |
||
229 |
"Modified: 10.9.1996 / 14:02:07 / cg" |
|
68 | 230 |
! ! |
231 |
||
620 | 232 |
!ClassDescription methodsFor:'renaming'! |
233 |
||
234 |
renameTo:newName |
|
235 |
"change the name of the class" |
|
236 |
||
1554 | 237 |
|oldSym newSym| |
620 | 238 |
|
239 |
oldSym := name asSymbol. |
|
1554 | 240 |
newSym := newName asSymbol. |
241 |
self setName:newSym. |
|
620 | 242 |
|
243 |
Smalltalk at:oldSym put:nil. |
|
244 |
Smalltalk removeKey:oldSym. "26.jun 93" |
|
1554 | 245 |
Smalltalk at:newSym put:self. |
246 |
||
247 |
"Modified: 18.7.1996 / 11:26:46 / cg" |
|
620 | 248 |
! ! |
249 |
||
250 |
!ClassDescription methodsFor:'signature checking'! |
|
251 |
||
252 |
classinstSizeFromSignature:aSignature |
|
253 |
"for checking class compatibility: return some number based on |
|
254 |
the classinstSize from a signature key (not always the real classinstsize)." |
|
255 |
||
256 |
^ (aSignature bitShift:-7) bitAnd:7 |
|
257 |
! |
|
258 |
||
259 |
instNameKeyFromSignature:aSignature |
|
260 |
"for checking class compatibility: return a number based on the |
|
261 |
names and order of the instance variables from a signature key." |
|
262 |
||
263 |
^ (aSignature bitShift:-14) bitAnd:16rFFFF |
|
264 |
||
265 |
" |
|
266 |
Point instNameKeyFromSignature:Point signature. |
|
267 |
Association instNameKeyFromSignature:Association signature. |
|
268 |
" |
|
269 |
! |
|
270 |
||
271 |
instSizeFromSignature:aSignature |
|
272 |
"for checking class compatibility: return the some number based on |
|
273 |
the instSize from a signature key (not always the real instSize)." |
|
274 |
||
275 |
^ aSignature bitAnd:16r7F |
|
276 |
||
277 |
" |
|
278 |
Class instSizeFromSignature:Point signature. |
|
279 |
Class instSizeFromSignature:Association signature. |
|
280 |
Class instSizeFromSignature:Dictionary signature. |
|
281 |
" |
|
282 |
! |
|
283 |
||
284 |
instTypeFromSignature:aSignature |
|
285 |
"for checking class compatibility: return some number based on |
|
286 |
the instType (i.e. variableBytes/Pointers etc.) from a signature key." |
|
287 |
||
288 |
^ (aSignature bitShift:-10) bitAnd:(Class maskIndexType) |
|
289 |
||
290 |
" |
|
291 |
Class instTypeFromSignature:Object signature. |
|
292 |
Class instTypeFromSignature:Array signature. |
|
293 |
Class instTypeFromSignature:String signature. |
|
294 |
Class instTypeFromSignature:OrderedCollection signature. |
|
295 |
" |
|
296 |
! |
|
297 |
||
298 |
signature |
|
299 |
"return a signature number - this number is useful for a quick |
|
300 |
check for changed classes, and is done in the binary-object loader, |
|
301 |
and the dynamic class loader. |
|
302 |
Do NOT change the algorithm here - others may depend on it. |
|
303 |
Also, the algorithm may change - so never interpret the returned value |
|
304 |
(if at all, use the access #XXXFromSignature: methods)" |
|
305 |
||
306 |
|value "{ Class: SmallInteger }" |
|
307 |
nameKey "{ Class: SmallInteger }" | |
|
308 |
||
309 |
signature notNil ifTrue:[^ signature]. |
|
310 |
||
311 |
value := self flags bitAnd:(Class maskIndexType). |
|
312 |
value := (value bitShift:3) + ((self class instSize - Class instSize) bitAnd:7). |
|
313 |
value := (value bitShift:7) + (self instSize bitAnd:16r7F). |
|
314 |
||
315 |
nameKey := 0. |
|
316 |
self allInstVarNames do:[:name | |
|
317 |
nameKey := nameKey bitShift:1. |
|
318 |
(nameKey bitAnd:16r10000) ~~ 0 ifTrue:[ |
|
319 |
nameKey := nameKey bitXor:1. |
|
320 |
nameKey := nameKey bitAnd:16rFFFF. |
|
321 |
]. |
|
322 |
nameKey := (nameKey + (name at:1) asciiValue) bitAnd:16rFFFF. |
|
323 |
]. |
|
324 |
value := value + (nameKey bitShift:14). |
|
325 |
signature := value. |
|
326 |
^ value |
|
327 |
||
328 |
" |
|
329 |
Array signature |
|
330 |
ByteArray signature |
|
331 |
View signature |
|
332 |
" |
|
333 |
! ! |
|
334 |
||
335 |
!ClassDescription methodsFor:'special accessing'! |
|
336 |
||
337 |
setInstanceVariableString:aString |
|
338 |
"set the classes instvarnames string - no recompilation |
|
339 |
or updates are done and no changeList records are written. |
|
340 |
This is NOT for general use." |
|
341 |
||
342 |
instvars := aString. |
|
343 |
! |
|
344 |
||
345 |
setName:aString |
|
346 |
"set the classes name - be careful, it will be still |
|
347 |
in the Smalltalk dictionary - under another key. |
|
348 |
This is NOT for general use - see renameTo:" |
|
349 |
||
350 |
name := aString |
|
351 |
! ! |
|
352 |
||
1715
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
353 |
!ClassDescription methodsFor:'subclass creation'! |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
354 |
|
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
355 |
subclass:nameSymbol instanceVariableNames:instVarNameString classVariableNames:classVarString poolDictionaries:pool category:cat |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
356 |
"create a new class as a subclass of an existing class (the receiver). |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
357 |
The subclass will have indexed variables if the receiving-class has." |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
358 |
|
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
359 |
self isVariable ifFalse:[ |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
360 |
^ self class |
1912
3828090cd7fe
use nameSpaceQuery to install classes, instead of Smalltalk
Claus Gittinger <cg@exept.de>
parents:
1899
diff
changeset
|
361 |
name:nameSymbol |
3828090cd7fe
use nameSpaceQuery to install classes, instead of Smalltalk
Claus Gittinger <cg@exept.de>
parents:
1899
diff
changeset
|
362 |
inEnvironment:(Class nameSpaceQuerySignal raise) |
1715
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
363 |
subclassOf:self |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
364 |
instanceVariableNames:instVarNameString |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
365 |
variable:false |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
366 |
words:true |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
367 |
pointers:true |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
368 |
classVariableNames:classVarString |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
369 |
poolDictionaries:pool |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
370 |
category:cat |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
371 |
comment:nil |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
372 |
changed:true |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
373 |
]. |
2435 | 374 |
^ self |
375 |
perform:(self definitionSelector) |
|
376 |
withArguments:(Array with:name |
|
377 |
with:instVarNameString |
|
378 |
with:classVarString |
|
379 |
with:pool |
|
380 |
with:cat). |
|
1715
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
381 |
|
2435 | 382 |
"Modified: 3.3.1997 / 11:55:30 / cg" |
1715
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
383 |
! |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
384 |
|
2365
407104ea10db
additional entry, passing the environment
Claus Gittinger <cg@exept.de>
parents:
1912
diff
changeset
|
385 |
subclass:nameSymbol instanceVariableNames:instVarNameString classVariableNames:classVarString poolDictionaries:pool category:cat inEnvironment:aNameSpace |
407104ea10db
additional entry, passing the environment
Claus Gittinger <cg@exept.de>
parents:
1912
diff
changeset
|
386 |
"create a new class as a subclass of an existing class (the receiver). |
407104ea10db
additional entry, passing the environment
Claus Gittinger <cg@exept.de>
parents:
1912
diff
changeset
|
387 |
The subclass will have indexed variables if the receiving-class has." |
407104ea10db
additional entry, passing the environment
Claus Gittinger <cg@exept.de>
parents:
1912
diff
changeset
|
388 |
|
407104ea10db
additional entry, passing the environment
Claus Gittinger <cg@exept.de>
parents:
1912
diff
changeset
|
389 |
self isVariable ifTrue:[ |
407104ea10db
additional entry, passing the environment
Claus Gittinger <cg@exept.de>
parents:
1912
diff
changeset
|
390 |
Class nameSpaceQuerySignal handle:[:ex | |
407104ea10db
additional entry, passing the environment
Claus Gittinger <cg@exept.de>
parents:
1912
diff
changeset
|
391 |
ex proceedWith:aNameSpace |
407104ea10db
additional entry, passing the environment
Claus Gittinger <cg@exept.de>
parents:
1912
diff
changeset
|
392 |
] do:[ |
407104ea10db
additional entry, passing the environment
Claus Gittinger <cg@exept.de>
parents:
1912
diff
changeset
|
393 |
^ self |
407104ea10db
additional entry, passing the environment
Claus Gittinger <cg@exept.de>
parents:
1912
diff
changeset
|
394 |
subclass:nameSymbol |
407104ea10db
additional entry, passing the environment
Claus Gittinger <cg@exept.de>
parents:
1912
diff
changeset
|
395 |
instanceVariableNames:instVarNameString |
407104ea10db
additional entry, passing the environment
Claus Gittinger <cg@exept.de>
parents:
1912
diff
changeset
|
396 |
classVariableNames:classVarString |
407104ea10db
additional entry, passing the environment
Claus Gittinger <cg@exept.de>
parents:
1912
diff
changeset
|
397 |
poolDictionaries:pool |
407104ea10db
additional entry, passing the environment
Claus Gittinger <cg@exept.de>
parents:
1912
diff
changeset
|
398 |
category:cat |
407104ea10db
additional entry, passing the environment
Claus Gittinger <cg@exept.de>
parents:
1912
diff
changeset
|
399 |
]. |
407104ea10db
additional entry, passing the environment
Claus Gittinger <cg@exept.de>
parents:
1912
diff
changeset
|
400 |
]. |
407104ea10db
additional entry, passing the environment
Claus Gittinger <cg@exept.de>
parents:
1912
diff
changeset
|
401 |
^ self class |
407104ea10db
additional entry, passing the environment
Claus Gittinger <cg@exept.de>
parents:
1912
diff
changeset
|
402 |
name:nameSymbol |
407104ea10db
additional entry, passing the environment
Claus Gittinger <cg@exept.de>
parents:
1912
diff
changeset
|
403 |
inEnvironment:aNameSpace |
407104ea10db
additional entry, passing the environment
Claus Gittinger <cg@exept.de>
parents:
1912
diff
changeset
|
404 |
subclassOf:self |
407104ea10db
additional entry, passing the environment
Claus Gittinger <cg@exept.de>
parents:
1912
diff
changeset
|
405 |
instanceVariableNames:instVarNameString |
407104ea10db
additional entry, passing the environment
Claus Gittinger <cg@exept.de>
parents:
1912
diff
changeset
|
406 |
variable:false |
407104ea10db
additional entry, passing the environment
Claus Gittinger <cg@exept.de>
parents:
1912
diff
changeset
|
407 |
words:true |
407104ea10db
additional entry, passing the environment
Claus Gittinger <cg@exept.de>
parents:
1912
diff
changeset
|
408 |
pointers:true |
407104ea10db
additional entry, passing the environment
Claus Gittinger <cg@exept.de>
parents:
1912
diff
changeset
|
409 |
classVariableNames:classVarString |
407104ea10db
additional entry, passing the environment
Claus Gittinger <cg@exept.de>
parents:
1912
diff
changeset
|
410 |
poolDictionaries:pool |
407104ea10db
additional entry, passing the environment
Claus Gittinger <cg@exept.de>
parents:
1912
diff
changeset
|
411 |
category:cat |
407104ea10db
additional entry, passing the environment
Claus Gittinger <cg@exept.de>
parents:
1912
diff
changeset
|
412 |
comment:nil |
407104ea10db
additional entry, passing the environment
Claus Gittinger <cg@exept.de>
parents:
1912
diff
changeset
|
413 |
changed:true |
407104ea10db
additional entry, passing the environment
Claus Gittinger <cg@exept.de>
parents:
1912
diff
changeset
|
414 |
|
407104ea10db
additional entry, passing the environment
Claus Gittinger <cg@exept.de>
parents:
1912
diff
changeset
|
415 |
"Created: 8.2.1997 / 19:41:44 / cg" |
407104ea10db
additional entry, passing the environment
Claus Gittinger <cg@exept.de>
parents:
1912
diff
changeset
|
416 |
"Modified: 8.2.1997 / 20:03:52 / cg" |
407104ea10db
additional entry, passing the environment
Claus Gittinger <cg@exept.de>
parents:
1912
diff
changeset
|
417 |
! |
407104ea10db
additional entry, passing the environment
Claus Gittinger <cg@exept.de>
parents:
1912
diff
changeset
|
418 |
|
1715
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
419 |
variableByteSubclass:nameSymbol instanceVariableNames:instVarNameString classVariableNames:classVarString poolDictionaries:pool category:cat |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
420 |
"create a new class as a subclass of an existing class (the receiver) |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
421 |
in which the subclass has indexable byte-sized nonpointer variables" |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
422 |
|
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
423 |
self isVariable ifTrue:[ |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
424 |
self isBytes ifFalse:[ |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
425 |
^ self error: |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
426 |
'cannot make a variable byte subclass of a variable non-byte class' |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
427 |
]. |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
428 |
]. |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
429 |
|
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
430 |
^ self class |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
431 |
name:nameSymbol |
1912
3828090cd7fe
use nameSpaceQuery to install classes, instead of Smalltalk
Claus Gittinger <cg@exept.de>
parents:
1899
diff
changeset
|
432 |
inEnvironment:(Class nameSpaceQuerySignal raise) |
1715
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
433 |
subclassOf:self |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
434 |
instanceVariableNames:instVarNameString |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
435 |
variable:true |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
436 |
words:false |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
437 |
pointers:false |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
438 |
classVariableNames:classVarString |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
439 |
poolDictionaries:pool |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
440 |
category:cat |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
441 |
comment:nil |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
442 |
changed:true |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
443 |
|
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
444 |
"Created: 12.10.1996 / 19:18:18 / cg" |
1912
3828090cd7fe
use nameSpaceQuery to install classes, instead of Smalltalk
Claus Gittinger <cg@exept.de>
parents:
1899
diff
changeset
|
445 |
"Modified: 6.11.1996 / 22:48:18 / cg" |
1715
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
446 |
! |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
447 |
|
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
448 |
variableDoubleSubclass:nameSymbol instanceVariableNames:instVarNameString classVariableNames:classVarString poolDictionaries:pool category:cat |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
449 |
|
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
450 |
"create a new class as a subclass of an existing class (the receiver) |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
451 |
in which the subclass has indexable double-sized nonpointer variables" |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
452 |
|
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
453 |
self isVariable ifTrue:[ |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
454 |
self isDoubles ifFalse:[ |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
455 |
^ self error: |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
456 |
'cannot make a variable double subclass of a variable non-double class' |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
457 |
]. |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
458 |
]. |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
459 |
|
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
460 |
^ self class |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
461 |
name:nameSymbol |
1912
3828090cd7fe
use nameSpaceQuery to install classes, instead of Smalltalk
Claus Gittinger <cg@exept.de>
parents:
1899
diff
changeset
|
462 |
inEnvironment:(Class nameSpaceQuerySignal raise) |
1715
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
463 |
subclassOf:self |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
464 |
instanceVariableNames:instVarNameString |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
465 |
variable:#double |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
466 |
words:false |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
467 |
pointers:false |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
468 |
classVariableNames:classVarString |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
469 |
poolDictionaries:pool |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
470 |
category:cat |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
471 |
comment:nil |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
472 |
changed:true |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
473 |
|
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
474 |
"Created: 12.10.1996 / 19:18:21 / cg" |
1912
3828090cd7fe
use nameSpaceQuery to install classes, instead of Smalltalk
Claus Gittinger <cg@exept.de>
parents:
1899
diff
changeset
|
475 |
"Modified: 6.11.1996 / 22:48:22 / cg" |
1715
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
476 |
! |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
477 |
|
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
478 |
variableFloatSubclass:nameSymbol instanceVariableNames:instVarNameString classVariableNames:classVarString poolDictionaries:pool category:cat |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
479 |
|
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
480 |
"create a new class as a subclass of an existing class (the receiver) |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
481 |
in which the subclass has indexable float-sized nonpointer variables" |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
482 |
|
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
483 |
self isVariable ifTrue:[ |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
484 |
self isFloats ifFalse:[ |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
485 |
^ self error: |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
486 |
'cannot make a variable float subclass of a variable non-float class' |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
487 |
]. |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
488 |
]. |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
489 |
|
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
490 |
^ self class |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
491 |
name:nameSymbol |
1912
3828090cd7fe
use nameSpaceQuery to install classes, instead of Smalltalk
Claus Gittinger <cg@exept.de>
parents:
1899
diff
changeset
|
492 |
inEnvironment:(Class nameSpaceQuerySignal raise) |
1715
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
493 |
subclassOf:self |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
494 |
instanceVariableNames:instVarNameString |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
495 |
variable:#float |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
496 |
words:false |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
497 |
pointers:false |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
498 |
classVariableNames:classVarString |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
499 |
poolDictionaries:pool |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
500 |
category:cat |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
501 |
comment:nil |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
502 |
changed:true |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
503 |
|
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
504 |
"Created: 12.10.1996 / 19:18:24 / cg" |
1912
3828090cd7fe
use nameSpaceQuery to install classes, instead of Smalltalk
Claus Gittinger <cg@exept.de>
parents:
1899
diff
changeset
|
505 |
"Modified: 6.11.1996 / 22:48:26 / cg" |
1715
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
506 |
! |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
507 |
|
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
508 |
variableLongSubclass:nameSymbol instanceVariableNames:instVarNameString classVariableNames:classVarString poolDictionaries:pool category:cat |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
509 |
"create a new class as a subclass of an existing class (the receiver) |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
510 |
in which the subclass has indexable long-sized nonpointer variables" |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
511 |
|
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
512 |
self isVariable ifTrue:[ |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
513 |
self isLongs ifFalse:[ |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
514 |
^ self error: |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
515 |
'cannot make a variable long subclass of a variable non-long class' |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
516 |
]. |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
517 |
]. |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
518 |
|
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
519 |
^ self class |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
520 |
name:nameSymbol |
1912
3828090cd7fe
use nameSpaceQuery to install classes, instead of Smalltalk
Claus Gittinger <cg@exept.de>
parents:
1899
diff
changeset
|
521 |
inEnvironment:(Class nameSpaceQuerySignal raise) |
1715
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
522 |
subclassOf:self |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
523 |
instanceVariableNames:instVarNameString |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
524 |
variable:#long |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
525 |
words:false |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
526 |
pointers:false |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
527 |
classVariableNames:classVarString |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
528 |
poolDictionaries:pool |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
529 |
category:cat |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
530 |
comment:nil |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
531 |
changed:true |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
532 |
|
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
533 |
"Created: 12.10.1996 / 19:18:27 / cg" |
1912
3828090cd7fe
use nameSpaceQuery to install classes, instead of Smalltalk
Claus Gittinger <cg@exept.de>
parents:
1899
diff
changeset
|
534 |
"Modified: 6.11.1996 / 22:48:29 / cg" |
1715
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
535 |
! |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
536 |
|
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
537 |
variableSignedLongSubclass:nameSymbol instanceVariableNames:instVarNameString classVariableNames:classVarString poolDictionaries:pool category:cat |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
538 |
"create a new class as a subclass of an existing class (the receiver) |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
539 |
in which the subclass has indexable signed long-sized nonpointer variables" |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
540 |
|
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
541 |
self isVariable ifTrue:[ |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
542 |
self isSignedLongs ifFalse:[ |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
543 |
^ self error: |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
544 |
'cannot make a variable signed long subclass of a variable non-long class' |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
545 |
]. |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
546 |
]. |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
547 |
|
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
548 |
^ self class |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
549 |
name:nameSymbol |
1912
3828090cd7fe
use nameSpaceQuery to install classes, instead of Smalltalk
Claus Gittinger <cg@exept.de>
parents:
1899
diff
changeset
|
550 |
inEnvironment:(Class nameSpaceQuerySignal raise) |
1715
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
551 |
subclassOf:self |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
552 |
instanceVariableNames:instVarNameString |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
553 |
variable:#signedLong |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
554 |
words:false |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
555 |
pointers:false |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
556 |
classVariableNames:classVarString |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
557 |
poolDictionaries:pool |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
558 |
category:cat |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
559 |
comment:nil |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
560 |
changed:true |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
561 |
|
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
562 |
"Created: 12.10.1996 / 19:18:31 / cg" |
1912
3828090cd7fe
use nameSpaceQuery to install classes, instead of Smalltalk
Claus Gittinger <cg@exept.de>
parents:
1899
diff
changeset
|
563 |
"Modified: 6.11.1996 / 22:48:32 / cg" |
1715
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
564 |
! |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
565 |
|
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
566 |
variableSignedWordSubclass:nameSymbol instanceVariableNames:instVarNameString classVariableNames:classVarString poolDictionaries:pool category:cat |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
567 |
"create a new class as a subclass of an existing class (the receiver) |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
568 |
in which the subclass has indexable word-sized signed nonpointer variables" |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
569 |
|
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
570 |
self isVariable ifTrue:[ |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
571 |
self isSignedWords ifFalse:[ |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
572 |
^ self error: |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
573 |
'cannot make a variable signed word subclass of a variable non-word class' |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
574 |
]. |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
575 |
]. |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
576 |
|
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
577 |
^ self class |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
578 |
name:nameSymbol |
1912
3828090cd7fe
use nameSpaceQuery to install classes, instead of Smalltalk
Claus Gittinger <cg@exept.de>
parents:
1899
diff
changeset
|
579 |
inEnvironment:(Class nameSpaceQuerySignal raise) |
1715
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
580 |
subclassOf:self |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
581 |
instanceVariableNames:instVarNameString |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
582 |
variable:#signedWord |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
583 |
words:false |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
584 |
pointers:false |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
585 |
classVariableNames:classVarString |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
586 |
poolDictionaries:pool |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
587 |
category:cat |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
588 |
comment:nil |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
589 |
changed:true |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
590 |
|
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
591 |
"Created: 12.10.1996 / 19:18:34 / cg" |
1912
3828090cd7fe
use nameSpaceQuery to install classes, instead of Smalltalk
Claus Gittinger <cg@exept.de>
parents:
1899
diff
changeset
|
592 |
"Modified: 6.11.1996 / 22:48:35 / cg" |
1715
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
593 |
! |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
594 |
|
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
595 |
variableSubclass:nameSymbol instanceVariableNames:instVarNameString classVariableNames:classVarString poolDictionaries:pool category:cat |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
596 |
"create a new class as a subclass of an existing class (the receiver) |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
597 |
in which the subclass has indexable pointer variables" |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
598 |
|
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
599 |
self isVariable ifTrue:[ |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
600 |
self isPointers ifFalse:[ |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
601 |
^ self error: |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
602 |
'cannot make a variable pointer subclass of a variable non-pointer class' |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
603 |
] |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
604 |
]. |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
605 |
|
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
606 |
^ self class |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
607 |
name:nameSymbol |
1912
3828090cd7fe
use nameSpaceQuery to install classes, instead of Smalltalk
Claus Gittinger <cg@exept.de>
parents:
1899
diff
changeset
|
608 |
inEnvironment:(Class nameSpaceQuerySignal raise) |
1715
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
609 |
subclassOf:self |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
610 |
instanceVariableNames:instVarNameString |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
611 |
variable:true |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
612 |
words:false |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
613 |
pointers:true |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
614 |
classVariableNames:classVarString |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
615 |
poolDictionaries:pool |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
616 |
category:cat |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
617 |
comment:nil |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
618 |
changed:true |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
619 |
|
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
620 |
"Created: 12.10.1996 / 19:18:37 / cg" |
1912
3828090cd7fe
use nameSpaceQuery to install classes, instead of Smalltalk
Claus Gittinger <cg@exept.de>
parents:
1899
diff
changeset
|
621 |
"Modified: 6.11.1996 / 22:48:40 / cg" |
1715
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
622 |
! |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
623 |
|
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
624 |
variableWordSubclass:nameSymbol instanceVariableNames:instVarNameString classVariableNames:classVarString poolDictionaries:pool category:cat |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
625 |
"create a new class as a subclass of an existing class (the receiver) |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
626 |
in which the subclass has indexable word-sized nonpointer variables" |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
627 |
|
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
628 |
self isVariable ifTrue:[ |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
629 |
self isWords ifFalse:[ |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
630 |
^ self error: |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
631 |
'cannot make a variable word subclass of a variable non-word class' |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
632 |
]. |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
633 |
]. |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
634 |
|
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
635 |
^ self class |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
636 |
name:nameSymbol |
1912
3828090cd7fe
use nameSpaceQuery to install classes, instead of Smalltalk
Claus Gittinger <cg@exept.de>
parents:
1899
diff
changeset
|
637 |
inEnvironment:(Class nameSpaceQuerySignal raise) |
1715
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
638 |
subclassOf:self |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
639 |
instanceVariableNames:instVarNameString |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
640 |
variable:true |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
641 |
words:true |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
642 |
pointers:false |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
643 |
classVariableNames:classVarString |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
644 |
poolDictionaries:pool |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
645 |
category:cat |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
646 |
comment:nil |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
647 |
changed:true |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
648 |
|
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
649 |
"Created: 12.10.1996 / 19:18:40 / cg" |
1912
3828090cd7fe
use nameSpaceQuery to install classes, instead of Smalltalk
Claus Gittinger <cg@exept.de>
parents:
1899
diff
changeset
|
650 |
"Modified: 6.11.1996 / 22:48:43 / cg" |
1715
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
651 |
! ! |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
652 |
|
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
653 |
!ClassDescription methodsFor:'subclass creation - private classes'! |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
654 |
|
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
655 |
subclass:nameSymbol instanceVariableNames:instVarNameString classVariableNames:classVarString poolDictionaries:pool privateIn:aClass |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
656 |
"create a new class as a subclass of an existing class (the receiver). |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
657 |
The subclass will have indexed variables if the receiving-class has." |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
658 |
|
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
659 |
|newClass| |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
660 |
|
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
661 |
self isVariable ifFalse:[ |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
662 |
newClass := self class |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
663 |
name:nameSymbol |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
664 |
inEnvironment:aClass |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
665 |
subclassOf:self |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
666 |
instanceVariableNames:instVarNameString |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
667 |
variable:false |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
668 |
words:true |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
669 |
pointers:true |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
670 |
classVariableNames:classVarString |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
671 |
poolDictionaries:pool |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
672 |
category:(aClass category) |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
673 |
comment:nil |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
674 |
changed:true. |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
675 |
^ newClass |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
676 |
]. |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
677 |
self isBytes ifTrue:[ |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
678 |
^ self |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
679 |
variableByteSubclass:nameSymbol |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
680 |
instanceVariableNames:instVarNameString |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
681 |
classVariableNames:classVarString |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
682 |
poolDictionaries:pool |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
683 |
privateIn:aClass |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
684 |
]. |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
685 |
self isLongs ifTrue:[ |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
686 |
^ self |
1899 | 687 |
variableLongSubclass:nameSymbol |
1715
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
688 |
instanceVariableNames:instVarNameString |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
689 |
classVariableNames:classVarString |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
690 |
poolDictionaries:pool |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
691 |
privateIn:aClass |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
692 |
]. |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
693 |
self isFloats ifTrue:[ |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
694 |
^ self |
1899 | 695 |
variableFloatSubclass:nameSymbol |
1715
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
696 |
instanceVariableNames:instVarNameString |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
697 |
classVariableNames:classVarString |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
698 |
poolDictionaries:pool |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
699 |
privateIn:aClass |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
700 |
]. |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
701 |
self isDoubles ifTrue:[ |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
702 |
^ self |
1899 | 703 |
variableDoubleSubclass:nameSymbol |
1715
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
704 |
instanceVariableNames:instVarNameString |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
705 |
classVariableNames:classVarString |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
706 |
poolDictionaries:pool |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
707 |
privateIn:aClass |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
708 |
]. |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
709 |
self isWords ifTrue:[ |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
710 |
^ self |
1899 | 711 |
variableWordSubclass:nameSymbol |
1715
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
712 |
instanceVariableNames:instVarNameString |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
713 |
classVariableNames:classVarString |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
714 |
poolDictionaries:pool |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
715 |
privateIn:aClass |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
716 |
]. |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
717 |
self isSignedWords ifTrue:[ |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
718 |
^ self |
1899 | 719 |
variableSignedWordSubclass:nameSymbol |
1715
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
720 |
instanceVariableNames:instVarNameString |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
721 |
classVariableNames:classVarString |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
722 |
poolDictionaries:pool |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
723 |
privateIn:aClass |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
724 |
]. |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
725 |
self isSignedLongs ifTrue:[ |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
726 |
^ self |
1899 | 727 |
variableSignedLongSubclass:nameSymbol |
1715
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
728 |
instanceVariableNames:instVarNameString |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
729 |
classVariableNames:classVarString |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
730 |
poolDictionaries:pool |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
731 |
privateIn:aClass |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
732 |
]. |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
733 |
|
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
734 |
^ self |
1899 | 735 |
variableSubclass:nameSymbol |
1715
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
736 |
instanceVariableNames:instVarNameString |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
737 |
classVariableNames:classVarString |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
738 |
poolDictionaries:pool |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
739 |
privateIn:aClass |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
740 |
|
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
741 |
"Created: 11.10.1996 / 16:30:53 / cg" |
1899 | 742 |
"Modified: 5.11.1996 / 23:05:22 / cg" |
1715
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
743 |
! |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
744 |
|
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
745 |
variableByteSubclass:nameSymbol instanceVariableNames:instVarNameString classVariableNames:classVarString poolDictionaries:pool privateIn:aClass |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
746 |
"create a new class as a subclass of an existing class (the receiver) |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
747 |
in which the subclass has indexable byte-sized nonpointer variables" |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
748 |
|
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
749 |
|newClass| |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
750 |
|
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
751 |
self isVariable ifTrue:[ |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
752 |
self isBytes ifFalse:[ |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
753 |
^ self error: |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
754 |
'cannot make a variable byte subclass of a variable non-byte class' |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
755 |
]. |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
756 |
]. |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
757 |
|
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
758 |
newClass := self class |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
759 |
name:nameSymbol |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
760 |
inEnvironment:aClass |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
761 |
subclassOf:self |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
762 |
instanceVariableNames:instVarNameString |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
763 |
variable:true |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
764 |
words:false |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
765 |
pointers:false |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
766 |
classVariableNames:classVarString |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
767 |
poolDictionaries:pool |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
768 |
category:(aClass category) |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
769 |
comment:nil |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
770 |
changed:true. |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
771 |
|
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
772 |
^ newClass |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
773 |
|
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
774 |
"Created: 11.10.1996 / 16:31:27 / cg" |
1740 | 775 |
"Modified: 14.10.1996 / 17:39:42 / cg" |
1715
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
776 |
! |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
777 |
|
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
778 |
variableDoubleSubclass:nameSymbol instanceVariableNames:instVarNameString classVariableNames:classVarString poolDictionaries:pool privateIn:aClass |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
779 |
|
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
780 |
"create a new class as a subclass of an existing class (the receiver) |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
781 |
in which the subclass has indexable double-sized nonpointer variables" |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
782 |
|
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
783 |
|newClass| |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
784 |
|
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
785 |
self isVariable ifTrue:[ |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
786 |
self isDoubles ifFalse:[ |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
787 |
^ self error: |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
788 |
'cannot make a variable double subclass of a variable non-double class' |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
789 |
]. |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
790 |
]. |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
791 |
|
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
792 |
newClass := self class |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
793 |
name:nameSymbol |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
794 |
inEnvironment:aClass |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
795 |
subclassOf:self |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
796 |
instanceVariableNames:instVarNameString |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
797 |
variable:#double |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
798 |
words:false |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
799 |
pointers:false |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
800 |
classVariableNames:classVarString |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
801 |
poolDictionaries:pool |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
802 |
category:(aClass category) |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
803 |
comment:nil |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
804 |
changed:true. |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
805 |
|
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
806 |
^ newClass |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
807 |
|
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
808 |
"Created: 11.10.1996 / 16:32:23 / cg" |
1740 | 809 |
"Modified: 14.10.1996 / 17:39:45 / cg" |
1715
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
810 |
! |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
811 |
|
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
812 |
variableFloatSubclass:nameSymbol instanceVariableNames:instVarNameString classVariableNames:classVarString poolDictionaries:pool privateIn:aClass |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
813 |
|
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
814 |
"create a new class as a subclass of an existing class (the receiver) |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
815 |
in which the subclass has indexable float-sized nonpointer variables" |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
816 |
|
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
817 |
|newClass| |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
818 |
|
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
819 |
self isVariable ifTrue:[ |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
820 |
self isFloats ifFalse:[ |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
821 |
^ self error: |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
822 |
'cannot make a variable float subclass of a variable non-float class' |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
823 |
]. |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
824 |
]. |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
825 |
|
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
826 |
newClass := self class |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
827 |
name:nameSymbol |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
828 |
inEnvironment:aClass |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
829 |
subclassOf:self |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
830 |
instanceVariableNames:instVarNameString |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
831 |
variable:#float |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
832 |
words:false |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
833 |
pointers:false |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
834 |
classVariableNames:classVarString |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
835 |
poolDictionaries:pool |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
836 |
category:(aClass category) |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
837 |
comment:nil |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
838 |
changed:true. |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
839 |
|
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
840 |
^ newClass |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
841 |
|
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
842 |
"Created: 11.10.1996 / 16:32:37 / cg" |
1740 | 843 |
"Modified: 14.10.1996 / 17:39:50 / cg" |
1715
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
844 |
! |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
845 |
|
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
846 |
variableLongSubclass:nameSymbol instanceVariableNames:instVarNameString classVariableNames:classVarString poolDictionaries:pool privateIn:aClass |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
847 |
"create a new class as a subclass of an existing class (the receiver) |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
848 |
in which the subclass has indexable long-sized nonpointer variables" |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
849 |
|
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
850 |
|newClass| |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
851 |
|
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
852 |
self isVariable ifTrue:[ |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
853 |
self isLongs ifFalse:[ |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
854 |
^ self error: |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
855 |
'cannot make a variable long subclass of a variable non-long class' |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
856 |
]. |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
857 |
]. |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
858 |
|
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
859 |
newClass := self class |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
860 |
name:nameSymbol |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
861 |
inEnvironment:aClass |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
862 |
subclassOf:self |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
863 |
instanceVariableNames:instVarNameString |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
864 |
variable:#long |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
865 |
words:false |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
866 |
pointers:false |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
867 |
classVariableNames:classVarString |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
868 |
poolDictionaries:pool |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
869 |
category:(aClass category) |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
870 |
comment:nil |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
871 |
changed:true. |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
872 |
|
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
873 |
^ newClass |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
874 |
|
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
875 |
"Created: 11.10.1996 / 16:32:48 / cg" |
1740 | 876 |
"Modified: 14.10.1996 / 17:39:54 / cg" |
1715
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
877 |
! |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
878 |
|
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
879 |
variableSignedLongSubclass:nameSymbol instanceVariableNames:instVarNameString classVariableNames:classVarString poolDictionaries:pool privateIn:aClass |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
880 |
"create a new class as a subclass of an existing class (the receiver) |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
881 |
in which the subclass has indexable signed long-sized nonpointer variables" |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
882 |
|
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
883 |
|newClass| |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
884 |
|
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
885 |
self isVariable ifTrue:[ |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
886 |
self isSignedLongs ifFalse:[ |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
887 |
^ self error: |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
888 |
'cannot make a variable signed long subclass of a variable non-long class' |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
889 |
]. |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
890 |
]. |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
891 |
|
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
892 |
newClass := self class |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
893 |
name:nameSymbol |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
894 |
inEnvironment:aClass |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
895 |
subclassOf:self |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
896 |
instanceVariableNames:instVarNameString |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
897 |
variable:#signedLong |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
898 |
words:false |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
899 |
pointers:false |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
900 |
classVariableNames:classVarString |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
901 |
poolDictionaries:pool |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
902 |
category:(aClass category) |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
903 |
comment:nil |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
904 |
changed:true. |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
905 |
|
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
906 |
^ newClass |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
907 |
|
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
908 |
"Created: 11.10.1996 / 16:46:30 / cg" |
1740 | 909 |
"Modified: 14.10.1996 / 17:39:58 / cg" |
1715
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
910 |
! |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
911 |
|
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
912 |
variableSignedWordSubclass:nameSymbol instanceVariableNames:instVarNameString classVariableNames:classVarString poolDictionaries:pool privateIn:aClass |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
913 |
"create a new class as a subclass of an existing class (the receiver) |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
914 |
in which the subclass has indexable word-sized signed nonpointer variables" |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
915 |
|
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
916 |
|newClass| |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
917 |
|
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
918 |
self isVariable ifTrue:[ |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
919 |
self isSignedWords ifFalse:[ |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
920 |
^ self error: |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
921 |
'cannot make a variable signed word subclass of a variable non-word class' |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
922 |
]. |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
923 |
]. |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
924 |
|
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
925 |
newClass := self class |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
926 |
name:nameSymbol |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
927 |
inEnvironment:aClass |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
928 |
subclassOf:self |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
929 |
instanceVariableNames:instVarNameString |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
930 |
variable:#signedWord |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
931 |
words:false |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
932 |
pointers:false |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
933 |
classVariableNames:classVarString |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
934 |
poolDictionaries:pool |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
935 |
category:(aClass category) |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
936 |
comment:nil |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
937 |
changed:true. |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
938 |
|
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
939 |
^ newClass |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
940 |
|
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
941 |
"Created: 11.10.1996 / 16:46:44 / cg" |
1740 | 942 |
"Modified: 14.10.1996 / 17:40:01 / cg" |
1715
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
943 |
! |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
944 |
|
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
945 |
variableSubclass:nameSymbol instanceVariableNames:instVarNameString classVariableNames:classVarString poolDictionaries:pool privateIn:aClass |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
946 |
"create a new class as a subclass of an existing class (the receiver) |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
947 |
in which the subclass has indexable pointer variables" |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
948 |
|
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
949 |
|newClass| |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
950 |
|
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
951 |
self isVariable ifTrue:[ |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
952 |
self isPointers ifFalse:[ |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
953 |
^ self error: |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
954 |
'cannot make a variable pointer subclass of a variable non-pointer class' |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
955 |
] |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
956 |
]. |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
957 |
|
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
958 |
newClass := self class |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
959 |
name:nameSymbol |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
960 |
inEnvironment:aClass |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
961 |
subclassOf:self |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
962 |
instanceVariableNames:instVarNameString |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
963 |
variable:true |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
964 |
words:false |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
965 |
pointers:true |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
966 |
classVariableNames:classVarString |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
967 |
poolDictionaries:pool |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
968 |
category:(aClass category) |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
969 |
comment:nil |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
970 |
changed:true. |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
971 |
|
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
972 |
^ newClass |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
973 |
|
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
974 |
"Created: 11.10.1996 / 16:54:33 / cg" |
1740 | 975 |
"Modified: 14.10.1996 / 17:40:06 / cg" |
1715
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
976 |
! |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
977 |
|
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
978 |
variableWordSubclass:nameSymbol instanceVariableNames:instVarNameString classVariableNames:classVarString poolDictionaries:pool privateIn:aClass |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
979 |
"create a new class as a subclass of an existing class (the receiver) |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
980 |
in which the subclass has indexable word-sized nonpointer variables" |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
981 |
|
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
982 |
|newClass| |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
983 |
|
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
984 |
self isVariable ifTrue:[ |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
985 |
self isWords ifFalse:[ |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
986 |
^ self error: |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
987 |
'cannot make a variable word subclass of a variable non-word class' |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
988 |
]. |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
989 |
]. |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
990 |
|
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
991 |
newClass := self class |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
992 |
name:nameSymbol |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
993 |
inEnvironment:aClass |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
994 |
subclassOf:self |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
995 |
instanceVariableNames:instVarNameString |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
996 |
variable:true |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
997 |
words:true |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
998 |
pointers:false |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
999 |
classVariableNames:classVarString |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
1000 |
poolDictionaries:pool |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
1001 |
category:(aClass category) |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
1002 |
comment:nil |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
1003 |
changed:true. |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
1004 |
|
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
1005 |
^ newClass |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
1006 |
|
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
1007 |
"Created: 11.10.1996 / 16:54:48 / cg" |
1740 | 1008 |
"Modified: 14.10.1996 / 17:40:09 / cg" |
1715
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
1009 |
! ! |
8bd2a2d8fbb4
moved subclass creation methods up to ClassDescription
Claus Gittinger <cg@exept.de>
parents:
1669
diff
changeset
|
1010 |
|
1740 | 1011 |
!ClassDescription class methodsFor:'documentation'! |
662 | 1012 |
|
1013 |
version |
|
2435 | 1014 |
^ '$Header: /cvs/stx/stx/libbasic/Attic/ClassDescr.st,v 1.40 1997-03-03 12:08:06 cg Exp $' |
662 | 1015 |
! ! |