Skip to content

Commit 72fe253

Browse files
committed
issue #953: preparing to add RwTestProjectLibraryGeneratorV4 which will test support for unicode codePoint method sort order
1 parent b0e403d commit 72fe253

File tree

5 files changed

+101
-4
lines changed

5 files changed

+101
-4
lines changed

rowan/src/Rowan-Core/RwDefinedProject.class.st

+32
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,16 @@ RwDefinedProject class >> newV2Named: aName [
3131
yourself
3232
]
3333

34+
{ #category : 'instance creation' }
35+
RwDefinedProject class >> newV3Named: aName [
36+
"Create a new project that uses project spec and component classes that are compatible with Rowan v3"
37+
38+
^ self new
39+
initializeForName: aName;
40+
_concreteProjectV3;
41+
yourself
42+
]
43+
3444
{ #category : 'private' }
3545
RwDefinedProject >> _concreteProject [
3646
"Create a new project that uses Rowan v3 project spec and component classes"
@@ -53,6 +63,28 @@ RwDefinedProject >> _concreteProjectV2 [
5363
yourself ]
5464
]
5565

66+
{ #category : 'private' }
67+
RwDefinedProject >> _concreteProjectV3 [
68+
"Create a new project that uses project spec and component classes that are compatible with Rowan v2"
69+
70+
^ concreteProject
71+
ifNil: [
72+
concreteProject := RwResolvedProjectV2 newV3
73+
projectName: self name;
74+
yourself ]
75+
]
76+
77+
{ #category : 'private' }
78+
RwDefinedProject >> _concreteProjectV4 [
79+
"Create a new project that uses project spec and component classes that are compatible with Rowan v4"
80+
81+
^ concreteProject
82+
ifNil: [
83+
concreteProject := RwResolvedProjectV2 newV4
84+
projectName: self name;
85+
yourself ]
86+
]
87+
5688
{ #category : 'private' }
5789
RwDefinedProject >> _gemstoneAllUsersName [
5890
^ self _concreteProject _gemstoneAllUsersName

rowan/src/Rowan-Definitions-Common/RwAbstractResolvedObjectV2.class.st

+33-4
Original file line numberDiff line numberDiff line change
@@ -18,11 +18,25 @@ RwAbstractResolvedObjectV2 class >> new [
1818

1919
{ #category : 'instance creation' }
2020
RwAbstractResolvedObjectV2 class >> newV2 [
21-
"Create a new project that uses project spec and component classes that are compatible with Rowan v2"
21+
"Create a new project that uses project spec and component classes that are default for Rowan v2; read and written by Rowan v3"
2222

2323
^ self basicNew initializeV2
2424
]
2525

26+
{ #category : 'instance creation' }
27+
RwAbstractResolvedObjectV2 class >> newV3 [
28+
"Create a new project that uses project spec and component classes that default for Rowan v3; read and written by Rowan v4"
29+
30+
^ self basicNew initializeV3
31+
]
32+
33+
{ #category : 'instance creation' }
34+
RwAbstractResolvedObjectV2 class >> newV4 [
35+
"Create a new project that uses project spec and component classes that are default for Rowan v4"
36+
37+
^ self basicNew initializeV4
38+
]
39+
2640
{ #category : 'private' }
2741
RwAbstractResolvedObjectV2 >> _gemstoneAllUsersName [
2842
^ self loadSpecification _gemstoneAllUsersName
@@ -159,18 +173,33 @@ RwAbstractResolvedObjectV2 >> groupNames: anArray [
159173
RwAbstractResolvedObjectV2 >> initialize [
160174
"Create a new project that uses Rowan v3 project spec and component classes"
161175

162-
projectSpecification := RwProjectSpecificationV3 new.
163-
loadSpecification := RwLoadSpecificationV2 new.
176+
self initializeV3
164177
]
165178

166179
{ #category : 'initialization' }
167180
RwAbstractResolvedObjectV2 >> initializeV2 [
168-
"Create a new project that uses project spec and component classes that are compatible with Rowan v2"
181+
"Create a new project that uses project spec and component classes that are default for Rowan v2; read and written by Rowan v3"
169182

170183
projectSpecification := RwProjectSpecificationV2 new.
171184
loadSpecification := RwLoadSpecificationV2 new.
172185
]
173186

187+
{ #category : 'initialization' }
188+
RwAbstractResolvedObjectV2 >> initializeV3 [
189+
"Create a new project that uses Rowan v3 project spec and component classes default for Rowan v3; read and written by Rowan v4"
190+
191+
projectSpecification := RwProjectSpecificationV3 new.
192+
loadSpecification := RwLoadSpecificationV2 new.
193+
]
194+
195+
{ #category : 'initialization' }
196+
RwAbstractResolvedObjectV2 >> initializeV4 [
197+
"Create a new project that uses Rowan v3 project spec and component classes default for Rowan v4; read and written by Rowan v3"
198+
199+
projectSpecification := RwProjectSpecificationV4 new.
200+
loadSpecification := RwLoadSpecificationV2 new.
201+
]
202+
174203
{ #category : 'testing' }
175204
RwAbstractResolvedObjectV2 >> isStrict [
176205
^ self loadSpecification isStrict

rowan/src/Rowan-SpecificationsV2/RwProjectSpecificationV2.class.st

+14
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,10 @@
1+
"
2+
RwProjectSpecificationV2 is a project specification that is use by Rowan V2 and Rowan V3 to specify project-specific attributes for Rowan.
3+
4+
Rowan 3 reads and writes projects that use this class.
5+
6+
methodSortOrder is `unicode`
7+
"
18
Class {
29
#name : 'RwProjectSpecificationV2',
310
#superclass : 'RwSpecification',
@@ -152,6 +159,13 @@ RwProjectSpecificationV2 >> loadedCommitId: aCommitId [
152159
loadedCommitId := aCommitId
153160
]
154161

162+
{ #category : 'accessing' }
163+
RwProjectSpecificationV2 >> methodSortOrder [
164+
"methods in tonel projects will be sorted in unicode sort order"
165+
166+
^ 'unicode'
167+
]
168+
155169
{ #category : 'accessing' }
156170
RwProjectSpecificationV2 >> packageConvention [
157171
^ packageConvention ifNil: [ 'RowanHybrid' ]

rowan/src/Rowan-SpecificationsV2/RwProjectSpecificationV3.class.st

+5
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,8 @@
1+
"
2+
RwProjectSpecificationV3 is a project specification that is use by Rowan V3 to specify project-specific attributes for Rowan.
3+
4+
Rowan versions 3.0.0 through 3.3.0 use this class. Methods in tonel packages are sorted using unicode sort order
5+
"
16
Class {
27
#name : 'RwProjectSpecificationV3',
38
#superclass : 'RwProjectSpecificationV2',
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
"
2+
RwProjectSpecificationV4 is a project specification that is use by Rowan V3.4.0 and beyond to specify project-specific attributes for Rowan.
3+
4+
Projects managed using this class write tonel files that conform to the tonel spec. Specifically this class writes packages sorting methods based Unicode codePoint sort
5+
"
6+
Class {
7+
#name : 'RwProjectSpecificationV4',
8+
#superclass : 'RwProjectSpecificationV3',
9+
#category : 'Rowan-SpecificationsV2'
10+
}
11+
12+
{ #category : 'accessing' }
13+
RwProjectSpecificationV4 >> methodSortOrder [
14+
"methods in tonel projects will be sorted in unicode codePoint sort order"
15+
16+
^ 'codePoint'
17+
]

0 commit comments

Comments
 (0)