Debian Codegraph @

terps/alan3/ParameterPosition.h

raw symbols SCIP
1 #ifndef PARAMETERPOSITION_H_
2 #define PARAMETERPOSITION_H_
3 /*----------------------------------------------------------------------*\
4
5 ParameterPosition
6
7 Represents on position in the player input holding a parameter. That
8 position is filled with some words from the player, those words must
9 be disambiguated to one or more instances. There are three cases:
10
11 1) words presuming it would be a single instance (it
12 might actually not be) "the chair"
13
14 2) words indicating explicit mentioning of multiple instances, "the
15 book and the chair"
16
17 3) implicit multiple using "all" or "everything except the blue
18 ball"
19
20 For all those cases the position must be able to deliver the words,
21 possible explicit or implicit multiple, and the resulting set of
22 instances.
23
24 \*----------------------------------------------------------------------*/
25
26 /* Imports: */
27 #include "acode.h"
28 #include "types.h"
29 #include "params.h"
30
31
32 /* Constants: */
33
34
35 /* Types: */
36 typedef struct ParameterPosition {
37 bool endOfList;
38 bool explicitMultiple;
39 bool all;
40 bool them;
41 bool checked;
42 Aword flags;
43 Parameter *parameters;
44 Parameter *exceptions;
45 } ParameterPosition;
46
47
48 /* Data: */
49
50
51 /* Functions: */
52 extern void deallocateParameterPositions(ParameterPosition *parameterPositions);
53 extern void uncheckAllParameterPositions(ParameterPosition parameterPositions[]);
54 extern void copyParameterPositions(ParameterPosition originalParameterPositions[], ParameterPosition parameterPositions[]);
55 extern bool equalParameterPositions(ParameterPosition parameterPositions1[], ParameterPosition parameterPositions2[]);
56 extern int findMultipleParameterPosition(ParameterPosition parameterPositions[]);
57 extern void markExplicitMultiple(ParameterPosition parameterPositions[], Parameter parameters[]);
58 extern void convertPositionsToParameters(ParameterPosition parameterPositions[], Parameter parameters[]);
59
60 #endif /* PARAMETERPOSITION_H_ */