Skip to content

Commit db9eb5f

Browse files
committed
Generated entities
1 parent 7ec87f0 commit db9eb5f

File tree

1 file changed

+51
-0
lines changed

1 file changed

+51
-0
lines changed

src/Famix-TypeScript-Entities/FamixTypeScriptProperty.class.st

Lines changed: 51 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,9 @@ I represent a TypeScript class property.
2727
| Name | Type | Default value | Comment |
2828
|---|
2929
| `isClassSide` | `Boolean` | false | Entity can be declared class side i.e. static|
30+
| `isDefinitelyAssigned` | `Boolean` | false | Properties may be postfixed with a definitely assigned modifier.|
31+
| `isJavaScriptPrivate` | `Boolean` | false | Properties may be postfixed with a private modifier that makes the property private even in JavaScript.|
32+
| `isOptional` | `Boolean` | false | Properties may be postfixed with an optional modifier.|
3033
| `isStub` | `Boolean` | false | Flag true if the entity attributes are incomplete, either because the entity is missing or not imported.|
3134
| `name` | `String` | nil | Basic name of the entity, not full reference.|
3235
| `readOnly` | `Boolean` | false | Properties may be prefixed with the readonly modifier. This prevents assignments to the field outside of the constructor.|
@@ -39,6 +42,9 @@ Class {
3942
#traits : 'FamixTAttribute + FamixTCanBeClassSide + FamixTHasVisibility',
4043
#classTraits : 'FamixTAttribute classTrait + FamixTCanBeClassSide classTrait + FamixTHasVisibility classTrait',
4144
#instVars : [
45+
'#isDefinitelyAssigned => FMProperty defaultValue: false',
46+
'#isJavaScriptPrivate => FMProperty defaultValue: false',
47+
'#isOptional => FMProperty defaultValue: false',
4248
'#readOnly => FMProperty defaultValue: false'
4349
],
4450
#category : #'Famix-TypeScript-Entities-Entities'
@@ -53,6 +59,51 @@ FamixTypeScriptProperty class >> annotation [
5359
^ self
5460
]
5561

62+
{ #category : #accessing }
63+
FamixTypeScriptProperty >> isDefinitelyAssigned [
64+
65+
<FMProperty: #isDefinitelyAssigned type: #Boolean defaultValue: false>
66+
<generated>
67+
<FMComment: 'Properties may be postfixed with a definitely assigned modifier.'>
68+
^ isDefinitelyAssigned ifNil: [ isDefinitelyAssigned := false ]
69+
]
70+
71+
{ #category : #accessing }
72+
FamixTypeScriptProperty >> isDefinitelyAssigned: anObject [
73+
<generated>
74+
isDefinitelyAssigned := anObject
75+
]
76+
77+
{ #category : #accessing }
78+
FamixTypeScriptProperty >> isJavaScriptPrivate [
79+
80+
<FMProperty: #isJavaScriptPrivate type: #Boolean defaultValue: false>
81+
<generated>
82+
<FMComment: 'Properties may be postfixed with a private modifier that makes the property private even in JavaScript.'>
83+
^ isJavaScriptPrivate ifNil: [ isJavaScriptPrivate := false ]
84+
]
85+
86+
{ #category : #accessing }
87+
FamixTypeScriptProperty >> isJavaScriptPrivate: anObject [
88+
<generated>
89+
isJavaScriptPrivate := anObject
90+
]
91+
92+
{ #category : #accessing }
93+
FamixTypeScriptProperty >> isOptional [
94+
95+
<FMProperty: #isOptional type: #Boolean defaultValue: false>
96+
<generated>
97+
<FMComment: 'Properties may be postfixed with an optional modifier.'>
98+
^ isOptional ifNil: [ isOptional := false ]
99+
]
100+
101+
{ #category : #accessing }
102+
FamixTypeScriptProperty >> isOptional: anObject [
103+
<generated>
104+
isOptional := anObject
105+
]
106+
56107
{ #category : #accessing }
57108
FamixTypeScriptProperty >> readOnly [
58109

0 commit comments

Comments
 (0)