blob: 2dca607b58ba8946bc3b4af35c2201e245057e05 [file] [log] [blame]
Bharat saraswaldedf9f82016-02-12 20:48:30 +05301/*
Brian O'Connor0f7908b2016-04-09 01:19:45 -07002 * Copyright 2016-present Open Networking Laboratory
Bharat saraswaldedf9f82016-02-12 20:48:30 +05303 *
4 * Licensed under the Apache License, Version 2.0 (the "License");
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
7 *
8 * http://www.apache.org/licenses/LICENSE-2.0
9 *
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an "AS IS" BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
15 */
16
17package org.onosproject.yangutils.utils;
18
Vinod Kumar S9f26ae52016-03-23 15:30:27 +053019import java.io.File;
b.jananie6d43af2016-03-04 12:29:05 +053020import java.util.Arrays;
21import java.util.List;
22
Bharat saraswaldedf9f82016-02-12 20:48:30 +053023/**
Bharat saraswal63f26fb2016-04-05 15:13:44 +053024 * Represents utilities constants which are used while generating java files.
Bharat saraswaldedf9f82016-02-12 20:48:30 +053025 */
26public final class UtilConstants {
27
28 /**
Bharat saraswald532a4c2016-03-25 18:19:46 +053029 * JavaDocs for impl class.
Bharat saraswaldedf9f82016-02-12 20:48:30 +053030 */
Gaurav Agrawal3b57f362016-09-07 13:16:35 +053031 public static final String IMPL_CLASS_JAVA_DOC =
32 " * Represents the implementation of ";
Bharat saraswald532a4c2016-03-25 18:19:46 +053033
34 /**
35 * JavaDocs for builder class.
36 */
Gaurav Agrawal3b57f362016-09-07 13:16:35 +053037 public static final String BUILDER_CLASS_JAVA_DOC =
38 " * Represents the builder implementation of ";
Bharat saraswald532a4c2016-03-25 18:19:46 +053039
40 /**
41 * JavaDocs for interface class.
42 */
Gaurav Agrawal3b57f362016-09-07 13:16:35 +053043 public static final String INTERFACE_JAVA_DOC =
44 " * Abstraction of an entity which represents the functionality " +
45 "of ";
Bharat saraswald532a4c2016-03-25 18:19:46 +053046
VinodKumarS-Huawei6266db32016-05-10 17:58:57 +053047 /**
48 * JavaDocs for event.
49 */
Gaurav Agrawal3b57f362016-09-07 13:16:35 +053050 public static final String EVENT_JAVA_DOC =
51 " * Represents event implementation of ";
VinodKumarS-Huawei6266db32016-05-10 17:58:57 +053052
53 /**
Shankara-Huaweia1039e52016-07-14 16:53:09 +053054 * JavaDocs for op param class.
55 */
Gaurav Agrawal3b57f362016-09-07 13:16:35 +053056 public static final String OP_PARAM_JAVA_DOC =
57 " * Represents operation parameter implementation of ";
Shankara-Huaweia1039e52016-07-14 16:53:09 +053058
59 /**
VinodKumarS-Huawei6266db32016-05-10 17:58:57 +053060 * JavaDocs for event listener.
61 */
Gaurav Agrawal3b57f362016-09-07 13:16:35 +053062 public static final String EVENT_LISTENER_JAVA_DOC =
63 " * Abstraction for event listener of ";
VinodKumarS-Huawei6266db32016-05-10 17:58:57 +053064
Bharat saraswald532a4c2016-03-25 18:19:46 +053065 /**
66 * JavaDocs for builder interface class.
67 */
Bharat saraswaldedf9f82016-02-12 20:48:30 +053068 public static final String BUILDER_INTERFACE_JAVA_DOC = " * Builder for ";
Bharat saraswald532a4c2016-03-25 18:19:46 +053069
70 /**
Bharat saraswal68fa0d12016-04-19 01:00:16 +053071 * JavaDocs for enum class.
72 */
Gaurav Agrawal3b57f362016-09-07 13:16:35 +053073 public static final String ENUM_CLASS_JAVADOC =
74 " * Represents ENUM data of ";
Bharat saraswal68fa0d12016-04-19 01:00:16 +053075
76 /**
77 * JavaDocs for enum attribute.
78 */
79 public static final String ENUM_ATTRIBUTE_JAVADOC = " * Represents ";
80
81 /**
Bharat saraswald532a4c2016-03-25 18:19:46 +053082 * JavaDocs for package info class.
83 */
Gaurav Agrawal3b57f362016-09-07 13:16:35 +053084 public static final String PACKAGE_INFO_JAVADOC =
85 " * Implementation of YANG node ";
Bharat saraswal68fa0d12016-04-19 01:00:16 +053086
87 /**
88 * JavaDocs for package info class.
89 */
Gaurav Agrawal3b57f362016-09-07 13:16:35 +053090 public static final String PACKAGE_INFO_JAVADOC_OF_CHILD =
91 "'s children nodes";
Bharat saraswald532a4c2016-03-25 18:19:46 +053092
93 /**
94 * JavaDocs's first line.
95 */
Bharat saraswaldedf9f82016-02-12 20:48:30 +053096 public static final String JAVA_DOC_FIRST_LINE = "/**\n";
Bharat saraswald532a4c2016-03-25 18:19:46 +053097
98 /**
99 * JavaDocs's last line.
100 */
Bharat saraswaldedf9f82016-02-12 20:48:30 +0530101 public static final String JAVA_DOC_END_LINE = " */\n";
Bharat saraswald532a4c2016-03-25 18:19:46 +0530102
103 /**
104 * JavaDocs's param annotation.
105 */
Bharat saraswaldedf9f82016-02-12 20:48:30 +0530106 public static final String JAVA_DOC_PARAM = " * @param ";
Bharat saraswald532a4c2016-03-25 18:19:46 +0530107
108 /**
109 * JavaDocs's return annotation.
110 */
Bharat saraswaldedf9f82016-02-12 20:48:30 +0530111 public static final String JAVA_DOC_RETURN = " * @return ";
Bharat saraswald532a4c2016-03-25 18:19:46 +0530112
113 /**
Bharat saraswald532a4c2016-03-25 18:19:46 +0530114 * JavaDocs's description for setter method.
115 */
Gaurav Agrawal3b57f362016-09-07 13:16:35 +0530116 public static final String JAVA_DOC_SETTERS =
117 " * Returns the builder object of ";
Bharat saraswald532a4c2016-03-25 18:19:46 +0530118
119 /**
Bharat saraswal8beac342016-08-04 02:00:03 +0530120 * JavaDocs's description for add to list method.
121 */
122 public static final String JAVA_DOC_ADD_TO_LIST = " * Adds to the list of ";
123
124 /**
VinodKumarS-Huawei6266db32016-05-10 17:58:57 +0530125 * JavaDocs's description for setter method.
126 */
Gaurav Agrawal3b57f362016-09-07 13:16:35 +0530127 public static final String JAVA_DOC_MANAGER_SETTERS =
128 " * Sets the value to attribute ";
VinodKumarS-Huawei6266db32016-05-10 17:58:57 +0530129
130 /**
Bharat saraswald532a4c2016-03-25 18:19:46 +0530131 * JavaDocs's description for OF method.
132 */
b.jananie6d43af2016-03-04 12:29:05 +0530133 public static final String JAVA_DOC_OF = " * Returns the object of ";
Bharat saraswald532a4c2016-03-25 18:19:46 +0530134
135 /**
136 * JavaDocs's description for typedef' setter method.
137 */
Gaurav Agrawal3b57f362016-09-07 13:16:35 +0530138 public static final String JAVA_DOC_SETTERS_COMMON =
139 " * Sets the value of ";
Bharat saraswald532a4c2016-03-25 18:19:46 +0530140
141 /**
142 * JavaDocs's description for getter method.
143 */
Bharat saraswaldedf9f82016-02-12 20:48:30 +0530144 public static final String JAVA_DOC_GETTERS = " * Returns the attribute ";
Bharat saraswald532a4c2016-03-25 18:19:46 +0530145
146 /**
Bharat saraswal64e7e232016-07-14 23:33:55 +0530147 * JavaDocs's description for getter method.
148 */
Gaurav Agrawal3b57f362016-09-07 13:16:35 +0530149 public static final String JAVA_DOC_FOR_VALIDATOR =
150 " * Validates if value is in given range.";
Bharat saraswal64e7e232016-07-14 23:33:55 +0530151
152 /**
153 * JavaDocs's description for getter method.
154 */
Gaurav Agrawal3b57f362016-09-07 13:16:35 +0530155 public static final String JAVA_DOC_FOR_VALIDATOR_RETURN =
Bharat saraswal9fab16b2016-09-23 23:27:24 +0530156 " true if value is in range";
Bharat saraswal64e7e232016-07-14 23:33:55 +0530157
158 /**
Bharat saraswald532a4c2016-03-25 18:19:46 +0530159 * JavaDocs's description for constructor.
160 */
Gaurav Agrawal3b57f362016-09-07 13:16:35 +0530161 public static final String JAVA_DOC_CONSTRUCTOR =
162 " * Creates an instance of ";
Bharat saraswald532a4c2016-03-25 18:19:46 +0530163
164 /**
165 * JavaDocs's description for build method.
166 */
Bharat saraswaldedf9f82016-02-12 20:48:30 +0530167 public static final String JAVA_DOC_BUILD = " * Builds object of ";
Bharat saraswald532a4c2016-03-25 18:19:46 +0530168
169 /**
Bharat saraswald532a4c2016-03-25 18:19:46 +0530170 * JavaDocs's statement for builder object.
171 */
172 public static final String BUILDER_OBJECT = "builder object of ";
173
174 /**
Gaurav Agrawal02a60de2016-04-20 15:49:17 +0530175 * JavaDocs's statement for rpc method.
176 */
177 public static final String JAVA_DOC_RPC = " * Service interface of ";
178
179 /**
180 * JavaDocs's statement for rpc's input string.
181 */
182 public static final String RPC_INPUT_STRING = "input of service interface ";
183
184 /**
185 * JavaDocs's statement for rpc's output string.
186 */
Gaurav Agrawal3b57f362016-09-07 13:16:35 +0530187 public static final String RPC_OUTPUT_STRING =
188 "output of service interface ";
Gaurav Agrawal02a60de2016-04-20 15:49:17 +0530189
190 /**
Bharat saraswald532a4c2016-03-25 18:19:46 +0530191 * Static attribute for new line.
Bharat saraswaldedf9f82016-02-12 20:48:30 +0530192 */
193 public static final String NEW_LINE = "\n";
Bharat saraswald532a4c2016-03-25 18:19:46 +0530194
195 /**
Bharat saraswal250a7472016-05-12 13:16:57 +0530196 * Static attribute for default.
197 */
198 public static final String DEFAULT = "default";
199
200 /**
Bharat saraswal9fab16b2016-09-23 23:27:24 +0530201 * Static attribute for default.
202 */
203 public static final String DEFAULT_CAPS = "Default";
204
205 /**
Shankara-Huaweia1039e52016-07-14 16:53:09 +0530206 * Static attribute for java code generation for sbi.
207 */
208 public static final String SBI = "sbi";
209
210 /**
Bharat saraswald532a4c2016-03-25 18:19:46 +0530211 * Static attribute for multiple new line.
212 */
Vinod Kumar S9f26ae52016-03-23 15:30:27 +0530213 public static final String MULTIPLE_NEW_LINE = "\n\n";
Bharat saraswald532a4c2016-03-25 18:19:46 +0530214
215 /**
216 * Static attribute for empty line.
217 */
b.jananie6d43af2016-03-04 12:29:05 +0530218 public static final String EMPTY_STRING = "";
Bharat saraswald532a4c2016-03-25 18:19:46 +0530219
220 /**
221 * Static attribute for new line with asterisk.
222 */
223 public static final String NEW_LINE_ASTERISK = " *\n";
224
225 /**
226 * Static attribute for period.
227 */
Bharat saraswaldedf9f82016-02-12 20:48:30 +0530228 public static final String PERIOD = ".";
Bharat saraswald532a4c2016-03-25 18:19:46 +0530229
230 /**
Bharat saraswal9fab16b2016-09-23 23:27:24 +0530231 * Static attribute for compare to.
232 */
233 public static final String COMPARE_TO = "compareTo";
234
235 /**
Bharat saraswal8beac342016-08-04 02:00:03 +0530236 * Static attribute for period.
237 */
238 public static final String INVOKE = "invoke";
239
240 /**
Gaurav Agrawal97a5e1c2016-04-18 18:53:11 +0530241 * Static attribute for parse byte.
242 */
243 public static final String PARSE_BYTE = "parseByte";
244
245 /**
Bharat saraswal715d3fc2016-05-17 19:59:16 +0530246 * Static attribute for parse boolean.
247 */
248 public static final String PARSE_BOOLEAN = "parseBoolean";
249
250 /**
Gaurav Agrawal97a5e1c2016-04-18 18:53:11 +0530251 * Static attribute for parse short.
252 */
253 public static final String PARSE_SHORT = "parseShort";
254
255 /**
256 * Static attribute for parse int.
257 */
258 public static final String PARSE_INT = "parseInt";
259
260 /**
261 * Static attribute for parse long.
262 */
263 public static final String PARSE_LONG = "parseLong";
264
265 /**
Mahesh Poojary Huawei41547ad2016-07-14 17:49:50 +0530266 * Static attribute for base64.
267 */
268 public static final String BASE64 = "Base64";
269
270 /**
271 * Static attribute for getEncoder.
272 */
273 public static final String GET_ENCODER = "getEncoder";
274
275 /**
276 * Static attribute for encodeToString.
277 */
278 public static final String ENCODE_TO_STRING = "encodeToString";
279
280 /**
281 * Static attribute for getDecoder.
282 */
283 public static final String GET_DECODER = "getDecoder";
284
285 /**
286 * Static attribute for decode.
287 */
288 public static final String DECODE = "decode";
289
290 /**
Gaurav Agrawal97a5e1c2016-04-18 18:53:11 +0530291 * Static attribute for omit null value.
292 */
293 public static final String OMIT_NULL_VALUE_STRING = "omitNullValues()";
294
295 /**
Bharat saraswald532a4c2016-03-25 18:19:46 +0530296 * Static attribute for underscore.
297 */
b.jananie6d43af2016-03-04 12:29:05 +0530298 public static final String UNDER_SCORE = "_";
Bharat saraswald532a4c2016-03-25 18:19:46 +0530299
300 /**
301 * Static attribute for semi-colan.
302 */
Bharat saraswal9fab16b2016-09-23 23:27:24 +0530303 public static final String SEMI_COLON = ";";
Bharat saraswald532a4c2016-03-25 18:19:46 +0530304
305 /**
306 * Static attribute for hyphen.
307 */
Bharat saraswaldedf9f82016-02-12 20:48:30 +0530308 public static final String HYPHEN = "-";
Bharat saraswald532a4c2016-03-25 18:19:46 +0530309
310 /**
311 * Static attribute for space.
312 */
Bharat saraswaldedf9f82016-02-12 20:48:30 +0530313 public static final String SPACE = " ";
Bharat saraswald532a4c2016-03-25 18:19:46 +0530314
315 /**
Bharat saraswal9fab16b2016-09-23 23:27:24 +0530316 * Static attribute for isSelectAllSchemaChild.
317 */
318 public static final String SELECT_ALL_CHILD = "isSelectAllSchemaChild";
319
320 /**
Bharat saraswal748fc3c2016-09-06 16:38:20 +0530321 * Static attribute for schema name.
322 */
323 public static final String SCHEMA_NAME = "schemaName";
324
325 /**
Bharat saraswal64e7e232016-07-14 23:33:55 +0530326 * Static attribute for validateRange.
327 */
328 public static final String VALIDATE_RANGE = "validateRange";
329
330 /**
331 * Static attribute for minRange.
332 */
333 public static final String MIN_RANGE = "minRange";
334
335 /**
336 * Static attribute for maxRange.
337 */
338 public static final String MAX_RANGE = "maxRange";
339
340 /**
341 * Static attribute for minRange.
342 */
Gaurav Agrawal3b57f362016-09-07 13:16:35 +0530343 public static final String SHORT_MIN_RANGE_ATTR =
344 "static final int INT16_MIN_RANGE = -32768;\n";
Bharat saraswal2da23bf2016-08-25 15:28:39 +0530345
346 /**
347 * Static attribute for minRange.
348 */
349 public static final String SHORT_MIN_RANGE = "INT16_MIN_RANGE";
350
351 /**
352 * Static attribute for minRange.
353 */
354 public static final String SHORT_MAX_RANGE = "INT16_MAX_RANGE";
355
356 /**
357 * Static attribute for maxRange.
358 */
Gaurav Agrawal3b57f362016-09-07 13:16:35 +0530359 public static final String SHORT_MAX_RANGE_ATTR =
360 "static final int INT16_MAX_RANGE = 32767;";
Bharat saraswal2da23bf2016-08-25 15:28:39 +0530361
362
363 /**
364 * Static attribute for minRange.
365 */
Gaurav Agrawal3b57f362016-09-07 13:16:35 +0530366 public static final String UINT8_MIN_RANGE_ATTR =
367 "static final int UINT8_MIN_RANGE = 0;\n";
Bharat saraswal2da23bf2016-08-25 15:28:39 +0530368
369 /**
370 * Static attribute for maxRange.
371 */
Gaurav Agrawal3b57f362016-09-07 13:16:35 +0530372 public static final String UINT8_MAX_RANGE_ATTR =
373 "static final int UINT8_MAX_RANGE = 32767;";
Bharat saraswal2da23bf2016-08-25 15:28:39 +0530374
375
376 /**
377 * Static attribute for minRange.
378 */
379 public static final String UINT8_MIN_RANGE = "UINT8_MIN_RANGE";
380
381 /**
382 * Static attribute for maxRange.
383 */
384 public static final String UINT8_MAX_RANGE = "UINT8_MAX_RANGE";
385
386 /**
387 * Static attribute for minRange.
388 */
Gaurav Agrawal3b57f362016-09-07 13:16:35 +0530389 public static final String INT_MIN_RANGE_ATTR =
390 "static final int INT32_MIN_RANGE = -2147483648;\n";
Bharat saraswal64e7e232016-07-14 23:33:55 +0530391
392 /**
393 * Static attribute for minRange.
394 */
395 public static final String INT_MIN_RANGE = "INT32_MIN_RANGE";
396
397 /**
398 * Static attribute for minRange.
399 */
400 public static final String INT_MAX_RANGE = "INT32_MAX_RANGE";
401
402 /**
403 * Static attribute for maxRange.
404 */
Gaurav Agrawal3b57f362016-09-07 13:16:35 +0530405 public static final String INT_MAX_RANGE_ATTR =
406 "static final int INT32_MAX_RANGE = 2147483647;";
Bharat saraswal64e7e232016-07-14 23:33:55 +0530407
408
409 /**
410 * Static attribute for minRange.
411 */
Gaurav Agrawal3b57f362016-09-07 13:16:35 +0530412 public static final String UINT_MIN_RANGE_ATTR =
413 "static final int UINT16_MIN_RANGE = 0;\n";
Bharat saraswal64e7e232016-07-14 23:33:55 +0530414
415 /**
416 * Static attribute for maxRange.
417 */
Gaurav Agrawal3b57f362016-09-07 13:16:35 +0530418 public static final String UINT_MAX_RANGE_ATTR =
419 "static final int UINT16_MAX_RANGE = 2147483647;";
Bharat saraswal64e7e232016-07-14 23:33:55 +0530420
421
422 /**
423 * Static attribute for minRange.
424 */
425 public static final String UINT_MIN_RANGE = "UINT16_MIN_RANGE";
426
427 /**
428 * Static attribute for maxRange.
429 */
430 public static final String UINT_MAX_RANGE = "UINT16_MAX_RANGE";
431
432 /**
433 * Static attribute for minRange.
434 */
Gaurav Agrawal3b57f362016-09-07 13:16:35 +0530435 public static final String LONG_MIN_RANGE_ATTR =
436 "static final BigInteger INT64_MIN_RANGE =" +
437 " new BigInteger(\"-9223372036854775808\");\n";
Bharat saraswal64e7e232016-07-14 23:33:55 +0530438
439 /**
440 * Static attribute for maxRange.
441 */
Gaurav Agrawal3b57f362016-09-07 13:16:35 +0530442 public static final String LONG_MAX_RANGE_ATTR =
443 "static final BigInteger INT64_MAX_RANGE =" +
444 " new BigInteger(\"9223372036854775807\");";
Bharat saraswal64e7e232016-07-14 23:33:55 +0530445
446 /**
447 * Static attribute for minRange.
448 */
449 public static final String LONG_MIN_RANGE = "INT64_MIN_RANGE";
450
451 /**
452 * Static attribute for maxRange.
453 */
454 public static final String LONG_MAX_RANGE = "INT64_MAX_RANGE";
455
456 /**
457 * Static attribute for minRange.
458 */
Gaurav Agrawal3b57f362016-09-07 13:16:35 +0530459 public static final String ULONG_MIN_RANGE_ATTR =
460 "static final BigInteger UINT32_MIN_RANGE =" +
461 " new BigInteger(\"0\");\n";
Bharat saraswal64e7e232016-07-14 23:33:55 +0530462
463 /**
464 * Static attribute for maxRange.
465 */
Gaurav Agrawal3b57f362016-09-07 13:16:35 +0530466 public static final String ULONG_MAX_RANGE_ATTR =
467 "static final BigInteger UINT32_MAX_RANGE =" +
468 " new BigInteger(\"9223372036854775807\");";
Bharat saraswal64e7e232016-07-14 23:33:55 +0530469
470
471 /**
472 * Static attribute for minRange.
473 */
474 public static final String ULONG_MIN_RANGE = "UINT32_MIN_RANGE";
475
476 /**
477 * Static attribute for maxRange.
478 */
479 public static final String ULONG_MAX_RANGE = "UINT32_MAX_RANGE";
480
481 /**
Bharat saraswal715d3fc2016-05-17 19:59:16 +0530482 * Static attribute for subject.
483 */
484 public static final String SUBJECT = "Subject";
485
486 /**
Bharat saraswal4aaab4d2016-05-17 14:19:38 +0530487 * Static attribute for ListenerService.
488 */
489 public static final String LISTENER_SERVICE = "ListenerService";
490
491 /**
492 * Static attribute for listener package.
493 */
Bharat saraswal715d3fc2016-05-17 19:59:16 +0530494 public static final String ONOS_EVENT_PKG = "org.onosproject.event";
Bharat saraswal4aaab4d2016-05-17 14:19:38 +0530495
496 /**
Vidyashree Ramab6248172016-05-17 16:16:15 +0530497 * Static attribute for colon.
498 */
499 public static final String COLON = ":";
500
501 /**
502 * Static attribute for caret.
503 */
504 public static final String CARET = "^";
505
506 /**
Gaurav Agrawal97a5e1c2016-04-18 18:53:11 +0530507 * Static attribute for input string.
Bharat saraswald532a4c2016-03-25 18:19:46 +0530508 */
Gaurav Agrawal97a5e1c2016-04-18 18:53:11 +0530509 public static final String INPUT = "input";
Bharat saraswald532a4c2016-03-25 18:19:46 +0530510
511 /**
janani b0e4e8ae2016-07-13 21:06:41 +0530512 * Static attribute for output string.
513 */
514 public static final String OUTPUT = "output";
515
516 /**
517 * Static attribute for current string.
518 */
519 public static final String CURRENT = "current";
520
521 /**
janani bb08850e2016-05-17 18:20:33 +0530522 * Static attribute for leafref string.
523 */
524 public static final String LEAFREF = "leafref";
525
526 /**
527 * Static attribute for identityref string.
528 */
529 public static final String IDENTITYREF = "identityref";
530
531 /**
Gaurav Agrawal02a60de2016-04-20 15:49:17 +0530532 * Static attribute for output variable of rpc.
533 */
534 public static final String RPC_INPUT_VAR_NAME = "inputVar";
535
536 /**
Bharat saraswald532a4c2016-03-25 18:19:46 +0530537 * Static attribute for new line.
538 */
Bharat saraswaldedf9f82016-02-12 20:48:30 +0530539 public static final String EQUAL = "=";
Bharat saraswald532a4c2016-03-25 18:19:46 +0530540
541 /**
542 * Static attribute for slash syntax.
543 */
Vinod Kumar S9f26ae52016-03-23 15:30:27 +0530544 public static final String SLASH = File.separator;
Bharat saraswald532a4c2016-03-25 18:19:46 +0530545
546 /**
547 * Static attribute for add syntax.
548 */
Bharat saraswaldedf9f82016-02-12 20:48:30 +0530549 public static final String ADD = "+";
Bharat saraswald532a4c2016-03-25 18:19:46 +0530550
551 /**
Mahesh Poojary Huawei41547ad2016-07-14 17:49:50 +0530552 * Static attribute for single quote.
553 */
554 public static final String SINGLE_QUOTE = "\'";
555
556 /**
Bharat saraswald532a4c2016-03-25 18:19:46 +0530557 * Static attribute for quotes.
558 */
b.jananie6d43af2016-03-04 12:29:05 +0530559 public static final String QUOTES = "\"";
Bharat saraswald532a4c2016-03-25 18:19:46 +0530560
561 /**
Mahesh Poojary Huawei41547ad2016-07-14 17:49:50 +0530562 * Static attribute for zero.
563 */
564 public static final String ZERO = "0";
565
566 /**
Bharat saraswald532a4c2016-03-25 18:19:46 +0530567 * Static attribute for ampersand.
568 */
b.jananie6d43af2016-03-04 12:29:05 +0530569 public static final String AND = "&";
Bharat saraswald532a4c2016-03-25 18:19:46 +0530570
571 /**
572 * Static attribute for comma.
573 */
b.jananie6d43af2016-03-04 12:29:05 +0530574 public static final String COMMA = ",";
Bharat saraswald532a4c2016-03-25 18:19:46 +0530575
576 /**
Bharat saraswalaf413b82016-07-14 15:18:20 +0530577 * Static attribute for class.
578 */
579 public static final String CLASS_STRING = "Class";
580
581 /**
582 * Static attribute for put.
583 */
584 public static final String PUT = "put";
585
586 /**
587 * Static attribute for get.
588 */
589 public static final String GET = "get";
590
591 /**
janani b0e4e8ae2016-07-13 21:06:41 +0530592 * Static attribute for slash character.
593 */
594 public static final char CHAR_OF_SLASH = '/';
595
596 /**
597 * Static attribute for open square bracket character.
598 */
599 public static final char CHAR_OF_OPEN_SQUARE_BRACKET = '[';
600
601 /**
602 * Static attribute for close square bracket character.
603 */
604 public static final char CHAR_OF_CLOSE_SQUARE_BRACKET = ']';
605
606 /**
607 * Static attribute for slash string.
608 */
609 public static final String SLASH_FOR_STRING = "/";
610
611 /**
612 * Static attribute for open square bracket.
613 */
614 public static final String OPEN_SQUARE_BRACKET = "[";
615
616 /**
617 * Static attribute for ancestor accessor.
618 */
619 public static final String ANCESTOR_ACCESSOR = "..";
620
621 /**
622 * Static attribute for ancestor accessor along with path.
623 */
624 public static final String ANCESTOR_ACCESSOR_IN_PATH = "../";
625
626 /**
Bharat saraswald532a4c2016-03-25 18:19:46 +0530627 * Static attribute for add syntax.
628 */
b.jananie6d43af2016-03-04 12:29:05 +0530629 public static final String ADD_STRING = "add";
Bharat saraswald532a4c2016-03-25 18:19:46 +0530630
631 /**
Mahesh Poojary Huawei41547ad2016-07-14 17:49:50 +0530632 * Static attribute for string replace syntax.
633 */
634 public static final String REPLACE_STRING = "replace";
635
636 /**
637 * Static attribute for string trim syntax.
638 */
639 public static final String TRIM_STRING = "trim";
640
641 /**
642 * Static attribute for string split syntax.
643 */
644 public static final String SPLIT_STRING = "split";
645
646 /**
Gaurav Agrawal97a5e1c2016-04-18 18:53:11 +0530647 * Static attribute for from syntax.
648 */
649 public static final String FROM_STRING_METHOD_NAME = "fromString";
650
651 /**
Bharat saraswald532a4c2016-03-25 18:19:46 +0530652 * Static attribute for check not null syntax.
653 */
b.jananie6d43af2016-03-04 12:29:05 +0530654 public static final String CHECK_NOT_NULL_STRING = "checkNotNull";
Bharat saraswald532a4c2016-03-25 18:19:46 +0530655
656 /**
657 * Static attribute for hash code syntax.
658 */
b.jananie6d43af2016-03-04 12:29:05 +0530659 public static final String HASH_CODE_STRING = "hashCode";
Bharat saraswald532a4c2016-03-25 18:19:46 +0530660
661 /**
662 * Static attribute for equals syntax.
663 */
b.jananie6d43af2016-03-04 12:29:05 +0530664 public static final String EQUALS_STRING = "equals";
Bharat saraswald532a4c2016-03-25 18:19:46 +0530665
666 /**
667 * Static attribute for object.
668 */
b.jananie6d43af2016-03-04 12:29:05 +0530669 public static final String OBJECT_STRING = "Object";
Bharat saraswald532a4c2016-03-25 18:19:46 +0530670
671 /**
672 * Static attribute for instance of syntax.
673 */
b.jananie6d43af2016-03-04 12:29:05 +0530674 public static final String INSTANCE_OF = " instanceof ";
675
Bharat saraswald532a4c2016-03-25 18:19:46 +0530676 /**
677 * Static attribute for value syntax.
678 */
b.jananie6d43af2016-03-04 12:29:05 +0530679 public static final String VALUE = "value";
Bharat saraswald532a4c2016-03-25 18:19:46 +0530680
681 /**
682 * Static attribute for suffix s.
683 */
Bharat saraswal84366c52016-03-23 19:40:35 +0530684 public static final String SUFFIX_S = "s";
b.jananie6d43af2016-03-04 12:29:05 +0530685
Bharat saraswald532a4c2016-03-25 18:19:46 +0530686 /**
687 * Static attribute for if.
688 */
b.jananie6d43af2016-03-04 12:29:05 +0530689 public static final String IF = "if";
Bharat saraswald532a4c2016-03-25 18:19:46 +0530690
691 /**
Bharat saraswald532a4c2016-03-25 18:19:46 +0530692 * Static attribute for of.
693 */
b.jananie6d43af2016-03-04 12:29:05 +0530694 public static final String OF = "of";
Bharat saraswald532a4c2016-03-25 18:19:46 +0530695
696 /**
697 * Static attribute for other.
698 */
Vinod Kumar S9f26ae52016-03-23 15:30:27 +0530699 public static final String OTHER = "other";
Bharat saraswald532a4c2016-03-25 18:19:46 +0530700
701 /**
702 * Static attribute for obj syntax.
703 */
Vinod Kumar S9f26ae52016-03-23 15:30:27 +0530704 public static final String OBJ = "obj";
Bharat saraswald532a4c2016-03-25 18:19:46 +0530705
706 /**
707 * Static attribute for hash syntax.
708 */
Vinod Kumar S9f26ae52016-03-23 15:30:27 +0530709 public static final String HASH = "hash";
Bharat saraswald532a4c2016-03-25 18:19:46 +0530710
711 /**
712 * Static attribute for to syntax.
713 */
Vinod Kumar S9f26ae52016-03-23 15:30:27 +0530714 public static final String TO = "to";
b.jananie6d43af2016-03-04 12:29:05 +0530715
Bharat saraswald532a4c2016-03-25 18:19:46 +0530716 /**
Bharat saraswal9fab16b2016-09-23 23:27:24 +0530717 * Static attribute for to syntax.
718 */
719 public static final String TO_CAPS = "To";
720
721 /**
Bharat saraswald532a4c2016-03-25 18:19:46 +0530722 * Static attribute for true syntax.
723 */
b.jananie6d43af2016-03-04 12:29:05 +0530724 public static final String TRUE = "true";
Bharat saraswald532a4c2016-03-25 18:19:46 +0530725
726 /**
727 * Static attribute for false syntax.
728 */
b.jananie6d43af2016-03-04 12:29:05 +0530729 public static final String FALSE = "false";
Bharat saraswald532a4c2016-03-25 18:19:46 +0530730
731 /**
732 * Static attribute for org.
733 */
Vinod Kumar S9f26ae52016-03-23 15:30:27 +0530734 public static final String ORG = "org";
Bharat saraswald532a4c2016-03-25 18:19:46 +0530735
736 /**
737 * Static attribute for temp.
738 */
Bharat saraswal9fab16b2016-09-23 23:27:24 +0530739 public static final String TEMP = "Temp";
Bharat saraswald532a4c2016-03-25 18:19:46 +0530740
741 /**
742 * Static attribute for YANG file directory.
743 */
Vinod Kumar S9f26ae52016-03-23 15:30:27 +0530744 public static final String YANG_RESOURCES = "yang/resources";
Bharat saraswaldedf9f82016-02-12 20:48:30 +0530745
746 /**
Bharat saraswald532a4c2016-03-25 18:19:46 +0530747 * Static attribute for diamond close bracket syntax.
Bharat saraswaldedf9f82016-02-12 20:48:30 +0530748 */
749 public static final String DIAMOND_OPEN_BRACKET = "<";
Bharat saraswald532a4c2016-03-25 18:19:46 +0530750
751 /**
752 * Static attribute for diamond close bracket syntax.
753 */
Bharat saraswaldedf9f82016-02-12 20:48:30 +0530754 public static final String DIAMOND_CLOSE_BRACKET = ">";
Bharat saraswald532a4c2016-03-25 18:19:46 +0530755
756 /**
Bharat saraswal9fab16b2016-09-23 23:27:24 +0530757 * Static attribute for event type.
758 */
759 public static final String EVENT_TYPE = ".Type";
760
761 /**
Gaurav Agrawal97a5e1c2016-04-18 18:53:11 +0530762 * Static attribute for exception syntax.
Bharat saraswald532a4c2016-03-25 18:19:46 +0530763 */
Gaurav Agrawal97a5e1c2016-04-18 18:53:11 +0530764 public static final String EXCEPTION = "Exception";
Bharat saraswald532a4c2016-03-25 18:19:46 +0530765
766 /**
Gaurav Agrawal97a5e1c2016-04-18 18:53:11 +0530767 * Static attribute for exception variable syntax.
Bharat saraswald532a4c2016-03-25 18:19:46 +0530768 */
Gaurav Agrawal97a5e1c2016-04-18 18:53:11 +0530769 public static final String EXCEPTION_VAR = "e";
Bharat saraswald532a4c2016-03-25 18:19:46 +0530770
771 /**
772 * Static attribute for open parenthesis syntax.
773 */
Bharat saraswaldedf9f82016-02-12 20:48:30 +0530774 public static final String OPEN_PARENTHESIS = "(";
Bharat saraswald532a4c2016-03-25 18:19:46 +0530775
776 /**
Bharat saraswal250a7472016-05-12 13:16:57 +0530777 * Static attribute for switch syntax.
778 */
779 public static final String SWITCH = "switch";
780
781 /**
782 * Static attribute for case syntax.
783 */
784 public static final String CASE = "case";
785
786 /**
Gaurav Agrawal97a5e1c2016-04-18 18:53:11 +0530787 * Static attribute for temp val syntax.
788 */
789 public static final String TMP_VAL = "tmpVal";
790
791 /**
Bharat saraswal64e7e232016-07-14 23:33:55 +0530792 * Static attribute for close curly bracket syntax.
793 */
794 public static final String ELSE = "else";
795
796 /**
Gaurav Agrawal97a5e1c2016-04-18 18:53:11 +0530797 * From string parameter name.
798 */
799 public static final String FROM_STRING_PARAM_NAME = "valInString";
800
801 /**
Bharat saraswald532a4c2016-03-25 18:19:46 +0530802 * Static attribute for close parenthesis syntax.
803 */
Bharat saraswaldedf9f82016-02-12 20:48:30 +0530804 public static final String CLOSE_PARENTHESIS = ")";
Bharat saraswald532a4c2016-03-25 18:19:46 +0530805
806 /**
VinodKumarS-Huawei9a91b482016-08-19 23:22:59 +0530807 * Static attribute for empty parameter function call.
808 */
809 public static final String EMPTY_PARAMETER_FUNCTION_CALL = "()";
810
811 /**
Bharat saraswald532a4c2016-03-25 18:19:46 +0530812 * Static attribute for open curly bracket syntax.
813 */
Bharat saraswaldedf9f82016-02-12 20:48:30 +0530814 public static final String OPEN_CURLY_BRACKET = "{";
Bharat saraswald532a4c2016-03-25 18:19:46 +0530815
816 /**
817 * Static attribute for close curly bracket syntax.
818 */
Bharat saraswaldedf9f82016-02-12 20:48:30 +0530819 public static final String CLOSE_CURLY_BRACKET = "}";
820
821 /**
Mahesh Poojary Huawei2cd44332016-07-14 12:38:17 +0530822 * Static attribute for square brackets syntax.
823 */
824 public static final String SQUARE_BRACKETS = "[]";
825
826 /**
Bharat saraswald532a4c2016-03-25 18:19:46 +0530827 * Static attribute for getter method prefix.
Bharat saraswaldedf9f82016-02-12 20:48:30 +0530828 */
829 public static final String GET_METHOD_PREFIX = "get";
Bharat saraswald532a4c2016-03-25 18:19:46 +0530830
831 /**
Bharat saraswal8beac342016-08-04 02:00:03 +0530832 * Static attribute for getter method prefix.
833 */
834 public static final String GET_METHOD = "getMethod";
835
836 /**
837 * Static attribute for getter method prefix.
838 */
839 public static final String GET_CLASS = "getClass()";
840
841 /**
Bharat saraswald532a4c2016-03-25 18:19:46 +0530842 * Static attribute for setter method prefix.
843 */
Bharat saraswaldedf9f82016-02-12 20:48:30 +0530844 public static final String SET_METHOD_PREFIX = "set";
845
846 /**
Shankara-Huaweia1039e52016-07-14 16:53:09 +0530847 * Static attribute for get filter leaf flags.
848 */
VinodKumarS-Huawei9a91b482016-08-19 23:22:59 +0530849 public static final String GET_VALUE_LEAF_FLAGS = "getValueLeafFlags";
850
851 /**
852 * Static attribute for get select filter leaf flags.
853 */
854 public static final String GET_SELECT_LEAF_FLAGS = "getSelectLeafFlags";
855
Shankara-Huaweia1039e52016-07-14 16:53:09 +0530856
857 /**
Bharat saraswal8beac342016-08-04 02:00:03 +0530858 * Static attribute for getLeafIndex.
Shankara-Huaweia1039e52016-07-14 16:53:09 +0530859 */
Bharat saraswal8beac342016-08-04 02:00:03 +0530860 public static final String GET_LEAF_INDEX = "getLeafIndex()";
Shankara-Huaweia1039e52016-07-14 16:53:09 +0530861
862 /**
Bharat saraswal8beac342016-08-04 02:00:03 +0530863 * Static attribute for op param.
Shankara-Huaweia1039e52016-07-14 16:53:09 +0530864 */
Bharat saraswal8beac342016-08-04 02:00:03 +0530865 public static final String OP_PARAM = "OpParam";
Shankara-Huaweia1039e52016-07-14 16:53:09 +0530866
Shankara-Huaweia1039e52016-07-14 16:53:09 +0530867
868 /**
869 * Static attribute for is filter content match method prefix.
870 */
Gaurav Agrawal3b57f362016-09-07 13:16:35 +0530871 public static final String PROCESS_SUBTREE_FILTERING =
872 "processSubtreeFiltering";
VinodKumarS-Huawei9a91b482016-08-19 23:22:59 +0530873
874 /**
875 * variable name of the subtree filtering result builder.
876 */
Gaurav Agrawal3b57f362016-09-07 13:16:35 +0530877 public static final String SUBTREE_FILTERING_RESULT_BUILDER =
878 "subTreeFilteringResultBuilder";
VinodKumarS-Huawei9a91b482016-08-19 23:22:59 +0530879
880 /**
881 * variable name of the subtree filtering result flag.
882 */
Gaurav Agrawal3b57f362016-09-07 13:16:35 +0530883 public static final String IS_ANY_SELECT_OR_CONTAINMENT_NODE_FLAG =
884 "isAnySelectOrContainmentNode";
VinodKumarS-Huawei9a91b482016-08-19 23:22:59 +0530885
886 /**
887 * variable name of the subtree filtering to select all child.
888 */
Gaurav Agrawal3b57f362016-09-07 13:16:35 +0530889 public static final String IS_SELECT_ALL_SCHEMA_CHILD_FLAG =
890 "isSelectAllSchemaChild";
Bharat saraswal8beac342016-08-04 02:00:03 +0530891
892 /**
893 * Static attribute for break prefix.
894 */
895 public static final String BREAK = "break";
896
897 /**
898 * Static attribute for break prefix.
899 */
900 public static final String IS_EMPTY = "isEmpty()";
901
902 /**
903 * Static attribute for is isLeafValueSet method prefix.
904 */
905 public static final String VALUE_LEAF_SET = "isLeafValueSet";
906
907 /**
908 * Static attribute for is isSelectLeaf method prefix.
909 */
910 public static final String IS_SELECT_LEAF = "isSelectLeaf";
911
912 /**
913 * Static attribute for is selectLeaf method prefix.
914 */
915 public static final String SET_SELECT_LEAF = "selectLeaf";
916
917 /**
918 * Static attribute for is LeafIdentifier enum prefix.
919 */
920 public static final String LEAF_IDENTIFIER = "LeafIdentifier";
Bharat saraswal9fab16b2016-09-23 23:27:24 +0530921 /**
922 * Static attribute for is leaf.
923 */
924 public static final String LEAF = "leaf";
Bharat saraswal8beac342016-08-04 02:00:03 +0530925
926 /**
Bharat saraswald532a4c2016-03-25 18:19:46 +0530927 * Static attribute for four space indentation.
Bharat saraswaldedf9f82016-02-12 20:48:30 +0530928 */
929 public static final String FOUR_SPACE_INDENTATION = " ";
Bharat saraswald532a4c2016-03-25 18:19:46 +0530930
931 /**
Shankara-Huaweia1039e52016-07-14 16:53:09 +0530932 * Static attribute for not syntax.
933 */
934 public static final String NOT = "!";
935
936 /**
Gaurav Agrawal97a5e1c2016-04-18 18:53:11 +0530937 * Static attribute for try syntax.
938 */
939 public static final String TRY = "try";
940
941 /**
942 * Static attribute for catch syntax.
943 */
944 public static final String CATCH = "catch";
945
946 /**
Bharat saraswald532a4c2016-03-25 18:19:46 +0530947 * Static attribute for eight space indentation.
948 */
Gaurav Agrawal3b57f362016-09-07 13:16:35 +0530949 public static final String EIGHT_SPACE_INDENTATION =
950 FOUR_SPACE_INDENTATION + FOUR_SPACE_INDENTATION;
Bharat saraswald532a4c2016-03-25 18:19:46 +0530951
952 /**
953 * Static attribute for twelve space indentation.
954 */
Gaurav Agrawal3b57f362016-09-07 13:16:35 +0530955 public static final String TWELVE_SPACE_INDENTATION =
956 EIGHT_SPACE_INDENTATION + FOUR_SPACE_INDENTATION;
Bharat saraswald532a4c2016-03-25 18:19:46 +0530957
958 /**
959 * Static attribute for sixteen space indentation.
960 */
Gaurav Agrawal3b57f362016-09-07 13:16:35 +0530961 public static final String SIXTEEN_SPACE_INDENTATION =
962 TWELVE_SPACE_INDENTATION + FOUR_SPACE_INDENTATION;
Bharat saraswaldedf9f82016-02-12 20:48:30 +0530963
964 /**
Bharat saraswal8beac342016-08-04 02:00:03 +0530965 * Static attribute for twenty space indentation.
966 */
Gaurav Agrawal3b57f362016-09-07 13:16:35 +0530967 public static final String TWENTY_SPACE_INDENTATION =
968 SIXTEEN_SPACE_INDENTATION + FOUR_SPACE_INDENTATION;
Bharat saraswal8beac342016-08-04 02:00:03 +0530969
970 /**
971 * Static attribute for twenty four space indentation.
972 */
Gaurav Agrawal3b57f362016-09-07 13:16:35 +0530973 public static final String TWENTY_FOUR_SPACE_INDENTATION =
974 TWENTY_SPACE_INDENTATION + FOUR_SPACE_INDENTATION;
VinodKumarS-Huawei9a91b482016-08-19 23:22:59 +0530975
976 /**
977 * Static attribute for twenty eight space indentation.
978 */
Gaurav Agrawal3b57f362016-09-07 13:16:35 +0530979 public static final String TWENTY_EIGHT_SPACE_INDENTATION =
980 TWENTY_FOUR_SPACE_INDENTATION + FOUR_SPACE_INDENTATION;
VinodKumarS-Huawei9a91b482016-08-19 23:22:59 +0530981
982 /**
983 * Static attribute for thirty two space indentation.
984 */
Gaurav Agrawal3b57f362016-09-07 13:16:35 +0530985 public static final String THIRTY_TWO_SPACE_INDENTATION =
986 TWENTY_EIGHT_SPACE_INDENTATION + FOUR_SPACE_INDENTATION;
VinodKumarS-Huawei9a91b482016-08-19 23:22:59 +0530987
988 /**
989 * continue.
990 */
991 public static final String CONTINUE = "continue";
Bharat saraswal8beac342016-08-04 02:00:03 +0530992
993 /**
Bharat saraswald532a4c2016-03-25 18:19:46 +0530994 * Static attribute for generated code path.
Bharat saraswaldedf9f82016-02-12 20:48:30 +0530995 */
Bharat saraswal5600f0f2016-03-09 18:34:56 +0530996 public static final String YANG_GEN_DIR = "src/main/java/";
Bharat saraswald532a4c2016-03-25 18:19:46 +0530997
998 /**
999 * Static attribute for base package.
1000 */
Bharat saraswaldedf9f82016-02-12 20:48:30 +05301001 public static final String DEFAULT_BASE_PKG = "org.onosproject.yang.gen";
Bharat saraswald532a4c2016-03-25 18:19:46 +05301002
1003 /**
1004 * Static attribute for YANG date prefix.
1005 */
Bharat saraswaldedf9f82016-02-12 20:48:30 +05301006 public static final String REVISION_PREFIX = "rev";
Bharat saraswald532a4c2016-03-25 18:19:46 +05301007
1008 /**
Gaurav Agrawal3b57f362016-09-07 13:16:35 +05301009 * Static attribute for YANG automatic prefix for identifiers with keywords
1010 * and beginning with digits.
janani b1c6acc42016-04-15 16:18:30 +05301011 */
1012 public static final String YANG_AUTO_PREFIX = "yangAutoPrefix";
1013
1014 /**
Bharat saraswal8beac342016-08-04 02:00:03 +05301015 * Static attribute for YANG version prefix.
Bharat saraswald532a4c2016-03-25 18:19:46 +05301016 */
Bharat saraswaldedf9f82016-02-12 20:48:30 +05301017 public static final String VERSION_PREFIX = "v";
1018
1019 /**
Bharat saraswald532a4c2016-03-25 18:19:46 +05301020 * Static attribute for private modifier.
Bharat saraswaldedf9f82016-02-12 20:48:30 +05301021 */
1022 public static final String PRIVATE = "private";
Bharat saraswaldedf9f82016-02-12 20:48:30 +05301023
1024 /**
Bharat saraswald532a4c2016-03-25 18:19:46 +05301025 * Static attribute for public modifier.
Bharat saraswaldedf9f82016-02-12 20:48:30 +05301026 */
Bharat saraswald532a4c2016-03-25 18:19:46 +05301027 public static final String PUBLIC = "public";
1028
1029 /**
Shankara-Huawei234cd092016-07-14 11:35:34 +05301030 * Static attribute for abstract modifier.
1031 */
1032 public static final String ABSTRACT = "abstract";
1033
1034 /**
Shankara-Huaweia1039e52016-07-14 16:53:09 +05301035 * Static attribute for protected modifier.
1036 */
1037 public static final String PROTECTED = "protected";
1038
1039 /**
Vinod Kumar S08710982016-03-03 19:55:30 +05301040 * Void java type.
1041 */
Bharat saraswaldedf9f82016-02-12 20:48:30 +05301042 public static final String VOID = "void";
Vinod Kumar S08710982016-03-03 19:55:30 +05301043
1044 /**
1045 * String built in java type.
1046 */
Bharat saraswal84366c52016-03-23 19:40:35 +05301047 public static final String STRING_DATA_TYPE = "String";
Bharat saraswale2bc60d2016-04-16 02:28:25 +05301048
Vinod Kumar S08710982016-03-03 19:55:30 +05301049 /**
Bharat saraswale2bc60d2016-04-16 02:28:25 +05301050 * Java.lang.* packages.
Vinod Kumar S08710982016-03-03 19:55:30 +05301051 */
1052 public static final String JAVA_LANG = "java.lang";
1053
1054 /**
Bharat saraswale2bc60d2016-04-16 02:28:25 +05301055 * Java.math.* packages.
1056 */
1057 public static final String JAVA_MATH = "java.math";
1058
1059 /**
1060 * Boolean built in java type.
Vinod Kumar S08710982016-03-03 19:55:30 +05301061 */
Bharat saraswal84366c52016-03-23 19:40:35 +05301062 public static final String BOOLEAN_DATA_TYPE = "boolean";
Vinod Kumar S08710982016-03-03 19:55:30 +05301063
1064 /**
Bharat saraswale2bc60d2016-04-16 02:28:25 +05301065 * BigInteger built in java type.
1066 */
1067 public static final String BIG_INTEGER = "BigInteger";
1068
1069 /**
Mahesh Poojary Huawei2cd44332016-07-14 12:38:17 +05301070 * BigDecimal built in java type.
1071 */
1072 public static final String BIG_DECIMAL = "BigDecimal";
1073
1074 /**
1075 * BitSet built in java type.
1076 */
1077 public static final String BIT_SET = "BitSet";
1078
1079 /**
Bharat saraswale2bc60d2016-04-16 02:28:25 +05301080 * Byte java built in type.
Vinod Kumar S08710982016-03-03 19:55:30 +05301081 */
Bharat saraswaldedf9f82016-02-12 20:48:30 +05301082 public static final String BYTE = "byte";
Vinod Kumar S08710982016-03-03 19:55:30 +05301083
1084 /**
Bharat saraswale2bc60d2016-04-16 02:28:25 +05301085 * Short java built in type.
Vinod Kumar S08710982016-03-03 19:55:30 +05301086 */
1087 public static final String SHORT = "short";
1088
1089 /**
Bharat saraswale2bc60d2016-04-16 02:28:25 +05301090 * Int java built in type.
Vinod Kumar S08710982016-03-03 19:55:30 +05301091 */
1092 public static final String INT = "int";
1093
1094 /**
Bharat saraswale2bc60d2016-04-16 02:28:25 +05301095 * Long java built in type.
Vinod Kumar S08710982016-03-03 19:55:30 +05301096 */
1097 public static final String LONG = "long";
1098
1099 /**
Bharat saraswale2bc60d2016-04-16 02:28:25 +05301100 * Double java built in type.
Vinod Kumar S08710982016-03-03 19:55:30 +05301101 */
Bharat saraswaldedf9f82016-02-12 20:48:30 +05301102 public static final String DOUBLE = "double";
1103
1104 /**
Bharat saraswale2bc60d2016-04-16 02:28:25 +05301105 * Boolean built in java wrapper type.
Vinod Kumar S08710982016-03-03 19:55:30 +05301106 */
1107 public static final String BOOLEAN_WRAPPER = "Boolean";
1108
1109 /**
Bharat saraswale2bc60d2016-04-16 02:28:25 +05301110 * Byte java built in wrapper type.
Vinod Kumar S08710982016-03-03 19:55:30 +05301111 */
1112 public static final String BYTE_WRAPPER = "Byte";
1113
1114 /**
Bharat saraswale2bc60d2016-04-16 02:28:25 +05301115 * Short java built in wrapper type.
Vinod Kumar S08710982016-03-03 19:55:30 +05301116 */
1117 public static final String SHORT_WRAPPER = "Short";
1118
1119 /**
1120 * Integer java built in wrapper type.
1121 */
1122 public static final String INTEGER_WRAPPER = "Integer";
1123
1124 /**
Bharat saraswale2bc60d2016-04-16 02:28:25 +05301125 * Long java built in wrapper type.
Vinod Kumar S08710982016-03-03 19:55:30 +05301126 */
1127 public static final String LONG_WRAPPER = "Long";
1128
1129 /**
Bharat saraswal8beac342016-08-04 02:00:03 +05301130 * Static variable for question mark.
Vinod Kumar S08710982016-03-03 19:55:30 +05301131 */
Bharat saraswalaf413b82016-07-14 15:18:20 +05301132 public static final String QUESTION_MARK = "?";
Mahesh Poojary Huawei2cd44332016-07-14 12:38:17 +05301133
1134 /**
Bharat saraswal9fab16b2016-09-23 23:27:24 +05301135 * Static variable for forType string.
1136 */
1137 public static final String FOR_TYPE_STRING = " for type ";
1138
1139 /**
Gaurav Agrawal3b57f362016-09-07 13:16:35 +05301140 * List of keywords in java, this is used for checking if the input does not
1141 * contain these keywords.
b.jananie6d43af2016-03-04 12:29:05 +05301142 */
Gaurav Agrawal3b57f362016-09-07 13:16:35 +05301143 public static final List<String> JAVA_KEY_WORDS =
1144 Arrays.asList("abstract", "assert", "boolean", "break", "byte",
1145 "case", "catch", "char", "class", "const", "continue",
1146 "default", "do", "double", "else", "extends", "false",
1147 "final", "finally", "float", "for", "goto", "if",
1148 "implements", "import", "instanceof", "enum", "int",
1149 "interface", "long", "native", "new", "null",
1150 "package", "private", "protected", "public", "return",
1151 "short", "static", "strictfp", "super", "switch",
1152 "synchronized", "this", "throw", "throws", "transient",
1153 "true", "try", "void", "volatile", "while");
b.jananie6d43af2016-03-04 12:29:05 +05301154
1155 /**
janani b1c6acc42016-04-15 16:18:30 +05301156 * Static attribute for regex for all the special characters.
b.jananie6d43af2016-03-04 12:29:05 +05301157 */
janani b1c6acc42016-04-15 16:18:30 +05301158 public static final String REGEX_WITH_ALL_SPECIAL_CHAR = "\\p{Punct}+";
1159
1160 /**
Gaurav Agrawal3b57f362016-09-07 13:16:35 +05301161 * Static attribute for regex for three special characters used in
1162 * identifier.
janani b1c6acc42016-04-15 16:18:30 +05301163 */
1164 public static final String REGEX_FOR_IDENTIFIER_SPECIAL_CHAR = "[. _ -]+";
1165
1166 /**
1167 * Static attribute for regex for period.
1168 */
1169 public static final String REGEX_FOR_PERIOD = "[.]";
1170
1171 /**
1172 * Static attribute for regex for underscore.
1173 */
1174 public static final String REGEX_FOR_UNDERSCORE = "[_]";
1175
1176 /**
1177 * Static attribute for regex for hyphen.
1178 */
1179 public static final String REGEX_FOR_HYPHEN = "[-]";
Bharat saraswald532a4c2016-03-25 18:19:46 +05301180
1181 /**
1182 * Static attribute for regex for digits.
1183 */
b.jananie6d43af2016-03-04 12:29:05 +05301184 public static final String REGEX_FOR_FIRST_DIGIT = "\\d.*";
1185
1186 /**
janani b703cfe42016-05-17 13:12:22 +05301187 * Static attribute for regex with digits.
1188 */
1189 public static final String REGEX_WITH_DIGITS = "(?=\\d+)";
1190
1191 /**
janani b1c6acc42016-04-15 16:18:30 +05301192 * Static attribute for regex for single letter.
1193 */
1194 public static final String REGEX_FOR_SINGLE_LETTER = "[a-zA-Z]";
1195
1196 /**
1197 * Static attribute for regex for digits with single letter.
1198 */
Gaurav Agrawal3b57f362016-09-07 13:16:35 +05301199 public static final String REGEX_FOR_DIGITS_WITH_SINGLE_LETTER =
1200 "[0-9]+[a-zA-Z]";
janani b1c6acc42016-04-15 16:18:30 +05301201
1202 /**
janani b703cfe42016-05-17 13:12:22 +05301203 * Static attribute for regex with uppercase.
1204 */
1205 public static final String REGEX_WITH_UPPERCASE = "(?=\\p{Upper})";
1206
1207 /**
1208 * Static attribute for regex for single capital case letter.
1209 */
1210 public static final String REGEX_WITH_SINGLE_CAPITAL_CASE = "[A-Z]";
1211
1212 /**
Gaurav Agrawal3b57f362016-09-07 13:16:35 +05301213 * Static attribute for regex for capital case letter with any number of
1214 * digits and small case letters.
janani b703cfe42016-05-17 13:12:22 +05301215 */
Gaurav Agrawal3b57f362016-09-07 13:16:35 +05301216 public static final String
1217 REGEX_WITH_SINGLE_CAPITAL_CASE_AND_DIGITS_SMALL_CASES =
1218 "[A-Z][0-9a-z]+";
janani b703cfe42016-05-17 13:12:22 +05301219
1220 /**
janani b3e357f62016-05-19 17:39:50 +05301221 * Static attribute for regex for any string ending with service.
1222 */
Gaurav Agrawal3b57f362016-09-07 13:16:35 +05301223 public static final String REGEX_FOR_ANY_STRING_ENDING_WITH_SERVICE =
1224 ".+Service";
janani b3e357f62016-05-19 17:39:50 +05301225
1226 /**
Bharat saraswald532a4c2016-03-25 18:19:46 +05301227 * Static attribute for class syntax.
Bharat saraswaldedf9f82016-02-12 20:48:30 +05301228 */
1229 public static final String CLASS = "class";
Bharat saraswaldedf9f82016-02-12 20:48:30 +05301230
1231 /**
Bharat saraswald532a4c2016-03-25 18:19:46 +05301232 * Static attribute for builder syntax.
1233 */
1234 public static final String BUILDER = "Builder";
1235
1236 /**
Bharat saraswal9fab16b2016-09-23 23:27:24 +05301237 * Static attribute for builder syntax.
VinodKumarS-Huawei6266db32016-05-10 17:58:57 +05301238 */
Bharat saraswal9fab16b2016-09-23 23:27:24 +05301239 public static final String BUILDER_LOWER_CASE = "builder";
VinodKumarS-Huawei6266db32016-05-10 17:58:57 +05301240
1241 /**
1242 * Static attribute for service syntax.
1243 */
1244 public static final String SERVICE = "Service";
1245
VinodKumarS-Huawei6266db32016-05-10 17:58:57 +05301246 /**
Bharat saraswald532a4c2016-03-25 18:19:46 +05301247 * Static attribute for interface syntax.
1248 */
1249 public static final String INTERFACE = "interface";
1250
1251 /**
1252 * Static attribute for enum syntax.
1253 */
1254 public static final String ENUM = "enum";
1255
1256 /**
Bharat saraswal715d3fc2016-05-17 19:59:16 +05301257 * Static attribute for type syntax.
1258 */
1259 public static final String TYPE = "Type";
1260
1261 /**
Bharat saraswald532a4c2016-03-25 18:19:46 +05301262 * Static attribute for static syntax.
1263 */
1264 public static final String STATIC = "static";
1265
1266 /**
1267 * Static attribute for final syntax.
1268 */
1269 public static final String FINAL = "final";
1270
1271 /**
1272 * Static attribute for package syntax.
1273 */
1274 public static final String PACKAGE = "package";
1275
1276 /**
1277 * Static attribute for import syntax.
1278 */
1279 public static final String IMPORT = "import ";
1280
1281 /**
1282 * Static attribute for null syntax.
1283 */
1284 public static final String NULL = "null";
1285
1286 /**
1287 * Static attribute for return syntax.
1288 */
1289 public static final String RETURN = "return";
1290
1291 /**
1292 * Static attribute for java new syntax.
1293 */
1294 public static final String NEW = "new";
1295
1296 /**
1297 * Static attribute for this syntax.
1298 */
1299 public static final String THIS = "this";
1300
1301 /**
1302 * Static attribute for implements syntax.
1303 */
1304 public static final String IMPLEMENTS = "implements";
1305
1306 /**
1307 * Static attribute for extends syntax.
1308 */
1309 public static final String EXTEND = "extends";
1310
1311 /**
Gaurav Agrawal02a60de2016-04-20 15:49:17 +05301312 * Static attribute for service interface suffix syntax.
1313 */
1314 public static final String SERVICE_METHOD_STRING = "Service";
1315
1316 /**
VinodKumarS-Huawei6266db32016-05-10 17:58:57 +05301317 * For event file generation.
1318 */
1319 public static final String EVENT_STRING = "Event";
1320
1321 /**
1322 * For event listener file generation.
1323 */
Bharat saraswalaab24b92016-08-02 18:43:16 +05301324 public static final String EVENT_LISTENER_STRING = "EventListener";
VinodKumarS-Huawei6266db32016-05-10 17:58:57 +05301325
1326 /**
Bharat saraswal715d3fc2016-05-17 19:59:16 +05301327 * For event subject file generation.
1328 */
1329 public static final String EVENT_SUBJECT_NAME_SUFFIX = "EventSubject";
1330
1331 /**
Bharat saraswald532a4c2016-03-25 18:19:46 +05301332 * Static attribute for build method syntax.
1333 */
1334 public static final String BUILD = "build";
1335
1336 /**
1337 * Static attribute for object.
1338 */
1339 public static final String OBJECT = "Object";
1340
1341 /**
Shankara-Huaweia1039e52016-07-14 16:53:09 +05301342 * Static attribute for app instance.
1343 */
1344 public static final String APP_INSTANCE = "appInstance";
1345
1346 /**
Bharat saraswale50edca2016-08-05 01:58:25 +05301347 * Static attribute for instance.
1348 */
1349 public static final String INSTANCE = "instance";
1350
1351 /**
Bharat saraswald532a4c2016-03-25 18:19:46 +05301352 * Static attribute for override annotation.
1353 */
1354 public static final String OVERRIDE = "@Override";
1355
1356 /**
Bharat saraswalaf413b82016-07-14 15:18:20 +05301357 * Static attribute for collections.
Bharat saraswaldedf9f82016-02-12 20:48:30 +05301358 */
b.jananie6d43af2016-03-04 12:29:05 +05301359 public static final String COLLECTION_IMPORTS = "java.util";
Bharat saraswald532a4c2016-03-25 18:19:46 +05301360
1361 /**
Bharat saraswalaf413b82016-07-14 15:18:20 +05301362 * Static attribute for map.
1363 */
1364 public static final String MAP = "Map";
1365
1366 /**
1367 * Static attribute for hash map.
1368 */
1369 public static final String HASH_MAP = "HashMap";
1370
1371
1372 /**
Bharat saraswald532a4c2016-03-25 18:19:46 +05301373 * Static attribute for more object import package.
1374 */
Gaurav Agrawal3b57f362016-09-07 13:16:35 +05301375 public static final String GOOGLE_MORE_OBJECT_IMPORT_PKG =
1376 "com.google.common.base";
Bharat saraswald532a4c2016-03-25 18:19:46 +05301377
1378 /**
1379 * Static attribute for more object import class.
1380 */
Gaurav Agrawal3b57f362016-09-07 13:16:35 +05301381 public static final String GOOGLE_MORE_OBJECT_IMPORT_CLASS =
Bharat saraswal9fab16b2016-09-23 23:27:24 +05301382 "MoreObjects";
Bharat saraswald532a4c2016-03-25 18:19:46 +05301383
1384 /**
1385 * Static attribute for to string method.
1386 */
Gaurav Agrawal3b57f362016-09-07 13:16:35 +05301387 public static final String GOOGLE_MORE_OBJECT_METHOD_STRING =
Bharat saraswal9fab16b2016-09-23 23:27:24 +05301388 "MoreObjects.toStringHelper(getClass())";
Bharat saraswald532a4c2016-03-25 18:19:46 +05301389
1390 /**
1391 * Static attribute for java utilities import package.
1392 */
Vinod Kumar S9f26ae52016-03-23 15:30:27 +05301393 public static final String JAVA_UTIL_OBJECTS_IMPORT_PKG = "java.util";
Bharat saraswald532a4c2016-03-25 18:19:46 +05301394
1395 /**
Shankara-Huaweia1039e52016-07-14 16:53:09 +05301396 * Static attribute for bitset.
1397 */
1398 public static final String BITSET = "BitSet";
1399
1400 /**
Bharat saraswald532a4c2016-03-25 18:19:46 +05301401 * Static attribute for java utilities objects import class.
1402 */
Bharat saraswal9fab16b2016-09-23 23:27:24 +05301403 public static final String JAVA_UTIL_OBJECTS_IMPORT_CLASS = "Objects";
Bharat saraswald532a4c2016-03-25 18:19:46 +05301404
1405 /**
Bharat saraswale2bc60d2016-04-16 02:28:25 +05301406 * Static attribute for AugmentedInfo class.
1407 */
Bharat saraswalaf413b82016-07-14 15:18:20 +05301408 public static final String YANG_AUGMENTED_INFO = "YangAugmentedInfo";
Bharat saraswale2bc60d2016-04-16 02:28:25 +05301409
1410 /**
Bharat saraswal9fab16b2016-09-23 23:27:24 +05301411 * Static attribute for AugmentedInfo class.
1412 */
1413 public static final String YANG_AUGMENTED_INFO_LOWER_CASE =
1414 "yangAugmentedInfo";
1415
1416 /**
Bharat saraswalaf413b82016-07-14 15:18:20 +05301417 * Static attribute for augmented.
Bharat saraswal4aaab4d2016-05-17 14:19:38 +05301418 */
Bharat saraswalaf413b82016-07-14 15:18:20 +05301419 public static final String AUGMENTED = "Augmented";
VinodKumarS-Huaweid81eccb2016-06-01 14:30:22 +05301420
Bharat saraswal4aaab4d2016-05-17 14:19:38 +05301421 /**
Bharat saraswald532a4c2016-03-25 18:19:46 +05301422 * Static attribute for list.
1423 */
Bharat saraswaldedf9f82016-02-12 20:48:30 +05301424 public static final String LIST = "List";
Bharat saraswald532a4c2016-03-25 18:19:46 +05301425
1426 /**
Vidyashree Ramab3670472016-08-06 15:49:56 +05301427 * Static attribute for queue.
1428 */
1429 public static final String QUEUE = "Queue";
1430
1431 /**
1432 * Static attribute for set.
1433 */
1434 public static final String SET = "Set";
1435
1436 /**
Bharat saraswal9fab16b2016-09-23 23:27:24 +05301437 * Comment to be added for auto generated impl methods.
VinodKumarS-Huawei6266db32016-05-10 17:58:57 +05301438 */
Gaurav Agrawal3b57f362016-09-07 13:16:35 +05301439 public static final String YANG_UTILS_TODO =
1440 "//TODO: YANG utils generated code";
VinodKumarS-Huawei6266db32016-05-10 17:58:57 +05301441
1442 /**
Bharat saraswal715d3fc2016-05-17 19:59:16 +05301443 * Static attribute for AbstractEvent.
1444 */
1445 public static final String ABSTRACT_EVENT = "AbstractEvent";
1446
1447 /**
1448 * Static attribute for EventListener.
1449 */
1450 public static final String EVENT_LISTENER = "EventListener";
1451
1452 /**
Shankara-Huaweia1039e52016-07-14 16:53:09 +05301453 * Static attribute for or operator.
1454 */
1455 public static final String OR_OPERATION = "||";
1456
1457 /**
VinodKumarS-Huawei9a91b482016-08-19 23:22:59 +05301458 * Static attribute for or operator.
1459 */
1460 public static final String AND_OPERATION = "&&";
1461
1462 /**
Vidyashree Ramab6248172016-05-17 16:16:15 +05301463 * Static attribute for YANG file error.
1464 */
1465 public static final String YANG_FILE_ERROR = "YANG file error : ";
1466
1467 /**
1468 * Static attribute for unsupported error information.
1469 */
Gaurav Agrawal3b57f362016-09-07 13:16:35 +05301470 public static final String UNSUPPORTED_YANG_CONSTRUCT =
1471 " is not supported.";
Vidyashree Ramab6248172016-05-17 16:16:15 +05301472
1473 /**
Bharat saraswal9fab16b2016-09-23 23:27:24 +05301474 * Static attribute for "is invalid" information.
1475 */
1476 public static final String IS_INVALID = " is invalid.";
1477
1478 /**
1479 * Static attribute for data model tree error information.
1480 */
1481 public static final String INVALID_TREE = "Internal datamodel error: " +
1482 "Datamodel tree is not correct";
1483
1484 /**
Vidyashree Ramab6248172016-05-17 16:16:15 +05301485 * Static attribute for currently unsupported error information.
1486 */
Gaurav Agrawal3b57f362016-09-07 13:16:35 +05301487 public static final String CURRENTLY_UNSUPPORTED =
1488 " is not supported in current version, please check wiki" +
1489 " for YANG utils road map.";
Vidyashree Ramab6248172016-05-17 16:16:15 +05301490
1491 /**
Bharat saraswal9fab16b2016-09-23 23:27:24 +05301492 * Static attribute for leaf ref target node error information.
1493 */
1494 public static final String LEAFREF_ERROR = "YANG file error: The target" +
1495 " node, in the leafref path ";
1496
1497 /**
1498 * Static attribute for leaf holder error information.
1499 */
1500 public static final String LEAF_HOLDER_ERROR = "Referred node should be of" +
1501 " type leaves holder in ";
1502
1503 /**
1504 * Static attribute for invalid resolve entity error information.
1505 */
1506 public static final String INVALID_RESOLVED_ENTITY = "Data Model " +
1507 "Exception: Entity to resolved is other than type/uses";
1508
1509 /**
1510 * Static attribute for invalid resolve entity error information.
1511 */
1512 public static final String INVALID_ENTITY = "Data Model Exception: Entity " +
1513 "to resolved is other than identityref";
1514
1515 /**
1516 * Static attribute for invalid state error information.
1517 */
1518 public static final String INVALID_LINKER_STATE = "Data Model Exception: " +
1519 "Unsupported, linker state";
1520
1521 /**
1522 * Static attribute for leaf ref resolve entity error information.
1523 */
1524 public static final String FAILED_TO_FIND_LEAD_INFO_HOLDER = "YANG file " +
1525 "error: Unable to find base leaf/leaf-list for given leafref path ";
1526
1527 /**
1528 * Static attribute for compiler annotation resolve entity error
1529 * information.
1530 */
1531 public static final String FAILED_TO_FIND_ANNOTATION = "Failed to link " +
1532 "compiler annotation ";
1533
1534 /**
1535 * Static attribute for failed to link entity error information.
1536 */
1537 public static final String FAILED_TO_LINK = "Failed to link ";
1538
1539 /**
1540 * Static attribute for un-resolve entity error information.
1541 */
1542 public static final String UNRESOLVABLE = "Data Model Exception: Entity " +
1543 "to resolved is not Resolvable";
1544
1545 /**
1546 * Static attribute for invalid resolve entity error information.
1547 */
1548 public static final String LINKER_ERROR = "Data Model Exception: Entity" +
1549 " to resolved is other than type/uses/if-feature/leafref/base/identityref";
1550
1551 /**
1552 * Static attribute for invalid resolve entity error information.
1553 */
1554 public static final String INVALID_TARGET = "Invalid target node type ";
1555 /**
Vidyashree Rama5daea742016-05-20 16:29:25 +05301556 * Static attribute for typedef linker error information.
1557 */
Gaurav Agrawal3b57f362016-09-07 13:16:35 +05301558 public static final String TYPEDEF_LINKER_ERROR =
1559 "YANG file error: Unable to find base typedef for given type";
Vidyashree Rama5daea742016-05-20 16:29:25 +05301560
1561 /**
1562 * Static attribute for grouping linker error information.
1563 */
Gaurav Agrawal3b57f362016-09-07 13:16:35 +05301564 public static final String GROUPING_LINKER_ERROR =
1565 "YANG file error: Unable to find base grouping for given uses";
Vidyashree Rama5daea742016-05-20 16:29:25 +05301566
1567 /**
janani b0e4e8ae2016-07-13 21:06:41 +05301568 * Static attribute for if-feature linker error information.
Vidyashree Rama13b4c552016-06-20 15:12:43 +05301569 */
Gaurav Agrawal3b57f362016-09-07 13:16:35 +05301570 public static final String FEATURE_LINKER_ERROR =
1571 "YANG file error: Unable to find feature for given if-feature";
Vidyashree Rama13b4c552016-06-20 15:12:43 +05301572
1573 /**
janani b0e4e8ae2016-07-13 21:06:41 +05301574 * Static attribute for leafref linker error information.
1575 */
Gaurav Agrawal3b57f362016-09-07 13:16:35 +05301576 public static final String LEAFREF_LINKER_ERROR =
1577 "YANG file error: Unable to find base leaf/leaf-list for given " +
1578 "leafref";
janani b0e4e8ae2016-07-13 21:06:41 +05301579
1580 /**
Shankara-Huawei234cd092016-07-14 11:35:34 +05301581 * Static attribute for base linker error information.
1582 */
Gaurav Agrawal3b57f362016-09-07 13:16:35 +05301583 public static final String BASE_LINKER_ERROR =
1584 "YANG file error: Unable to find base identity for given base";
Shankara-Huawei234cd092016-07-14 11:35:34 +05301585
1586 /**
1587 * Static attribute for identityref linker error information.
1588 */
Gaurav Agrawal3b57f362016-09-07 13:16:35 +05301589 public static final String IDENTITYREF_LINKER_ERROR =
1590 "YANG file error: Unable to find base identity for given base";
Shankara-Huawei234cd092016-07-14 11:35:34 +05301591
1592 /**
Bharat saraswalc2d3be12016-06-16 00:29:12 +05301593 * Static attribute for jar.
1594 */
1595 public static final String JAR = "jar";
1596
1597 /**
Bharat saraswal039f59c2016-07-14 21:57:13 +05301598 * Static attribute for for.
1599 */
1600 public static final String FOR = "for";
1601
1602 /**
1603 * Static attribute for YangAugmentedOpParamInfo.
1604 */
Gaurav Agrawal3b57f362016-09-07 13:16:35 +05301605 public static final String YANG_AUGMENTED_OP_PARAM_INFO =
1606 "YangAugmentedOpParamInfo";
Bharat saraswal039f59c2016-07-14 21:57:13 +05301607
1608 /**
Bharat saraswal8beac342016-08-04 02:00:03 +05301609 * Static attribute for NoSuchMethodException.
Bharat saraswal039f59c2016-07-14 21:57:13 +05301610 */
Gaurav Agrawal3b57f362016-09-07 13:16:35 +05301611 public static final String NO_SUCH_METHOD_EXCEPTION =
1612 "NoSuchMethodException";
Bharat saraswal039f59c2016-07-14 21:57:13 +05301613
1614 /**
Bharat saraswal8beac342016-08-04 02:00:03 +05301615 * Static attribute for InvocationTargetException.
Bharat saraswal039f59c2016-07-14 21:57:13 +05301616 */
Gaurav Agrawal3b57f362016-09-07 13:16:35 +05301617 public static final String INVOCATION_TARGET_EXCEPTION =
1618 "InvocationTargetException";
Bharat saraswal039f59c2016-07-14 21:57:13 +05301619
1620 /**
Bharat saraswal8beac342016-08-04 02:00:03 +05301621 * Static attribute for InvocationTargetException.
Bharat saraswal039f59c2016-07-14 21:57:13 +05301622 */
Bharat saraswal8beac342016-08-04 02:00:03 +05301623 public static final String INVOCATION_TARGET_EXCEPTION_IMPORT = "import" +
1624 " java.lang.reflect.InvocationTargetException;\n";
1625 /**
1626 * Static attribute for IllegalAccessException.
1627 */
Gaurav Agrawal3b57f362016-09-07 13:16:35 +05301628 public static final String ILLEGAL_ACCESS_EXCEPTION =
1629 "IllegalAccessException";
Bharat saraswal039f59c2016-07-14 21:57:13 +05301630
1631 /**
Bharat saraswal8beac342016-08-04 02:00:03 +05301632 * Static attribute for arrayList.
Bharat saraswal039f59c2016-07-14 21:57:13 +05301633 */
Bharat saraswal8beac342016-08-04 02:00:03 +05301634 public static final String ARRAY_LIST = "ArrayList<>()";
Bharat saraswal039f59c2016-07-14 21:57:13 +05301635
1636 /**
Bharat saraswal8beac342016-08-04 02:00:03 +05301637 * Static attribute for arrayList import.
Bharat saraswal039f59c2016-07-14 21:57:13 +05301638 */
Gaurav Agrawal3b57f362016-09-07 13:16:35 +05301639 public static final String ARRAY_LIST_IMPORT =
1640 IMPORT + COLLECTION_IMPORTS + ".ArrayList;\n";
Gaurav Agrawal8a147522016-08-10 13:43:01 +05301641
1642 /**
1643 * Static attribute for unused keyword.
1644 */
1645 public static final String UNUSED = "UNUSED";
1646
1647 /**
1648 * Static attribute for 1 keyword.
1649 */
1650 public static final String ONE = "1";
1651
1652 /**
Gaurav Agrawal3b57f362016-09-07 13:16:35 +05301653 * Static attribute for YANG node operation type class.
Vidyashree Rama13960652016-04-26 15:06:06 +05301654 */
Gaurav Agrawal3b57f362016-09-07 13:16:35 +05301655 public static final String OPERATION_TYPE_CLASS =
1656 "OnosYangNodeOperationType";
1657
1658 /**
1659 * Static attribute for YANG node operation type attribute.
1660 */
1661 public static final String OPERATION_TYPE_ATTRIBUTE =
Bharat saraswal9fab16b2016-09-23 23:27:24 +05301662 "OpType";
Gaurav Agrawal3b57f362016-09-07 13:16:35 +05301663
1664 /**
1665 * Static attribute for event class.
1666 */
1667 public static final String EVENT_CLASS = "event class";
1668
1669 /**
1670 * Static attribute for typedef class.
1671 */
1672 public static final String TYPEDEF_CLASS = "typedef class";
1673
1674 /**
1675 * Static attribute for impl class.
1676 */
1677 public static final String IMPL_CLASS = "impl class";
1678
1679 /**
1680 * Static attribute for union class.
1681 */
1682 public static final String UNION_CLASS = "union class";
1683
1684 /**
1685 * Static attribute for enum class.
1686 */
1687 public static final String ENUM_CLASS = "enum class";
1688
1689 /**
1690 * Static attribute for rpc class.
1691 */
1692 public static final String RPC_CLASS = "rpc class";
1693
1694 /**
1695 * Static attribute for builder class.
1696 */
1697 public static final String BUILDER_CLASS = "builder class";
1698
1699 /**
1700 * Static attribute for builder interface.
1701 */
1702 public static final String BUILDER_INTERFACE = "builder interface";
1703
1704 /**
1705 * Static attribute for binary.
1706 */
1707 public static final String BINARY = "binary";
1708
1709 /**
1710 * Static attribute for bits.
1711 */
1712 public static final String BITS = "bits";
1713
1714 /**
1715 * Static attribute for YANG.
1716 */
1717 public static final String YANG = "yang";
1718
Bharat saraswal9fab16b2016-09-23 23:27:24 +05301719 /**
1720 * Static attribute for error msg.
1721 */
1722 public static final String ERROR_MSG_FOR_GEN_CODE = "please check whether " +
1723 "multiple yang" + " files has same module/submodule" +
1724 " \"name\" and \"namespace\"" + "or You may have generated code of" +
1725 " previous build present in your directory.";
1726
1727 /**
1728 * Static attribute for error msg.
1729 */
1730 public static final String ERROR_MSG_JAVA_IDENTITY = "Expected java " +
1731 "identity instance node ";
1732 /**
1733 * Static attribute for in.
1734 */
1735 public static final String IN = " in ";
1736
1737 /**
1738 * Static attribute for at.
1739 */
1740 public static final String AT = " at ";
1741
Gaurav Agrawal3b57f362016-09-07 13:16:35 +05301742 // No instantiation.
Vidyashree Rama13960652016-04-26 15:06:06 +05301743 private UtilConstants() {
1744 }
Gaurav Agrawal3b57f362016-09-07 13:16:35 +05301745
1746 /**
1747 * Represents operation type.
1748 */
1749 public enum Operation {
1750 /**
1751 * Represents add operation.
1752 */
1753 ADD,
1754
1755 /**
1756 * Represents remove operation.
1757 */
1758 REMOVE
1759 }
Bharat saraswaldedf9f82016-02-12 20:48:30 +05301760}