0
|
1 |
"{ Package: 'stx:goodies/ring' }"
|
|
2 |
|
|
3 |
"{ NameSpace: Smalltalk }"
|
|
4 |
|
|
5 |
RGElementDefinition subclass:#RGVariableDefinition
|
|
6 |
instanceVariableNames:''
|
|
7 |
classVariableNames:''
|
|
8 |
poolDictionaries:''
|
|
9 |
category:'Ring-Core-Kernel'
|
|
10 |
!
|
|
11 |
|
|
12 |
RGVariableDefinition comment:'A variable definition'
|
|
13 |
!
|
|
14 |
|
|
15 |
|
|
16 |
!RGVariableDefinition methodsFor:'accessing'!
|
|
17 |
|
|
18 |
environment
|
|
19 |
|
|
20 |
^ self parent environment
|
|
21 |
!
|
|
22 |
|
|
23 |
fullName
|
|
24 |
"Keeps a unique description for the receiver. As annotation to avoid converting each time is invoked"
|
|
25 |
|
|
26 |
^self annotationNamed: self class fullNameKey
|
|
27 |
ifAbsentPut:[ (self parentName, '->', self name) asSymbol ]
|
|
28 |
! !
|
|
29 |
|
|
30 |
!RGVariableDefinition methodsFor:'comparing'!
|
|
31 |
|
|
32 |
= aRGVariableDefinition
|
|
33 |
"This variable look for equality of the key properties of the receiver"
|
|
34 |
|
|
35 |
^(super = aRGVariableDefinition)
|
|
36 |
and:[ self name == aRGVariableDefinition name ]
|
|
37 |
!
|
|
38 |
|
|
39 |
hash
|
|
40 |
|
|
41 |
^super hash bitXor: self name hash
|
|
42 |
! !
|
|
43 |
|
|
44 |
!RGVariableDefinition methodsFor:'testing'!
|
|
45 |
|
|
46 |
isClassInstanceVariable
|
|
47 |
|
|
48 |
^false
|
|
49 |
!
|
|
50 |
|
|
51 |
isClassVariable
|
|
52 |
|
|
53 |
^false
|
|
54 |
!
|
|
55 |
|
|
56 |
isInstanceVariable
|
|
57 |
|
|
58 |
^false
|
|
59 |
!
|
|
60 |
|
|
61 |
isPoolVariable
|
|
62 |
|
|
63 |
^false
|
|
64 |
!
|
|
65 |
|
|
66 |
isVariable
|
|
67 |
|
|
68 |
^true
|
|
69 |
! !
|
|
70 |
|
|
71 |
!RGVariableDefinition class methodsFor:'documentation'!
|
|
72 |
|
|
73 |
version_HG
|
|
74 |
|
|
75 |
^ '$Changeset: <not expanded> $'
|
|
76 |
! !
|
|
77 |
|