author | Jan Vrany <jan.vrany@fit.cvut.cz> |
Mon, 25 Feb 2019 17:55:20 +0000 | |
changeset 177 | e7bd05df3d6b |
parent 162 | e56b2f6369af |
child 211 | d493b4969b59 |
permissions | -rw-r--r-- |
154
abd4d9bdec0e
Portability: remove `GDBOutputFormats` pool
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
97
diff
changeset
|
1 |
"{ Encoding: utf8 }" |
abd4d9bdec0e
Portability: remove `GDBOutputFormats` pool
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
97
diff
changeset
|
2 |
|
97 | 3 |
" |
4 |
jv:libgdbs - GNU Debugger Interface Library |
|
5 |
Copyright (C) 2015-now Jan Vrany |
|
6 |
||
7 |
This library is free software; you can redistribute it and/or |
|
8 |
modify it under the terms of the GNU Lesser General Public |
|
9 |
License as published by the Free Software Foundation; either |
|
10 |
version 2.1 of the License. |
|
11 |
||
12 |
This library is distributed in the hope that it will be useful, |
|
13 |
but WITHOUT ANY WARRANTY; without even the implied warranty of |
|
14 |
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU |
|
15 |
Lesser General Public License for more details. |
|
16 |
||
17 |
You should have received a copy of the GNU Lesser General Public |
|
18 |
License along with this library; if not, write to the Free Software |
|
19 |
Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA |
|
20 |
" |
|
21 |
"{ Package: 'jv:libgdbs' }" |
|
22 |
||
23 |
"{ NameSpace: Smalltalk }" |
|
24 |
||
25 |
Object subclass:#GDBOutputFormat |
|
26 |
instanceVariableNames:'format name description' |
|
154
abd4d9bdec0e
Portability: remove `GDBOutputFormats` pool
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
97
diff
changeset
|
27 |
classVariableNames:'FormatAddress FormatBinary FormatCharacterConstant |
abd4d9bdec0e
Portability: remove `GDBOutputFormats` pool
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
97
diff
changeset
|
28 |
FormatFloatingPoint FormatHexadecimal FormatOctal |
abd4d9bdec0e
Portability: remove `GDBOutputFormats` pool
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
97
diff
changeset
|
29 |
FormatPaddedHexadecimal FormatRaw FormatSignedDecimal |
abd4d9bdec0e
Portability: remove `GDBOutputFormats` pool
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
97
diff
changeset
|
30 |
FormatString FormatUnsignedDecimal' |
97 | 31 |
poolDictionaries:'' |
154
abd4d9bdec0e
Portability: remove `GDBOutputFormats` pool
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
97
diff
changeset
|
32 |
category:'GDB-Core' |
97 | 33 |
! |
34 |
||
35 |
!GDBOutputFormat class methodsFor:'documentation'! |
|
36 |
||
37 |
copyright |
|
38 |
" |
|
39 |
jv:libgdbs - GNU Debugger Interface Library |
|
40 |
Copyright (C) 2015-now Jan Vrany |
|
41 |
||
42 |
This library is free software; you can redistribute it and/or |
|
43 |
modify it under the terms of the GNU Lesser General Public |
|
44 |
License as published by the Free Software Foundation; either |
|
45 |
version 2.1 of the License. |
|
46 |
||
47 |
This library is distributed in the hope that it will be useful, |
|
48 |
but WITHOUT ANY WARRANTY; without even the implied warranty of |
|
49 |
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU |
|
50 |
Lesser General Public License for more details. |
|
51 |
||
52 |
You should have received a copy of the GNU Lesser General Public |
|
53 |
License along with this library; if not, write to the Free Software |
|
54 |
Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA |
|
55 |
" |
|
56 |
! |
|
57 |
||
58 |
documentation |
|
59 |
" |
|
60 |
GDBOutputFormat is a reification of one of output formats |
|
61 |
defined by GDB. |
|
62 |
||
63 |
Do not use this class directly in user code, use constants |
|
64 |
defined `GDBOutputFormats` |
|
65 |
||
66 |
[author:] |
|
67 |
Jan Vrany <jan.vrany@fit.cvut.cz> |
|
68 |
||
69 |
[instance variables:] |
|
70 |
||
71 |
[class variables:] |
|
72 |
||
73 |
[see also:] |
|
74 |
GDBOutputFormats |
|
75 |
https://sourceware.org/gdb/onlinedocs/gdb/Output-Formats.html#Output-Formats |
|
76 |
||
77 |
" |
|
78 |
! ! |
|
79 |
||
154
abd4d9bdec0e
Portability: remove `GDBOutputFormats` pool
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
97
diff
changeset
|
80 |
!GDBOutputFormat class methodsFor:'initialization'! |
abd4d9bdec0e
Portability: remove `GDBOutputFormats` pool
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
97
diff
changeset
|
81 |
|
abd4d9bdec0e
Portability: remove `GDBOutputFormats` pool
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
97
diff
changeset
|
82 |
initialize |
abd4d9bdec0e
Portability: remove `GDBOutputFormats` pool
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
97
diff
changeset
|
83 |
"Invoked at system start or when the class is dynamically loaded." |
abd4d9bdec0e
Portability: remove `GDBOutputFormats` pool
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
97
diff
changeset
|
84 |
|
abd4d9bdec0e
Portability: remove `GDBOutputFormats` pool
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
97
diff
changeset
|
85 |
"/ See https://sourceware.org/gdb/onlinedocs/gdb/Output-Formats.html#Output-Formats |
abd4d9bdec0e
Portability: remove `GDBOutputFormats` pool
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
97
diff
changeset
|
86 |
|
abd4d9bdec0e
Portability: remove `GDBOutputFormats` pool
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
97
diff
changeset
|
87 |
FormatHexadecimal := GDBOutputFormat format: $x name: 'Hexadecimal' description: 'Regard the bits of the value as an integer, and print the integer in hexadecimal.'. |
abd4d9bdec0e
Portability: remove `GDBOutputFormats` pool
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
97
diff
changeset
|
88 |
FormatSignedDecimal := GDBOutputFormat format: $d name: 'Signed decimal' description: 'Print as integer in signed decimal.'. |
abd4d9bdec0e
Portability: remove `GDBOutputFormats` pool
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
97
diff
changeset
|
89 |
FormatUnsignedDecimal := GDBOutputFormat format: $u name: 'Unsigned decimal' description: 'Print as integer in unsigned decimal.'. |
abd4d9bdec0e
Portability: remove `GDBOutputFormats` pool
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
97
diff
changeset
|
90 |
FormatOctal := GDBOutputFormat format: $o name: 'Octal' description: 'Print as integer in octal.'. |
abd4d9bdec0e
Portability: remove `GDBOutputFormats` pool
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
97
diff
changeset
|
91 |
FormatBinary := GDBOutputFormat format: $t name: 'Binary' description: 'Print as integer in binary.'. |
abd4d9bdec0e
Portability: remove `GDBOutputFormats` pool
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
97
diff
changeset
|
92 |
FormatAddress := GDBOutputFormat format: $a name: 'Address' description: 'Print as an address, both absolute in hexadecimal and as an offset from the nearest preceding symbol. You can use this format used to discover where (in what function) an unknown address is located: |
abd4d9bdec0e
Portability: remove `GDBOutputFormats` pool
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
97
diff
changeset
|
93 |
|
abd4d9bdec0e
Portability: remove `GDBOutputFormats` pool
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
97
diff
changeset
|
94 |
(gdb) p/a 0x54320 |
abd4d9bdec0e
Portability: remove `GDBOutputFormats` pool
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
97
diff
changeset
|
95 |
$3 = 0x54320 <_initialize_vx+396> |
abd4d9bdec0e
Portability: remove `GDBOutputFormats` pool
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
97
diff
changeset
|
96 |
|
abd4d9bdec0e
Portability: remove `GDBOutputFormats` pool
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
97
diff
changeset
|
97 |
The command info symbol 0x54320 yields similar results. See info symbol. '. |
abd4d9bdec0e
Portability: remove `GDBOutputFormats` pool
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
97
diff
changeset
|
98 |
FormatCharacterConstant := GDBOutputFormat format: $c name: 'Character constant' description: ' Regard as an integer and print it as a character constant. This prints both the numerical value and its character representation. The character representation is replaced with the octal escape ‘\nnn’ for characters outside the 7-bit ASCII range. |
abd4d9bdec0e
Portability: remove `GDBOutputFormats` pool
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
97
diff
changeset
|
99 |
|
abd4d9bdec0e
Portability: remove `GDBOutputFormats` pool
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
97
diff
changeset
|
100 |
Without this format, GDB displays char, unsigned char, and signed char data as character constants. Single-byte members of vectors are displayed as integer data. |
abd4d9bdec0e
Portability: remove `GDBOutputFormats` pool
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
97
diff
changeset
|
101 |
'. |
abd4d9bdec0e
Portability: remove `GDBOutputFormats` pool
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
97
diff
changeset
|
102 |
FormatFloatingPoint := GDBOutputFormat format: $f name: 'Floating point' description: 'Regard the bits of the value as a floating point number and print using typical floating point syntax. '. |
abd4d9bdec0e
Portability: remove `GDBOutputFormats` pool
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
97
diff
changeset
|
103 |
FormatString := GDBOutputFormat format: $s name: 'String' description: 'Regard as a string, if possible. With this format, pointers to single-byte data are displayed as null-terminated strings and arrays of single-byte data are displayed as fixed-length strings. Other values are displayed in their natural types. |
abd4d9bdec0e
Portability: remove `GDBOutputFormats` pool
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
97
diff
changeset
|
104 |
|
abd4d9bdec0e
Portability: remove `GDBOutputFormats` pool
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
97
diff
changeset
|
105 |
Without this format, GDB displays pointers to and arrays of char, unsigned char, and signed char as strings. Single-byte members of a vector are displayed as an integer array. '. |
abd4d9bdec0e
Portability: remove `GDBOutputFormats` pool
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
97
diff
changeset
|
106 |
FormatPaddedHexadecimal := GDBOutputFormat format: $x name: 'Padded hexadecimal' description: 'Like ‘x’ (hexadecimal) formatting, the value is treated as an integer and printed as hexadecimal, but leading zeros are printed to pad the value to the size of the integer type. '. |
abd4d9bdec0e
Portability: remove `GDBOutputFormats` pool
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
97
diff
changeset
|
107 |
FormatRaw := GDBOutputFormat format: $r name: 'Raw' description: 'Print using the ‘raw’ formatting. By default, GDB will use a Python-based pretty-printer, if one is available (see Pretty Printing). This typically results in a higher-level display of the value’s contents. The ‘r’ format bypasses any Python pretty-printer which might exist. '. |
abd4d9bdec0e
Portability: remove `GDBOutputFormats` pool
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
97
diff
changeset
|
108 |
|
abd4d9bdec0e
Portability: remove `GDBOutputFormats` pool
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
97
diff
changeset
|
109 |
"Modified: / 25-01-2018 / 09:29:51 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
abd4d9bdec0e
Portability: remove `GDBOutputFormats` pool
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
97
diff
changeset
|
110 |
! ! |
abd4d9bdec0e
Portability: remove `GDBOutputFormats` pool
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
97
diff
changeset
|
111 |
|
97 | 112 |
!GDBOutputFormat class methodsFor:'instance creation'! |
113 |
||
114 |
format:formatArg name:nameArg description:descriptionArg |
|
115 |
^ self new format:formatArg name:nameArg description:descriptionArg |
|
116 |
! ! |
|
117 |
||
154
abd4d9bdec0e
Portability: remove `GDBOutputFormats` pool
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
97
diff
changeset
|
118 |
!GDBOutputFormat class methodsFor:'accessing'! |
abd4d9bdec0e
Portability: remove `GDBOutputFormats` pool
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
97
diff
changeset
|
119 |
|
162
e56b2f6369af
Add methods for accessing individual output formats
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
154
diff
changeset
|
120 |
address |
e56b2f6369af
Add methods for accessing individual output formats
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
154
diff
changeset
|
121 |
^ FormatAddress |
e56b2f6369af
Add methods for accessing individual output formats
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
154
diff
changeset
|
122 |
|
e56b2f6369af
Add methods for accessing individual output formats
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
154
diff
changeset
|
123 |
"Created: / 28-11-2018 / 14:00:46 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
e56b2f6369af
Add methods for accessing individual output formats
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
154
diff
changeset
|
124 |
! |
e56b2f6369af
Add methods for accessing individual output formats
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
154
diff
changeset
|
125 |
|
154
abd4d9bdec0e
Portability: remove `GDBOutputFormats` pool
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
97
diff
changeset
|
126 |
all |
abd4d9bdec0e
Portability: remove `GDBOutputFormats` pool
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
97
diff
changeset
|
127 |
^ self classVariables collect:[:name | self classVarAt: name ] |
abd4d9bdec0e
Portability: remove `GDBOutputFormats` pool
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
97
diff
changeset
|
128 |
|
abd4d9bdec0e
Portability: remove `GDBOutputFormats` pool
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
97
diff
changeset
|
129 |
"Created: / 26-01-2018 / 00:45:14 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
162
e56b2f6369af
Add methods for accessing individual output formats
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
154
diff
changeset
|
130 |
! |
e56b2f6369af
Add methods for accessing individual output formats
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
154
diff
changeset
|
131 |
|
e56b2f6369af
Add methods for accessing individual output formats
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
154
diff
changeset
|
132 |
binary |
e56b2f6369af
Add methods for accessing individual output formats
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
154
diff
changeset
|
133 |
^ FormatBinary |
e56b2f6369af
Add methods for accessing individual output formats
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
154
diff
changeset
|
134 |
|
e56b2f6369af
Add methods for accessing individual output formats
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
154
diff
changeset
|
135 |
"Created: / 28-11-2018 / 14:00:58 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
e56b2f6369af
Add methods for accessing individual output formats
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
154
diff
changeset
|
136 |
! |
e56b2f6369af
Add methods for accessing individual output formats
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
154
diff
changeset
|
137 |
|
e56b2f6369af
Add methods for accessing individual output formats
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
154
diff
changeset
|
138 |
characterConstant |
e56b2f6369af
Add methods for accessing individual output formats
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
154
diff
changeset
|
139 |
^ FormatCharacterConstant |
e56b2f6369af
Add methods for accessing individual output formats
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
154
diff
changeset
|
140 |
|
e56b2f6369af
Add methods for accessing individual output formats
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
154
diff
changeset
|
141 |
"Created: / 28-11-2018 / 14:01:12 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
e56b2f6369af
Add methods for accessing individual output formats
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
154
diff
changeset
|
142 |
! |
e56b2f6369af
Add methods for accessing individual output formats
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
154
diff
changeset
|
143 |
|
e56b2f6369af
Add methods for accessing individual output formats
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
154
diff
changeset
|
144 |
floatingPoint |
e56b2f6369af
Add methods for accessing individual output formats
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
154
diff
changeset
|
145 |
^ FormatFloatingPoint |
e56b2f6369af
Add methods for accessing individual output formats
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
154
diff
changeset
|
146 |
|
e56b2f6369af
Add methods for accessing individual output formats
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
154
diff
changeset
|
147 |
"Created: / 28-11-2018 / 14:01:20 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
e56b2f6369af
Add methods for accessing individual output formats
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
154
diff
changeset
|
148 |
! |
e56b2f6369af
Add methods for accessing individual output formats
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
154
diff
changeset
|
149 |
|
e56b2f6369af
Add methods for accessing individual output formats
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
154
diff
changeset
|
150 |
hexadecimal |
e56b2f6369af
Add methods for accessing individual output formats
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
154
diff
changeset
|
151 |
^ FormatHexadecimal |
e56b2f6369af
Add methods for accessing individual output formats
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
154
diff
changeset
|
152 |
|
e56b2f6369af
Add methods for accessing individual output formats
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
154
diff
changeset
|
153 |
"Created: / 28-11-2018 / 14:01:35 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
e56b2f6369af
Add methods for accessing individual output formats
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
154
diff
changeset
|
154 |
! |
e56b2f6369af
Add methods for accessing individual output formats
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
154
diff
changeset
|
155 |
|
e56b2f6369af
Add methods for accessing individual output formats
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
154
diff
changeset
|
156 |
octal |
e56b2f6369af
Add methods for accessing individual output formats
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
154
diff
changeset
|
157 |
^ FormatOctal |
e56b2f6369af
Add methods for accessing individual output formats
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
154
diff
changeset
|
158 |
|
e56b2f6369af
Add methods for accessing individual output formats
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
154
diff
changeset
|
159 |
"Created: / 28-11-2018 / 14:01:47 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
e56b2f6369af
Add methods for accessing individual output formats
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
154
diff
changeset
|
160 |
! |
e56b2f6369af
Add methods for accessing individual output formats
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
154
diff
changeset
|
161 |
|
e56b2f6369af
Add methods for accessing individual output formats
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
154
diff
changeset
|
162 |
paddedHexadecimal |
e56b2f6369af
Add methods for accessing individual output formats
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
154
diff
changeset
|
163 |
^ FormatPaddedHexadecimal |
e56b2f6369af
Add methods for accessing individual output formats
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
154
diff
changeset
|
164 |
|
e56b2f6369af
Add methods for accessing individual output formats
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
154
diff
changeset
|
165 |
"Created: / 28-11-2018 / 13:07:31 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
e56b2f6369af
Add methods for accessing individual output formats
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
154
diff
changeset
|
166 |
! |
e56b2f6369af
Add methods for accessing individual output formats
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
154
diff
changeset
|
167 |
|
e56b2f6369af
Add methods for accessing individual output formats
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
154
diff
changeset
|
168 |
raw |
e56b2f6369af
Add methods for accessing individual output formats
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
154
diff
changeset
|
169 |
^ FormatRaw |
e56b2f6369af
Add methods for accessing individual output formats
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
154
diff
changeset
|
170 |
|
e56b2f6369af
Add methods for accessing individual output formats
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
154
diff
changeset
|
171 |
"Created: / 28-11-2018 / 14:01:58 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
e56b2f6369af
Add methods for accessing individual output formats
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
154
diff
changeset
|
172 |
! |
e56b2f6369af
Add methods for accessing individual output formats
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
154
diff
changeset
|
173 |
|
e56b2f6369af
Add methods for accessing individual output formats
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
154
diff
changeset
|
174 |
signedDecimal |
e56b2f6369af
Add methods for accessing individual output formats
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
154
diff
changeset
|
175 |
^ FormatSignedDecimal |
e56b2f6369af
Add methods for accessing individual output formats
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
154
diff
changeset
|
176 |
|
e56b2f6369af
Add methods for accessing individual output formats
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
154
diff
changeset
|
177 |
"Created: / 28-11-2018 / 14:02:10 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
e56b2f6369af
Add methods for accessing individual output formats
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
154
diff
changeset
|
178 |
! |
e56b2f6369af
Add methods for accessing individual output formats
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
154
diff
changeset
|
179 |
|
e56b2f6369af
Add methods for accessing individual output formats
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
154
diff
changeset
|
180 |
string |
e56b2f6369af
Add methods for accessing individual output formats
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
154
diff
changeset
|
181 |
^ FormatString |
e56b2f6369af
Add methods for accessing individual output formats
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
154
diff
changeset
|
182 |
|
e56b2f6369af
Add methods for accessing individual output formats
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
154
diff
changeset
|
183 |
"Created: / 28-11-2018 / 14:02:20 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
e56b2f6369af
Add methods for accessing individual output formats
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
154
diff
changeset
|
184 |
! |
e56b2f6369af
Add methods for accessing individual output formats
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
154
diff
changeset
|
185 |
|
e56b2f6369af
Add methods for accessing individual output formats
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
154
diff
changeset
|
186 |
unsignedDecimal |
e56b2f6369af
Add methods for accessing individual output formats
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
154
diff
changeset
|
187 |
^ FormatUnsignedDecimal |
e56b2f6369af
Add methods for accessing individual output formats
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
154
diff
changeset
|
188 |
|
e56b2f6369af
Add methods for accessing individual output formats
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
154
diff
changeset
|
189 |
"Created: / 28-11-2018 / 14:02:35 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
154
abd4d9bdec0e
Portability: remove `GDBOutputFormats` pool
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
97
diff
changeset
|
190 |
! ! |
abd4d9bdec0e
Portability: remove `GDBOutputFormats` pool
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
97
diff
changeset
|
191 |
|
97 | 192 |
!GDBOutputFormat methodsFor:'accessing'! |
193 |
||
194 |
description |
|
195 |
^ description |
|
196 |
! |
|
197 |
||
198 |
format |
|
199 |
^ format |
|
200 |
! |
|
201 |
||
202 |
name |
|
203 |
^ name |
|
204 |
! ! |
|
205 |
||
206 |
!GDBOutputFormat methodsFor:'displaying'! |
|
207 |
||
208 |
displayString |
|
209 |
^ name |
|
210 |
||
211 |
"Created: / 26-01-2018 / 00:46:10 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
|
212 |
! ! |
|
213 |
||
214 |
!GDBOutputFormat methodsFor:'initialization'! |
|
215 |
||
216 |
format:formatArg name:nameArg description:descriptionArg |
|
217 |
format := formatArg. |
|
218 |
name := nameArg. |
|
219 |
description := descriptionArg. |
|
220 |
! ! |
|
221 |
||
162
e56b2f6369af
Add methods for accessing individual output formats
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
154
diff
changeset
|
222 |
!GDBOutputFormat methodsFor:'printing & storing'! |
e56b2f6369af
Add methods for accessing individual output formats
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
154
diff
changeset
|
223 |
|
e56b2f6369af
Add methods for accessing individual output formats
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
154
diff
changeset
|
224 |
printOn:aStream |
e56b2f6369af
Add methods for accessing individual output formats
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
154
diff
changeset
|
225 |
"append a printed representation of the receiver to the argument, aStream" |
e56b2f6369af
Add methods for accessing individual output formats
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
154
diff
changeset
|
226 |
|
e56b2f6369af
Add methods for accessing individual output formats
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
154
diff
changeset
|
227 |
super printOn:aStream. |
e56b2f6369af
Add methods for accessing individual output formats
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
154
diff
changeset
|
228 |
aStream nextPutAll:'('. |
e56b2f6369af
Add methods for accessing individual output formats
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
154
diff
changeset
|
229 |
format printOn:aStream. |
e56b2f6369af
Add methods for accessing individual output formats
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
154
diff
changeset
|
230 |
aStream nextPutAll:')'. |
e56b2f6369af
Add methods for accessing individual output formats
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
154
diff
changeset
|
231 |
|
e56b2f6369af
Add methods for accessing individual output formats
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
154
diff
changeset
|
232 |
"Modified: / 28-11-2018 / 13:05:45 / Jan Vrany <jan.vrany@fit.cvut.cz>" |
e56b2f6369af
Add methods for accessing individual output formats
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
154
diff
changeset
|
233 |
! ! |
e56b2f6369af
Add methods for accessing individual output formats
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
154
diff
changeset
|
234 |
|
e56b2f6369af
Add methods for accessing individual output formats
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
154
diff
changeset
|
235 |
!GDBOutputFormat class methodsFor:'documentation'! |
e56b2f6369af
Add methods for accessing individual output formats
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
154
diff
changeset
|
236 |
|
e56b2f6369af
Add methods for accessing individual output formats
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
154
diff
changeset
|
237 |
version_HG |
e56b2f6369af
Add methods for accessing individual output formats
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
154
diff
changeset
|
238 |
|
e56b2f6369af
Add methods for accessing individual output formats
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
154
diff
changeset
|
239 |
^ '$Changeset: <not expanded> $' |
e56b2f6369af
Add methods for accessing individual output formats
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
154
diff
changeset
|
240 |
! ! |
e56b2f6369af
Add methods for accessing individual output formats
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
154
diff
changeset
|
241 |
|
154
abd4d9bdec0e
Portability: remove `GDBOutputFormats` pool
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
97
diff
changeset
|
242 |
|
abd4d9bdec0e
Portability: remove `GDBOutputFormats` pool
Jan Vrany <jan.vrany@fit.cvut.cz>
parents:
97
diff
changeset
|
243 |
GDBOutputFormat initialize! |