Core  3.2
PHP API documentation
 All Data Structures Namespaces Files Functions Variables Pages
ErrorCodeATTR.php
Go to the documentation of this file.
1 <?php
2 /*
3  * @author Anakeen
4  * @package FDL
5 */
6 /**
7  * Error codes used to checking family attribute structure
8  * @class ErrorCodeATTR
9  * @see ErrorCode
10  * @brief List all error code for document's attribute errors
11  * It is triggered by 'ATTR', 'PARAM', 'MODATTR' keywords
12  */
14 {
15  /**
16  * @errorCode Attribute identicator is limit to 63 alphanum characters
17  */
18  const ATTR0100 = 'syntax error for attribute "%s"';
19  /**
20  * @errorCode Attribute identifier cannot be equal to a reserved postgresql word
21  */
22  const ATTR0101 = 'attribute identifier "%s" use a reserved word';
23  /**
24  * @errorCode Attribute identifier is required
25  */
26  const ATTR0102 = 'attribute identifier is not set';
27  /**
28  * @errorCode Attribute identifier cannot be equal to a doc properties name
29  */
30  const ATTR0103 = 'attribute identifier "%s" use a property identificator';
31  /**
32  * @errorCode Attribute identicator is limit to 63 alphanum characters
33  */
34  const ATTR0200 = 'syntax error for structure "%s" attribute "%s"';
35  /**
36  * @errorCode Attribute structure identifier is required
37  */
38  const ATTR0201 = 'attribute structure is not set for attribute "%s"';
39  /**
40  * @errorCode Attribute structure must reference other attribute
41  */
42  const ATTR0202 = 'attribute structure is same as attribute "%s"';
43  /**
44  * @errorCode Attribute structure must reference an attribute
45  */
46  const ATTR0203 = 'attribute structure reference is not an attribute for "%s", family "%s"';
47  /**
48  * @errorCode Attribute structure must compatible with level hierarchy
49  * @note a tab has no parent,
50  * a frame must have only tab parent,
51  * another attribute must have only frame parent or array parent
52  */
53  const ATTR0204 = 'attribute structure "%s" is not possible for "%s"';
54  /**
55  * @errorCode Attribute structure must reference a frame or array attribute for normal attribute
56  */
57  const ATTR0205 = 'this attribute structure "%s" is not a allowed for normal attribute"%s"';
58  /**
59  * @errorCode Attribute structure must be empty for tab attribute
60  */
61  const ATTR0206 = 'attribute structure "%s" is forbidden for a tab attribute for "%s"';
62  /**
63  * @errorCode Attribute structure must reference a tab attribute or nothing
64  */
65  const ATTR0207 = 'this attribute structure "%s" is not a allowed for frame attribute "%s"';
66  /**
67  * @errorCode Parameter structure must reference a parameter
68  */
69  const ATTR0208 = 'param structure reference is not a parameter for "%s", family "%s"';
70  /**
71  * @errorCode Parameter structure must compatible with level hierarchy
72  * @note a tab has no parent,
73  * a frame must have only tab parent,
74  * another parameter must have only frame parent or array parent
75  */
76  const ATTR0209 = 'parameter structure "%s" is not possible for "%s"';
77  /**
78  * @errorCode Parameter structure must reference a frame or array parameter for parameter
79  */
80  const ATTR0210 = 'this parameter structure "%s" is not a allowed for parameter"%s"';
81  /**
82  * @errorCode
83  */
84  const ATTR0211 = 'parameter "%s" must not have a phpfunc with output variables';
85  /**
86  * @errorCode Attribute order must reference an attribute family
87  */
88  const ATTR0212 = 'the attribute "%s" has incorrect order : "%s" (must be numeric or reference an attribute)';
89  /**
90  * @errorCode Attribute order reference is not in the current frame
91  */
92  const ATTR0213 = 'the attribute "%s" has incorrect order : parent is "%s" must be "%s": out of field';
93 
94  /**
95  * @errorCode A parent id reference a child id
96  */
97  const ATTR0214 = 'the attribute "%s" has a loop reference for parent ';
98  /**
99  * @errorCode Attribute isTitle is Y or N
100  */
101  const ATTR0400 = 'invalid value "%s" for isTitle in attribute "%s"';
102  /**
103  * @errorCode Attribute isTitle must not be Y for structured attributes
104  */
105  const ATTR0401 = 'isTitle cannot be set for structured attribute "%s"';
106  /**
107  * @errorCode Attribute isAbstract is Y or N
108  */
109  const ATTR0500 = 'invalid value "%s" for isAbstract in attribute "%s"';
110  /**
111  * @errorCode Attribute isAbstract must not be Y for structured attributes
112  */
113  const ATTR0501 = 'isAbstract cannot be set for structured attribute "%s"';
114  /**
115  * @errorCode Attribute type is required
116  */
117  const ATTR0600 = 'type is not defined for attribute "%s"';
118  /**
119  * @errorCode Attribute type is not available
120  */
121  const ATTR0601 = 'unrecognized attribute type "%s" (attribute "%s"), type is one of %s';
122  /**
123  * @errorCode a type is can be only a alpha characters
124  * example text, double, money("%.02f $")
125  */
126  const ATTR0602 = 'syntax error for type "%s" in attribute "%s"';
127  /**
128  * @errorCode the format string must contains only one %s variable
129  */
130  const ATTR0603 = 'bad output format "%s" in attribute "%s" ';
131  /**
132  * @errorCode the basic type set in a MODATTR cannot be changed
133  */
134  const ATTR0604 = 'incompatible redefinition of type for "%s" attribute (family "%s"). New type "%s" is not compatible with origin "%s"';
135  /**
136  * @errorCode a MODATTR attribute is not defined in its ancestor
137  * Cannot modify an attribute which has not defined before
138  */
139  const ATTR0605 = 'attribute modification for "%s" attribute (family "%s") is not found in ancestor';
140  /**
141  * @errorCode a enum MODATTR attribute cannot redefine its items
142  * If need redefine, a ATTR must be used (not a MODATTR) to redefine the attribut and cut inheritance
143  */
144  const ATTR0606 = 'enum attribute modification for "%s" attribute (family "%s"): the enum items cannot be redefined';
145  /**
146  * @errorCode The attribute's order must be a number or an attribute id reference
147  */
148  const ATTR0700 = 'the order "%s" must be a number or an attribute reference in attribute "%s"';
149  /**
150  * @errorCode The attribute's order is required when attribute is not a frame or a tab
151  */
152  const ATTR0702 = 'the order is required in attribute "%s"';
153  /**
154  * @errorCode The attribute's visibility must be defined
155  */
156  const ATTR0800 = 'the visibility is required in attribute "%s"';
157  /**
158  * @errorCode The attribute's visibility is limited to defined visibilities (H,R,...)
159  */
160  const ATTR0801 = 'the visibility "%s" in attribute "%s" must be one of %s';
161  /**
162  * @errorCode The U visibility can be applied only on array attribute
163  */
164  const ATTR0802 = 'the U visibility is reserved to array, in attribute "%s"';
165  /**
166  * @errorCode property isNeeded is Y or N
167  */
168  const ATTR0900 = 'invalid value "%s" for isNeeded in attribute "%s"';
169  /**
170  * @errorCode property isNeeded must not be Y for structured attributes
171  */
172  const ATTR0901 = 'isNeeded cannot be set for structured attribute "%s"';
173  /**
174  * @errorCode property isNeeded cannot be used when attribute is included in an array
175  */
176  const ATTR0902 = 'isNeeded cannot be set for attribute included in array "%s"';
177  /**
178  * @errorCode property isNeeded cannot be used when parameter is included in an array
179  */
180  const ATTR0903 = 'isNeeded cannot be set for parameter included in array "%s"';
181  /**
182  * @errorCode syntaxt error in method describe in link
183  */
184  const ATTR1000 = 'method syntax error in link "%s" for attribute "%s":%s';
185  /**
186  * @errorCode call method in link property must be defined in file method or in another class if precised
187  * @see ATTR1260
188  * @see ATTR1261
189  * @see ATTR1262
190  * @see ATTR1263
191  */
192  const ATTR1001 = 'link method error in "%s" family : %s';
193  /**
194  * @errorCode Method use in link must have @apiExpose tag comment in their description
195  */
196  const ATTR1002 = 'method "%s" in attribute link "%s" is not an exposable method';
197  /**
198  * @errorCode The input help file must exists before declared it
199  */
200  const ATTR1100 = 'the input help file "%s" not exists, in attribute "%s"';
201  /**
202  * @errorCode The input help file must be a correct PHP file
203  */
204  const ATTR1101 = 'the input help file "%s" is not parsable, in attribute "%s" : %s';
205  /**
206  * @errorCode The option name are composed only of alpha characters
207  */
208  const ATTR1500 = 'the option name "%s" is not valid in attribute "%s"';
209  /**
210  * @errorCode The syntax option is : optname=optvalue
211  * @note example : elabel=enter a value
212  */
213  const ATTR1501 = 'the option "%s" must have = sign, in attribute "%s"';
214  /**
215  * @errorCode the phpfunc must be a call to a valid function or method
216  */
217  const ATTR1200 = 'syntax error in phpfunc attribute "%s" : %s';
218  /**
219  * @errorCode function must have 2 parenthesis one open and one close
220  */
221  const ATTR1201 = 'error parenthesis in method/file definition : "%s"';
222  /**
223  * @errorCode function name must be a valid PHP name
224  */
225  const ATTR1202 = 'syntax error in function name : "%s"';
226  /**
227  * @errorCode function name must exists
228  */
229  const ATTR1203 = 'function "%s" not exists';
230  /**
231  * @errorCode double quote error in function call
232  */
233  const ATTR1204 = 'double quote syntax error (character %d) in function "%s"';
234  /**
235  * @errorCode simple quote error in function call
236  */
237  const ATTR1205 = 'simple quote syntax error (character %d) in function "%s"';
238  /**
239  * @errorCode output attributes must be declared after semicolumn characters
240  * @note
241  * example : test():MY_TEST1, MY_TEST2
242  */
243  const ATTR1206 = 'no output attribute, missing ":" character in function "%s"';
244  /**
245  * @errorCode output attributes must represent attribute name with a comma separator
246  * @note
247  * example :test():MY_TEST1, MY_TEST2
248  * test(My_TEST2):MY_TEST1
249  */
250  const ATTR1207 = 'outputs in function "%s" can be only alphanum characters ';
251  /**
252  * @errorCode appname must be only alphanum characters
253  * @note when use special help as help input
254  */
255  const ATTR1208 = 'appname in special help can be only alphanum characters';
256  /**
257  * @errorCode input help can use only user function
258  */
259  const ATTR1209 = 'function "%s" is an internal php function';
260  /**
261  * @errorCode input help must be defined in declared file
262  */
263  const ATTR1210 = 'function "%s" is not defined in "%s" file';
264  /**
265  * @errorCode the called function need more arguments
266  */
267  const ATTR1211 = 'not enough argument call to use function "%s" (need %d arguments)';
268  /**
269  * @errorCode the method use for computed must declarer an existed attribute
270  * @note triggered in Doc::specRefreshGen()
271  */
272  const ATTR1212 = 'unknow output attribut for method "%s" in family "%s"';
273  /**
274  * @errorCode declaration of call method is not correct
275  * @note example : ::test() or myClass::test()
276  */
277  const ATTR1250 = 'syntax error in method call (phpfunc) for attribute "%s" : %s';
278  /**
279  * @errorCode call of a method mudt contains '::' characters
280  * @note example : ::test() or myClass::test()
281  */
282  const ATTR1251 = 'no "::" delimiter in method call "%s"';
283  /**
284  * @errorCode method name must be a valid PHP name
285  */
286  const ATTR1252 = 'syntax error in method name : "%s"';
287  /**
288  * @errorCode method name must be a valid PHP class name
289  */
290  const ATTR1253 = 'syntax error in class name in method call: "%s"';
291  /**
292  * @errorCode call method can be return only one value
293  * @note example : ::test():MY_RET
294  */
295  const ATTR1254 = 'only one output is possible in method "%s"';
296  /**
297  * @errorCode generally when it is in constraint attribute
298  */
299  const ATTR1255 = 'no output is possible in method "%s"';
300  /**
301  * @errorCode call method in phpfunc property must be defined in file method or in another class if precised
302  */
303  const ATTR1260 = 'method "%s" (context : "%s") is not found for "%s" attribute';
304  /**
305  * @errorCode call method require more arguments
306  */
307  const ATTR1261 = 'not enough argument call to use method "%s" (context "%s", need %d arguments) for "%s" attribute';
308  /**
309  * @errorCode the phpfunc is not correct generally detected on inherited attributes
310  */
311  const ATTR1262 = 'syntax error in method "%s" phpfunc for "%s" attribute : %s';
312  /**
313  * @errorCode the phpfunc method must be static if a classname is set
314  * @note example : myClass::myStaticMethod()
315  */
316  const ATTR1263 = 'method "%s" (context : "%s") is not static phpfunc for "%s" attribute';
317  /**
318  * @errorCode call method in phpfunc property must be defined in file method or in another class if precised
319  * @see ATTR1260
320  * @see ATTR1261
321  * @see ATTR1262
322  * @see ATTR1263
323  */
324  const ATTR1265 = 'phpfunc method error in "%s" family : %s';
325  /**
326  * @errorCode call method in phpfunc property must be defined in file method or in another class if precised
327  */
328  const ATTR1266 = 'method "%s" (context "%s" defined in parent family "%s") is not found for "%s" attribute';
329  /**
330  * @errorCode enum declaration must be a set of key value
331  * @note example : yellow|Yellow color,red|Red color
332  */
333  const ATTR1270 = 'syntax error in enum declaration near "%s" for "%s" attribute';
334  /**
335  * @errorCode the enum key must be a simple word without accent
336  * @note example : yellow|Yellow color,red|Red color
337  */
338  const ATTR1271 = 'key must not have accent characters in enum declaration "%s" for "%s" attribute';
339  /**
340  * @errorCode the enum key is required
341  * @note example : yellow|Yellow color,red|Red color
342  */
343  const ATTR1272 = 'key must not be empty in enum declaration "%s" for "%s" attribute';
344  /**
345  * @errorCode declaration of call constraint is not correct
346  * @note example : ::isInteger(MY_ATTR) or myClass::isSpecial(MY_ATTR)
347  */
348  const ATTR1400 = 'syntax error in constraint call for attribute "%s" : %s';
349  /**
350  * @errorCode call method in constraint require more arguments
351  */
352  const ATTR1401 = 'not enough argument call to use constraint "%s" (need %d arguments, given %d) for "%s" attribute';
353  /**
354  * @errorCode call constraint method must be defined in file method or in another class if precised
355  */
356  const ATTR1402 = 'constraint method "%s" is not found for "%s" attribute';
357  /**
358  * @errorCode the phpfunc method must be static if a classname is set
359  * @note example : myClass::myStaticMethod()
360  */
361  const ATTR1403 = 'method "%s" is not static phpfunc for "%s" attribute';
362  /**
363  * @errorCode the constraint is not correct generally detected on inherited attributes
364  */
365  const ATTR1404 = 'syntax error in constraint "%s" for "%s" attribute : %s';
366  /**
367  * @errorCode database type are incompatible with attribute type declaration
368  */
369  const ATTR1700 = 'database document column are erronous : %s';
370  /**
371  * @errorCode due to postgresql limit, sql column number is limited
372  * @note declaration for an attribute can create more than one sql column
373  */
374  const ATTR1701 = 'too many attributes : %d (maximum sql column is %d)';
375  /**
376  * @errorCode The value of the attribute will not be computed because the visibility is 'I'
377  */
378  const ATTR1800 = "value of attribute \"%s\" with phpfunc \"%s\" will not be computed because visibility is \"I\".";
379 }
List all error code for document's attribute errors It is triggered by 'ATTR', 'PARAM', 'MODATTR' keywords.
← centre documentaire © anakeen