| 1 |
(* Library module defined by the International Standard |
| 2 |
Information technology - programming languages |
| 3 |
BS ISO/IEC 10514-1:1996E Part 1: Modula-2, Base Language. |
| 4 |
|
| 5 |
Copyright ISO/IEC (International Organization for Standardization |
| 6 |
and International Electrotechnical Commission) 1996-2021. |
| 7 |
|
| 8 |
It may be freely copied for the purpose of implementation (see page |
| 9 |
707 of the Information technology - Programming languages Part 1: |
| 10 |
Modula-2, Base Language. BS ISO/IEC 10514-1:1996). *) |
| 11 |
|
| 12 |
DEFINITION MODULE SIOResult; |
| 13 |
|
| 14 |
(* Read results for the default input channel *) |
| 15 |
|
| 16 |
IMPORT IOConsts; |
| 17 |
|
| 18 |
TYPE |
| 19 |
ReadResults = IOConsts.ReadResults; |
| 20 |
|
| 21 |
(* |
| 22 |
ReadResults = (* This type is used to classify the result of an input operation *) |
| 23 |
( |
| 24 |
notKnown, (* no read result is set *) |
| 25 |
allRight, (* data is as expected or as required *) |
| 26 |
outOfRange, (* data cannot be represented *) |
| 27 |
wrongFormat, (* data not in expected format *) |
| 28 |
endOfLine, (* end of line seen before expected data *) |
| 29 |
endOfInput (* end of input seen before expected data *) |
| 30 |
); |
| 31 |
*) |
| 32 |
|
| 33 |
PROCEDURE ReadResult (): ReadResults; |
| 34 |
(* Returns the result for the last read operation on the default input channel. *) |
| 35 |
|
| 36 |
END SIOResult. |
| 37 |
|