30 inclusion of the above copyright notice. This software may not |
30 inclusion of the above copyright notice. This software may not |
31 be provided or otherwise made available to, or used by, any |
31 be provided or otherwise made available to, or used by, any |
32 other person. No title to or ownership of the software is |
32 other person. No title to or ownership of the software is |
33 hereby transferred. |
33 hereby transferred. |
34 " |
34 " |
|
35 ! ! |
|
36 |
|
37 !SmalltalkChunkFileSourceWriter class methodsFor:'utilities - source code'! |
|
38 |
|
39 methodTemplate |
|
40 "return a method definition template string" |
|
41 |
|
42 |s| |
|
43 |
|
44 s := TextStream on:''. |
|
45 s nextPutAll: |
|
46 'message selector and argument names |
|
47 "comment stating purpose of this message" |
|
48 |
|
49 |temporaries| |
|
50 |
|
51 statement. |
|
52 statement. |
|
53 |
|
54 " |
|
55 optional: comment giving example use |
|
56 " |
|
57 '. |
|
58 s cr. |
|
59 s emphasis:(UserPreferences current commentEmphasisAndColor). |
|
60 s nextPutAll: |
|
61 '" |
|
62 change the above template into real code; |
|
63 remove this comment. |
|
64 Then `accept'' either via the menu |
|
65 or via the keyboard (usually CMD-A). |
|
66 |
|
67 You do not need this template; you can also |
|
68 select any existing methods code, change it, |
|
69 and finally `accept''. The method will then be |
|
70 installed under the selector as defined in the |
|
71 actual text - no matter which method is selected |
|
72 in the browser. |
|
73 |
|
74 Or clear this text, type in the method from scratch |
|
75 and install it with `accept''. |
|
76 " |
|
77 '. |
|
78 ^ s contents |
|
79 ! |
|
80 |
|
81 versionMethodTemplateForCVS |
|
82 "careful to avoid expansion by cvs here!!" |
|
83 |
|
84 ^ ('version\ ^ ''$' , 'Header$''') withCRs |
|
85 |
|
86 "Created: / 21-08-2012 / 11:52:27 / cg" |
35 ! ! |
87 ! ! |
36 |
88 |
37 !SmalltalkChunkFileSourceWriter methodsFor:'source writing'! |
89 !SmalltalkChunkFileSourceWriter methodsFor:'source writing'! |
38 |
90 |
39 fileOut:aClass on:outStreamArg withTimeStamp:stampIt withInitialize:initIt withDefinition:withDefinition methodFilter:methodFilter encoder:encoderOrNil |
91 fileOut:aClass on:outStreamArg withTimeStamp:stampIt withInitialize:initIt withDefinition:withDefinition methodFilter:methodFilter encoder:encoderOrNil |