1 | <?php |
||
4 | trait queryProcessor |
||
5 | { |
||
6 | /** |
||
7 | * Message to show error when query prcocessor found |
||
8 | * invalid value for $format option. |
||
9 | * |
||
10 | * @return string The message |
||
11 | */ |
||
12 | public static function queryProcessorInvalidValueForFormat() |
||
16 | |||
17 | /** |
||
18 | * Message to show error when query processor found odata query option |
||
19 | * in the request uri which is not applicable for the |
||
20 | * resource targeted by the resource path. |
||
21 | * |
||
22 | * @return string The message |
||
23 | */ |
||
24 | public static function queryProcessorNoQueryOptionsApplicable() |
||
28 | |||
29 | /** |
||
30 | * Message to show error when query processor found $filter option in the |
||
31 | * request uri but is not applicable for the resource targeted by the |
||
32 | * resource path. |
||
33 | * |
||
34 | * @return string The message |
||
35 | */ |
||
36 | public static function queryProcessorQueryFilterOptionNotApplicable() |
||
40 | |||
41 | /** |
||
42 | * Message to show error when query processor found any $orderby, |
||
43 | * $inlinecount, $skip or $top options in the request uri but is not |
||
44 | * applicable for the resource targeted by the resource path. |
||
45 | * |
||
46 | * @return string The message |
||
47 | */ |
||
48 | public static function queryProcessorQuerySetOptionsNotApplicable() |
||
52 | |||
53 | /** |
||
54 | * Message to show error when query processor found skiptoken option in the |
||
55 | * request uri but is not applicable for the resource targeted by the |
||
56 | * resource path. |
||
57 | * |
||
58 | * @return string The message |
||
59 | */ |
||
60 | public static function queryProcessorSkipTokenNotAllowed() |
||
64 | |||
65 | /** |
||
66 | * Message to show error when query processor found $expand option in the |
||
67 | * request uri but is not applicable for the resource targeted by the |
||
68 | * resource path. |
||
69 | * |
||
70 | * @return string The message |
||
71 | */ |
||
72 | public static function queryProcessorQueryExpandOptionNotApplicable() |
||
76 | |||
77 | /** |
||
78 | * Message to show error when query processor found usage of $inline count |
||
79 | * option for a resource path ending with $count. |
||
80 | * |
||
81 | * @return string The message |
||
82 | */ |
||
83 | public static function queryProcessorInlineCountWithValueCount() |
||
87 | |||
88 | /** |
||
89 | * Message to show error when value of $inlinecount option found invalid. |
||
90 | * |
||
91 | * @return string The message |
||
92 | */ |
||
93 | public static function queryProcessorInvalidInlineCountOptionError() |
||
97 | |||
98 | /** |
||
99 | * Format a message to show error when query processor found invalid |
||
100 | * value for a query option. |
||
101 | * |
||
102 | * @param string $argName The name of the argument |
||
103 | * @param string $argValue The value of the argument |
||
104 | * |
||
105 | * @return string The formatted message |
||
106 | */ |
||
107 | public static function queryProcessorIncorrectArgumentFormat($argName, $argValue) |
||
111 | |||
112 | /** |
||
113 | * Format a message to show error when query processor found $skiptoken |
||
114 | * in the request uri targetting to a resource for which paging is not |
||
115 | * enabled. |
||
116 | * |
||
117 | * @param string $resourceSetName The name of the resource set |
||
118 | * |
||
119 | * @return string The formatted message |
||
120 | */ |
||
121 | public static function queryProcessorSkipTokenCannotBeAppliedForNonPagedResourceSet($resourceSetName) |
||
125 | |||
126 | /** |
||
127 | * Format a message to show error when query processor found $select |
||
128 | * or $expand which cannot be applied to resource targeted by the |
||
129 | * request uri. |
||
130 | * |
||
131 | * @param string $queryItem Query item |
||
132 | * |
||
133 | * @return string The formatted message |
||
134 | */ |
||
135 | public static function queryProcessorSelectOrExpandOptionNotApplicable($queryItem) |
||
139 | } |
||
140 |