Remove trailing whitespace in all files
[integration/test.git] / csit / variables / gbp / ios-xe-schemas / tailf-cli-extensions@2015-03-19.yang
1 submodule tailf-cli-extensions {
2   belongs-to tailf-common {
3     prefix tailf;
4   }
5
6   include tailf-meta-extensions {
7     revision-date 2013-11-07;
8   }
9
10   organization
11     "Tail-f Systems";
12   description
13     "This module defines all Tail-f YANG extensions statements
14      related to CLI customization.
15
16      See also the 'display-' statements and the 'alt-name' statement
17      in tailf-common.yang.";
18
19   revision 2015-03-19 {
20     description
21       "Released as part of ConfD-5.4 / NCS-3.4.
22
23        Added cli-show-obu-comments.
24        Added cli-batch-confirm-default.";
25   }
26   revision 2014-11-13 {
27     description
28       "Released as part of ConfD-5.3 / NCS-3.3.
29
30        Added cli-strict-leafref.
31        Added cli-trigger-on-*.
32        Allow cli-boolean-no in typedef.";
33   }
34   revision 2013-11-07 {
35     description
36       "Released as part of ConfD-5.0.
37
38        Added cli-disabled-info.
39        Added cli-suppress-shortenabled.
40        Added cli-no-keyword.
41        Added cli-case-sensitive and cli-case-insensitive.";
42   }
43   revision 2012-11-08 {
44     description
45       "Released as part of ConfD-4.1.
46
47        Added cli-delete-when-empty.
48        Added cli-diff-dependency.
49        Added cli-ignore-modified.";
50   }
51   revision 2012-08-23 {
52     description
53       "Released as part of ConfD-4.0.1.
54
55        Allow tailf:cli-operational-mode and tailf:cli-configure-mode in
56          rpc.";
57   }
58   revision 2012-06-14 {
59     description
60       "Released as part of ConfD-4.0.
61
62        Do not allow tailf:cli-drop-node-name and tailf:cli-sequence-commands
63          inside tailf:action.
64        Added tailf:cli-configure-mode.
65        Added tailf:cli-operational-mode.";
66   }
67   revision 2012-05-24 {
68     description
69       "Released as part of ConfD-3.9.2.
70
71        Added tailf:cli-no-value-on-delete.
72        Added tailf:cli-no-name-on-delete.
73        Added tailf:cli-replace-all.
74        Allow tailf:cli-remove-before-change in leaf.";
75   }
76   revision 2012-03-08 {
77     description
78       "Released as part of ConfD-3.9.
79
80        Allow tailf:cli-range-list-syntax in lists with one integer based
81          key.";
82   }
83   revision 2011-12-08 {
84     description
85       "Released as part of ConfD-3.8.
86
87        Added tailf:cli-min-column-with.";
88   }
89   revision 2011-09-22 {
90     description
91       "Released as part of ConfD-3.7.
92
93        Added tailf:cli-disallow-value.
94        Added tailf:cli-multi-word.
95        Added tailf:cli-before-key.
96        Allow tailf:cli-flatten-container in list.";
97   }
98   revision 2011-08-25 {
99     description
100       "Released as part of ConfD-3.6.2.
101
102        Added cli-suppress-silent-no.
103        Added cli-range-delimiters.
104        Removed duplicate tailf:use-in statement from cli-show-config.";
105   }
106   revision 2011-06-30 {
107     description
108       "Released as part of ConfD-3.6.1.
109
110        Added cli-reversed.
111        Added cli-range-list-syntax.";
112   }
113   revision 2011-05-26 {
114     description
115       "Released as part of ConfD-3.6.
116
117        Added cli-allow-join-with-key.
118        Added cli-display-joined.";
119   }
120   revision 2011-02-24 {
121     description
122       "Released as part of ConfD-3.5.
123
124        Added cli-boolean-no.
125        Added cli-exit-command.
126        Added cli-custom-range-enumerator.
127        Added cli-reset-siblings.
128        Added cli-reset-all-siblings.
129        Added cli-reset-container.
130        Added cli-hide-in-submode.
131        Added cli-prefix-key.
132        Added cli-show-with-default.
133
134        Added 'commasep' and 'show:<dictionary>' filter in
135        cli-template-string.
136
137        Removed deprecated tailf:cli-default-order.";
138   }
139   revision 2010-12-02 {
140     description
141       "Released as part of ConfD-3.4.1.
142
143        Added cli-flatten-container.";
144   }
145   revision 2010-11-04 {
146     description
147       "Released as part of ConfD-3.4.
148
149        Added cli-key-format.
150        Added cli-list-syntax.
151        Added cli-flat-list-syntax.
152
153        The following statements were added in ConfD-3.3.3:
154
155        Added cli-suppress-list-no.
156        Added cli-suppress-no.
157        Added cli-full-no.
158        Added cli-incomplete-no.";
159   }
160   revision 2010-09-16 {
161     description
162       "Released as part of ConfD-3.3.2.
163
164        Added cli-autowizard.
165        Added cli-multi-word-key.
166        Added cli-no-match-completion.";
167   }
168   revision 2010-08-19 {
169     description
170       "Released as part of ConfD-3.3.1.
171
172        Added cli-show-template-footer.
173        Added cli-run-template-footer.
174        Added cli-table-footer.
175        Changed cli-table-legend to be a template.";
176   }
177   revision 2010-06-17 {
178     description
179       "Released as part of ConfD-3.3.
180
181        Added cli-display-empty-config.
182
183        Added cli-expose-key-name.
184
185        Added cli-value-display-template.
186
187        Added cli-run-template.
188        Added cli-run-template-legend.
189        Added cli-run-template-enter.
190
191        Added cli-suppress-key-sort.
192
193        Added cli-suppress-validation-warning-prompt.
194
195        Added 'hex' and 'hexlist' as display parameters in the
196        type cli-template-string.
197
198        Deprecated tailf:cli-default-order.";
199   }
200   revision 2010-03-18 {
201     description
202       "Released as part of ConfD-3.2.";
203   }
204
205   extension cli-show-no {
206     tailf:use-in "leaf";
207     tailf:use-in "list";
208     tailf:use-in "leaf-list";
209     tailf:use-in "refine";
210     tailf:use-in "tailf:symlink";
211     tailf:use-in "container";
212     description
213       "Specifies that an optional leaf node or presence container
214        should be displayed as 'no <name>' when it does not exist.
215        For example, if a leaf 'shutdown' has this property and
216        does not exist, 'no shutdown' is displayed.
217
218        Used in I- and C-style CLIs.";
219   }
220
221   extension cli-disallow-value {
222     argument value {
223       tailf:arg-type {
224         type string;
225       }
226     }
227     tailf:use-in "leaf";
228     tailf:use-in "leaf-list";
229     tailf:use-in "refine";
230     tailf:use-in "tailf:symlink";
231     description
232       "Specifies that a pattern for invalid values.
233
234        Used in I- and C-style CLIs.";
235   }
236
237   extension cli-boolean-no {
238     tailf:use-in "typedef";
239     tailf:use-in "leaf";
240     tailf:use-in "refine";
241     tailf:use-in "tailf:symlink";
242     tailf:substatement "tailf:cli-reversed";
243     description
244       "Specifies that a leaf of type boolean should be displayed as
245        '<leafname>' if set to true, and 'no <leafname>' if set to
246        false.
247
248        Cannot be used in conjunction with tailf:cli-hide-in-submode
249        or tailf:cli-compact-syntax.
250
251        Used in I- and C-style CLIs.";
252   }
253
254   extension cli-reversed {
255     tailf:use-in "tailf:cli-boolean-no";
256     description
257       "Specified that true should be displayed as 'no <name>' and
258        false as 'name'.
259
260        Used in I- and C-style CLIs.";
261   }
262
263   extension cli-autowizard {
264     tailf:use-in "leaf";
265     tailf:use-in "tailf:symlink";
266     tailf:use-in "refine";
267     description
268       "Specifies that the autowizard should include this leaf even
269        if the leaf is optional.
270
271        One use case is when implementing pre-configuration of devices.
272        A config false node can be defined for showing if the
273        configuration is active or not (preconfigured).
274
275        Used in J-, I- and C-style CLIs.";
276   }
277
278   extension cli-show-config {
279     tailf:use-in "leaf";
280     tailf:use-in "leaf-list";
281     tailf:use-in "list";
282     tailf:use-in "container";
283     tailf:use-in "refine";
284     tailf:use-in "tailf:symlink";
285     description
286       "Specifies that the node will be included when doing a 'show
287        running-configuration', even if it is a non-config node.
288
289        Used in I- and C-style CLIs.";
290   }
291
292   extension cli-display-empty-config {
293     tailf:use-in "list";
294     tailf:use-in "tailf:symlink";
295     tailf:use-in "refine";
296     description
297       "Specifies that the node will be included when doing a 'show
298        stats', even if it is a non-config node, provided
299        that the list contains at least one non-config node.
300
301        Used in J-style CLI.";
302   }
303
304   extension cli-mode-name {
305     argument value {
306       tailf:arg-type {
307         type string;
308       }
309     }
310     tailf:use-in "container";
311     tailf:use-in "list";
312     tailf:use-in "tailf:symlink";
313     tailf:use-in "refine";
314     description
315       "Specifies a custom mode name, instead of the default which is the
316        name of the list or container node.
317
318        Can be used in config nodes only.  If used in a container, the
319        container must also have a tailf:cli-add-mode statement, and if
320        used in a list, the list must not also have a
321        tailf:cli-suppress-mode statement.
322
323        Variables for the list keys in the current mode are available.
324        For examples, 'config-foo-xx$(name)' (privided the key leaf
325        is called 'name').
326
327        Used in I- and C-style CLIs.";
328   }
329
330   extension cli-show-order-taglist {
331     argument value {
332       tailf:arg-type {
333         type string;
334       }
335     }
336     tailf:use-in "container";
337     tailf:use-in "list";
338     tailf:use-in "tailf:symlink";
339     tailf:use-in "refine";
340     description
341       "Specifies a custom display order for nodes with the
342        tailf:cli-show-order-tag attribute. Nodes will be displayed
343        in the order indicated in the list. Nodes without a tag will
344        be displayed after all nodes with a tag have been displayed.
345
346        The scope of a taglist is until a new taglist is encountered.
347
348        Used in I- and C-style CLIs.";
349   }
350
351   extension cli-show-order-tag {
352     argument value {
353       tailf:arg-type {
354         type string;
355       }
356     }
357     tailf:use-in "container";
358     tailf:use-in "list";
359     tailf:use-in "leaf";
360     tailf:use-in "leaf-list";
361     tailf:use-in "tailf:symlink";
362     tailf:use-in "refine";
363     description
364       "Specifies a custom display order for nodes with the
365        tailf:cli-show-order-tag attribute. Nodes will be displayed
366        in the order indicated by a cli-show-order-taglist attribute in
367        a parent node.
368
369        The scope of a tag reaches until a new taglist is encountered.
370
371        Used in I- and C-style CLIs.";
372   }
373
374   extension cli-mode-name-actionpoint {
375     argument value {
376       tailf:arg-type {
377         type string;
378       }
379     }
380     tailf:use-in "container";
381     tailf:use-in "list";
382     tailf:use-in "refine";
383     description
384       "Specifies that a custom function will be invoked to find out the mode
385        name, instead of using the default with is the name of the list
386        or container node.
387
388        The argument is the name of an actionpoint, which must be
389        implemented by custom code.  In the actionpoint, the command()
390        callback function will be invoked, and it must return a string
391        with the mode name.  See confd_lib_dp(3) for details.
392
393        Can be used in config nodes only.  If used in a container, the
394        container must also have a tailf:cli-add-mode statement, and if
395        used in a list, the list must not also have a
396        tailf:cli-suppress-mode statement.
397
398        Used in I- and C-style CLIs.";
399   }
400
401   extension cli-add-mode {
402     tailf:use-in "container";
403     tailf:use-in "tailf:symlink";
404     tailf:use-in "refine";
405     description
406       "Creates a mode of the container.
407
408        Can be used in config nodes only.
409
410        Used in I- and C-style CLIs.";
411   }
412
413   extension cli-flatten-container {
414     tailf:use-in "container";
415     tailf:use-in "list";
416     tailf:use-in "tailf:symlink";
417     tailf:use-in "refine";
418     description
419       "Allows the CLI to exit the container and continue to input
420        from the parent container when all leaves in the current
421        container has been set.
422
423        Can be used in config nodes only.
424
425        Used in I- and C-style CLIs.";
426   }
427
428   extension cli-suppress-mode {
429     tailf:use-in "list";
430     tailf:use-in "tailf:symlink";
431     tailf:use-in "refine";
432     description
433       "Instructs the CLI engine to not make a mode of the list node.
434
435        Can be used in config nodes only.
436
437        Used in I- and C-style CLIs.";
438   }
439
440   extension cli-delete-when-empty {
441     tailf:use-in "list";
442     tailf:use-in "container";
443     description
444       "Instructs the CLI engine to delete the list when the last list
445        instance is deleted'. Requires that cli-suppress-mode is set.
446
447        The behavior is recursive. If all optional leafs in a list
448        instance are deleted the list instance itself is deleted. If
449        that list instance happens to be the last list instance in a
450        list it is also deleted. And so on. Used in I- and C-style
451        CLIs.";
452   }
453
454   extension cli-remove-before-change {
455     tailf:use-in "leaf-list";
456     tailf:use-in "list";
457     tailf:use-in "leaf";
458     tailf:use-in "tailf:symlink";
459     tailf:use-in "refine";
460     description
461       "Instructs the CLI engine to generate a no-commnd before
462        modifying an existing instance. It only applies when
463        generating diffs, eg 'show configuration' in C-style.";
464   }
465
466   extension cli-no-value-on-delete {
467     tailf:use-in "leaf";
468     tailf:use-in "leaf-list";
469     tailf:use-in "tailf:symlink";
470     tailf:use-in "refine";
471     description
472       "When displaying the deleted version of this leaf do not
473        include the old value.
474
475        Applies to C-style";
476   }
477
478   extension cli-no-name-on-delete {
479     tailf:use-in "leaf";
480     tailf:use-in "container";
481     tailf:use-in "list";
482     tailf:use-in "leaf-list";
483     tailf:use-in "tailf:symlink";
484     tailf:use-in "refine";
485     description
486       "When displaying the deleted version of this element do not
487        include the name.
488
489        Applies to C-style";
490   }
491
492   extension cli-embed-no-on-delete {
493     tailf:use-in "leaf";
494     tailf:use-in "container";
495     tailf:use-in "list";
496     tailf:use-in "leaf-list";
497     tailf:use-in "tailf:symlink";
498     tailf:use-in "refine";
499     description
500       "Embed no in front of the element name insead of at the
501        beginning of the line.
502
503        Applies to C-style";
504   }
505
506   extension cli-recursive-delete {
507     tailf:use-in "container";
508     tailf:use-in "list";
509     tailf:use-in "tailf:symlink";
510     tailf:use-in "refine";
511     description
512       "When generating configuration diffs delete all contents
513        of a container or list before deleting the node.
514
515        Applies to C-style";
516   }
517
518   extension cli-diff-dependency {
519     argument path {
520       tailf:arg-type {
521         type string;
522       }
523     }
524     tailf:use-in "container";
525     tailf:use-in "list";
526     tailf:use-in "leaf";
527     tailf:use-in "leaf-list";
528     tailf:use-in "tailf:symlink";
529     tailf:use-in "refine";
530     tailf:substatement "tailf:xpath-root";
531     tailf:substatement "tailf:cli-trigger-on-set";
532     tailf:substatement "tailf:cli-trigger-on-delete";
533     tailf:substatement "tailf:cli-trigger-on-all";
534     tailf:occurence "*";
535     description
536       "Tells the 'show configuration' command, and the diff generator
537        that this node depends on another node. When removing the node
538        with this declaration, it should be removed before the node
539        it depends on is removed, ie the declaration controlls the ordering
540        of the commands in the 'show configuration' output.
541
542        Applies to C-style";
543   }
544
545   extension cli-trigger-on-set {
546     tailf:use-in "tailf:cli-diff-dependency";
547     description
548       "Specify that the dependency should trigger on set/modify of
549               the target path, but deletion of the target will trigger the
550               current node to be placed in front of the target.
551
552               The annotation can be used to get the diff behavior where
553               one leaf is first deleted before the other leaf is set.
554               For example, having the data model below:
555
556                container X {
557                  leaf A {
558                    tailf:cli-diff-dependency \"../B\" {
559                      tailf:cli-trigger-on-set;
560                    }
561                    type empty;
562                  }
563                  leaf B {
564                    tailf:cli-diff-dependency \"../A\"  {
565                      tailf:cli-trigger-on-set;
566                    }
567                    type empty;
568                  }
569                }
570
571               produces the following diffs when setting one leaf
572               and deleting the other
573
574                 no X A
575                 X B
576
577               and
578
579                 no X B
580                 X A
581
582               this can also be done with list instances, for example
583
584                 list a {
585                   key id;
586
587                   leaf id {
588                     tailf:cli-diff-dependency \"/c[id=current()/../id]\" {
589                       tailf:cli-trigger-on-set;
590                     }
591                     type string;
592                   }
593                 }
594
595                 list c {
596                   key id;
597                   leaf id {
598                     tailf:cli-diff-dependency \"/a[id=current()/../id]\" {
599                       tailf:cli-trigger-on-set;
600                     }
601                     type string;
602                   }
603                 }
604
605               we get
606
607                 no a foo
608                 c foo
609                 !
610
611               and
612
613                 no c foo
614                 a foo
615                 !
616
617               In the above case if we have the same id in list \"a\" and \"c\"
618               and we delete the instance in one list, and add it in the other,
619               then the deletion will always preceed the create.
620              ";
621   }
622
623   extension cli-trigger-on-delete {
624     tailf:use-in "tailf:cli-diff-dependency";
625     description
626       "This annotation can be used togeter with tailf:cli-trigger-on-set
627        to also get the behavior that when deleting the target display
628        changes to this node first. For exmaple:
629
630         container settings {
631           tailf:cli-add-mode;
632
633           leaf opmode {
634             tailf:cli-no-value-on-delete;
635
636             type enumeration {
637               enum nat;
638               enum transparent;
639             }
640           }
641
642           leaf manageip {
643             when \"../opmode = 'transparent'\";
644             mandatory true;
645             tailf:cli-no-value-on-delete;
646             tailf:cli-diff-dependency '../opmode' {
647               tailf:cli-trigger-on-set;
648               tailf:cli-trigger-on-delete;
649             }
650
651             type string;
652           }
653         }
654
655        What we are trying to achieve here is that if manageip is
656        deleted, it should be displayed before opmode, but if we
657        configure both opmode and manageip, we should display opmode
658        first, ie get the diffs:
659
660        settings
661         opmode   transparent
662         manageip 1.1.1.1
663        !
664
665        and
666
667        settings
668         no manageip
669         opmode nat
670        !
671
672        and
673
674        settings
675         no manageip
676         no opmode
677        !
678
679        The cli-trigger-on-set annotation will cause the 'no manageip'
680        command to be displayed before setting opmode. The
681        tailf:cli-trigger-on-delete will cause 'no manageip' to be
682        placed before 'no opmode' when both are deleted.
683
684        In the first diff where both are created, opmode will come first
685        due to the diff-dependency setting, regardless of the
686        cli-trigger-on-delete and cli-trigger-on-set.
687       ";
688   }
689
690   extension cli-trigger-on-all {
691     tailf:use-in "tailf:cli-diff-dependency";
692     description
693       "Specify that the dependency should always trigger. It is the
694        same as placing one element before another in the data model.
695        For example, given the data model:
696
697        container X {
698          leaf A {
699            tailf:cli-diff-dependency '../B' {
700              tailf:cli-trigger-on-all;
701            }
702            type empty;
703          }
704          leaf B {
705            type empty;
706          }
707        }
708
709        We get the diffs
710
711          X B
712          X A
713
714        and
715
716          no X B
717          no X A
718       ";
719   }
720
721   extension cli-ignore-modified {
722     tailf:use-in "container";
723     tailf:use-in "list";
724     tailf:use-in "leaf";
725     tailf:use-in "leaf-list";
726     tailf:use-in "tailf:symlink";
727     tailf:use-in "refine";
728     description
729       "Tells the cdb_cli_diff_iterate system call to not generate
730        a CLI string when this container is modified. The string will
731        instead be generated for the modified sub-element.
732
733        Applies to C-style and I-style";
734   }
735
736   extension cli-show-long-obu-diffs {
737     tailf:use-in "list";
738     tailf:use-in "tailf:symlink";
739     tailf:use-in "refine";
740     description
741       "Instructs the CLI engine to not generate 'insert' comments
742        when displaying configuration changes of ordered-by user
743        lists, but instead explicitly remove old instances with 'no'
744        and then add the instances following a newly inserted instance.
745        Should not be used together with tailf:cli-show-obu-comments";
746   }
747
748   extension cli-show-obu-comments {
749     tailf:use-in "list";
750     tailf:use-in "tailf:symlink";
751     tailf:use-in "refine";
752     description
753       "Enforces the CLI engine to generate 'insert' comments
754        when displaying configuration changes of ordered-by user
755        lists. Should not be used together with tailf:cli-show-long-obu-diffs";
756   }
757
758   extension cli-allow-join-with-key {
759     tailf:use-in "list";
760     tailf:use-in "tailf:symlink";
761     tailf:use-in "refine";
762     tailf:substatement "tailf:cli-display-joined";
763     description
764       "Indicates that the list name may be written together
765        with the first key, without requiring a whitespace
766        in between, ie allowing both
767             interface ethernet1/1
768        and
769             interface ethernet 1/1
770
771        Used in I- and C-style CLIs.";
772   }
773
774   extension cli-allow-join-with-value {
775     tailf:use-in "leaf";
776     tailf:use-in "tailf:symlink";
777     tailf:use-in "refine";
778     tailf:substatement "tailf:cli-display-joined";
779     description
780       "Indicates that the leaf name may be written together
781        with the value, without requiring a whitespace
782        in between, ie allowing both
783             interface ethernet1/1
784        and
785             interface ethernet 1/1
786
787        Used in I- and C-style CLIs.";
788   }
789
790   extension cli-display-joined {
791     tailf:use-in "tailf:cli-allow-join-with-key";
792     tailf:use-in "tailf:cli-allow-join-with-value";
793     description
794       "Specifies that the joined version should be used when displaying
795        the configuration in C- and I- mode.";
796   }
797
798   extension cli-exit-command {
799     argument value {
800       yin-element true;
801       tailf:arg-type {
802         type string;
803       }
804     }
805     tailf:use-in "list";
806     tailf:use-in "container";
807     tailf:use-in "refine";
808     tailf:use-in "tailf:symlink";
809     tailf:substatement "tailf:info";
810     description
811       "Tells the CLI to add an explicit exit-from-submode command.
812        The tailf:info substatement can be used for adding a custom
813        info text for the command.
814
815        Used in I- and C-style CLIs.";
816   }
817
818   extension cli-explicit-exit {
819     tailf:use-in "list";
820     tailf:use-in "container";
821     tailf:use-in "refine";
822     tailf:use-in "tailf:symlink";
823     description
824       "Tells the CLI to add an explicit exit command when displaying
825        the configuration. It will not be added if cli-exit-command
826        is defined as well. The annotation is inherited by all
827        sub-modes.
828
829        Used in I- and C-style CLIs.";
830   }
831
832   extension cli-key-format {
833     argument value {
834       yin-element true;
835       tailf:arg-type {
836         type string;
837       }
838     }
839     tailf:use-in "list";
840     tailf:use-in "tailf:symlink";
841     tailf:use-in "refine";
842     description
843       "The format string is used when parsing a key value and when
844        generating a key value for an existing configuration. The key
845        items are numbered from 1-N and the format string should
846        indicate how they are related by using $(X) (where X is the
847        key number). For example:
848
849        tailf:cli-key-format '$(1)-$(2)' means that the first key
850        item is concatenated with the second key item by a '-'.
851
852        Used in J-, I- and C-style CLIs.";
853   }
854
855   extension cli-suppress-key-sort {
856     tailf:use-in "list";
857     tailf:use-in "tailf:symlink";
858     tailf:use-in "refine";
859     description
860       "Instructs the CLI engine to not sort the keys in alphabetical order
861        when presenting them to the user during TAB completion.
862
863        Used in J-, I- and C-style CLIs.";
864   }
865
866   extension cli-suppress-table {
867     tailf:use-in "list";
868     tailf:use-in "tailf:symlink";
869     tailf:use-in "refine";
870     description
871       "Instructs the CLI engine to not print the list as a table in
872        the 'show' command.
873
874        Can be used in non-config nodes only.
875
876        Used in I- and C-style CLIs.";
877   }
878
879   extension cli-suppress-validation-warning-prompt {
880     tailf:use-in "list";
881     tailf:use-in "leaf";
882     tailf:use-in "container";
883     tailf:use-in "leaf-list";
884     tailf:use-in "tailf:symlink";
885     tailf:use-in "refine";
886     description
887       "Instructs the CLI engine to not prompt the user whether to proceed
888        or not if a warning is generated for this node.
889
890        Used in I- and C-style CLIs.";
891   }
892
893   extension cli-suppress-key-abbreviation {
894     tailf:use-in "list";
895     tailf:use-in "tailf:symlink";
896     tailf:use-in "refine";
897     description
898       "Key values cannot be abbreviated.  The user must always give
899        complete values for keys.
900
901        In the J-style CLI this is relevant when using the commands
902        'delete' and 'edit'.
903
904        In the I- and C-style CLIs this is relevant when using the
905        commands 'no', 'show configuration' and for commands to enter
906        submodes.
907
908        See also /confdConfig/cli/allowAbbrevKeys in confd.conf(5).";
909   }
910
911   extension cli-allow-key-abbreviation {
912     tailf:use-in "list";
913     tailf:use-in "tailf:symlink";
914     tailf:use-in "refine";
915     description
916       "Key values can be abbreviated.
917
918        In the J-style CLI this is relevant when using the commands
919        'delete' and 'edit'.
920
921        In the I- and C-style CLIs this is relevant when using the
922        commands 'no', 'show configuration' and for commands to enter
923        submodes.
924
925        See also /confdConfig/cli/allowAbbrevKeys in confd.conf(5).";
926   }
927
928   extension cli-table-legend {
929     argument value {
930       yin-element true;
931       tailf:arg-type {
932         type string;
933       }
934     }
935     tailf:use-in "list";
936     tailf:use-in "tailf:symlink";
937     tailf:use-in "refine";
938     description
939       "Specifies a template string to be printed before all list entries are
940        printed.
941
942        Used in J-, I- and C-style CLIs.";
943   }
944
945   extension cli-table-footer {
946     argument value {
947       yin-element true;
948       tailf:arg-type {
949         type string;
950       }
951     }
952     tailf:use-in "list";
953     tailf:use-in "tailf:symlink";
954     tailf:use-in "refine";
955     description
956       "Specifies a template string to be printed after all list entries are
957        printed.
958
959        Used in J-, I- and C-style CLIs.";
960   }
961
962   extension cli-completion-actionpoint {
963     argument value {
964       tailf:arg-type {
965         type tailf:identifier;
966       }
967     }
968     tailf:use-in "leaf-list";
969     tailf:use-in "leaf";
970     tailf:use-in "tailf:symlink";
971     tailf:use-in "refine";
972     tailf:substatement "tailf:cli-completion-id";
973     description
974       "Specifies that completion for the leaf values is done through a
975        callback function.
976
977        The argument is the name of an actionpoint, which must be
978        implemented by custom code.  In the actionpoint, the completion()
979        callback function will be invoked.  See confd_lib_dp(3) for details.
980
981        Used in J-, I- and C-style CLIs.";
982   }
983
984   extension cli-completion-id {
985     argument value {
986       tailf:arg-type {
987         type tailf:identifier;
988       }
989     }
990     tailf:use-in "tailf:cli-completion-actionpoint";
991     tailf:use-in "tailf:cli-custom-range-actionpoint";
992     description
993       "Specifies a string which is passed to the callback when invoked.
994        This makes it possible to use the same callback at several
995        locations and still keep track of which point it is invoked
996        from.";
997   }
998
999   extension cli-allow-caching {
1000     tailf:use-in "tailf:cli-custom-range-actionpoint";
1001     tailf:use-in "tailf:cli-custom-range-enumerator";
1002     description
1003       "Allow caching of the evaluation results between different parent paths.";
1004   }
1005
1006   extension cli-multi-line-prompt {
1007     tailf:use-in "leaf";
1008     tailf:use-in "tailf:symlink";
1009     tailf:use-in "refine";
1010     description
1011       "Tells the CLI to automatically enter multi-line mode when prompting
1012        the user for a value to this leaf.
1013
1014        Used in J-, I- and C-style CLIs.";
1015   }
1016
1017   extension cli-multi-word-key {
1018     tailf:use-in "leaf";
1019     tailf:use-in "tailf:symlink";
1020     tailf:use-in "refine";
1021     tailf:substatement "tailf:cli-max-words";
1022     description
1023       "Specifies that the key should allow multiple tokens for the
1024        value. Proper type restrictions needs to be used to limit
1025        the range of the leaf value.
1026
1027        Can be used in key leafs only.
1028
1029        Used in J-, I- and C-style CLIs.";
1030   }
1031
1032   extension cli-max-words {
1033     argument value {
1034       tailf:arg-type {
1035         type uint32;
1036       }
1037     }
1038     tailf:use-in "tailf:cli-multi-word-key";
1039     tailf:use-in "tailf:cli-multi-word";
1040     tailf:use-in "tailf:cli-multi-value";
1041     description
1042       "Specifies the maximum number of allowed words for the key or value.";
1043   }
1044
1045   extension cli-allow-range {
1046     tailf:use-in "leaf";
1047     tailf:use-in "tailf:symlink";
1048     tailf:use-in "refine";
1049     description
1050       "Means that the non-integer key should allow range expressions.
1051
1052        Can be used in key leafs only.
1053
1054        Used in J-, I- and C-style CLIs.";
1055   }
1056
1057   extension cli-range-delimiters {
1058     argument value {
1059       tailf:arg-type {
1060         type string;
1061       }
1062     }
1063     tailf:use-in "list";
1064     tailf:use-in "tailf:symlink";
1065     tailf:use-in "refine";
1066     description
1067       "Allows for custom delimiters to be defined for range expressions.
1068        By default only / is considered a delimiter, ie when processing
1069        a key like 1/2/3 then each of 1, 2 and 3 will be matched separately
1070        agains range expressions, ie given the expression 1-3/5-6/7,8
1071        1 will be matched with 1-3, 2 with 5-6, and 3 with 7,8. If, for
1072        example, the delimiters value is set to '/.' then both '/' and
1073        '.' will be considered delimiters and an key such as 1/2/3.4 will
1074        consist of the enteties 1,2,3,4, all matched separately.
1075
1076        Used in J-, I- and C-style CLIs.";
1077   }
1078
1079   extension cli-suppress-range {
1080     tailf:use-in "leaf";
1081     tailf:use-in "tailf:symlink";
1082     tailf:use-in "refine";
1083     description
1084       "Means that the integer key should not allow range expressions.
1085
1086        Can be used in key leafs only.
1087
1088        Used in J-, I- and C-style CLIs.";
1089   }
1090
1091   extension cli-custom-range {
1092     tailf:use-in "leaf";
1093     tailf:use-in "tailf:symlink";
1094     tailf:use-in "refine";
1095     tailf:substatement "tailf:cli-range-type" {
1096       tailf:occurence "1";
1097     }
1098     description
1099       "Specifies that the key should support ranges.  A type matching the
1100        range expression must be supplied.
1101
1102        Can be used in key leafs only.
1103
1104        Used in J-, I- and C-style CLIs.";
1105   }
1106
1107   extension cli-custom-range-actionpoint {
1108     argument value {
1109       tailf:arg-type {
1110         type tailf:identifier;
1111       }
1112     }
1113     tailf:use-in "list";
1114     tailf:use-in "tailf:symlink";
1115     tailf:use-in "refine";
1116     tailf:substatement "tailf:cli-completion-id";
1117     tailf:substatement "tailf:cli-allow-caching";
1118     description
1119       "Specifies that the list supports range expressions and that a custom
1120        function will be invoked to determine if an instance belong in
1121        the range or not. At least one key element needs a
1122        cli-custom-range statement.
1123
1124        The argument is the name of an actionpoint, which must be
1125        implemented by custom code.  In the actionpoint, the
1126        completion() callback function will be invoked.  See
1127        confd_lib_dp(3) for details.
1128
1129        When a range expression value which matches the type is given in
1130        the CLI, the CLI engine will invoke the callback with each
1131        existing list entry instance.  If the callback returns CONFD_OK,
1132        it matches the range expression, and if it returns CONFD_ERR, it
1133        doesn't match.
1134
1135        Used in J-, I- and C-style CLIs.";
1136   }
1137
1138   extension cli-custom-range-enumerator {
1139     argument value {
1140       tailf:arg-type {
1141         type tailf:identifier;
1142       }
1143     }
1144     tailf:use-in "list";
1145     tailf:use-in "tailf:symlink";
1146     tailf:use-in "refine";
1147     tailf:substatement "tailf:cli-completion-id";
1148     tailf:substatement "tailf:cli-allow-caching";
1149     description
1150       "Specifies a callback to invoke to get an array of
1151        instances matching a regular expression. This is used
1152        when instances should be allowed to be created using
1153        a range expression in set.
1154
1155        The callback is not used for delete or show operations.
1156
1157        The callback is allowed to return a superset of all matching
1158        instances since the instances will be filtered using the
1159        range expression afterwards.
1160
1161        Used in J-, I- and C-style CLIs.";
1162   }
1163
1164   extension cli-range-type {
1165     argument value {
1166       tailf:arg-type {
1167         type string;
1168       }
1169     }
1170     tailf:use-in "tailf:cli-custom-range";
1171     description
1172       "This statement contains the name of a derived type, possibly
1173        with a prefix.  If no prefix is given, the type must be defined in
1174        the local module.  For example:
1175
1176         cli-range-type p:my-range-type;
1177
1178        All range expressions must match this type, and a valid key
1179        value must not match this type.";
1180   }
1181
1182   extension cli-allow-wildcard {
1183     tailf:use-in "list";
1184     tailf:use-in "tailf:symlink";
1185     tailf:use-in "refine";
1186     description
1187       "Means that the list allows wildcard expressions in the 'show' pattern.
1188
1189        See also /confdConfig/cli/allowWildcard in confd.conf(5).
1190
1191        Used in J-, I- and C-style CLIs.";
1192   }
1193
1194   extension cli-suppress-wildcard {
1195     tailf:use-in "list";
1196     tailf:use-in "tailf:symlink";
1197     tailf:use-in "refine";
1198     description
1199       "Means that the list does not allow wildcard expressions in the 'show'
1200        pattern.
1201
1202        See also /confdConfig/cli/allowWildcard in confd.conf(5).
1203
1204        Used in J-, I- and C-style CLIs.";
1205   }
1206
1207   extension cli-configure-mode {
1208     tailf:use-in "tailf:action";
1209     tailf:use-in "rpc";
1210     description
1211       "An action or rpc with this attribute will be available in
1212        configure mode, but not in operational mode.
1213
1214        The default is that the action or rpc is available in both
1215        configure and operational mode.
1216
1217        Used in J-, I- and C-style CLIs.";
1218   }
1219
1220   extension cli-operational-mode {
1221     tailf:use-in "tailf:action";
1222     tailf:use-in "rpc";
1223     description
1224       "An action or rpc with this attribute will be available in
1225        operational mode, but not in configure mode.
1226
1227        The default is that the action or rpc is available in both
1228        configure and operational mode.
1229
1230        Used in J-, I- and C-style CLIs.";
1231   }
1232
1233   extension cli-mount-point {
1234     argument value {
1235       tailf:arg-type {
1236         type string;
1237       }
1238     }
1239     tailf:use-in "tailf:action";
1240     tailf:use-in "rpc";
1241     description
1242       "By default actions are mounted under the 'request'
1243        command in the J-style CLI and at the top-level in
1244        the I- and C-style CLIs. This annotation allowes
1245        the action to be mounted under other top level commands";
1246   }
1247
1248   extension cli-batch-confirm-default {
1249     argument name {
1250       tailf:arg-type {
1251         type boolean;
1252       }
1253     }
1254     tailf:use-in "tailf:confirm-text";
1255     description
1256       "Specifies if the default is to proceed or abort the action during batch
1257        processing in the CLI (e.g. non-interactive mode) when a confirm-text is
1258        set. If this value is not specified, the default value may instead be
1259        provdied by tailf:confirm-default or by the ConfD global default if
1260        specified in a clispec(5).";
1261   }
1262
1263   extension cli-delayed-auto-commit {
1264     tailf:use-in "container";
1265     tailf:use-in "list";
1266     tailf:use-in "tailf:symlink";
1267     tailf:use-in "refine";
1268     description
1269       "Enables transactions while in a specific submode (or submode of that
1270        mode).  The modifications performed in that mode will not take effect
1271        until the user exits that submode.
1272
1273        Can be used in config nodes only.  If used in a container, the
1274        container must also have a tailf:cli-add-mode statement, and if
1275        used in a list, the list must not also have a
1276        tailf:cli-suppress-mode statement.
1277
1278        Used in I- and C-style CLIs.";
1279   }
1280
1281   extension cli-preformatted {
1282     tailf:use-in "leaf";
1283     tailf:use-in "tailf:symlink";
1284     tailf:use-in "refine";
1285     description
1286       "Suppresses quoting of non-config elements when displaying them.
1287        Newlines will be preserved in strings etc.
1288
1289        Used in J-, I- and C-style CLIs.";
1290   }
1291
1292   extension cli-disabled-info {
1293     argument value {
1294       tailf:arg-type {
1295         type string;
1296       }
1297     }
1298     tailf:use-in "leaf";
1299     tailf:use-in "tailf:symlink";
1300     tailf:use-in "refine";
1301     description
1302       "Specifies an info string that will be used as a descriptive text for the
1303        value 'disable' (false) of boolean-typed leafs when the confd.conf(5)
1304        setting /confdConfig/cli/useShortEnabled is set to 'true'.
1305
1306        Used in J-, I- and C-style CLIs.";
1307   }
1308
1309   extension cli-suppress-shortenabled {
1310     tailf:use-in "leaf";
1311     tailf:use-in "tailf:symlink";
1312     tailf:use-in "refine";
1313     description
1314       "Suppresses the confd.conf(5) setting /confdConfig/cli/useShortEnabled.
1315
1316        Used in J-, I- and C-style CLIs.";
1317   }
1318
1319   extension cli-trim-default {
1320     tailf:use-in "leaf";
1321     tailf:use-in "tailf:symlink";
1322     tailf:use-in "refine";
1323     description
1324       "Do not display value if it is same as default.
1325
1326        Used in I- and C-style CLIs.";
1327   }
1328
1329   extension cli-expose-key-name {
1330     tailf:use-in "leaf";
1331     tailf:use-in "tailf:symlink";
1332     tailf:use-in "refine";
1333     description
1334       "Force the user to enter the name of the key and display the
1335        key name when displaying the running-configuration.
1336
1337        Used in J-, I- and C-style CLIs.";
1338   }
1339
1340   extension cli-enforce-table {
1341     tailf:use-in "list";
1342     tailf:use-in "tailf:symlink";
1343     tailf:use-in "refine";
1344     description
1345       "Forces the generation of a table for a list element node regardless of
1346        whether the table will be too wide or not.  This applies to the
1347        tables generated by the auto-rendred show commands for non-config data.
1348
1349        Used in I- and C-style CLIs.";
1350   }
1351
1352   extension cli-drop-node-name {
1353     tailf:use-in "leaf";
1354     tailf:use-in "container";
1355     tailf:use-in "list";
1356     tailf:use-in "leaf-list";
1357     tailf:use-in "tailf:symlink";
1358     tailf:use-in "refine";
1359     description
1360       "Specifies that the name of a node is not present in the CLI.
1361
1362        If tailf:cli-drop-node-name is given on a child to a list node,
1363        we recommend that you also use tailf:cli-suppress-mode on that
1364        list node, otherwise the CLI will be very confusing.
1365
1366        For example, consider this data model, from the tailf-aaa module:
1367
1368        list alias {
1369         key name;
1370         leaf name {
1371           type string;
1372         }
1373         leaf expansion {
1374           type string;
1375           mandatory true;
1376           tailf:cli-drop-node-name;
1377         }
1378        }
1379
1380        If you type 'alias foo' in the CLI, you would end up in the
1381        'alias' submode.  But since the expansion is dropped, you would
1382        end up specifying the expansion value without typing any command.
1383
1384        If, on the other hand, the 'alias' list had a
1385        tailf:cli-suppress-mode statement, you would set an expansion
1386        'bar' by typing 'alias foo bar'.
1387
1388        tailf:cli-drop-node-name cannot be used inside tailf:action.
1389
1390        Used in I- and C-style CLIs.";
1391   }
1392
1393   extension cli-no-keyword {
1394     tailf:use-in "leaf";
1395     tailf:use-in "container";
1396     tailf:use-in "list";
1397     tailf:use-in "leaf-list";
1398     tailf:use-in "tailf:symlink";
1399     tailf:use-in "refine";
1400     description
1401       "Specifies that the name of a node is not present in the CLI.
1402
1403
1404        Note that is must be used with some care, just
1405        like tailf:cli-drop-node-name. The resulting data model must still
1406        be possible to parse deterministically.
1407        For example, consider the data model
1408
1409        container interfaces {
1410           list traffic {
1411               tailf:cli-no-keyword;
1412               key id;
1413               leaf id { type string; }
1414               leaf mtu { type uint16; }
1415           }
1416           list management {
1417               tailf:cli-no-keyword;
1418               key id;
1419               leaf id { type string; }
1420               leaf mtu { type uint16; }
1421           }
1422        }
1423
1424        In this case it is impossible to determine if the config
1425
1426        interfaces {
1427           eth0 {
1428              mtu 1400;
1429            }
1430        }
1431
1432        Means that there should be an traffic interface instance named
1433        'eth0' or a management interface instance maned 'eth0'. If, on
1434        the other hand, a restriction on the type was used, for example
1435
1436        container interfaces {
1437           list traffic {
1438               tailf:cli-no-keyword;
1439               key id;
1440               leaf id { type string; pattern 'eth.*'; }
1441               leaf mtu { type uint16; }
1442           }
1443           list management {
1444               tailf:cli-no-keyword;
1445               key id;
1446               leaf id { type string; pattern 'lo.*';}
1447               leaf mtu { type uint16; }
1448           }
1449        }
1450
1451        then the problem would disappear.
1452
1453        Used in the J-style CLIs.";
1454   }
1455
1456   extension cli-compact-syntax {
1457     tailf:use-in "list";
1458     tailf:use-in "container";
1459     tailf:use-in "tailf:symlink";
1460     tailf:use-in "refine";
1461     description
1462       "Instructs the CLI engine to use the compact representation for this
1463        node in the 'show running-configuration' command.  The compact
1464        representation means that all leaf elements are shown on a
1465        single line.
1466
1467        Cannot be used in conjunction with tailf:cli-boolean-no.
1468
1469        Used in I- and C-style CLIs.";
1470   }
1471
1472   extension cli-compact-stats {
1473     tailf:use-in "list";
1474     tailf:use-in "container";
1475     tailf:use-in "tailf:symlink";
1476     tailf:use-in "refine";
1477     tailf:substatement "tailf:cli-wrap";
1478     tailf:substatement "tailf:cli-width";
1479     tailf:substatement "tailf:cli-delimiter";
1480     tailf:substatement "tailf:cli-prettify";
1481     tailf:substatement "tailf:cli-spacer";
1482     description
1483       "Instructs the CLI engine to use the compact representation for this
1484        node.  The compact representation means that all leaf elements
1485        are shown on a single line.
1486
1487        Used in J-, I- and C-style CLIs.";
1488   }
1489
1490   extension cli-wrap {
1491     tailf:use-in "tailf:cli-compact-stats";
1492     description
1493       "If present, the line will be wrapped at screen width.";
1494   }
1495
1496   extension cli-width {
1497     argument value {
1498       tailf:arg-type {
1499         type uint32;
1500       }
1501     }
1502     tailf:use-in "tailf:cli-compact-stats";
1503     description
1504       "Specifies a fixed terminal width to use before wrapping line. It is
1505        only used when tailf:cli-wrap is present.  If a width is not
1506        specified the line is wrapped when the terminal width is
1507        reached.";
1508   }
1509
1510   extension cli-delimiter {
1511     argument value {
1512       tailf:arg-type {
1513         type string;
1514       }
1515     }
1516     tailf:use-in "tailf:cli-compact-stats";
1517     description
1518       "Specifies a string to print between the leaf name and its value
1519        when displaying leaf values.";
1520   }
1521
1522   extension cli-prettify {
1523     tailf:use-in "tailf:cli-compact-stats";
1524     description
1525       "If present, dashes (-) and underscores (_) in leaf names are replaced
1526        with spaces.";
1527   }
1528
1529   extension cli-spacer {
1530     argument value {
1531       tailf:arg-type {
1532         type string;
1533       }
1534     }
1535     tailf:use-in "tailf:cli-compact-stats";
1536     description
1537       "Specifies a string to print between the nodes.";
1538   }
1539
1540   extension cli-column-stats {
1541     tailf:use-in "container";
1542     tailf:use-in "refine";
1543     tailf:use-in "tailf:symlink";
1544     description
1545       "Display leafs in the container as columns, i.e., do not repeat
1546        the name of the container on each line, but instead indent each
1547        leaf under the container.
1548
1549        Used in I- and C-style CLIs.";
1550   }
1551
1552   extension cli-column-width {
1553     argument value {
1554       tailf:arg-type {
1555         type uint32;
1556       }
1557     }
1558     tailf:use-in "leaf";
1559     tailf:use-in "leaf-list";
1560     tailf:use-in "tailf:symlink";
1561     tailf:use-in "refine";
1562     description
1563       "Set a fixed width for the column in the auto-rendered tables.
1564
1565        Used in J-, I- and C-style CLIs.";
1566   }
1567
1568   extension cli-min-column-width {
1569     argument value {
1570       tailf:arg-type {
1571         type uint32;
1572       }
1573     }
1574     tailf:use-in "leaf";
1575     tailf:use-in "leaf-list";
1576     tailf:use-in "tailf:symlink";
1577     tailf:use-in "refine";
1578     description
1579       "Set a minimum width for the column in the auto-rendered tables.
1580
1581        Used in J-, I- and C-style CLIs.";
1582   }
1583
1584   extension cli-column-align {
1585     argument value {
1586       tailf:arg-type {
1587         type enumeration {
1588           enum "left";
1589           enum "center";
1590           enum "right";
1591         }
1592       }
1593     }
1594     tailf:use-in "leaf";
1595     tailf:use-in "leaf-list";
1596     tailf:use-in "tailf:symlink";
1597     tailf:use-in "refine";
1598     description
1599       "Specifies the alignment of the data in the column in the
1600        auto-rendered tables.
1601
1602        Used in J-, I- and C-style CLIs.";
1603   }
1604
1605   extension cli-list-syntax {
1606     tailf:use-in "leaf-list";
1607     tailf:use-in "tailf:symlink";
1608     tailf:use-in "refine";
1609     tailf:substatement "tailf:cli-multi-word";
1610     description
1611       "Specifies that each entry in a leaf-list should be displayed as
1612        a separate element.
1613
1614        Used in J-, I- and C-style CLIs.";
1615   }
1616
1617   extension cli-multi-word {
1618     tailf:use-in "tailf:cli-list-syntax";
1619     tailf:substatement "tailf:cli-max-words";
1620     description
1621       "Specifies that a multi-word value may be entered without quotes.";
1622   }
1623
1624   extension cli-flat-list-syntax {
1625     tailf:use-in "leaf-list";
1626     tailf:substatement "tailf:cli-replace-all";
1627     tailf:use-in "refine";
1628     description
1629       "Specifies that elements in a leaf-list should be entered without
1630        surrounding brackets. Also, multiple elements can be added to a list
1631        or deleted from a list.
1632
1633        Used in J-, I- and C-style CLIs.";
1634   }
1635
1636   extension cli-replace-all {
1637     tailf:use-in "leaf-list";
1638     tailf:use-in "tailf:cli-flat-list-syntax";
1639     tailf:use-in "refine";
1640     description
1641       "Specifies that the new leaf-list value(s) should replace the old,
1642        as opposed to be added to the old leaf-list.";
1643   }
1644
1645   extension cli-range-list-syntax {
1646     tailf:use-in "leaf-list";
1647     tailf:use-in "list";
1648     tailf:use-in "refine";
1649     description
1650       "Specifies that elements in a leaf-list or a list should be entered
1651        without surrounding brackets and presented as ranges.  The
1652        element in the list should be separated by a comma.  For
1653        example:
1654
1655         vlan 1,3,10-20,30,32,300-310
1656
1657        When this statement is used for lists, the list must have a
1658        single key.  The elements are be presented as ranges as above.
1659
1660        The type of the list key, or the leaf-list, must be integer based.
1661
1662        Used in J-, I- and C-style CLIs.";
1663   }
1664
1665   extension cli-incomplete-command {
1666     tailf:use-in "leaf";
1667     tailf:use-in "leaf-list";
1668     tailf:use-in "list";
1669     tailf:use-in "container";
1670     tailf:use-in "refine";
1671     description
1672       "Specifies that an auto-rendered command should be considered
1673        incomplete.  Can be used to prevent <cr> from appearing in
1674        the completion list for optional internal nodes, for example, or
1675        to ensure that the user enters all leaf values in a container
1676        (if used in combination with cli-sequence-commands).
1677
1678        Used in I- and C-style CLIs.";
1679   }
1680
1681   extension cli-full-command {
1682     tailf:use-in "leaf";
1683     tailf:use-in "leaf-list";
1684     tailf:use-in "list";
1685     tailf:use-in "tailf:symlink";
1686     tailf:use-in "container";
1687     tailf:use-in "refine";
1688     description
1689       "Specifies that an auto-rendered command should be considered complete,
1690        ie, no additional leaves or containers can be entered on the same
1691        command line.
1692
1693        Used in I- and C-style CLIs.";
1694   }
1695
1696   extension cli-sequence-commands {
1697     tailf:use-in "list";
1698     tailf:use-in "container";
1699     tailf:use-in "tailf:symlink";
1700     tailf:use-in "refine";
1701     tailf:substatement "tailf:cli-reset-siblings";
1702     tailf:substatement "tailf:cli-reset-all-siblings";
1703     description
1704       "Specifies that an auto-rendered command should only accept arguments
1705        in the same order as they are specified in the YANG model.
1706        This, in combination with tailf:cli-drop-node-name, can be used
1707        to create CLI commands for setting multiple leafs in a container
1708        without having to specify the leaf names.
1709
1710        In almost all cases this annotation should be accompanied by the
1711        tailf:cli-compact-syntax annotation. Otherwise the output from
1712        'show running-config' will not be correct, and the sequence
1713        'save xx' 'load override xx' will not work.
1714
1715        Used in I- and C-style CLIs.";
1716   }
1717
1718   extension cli-reset-siblings {
1719     tailf:use-in "tailf:cli-sequence-commands";
1720     description
1721       "Specifies that all sibling leaves in the sequence should be reset
1722        whenever the first leaf in the sequence is set.";
1723   }
1724
1725   extension cli-reset-all-siblings {
1726     tailf:use-in "tailf:cli-sequence-commands";
1727     description
1728       "Specifies that all sibling leaves in the container should be reset
1729        whenever the first leaf in the sequence is set.";
1730   }
1731
1732   extension cli-reset-container {
1733     tailf:use-in "leaf";
1734     tailf:use-in "list";
1735     tailf:use-in "container";
1736     tailf:use-in "tailf:symlink";
1737     tailf:use-in "refine";
1738     description
1739       "Specifies that all sibling leaves in the container should be
1740        reset when this element is set.
1741
1742        When used on a container its content is cleared when set.";
1743   }
1744
1745   extension cli-display-separated {
1746     tailf:use-in "container";
1747     tailf:use-in "tailf:symlink";
1748     tailf:use-in "refine";
1749     description
1750       "Tells CLI engine to display this container as a separate
1751        line item even when it has children. Only applies to
1752        presence containers.
1753
1754        Applicable for optional containers in the C- and I- style CLIs.";
1755   }
1756
1757   extension cli-delete-container-on-delete {
1758     tailf:use-in "leaf";
1759     tailf:use-in "tailf:symlink";
1760     tailf:use-in "refine";
1761     description
1762       "Specifies that the parent container should be deleted when
1763        .      this leaf is deleted.";
1764   }
1765
1766   extension cli-break-sequence-commands {
1767     tailf:use-in "leaf";
1768     tailf:use-in "tailf:symlink";
1769     tailf:use-in "leaf-list";
1770     tailf:use-in "list";
1771     tailf:use-in "container";
1772     tailf:use-in "refine";
1773     description
1774       "Specifies that previous cli-sequence-command declaration should
1775        stop at this point. Only applicable when a cli-sequence-command
1776        declaration has been used in the parent container.
1777
1778        Used in I- and C-style CLIs.";
1779   }
1780
1781   extension cli-strict-leafref {
1782     tailf:use-in "leaf";
1783     tailf:use-in "leaf-list";
1784     tailf:use-in "tailf:symlink";
1785     tailf:use-in "refine";
1786     description
1787       "Specifies that the leaf should only be allowed to be assigned
1788        references to existing instances when the command is executed.
1789        Without this annotation the requirement is that the instance
1790        exists on commit time.
1791
1792        Used in I- and C-style CLIs.";
1793   }
1794
1795   extension cli-optional-in-sequence {
1796     tailf:use-in "leaf";
1797     tailf:use-in "tailf:symlink";
1798     tailf:use-in "leaf-list";
1799     tailf:use-in "list";
1800     tailf:use-in "container";
1801     tailf:use-in "refine";
1802     description
1803       "Specifies that this element is optional in the sequence. If it
1804        is set it must be set in the right sequence but may be skipped.
1805
1806        Used in I- and C-style CLIs.";
1807   }
1808
1809   extension cli-incomplete-show-path {
1810     tailf:use-in "leaf";
1811     tailf:use-in "tailf:symlink";
1812     tailf:use-in "leaf-list";
1813     tailf:use-in "list";
1814     tailf:use-in "container";
1815     tailf:use-in "refine";
1816     tailf:substatement "tailf:cli-min-keys";
1817     description
1818       "Specifies that a path to the show command is considered incomplete,
1819        i.e., it needs more elements added to the path.  It can also be used
1820        to specify a minimum number of keys to be given for lists.
1821
1822        Used in J-, I- and C-style CLIs.";
1823   }
1824
1825   extension cli-min-keys {
1826     argument value {
1827       tailf:arg-type {
1828         type uint32;
1829       }
1830     }
1831     tailf:use-in "tailf:cli-incomplete-show-path";
1832     description
1833       "Specifies the minimum number of required keys for the show command.";
1834   }
1835
1836   extension cli-hide-in-submode {
1837     tailf:use-in "leaf";
1838     tailf:use-in "container";
1839     tailf:use-in "tailf:symlink";
1840     tailf:use-in "refine";
1841     description
1842       "Hide leaf when submode has been entered. Mostly useful when
1843        leaf has to be entered in order to enter a submode. Also works
1844        for flattened containers.
1845
1846        Cannot be used in conjunction with tailf:cli-boolean-no.
1847
1848        Used in I- and C-style CLIs.";
1849   }
1850
1851   extension cli-expose-ns-prefix {
1852     tailf:use-in "container";
1853     tailf:use-in "list";
1854     tailf:use-in "tailf:symlink";
1855     tailf:use-in "refine";
1856     description
1857       "When used force the CLI to display namespace prefix of all children.";
1858   }
1859
1860   extension cli-prefix-key {
1861     tailf:use-in "leaf";
1862     tailf:use-in "tailf:symlink";
1863     tailf:use-in "refine";
1864     tailf:use-in "leaf-list";
1865     tailf:substatement "tailf:cli-before-key";
1866     description
1867       "This leaf has to be given as a prefix before entering the actual
1868        list keys. Very backwards but a construct that exists in some
1869        Cisco CLIs.
1870
1871        The construct can be used also for leaf-lists but only when
1872        then tailf:cli-range-list-syntax is also used.
1873
1874        Used in I- and C-style CLIs.";
1875   }
1876
1877   extension cli-before-key {
1878     argument value {
1879       tailf:arg-type {
1880         type uint32;
1881       }
1882     }
1883     tailf:use-in "tailf:cli-prefix-key";
1884     description
1885       "Specifies before which key the prefix element should be inserted.
1886        The first key has number 1.";
1887   }
1888
1889   extension cli-show-with-default {
1890     tailf:use-in "leaf";
1891     tailf:use-in "refine";
1892     tailf:use-in "tailf:symlink";
1893     description
1894       "This leaf will be displayed even when it has its default value.
1895        Note that this will somewhat result in a slightly different behaviour
1896        when you save a config and then load it again. With this setting
1897        in place a leaf that has not been configured will be configured
1898        after the load.
1899
1900        Used in I- and C-style CLIs.";
1901   }
1902
1903   extension cli-oper-info {
1904     argument text {
1905       yin-element true;
1906       tailf:arg-type {
1907         type string;
1908       }
1909     }
1910     tailf:use-in "leaf";
1911     tailf:use-in "leaf-list";
1912     tailf:use-in "list";
1913     tailf:use-in "container";
1914     tailf:use-in "rpc";
1915     tailf:use-in "identity";
1916     tailf:use-in "tailf:action";
1917     tailf:use-in "tailf:symlink";
1918     tailf:use-in "refine";
1919     description
1920       "This statement works exactly as tailf:info, with the exception
1921        that it is used when displaying the element info in the context
1922        of stats.
1923
1924        Both tailf:info and tailf:cli-oper-info can be present at the same
1925        time.";
1926   }
1927
1928   extension cli-case-sensitive {
1929     tailf:use-in "container";
1930     tailf:use-in "list";
1931     tailf:use-in "leaf";
1932     description
1933       "Specifies that this node is case-sensitive.
1934        If applied to a container or a list, any nodes below will
1935        also be case-sensitive.
1936
1937        Note that this will override any case-sensitivity settings
1938        configured in confd.conf";
1939   }
1940
1941   extension cli-case-insensitive {
1942     tailf:use-in "container";
1943     tailf:use-in "list";
1944     tailf:use-in "leaf";
1945     description
1946       "Specifies that node is case-insensitive.
1947        If applied to a container or a list, any nodes below will
1948        also be case-insensitive.
1949
1950        Note that this will override any case-insensitivity settings
1951        configured in confd.conf";
1952   }
1953
1954   extension cli-custom-error {
1955     argument text {
1956       yin-element true;
1957       tailf:arg-type {
1958         type string;
1959       }
1960     }
1961     tailf:use-in "leaf";
1962     tailf:use-in "tailf:symlink";
1963     tailf:use-in "refine";
1964     description
1965       "This statement specifies a custom error message to be displayed
1966        when the user enters an invalid value.";
1967   }
1968
1969   extension cli-full-show-path {
1970     tailf:use-in "leaf";
1971     tailf:use-in "leaf-list";
1972     tailf:use-in "list";
1973     tailf:use-in "container";
1974     tailf:use-in "tailf:symlink";
1975     tailf:use-in "refine";
1976     tailf:substatement "tailf:cli-max-keys";
1977     description
1978       "Specifies that a path to the show command is considered complete, i.e.,
1979        no more elements can be added to the path.  It can also be used to
1980        specify a maximum number of keys to be given for lists.
1981
1982        Used in J-, I- and C-style CLIs.";
1983   }
1984
1985   extension cli-max-keys {
1986     argument value {
1987       tailf:arg-type {
1988         type uint32;
1989       }
1990     }
1991     tailf:use-in "tailf:cli-full-show-path";
1992     description
1993       "Specifies the maximum number of allowed keys for the show command.";
1994   }
1995
1996   extension cli-suppress-show-path {
1997     tailf:use-in "leaf";
1998     tailf:use-in "leaf-list";
1999     tailf:use-in "list";
2000     tailf:use-in "tailf:symlink";
2001     tailf:use-in "container";
2002     tailf:use-in "refine";
2003     description
2004       "Specifies that the show command cannot be invoked with the path,
2005        ie the path is suppressed when auto-rendering show commands for
2006        config='false' data.
2007
2008        Used in J-, I- and C-style CLIs.";
2009   }
2010
2011   extension cli-suppress-show-match {
2012     tailf:use-in "leaf";
2013     tailf:use-in "leaf-list";
2014     tailf:use-in "list";
2015     tailf:use-in "tailf:symlink";
2016     tailf:use-in "container";
2017     tailf:use-in "refine";
2018     description
2019       "Specifies that a specific completion match (i.e., a filter match that
2020        appear at list nodes as an alternative to specifying a single
2021        instance) to the show command should not be available.
2022
2023        Used in J-, I- and C-style CLIs.";
2024   }
2025
2026   extension cli-suppress-list-no {
2027     tailf:use-in "leaf-list";
2028     tailf:use-in "list";
2029     tailf:use-in "tailf:symlink";
2030     tailf:use-in "refine";
2031     description
2032       "Specifies that the CLI should not accept deletion of the entire list
2033        or leaf-list. Only specific instances should be deletable not the
2034        entire list in one command. ie, 'no foo <instance>' should be allowed
2035        but not 'no foo'.
2036
2037        Used in I- and C-style CLIs.";
2038   }
2039
2040   extension cli-suppress-no {
2041     tailf:use-in "leaf";
2042     tailf:use-in "leaf-list";
2043     tailf:use-in "list";
2044     tailf:use-in "tailf:symlink";
2045     tailf:use-in "container";
2046     tailf:use-in "refine";
2047     description
2048       "Specifies that the CLI should not auto-render 'no' commands for
2049        this element. An element with this annotation will not appear in the
2050        completion list to the 'no' command.
2051
2052        Used in I- and C-style CLIs.";
2053   }
2054
2055   extension cli-suppress-silent-no {
2056     argument value {
2057       tailf:arg-type {
2058         type string;
2059       }
2060     }
2061     tailf:use-in "leaf";
2062     tailf:use-in "leaf-list";
2063     tailf:use-in "list";
2064     tailf:use-in "tailf:symlink";
2065     tailf:use-in "container";
2066     tailf:use-in "refine";
2067     description
2068       "Specifies that the confd.cnof directive cSilentNo should be
2069        suppressed for a leaf and that a custom error message should
2070        be displayed when the user attempts to delete a non-existing
2071        element.
2072
2073        Used in I- and C-style CLIs.";
2074   }
2075
2076   extension cli-full-no {
2077     tailf:use-in "leaf";
2078     tailf:use-in "leaf-list";
2079     tailf:use-in "list";
2080     tailf:use-in "tailf:symlink";
2081     tailf:use-in "container";
2082     tailf:use-in "refine";
2083     description
2084       "Specifies that an auto-rendered 'no'-command should be considered complete,
2085        ie, no additional leaves or containers can be entered on the same
2086        command line.
2087
2088        Used in I- and C-style CLIs.";
2089   }
2090
2091   extension cli-incomplete-no {
2092     tailf:use-in "leaf";
2093     tailf:use-in "leaf-list";
2094     tailf:use-in "list";
2095     tailf:use-in "container";
2096     tailf:use-in "tailf:symlink";
2097     tailf:use-in "refine";
2098     description
2099       "Specifies that an auto-rendered 'no'-command should not be considered
2100        complete, ie, additional leaves or containers must be entered on the same
2101        command line.
2102
2103        Used in I- and C-style CLIs.";
2104   }
2105
2106   extension cli-no-match-completion {
2107     tailf:use-in "list";
2108     tailf:use-in "tailf:symlink";
2109     tailf:use-in "refine";
2110     description
2111       "Specifies that the CLI engine should not provide match completion
2112        for the key leafs in the list.
2113
2114        Used in J-, I- and C-style CLIs.";
2115   }
2116
2117   extension cli-suppress-show-conf-path {
2118     tailf:use-in "leaf";
2119     tailf:use-in "leaf-list";
2120     tailf:use-in "list";
2121     tailf:use-in "container";
2122     tailf:use-in "tailf:symlink";
2123     tailf:use-in "refine";
2124     description
2125       "Specifies that the show running-config command cannot be invoked with
2126        the path, ie the path is suppressed when auto-rendering show running-
2127        config commands for config='true' data.
2128
2129        Used in J-, I- and C-style CLIs.";
2130   }
2131
2132   extension cli-no-key-completion {
2133     tailf:use-in "list";
2134     tailf:use-in "tailf:symlink";
2135     tailf:use-in "refine";
2136     description
2137       "Specifies that the CLI engine should not perform completion for key
2138        leafs in the list. This is to avoid querying the data provider
2139        for all existing keys.
2140
2141        Used in J-, I- and C-style CLIs.";
2142   }
2143
2144   extension cli-instance-info-leafs {
2145     argument value {
2146       tailf:arg-type {
2147         type string;
2148       }
2149     }
2150     tailf:use-in "list";
2151     tailf:use-in "tailf:symlink";
2152     tailf:use-in "refine";
2153     description
2154       "This statement is used to specifiy how list entries are displayed
2155        when doing completion in the CLI.  By default, a list entry is
2156        displayed by listing its key values, and the value of a leaf
2157        called 'description', if such a leaf exists in the list entry.
2158
2159        The 'cli-instance-info-leafs' statement takes as its argument a
2160        space separated string of leaf names.  When a list entry is
2161        displayed, the values of these leafs are concatenated with a
2162        space character as separator and shown to the user.
2163
2164        For example, when asked to specify an interface the CLI will
2165        display a list of possible interface instances, say 1 2 3 4.  If
2166        the cli-instance-info-leafs property is set to 'description' then
2167        the CLI might show:
2168
2169         Possible completions:
2170           1 - internet
2171           2 - lab
2172           3 - dmz
2173           4 - wlan
2174
2175        Used in J-, I- and C-style CLIs.";
2176   }
2177
2178   extension cli-multi-value {
2179     tailf:use-in "leaf";
2180     tailf:use-in "tailf:symlink";
2181     tailf:use-in "refine";
2182     tailf:substatement "tailf:cli-max-words";
2183     description
2184       "Specifies that all remaining tokens on the command line
2185        should be considered a value for this leaf. This prevents
2186        the need for quoting values containing spaces, but also
2187        prevents multiple leaves from being set on the same command
2188        line once a multi-value leaf has been given on a line.
2189
2190        If the tailf:cli-max-words substatements is used then
2191        additional leaves may be entered.
2192
2193        Used in I- and C-style CLIs.";
2194   }
2195
2196   extension cli-value-display-template {
2197     argument value {
2198       yin-element true;
2199       tailf:arg-type {
2200         type tailf:cli-template-string;
2201       }
2202     }
2203     tailf:use-in "leaf";
2204     tailf:use-in "tailf:symlink";
2205     tailf:use-in "refine";
2206     description
2207       "Specifies a template string to be used when formating the
2208        value of a leaf for display. Note that other leaves cannot
2209        be referenced from a display template of one leaf. The only
2210        value accessible is the leaf's own value, accessed through
2211        $(.).
2212
2213        See the defintion of cli-template-string for more info.
2214
2215        Used in J-, I- and C-style CLIs.";
2216   }
2217
2218   extension cli-show-template {
2219     argument value {
2220       yin-element true;
2221       tailf:arg-type {
2222         type tailf:cli-template-string;
2223       }
2224     }
2225     tailf:use-in "leaf";
2226     tailf:use-in "leaf-list";
2227     tailf:use-in "list";
2228     tailf:use-in "tailf:symlink";
2229     tailf:use-in "container";
2230     tailf:use-in "refine";
2231     tailf:substatement "tailf:cli-auto-legend";
2232     description
2233       "Specifies a template string to be used by the 'show' command in
2234        operational mode.  It is primarily intended for displaying
2235        non-config data but config data may be included in the template
2236        as well.
2237
2238        See the defintion of cli-template-string for more info.
2239
2240        Some restrictions includes not applying templates on a leaf that
2241        is the key in a list. It is recommended to use the template
2242        directly on the list to format the whole list instead.
2243
2244        Used in J-, I- and C-style CLIs.";
2245   }
2246
2247   extension cli-auto-legend {
2248     tailf:use-in "tailf:cli-show-template";
2249     description
2250       "Specifies that the legend should be automatically rendered if not already displayed. Useful when using templates for rendering tables.";
2251   }
2252
2253   extension cli-show-template-legend {
2254     argument value {
2255       yin-element true;
2256       tailf:arg-type {
2257         type tailf:cli-template-string;
2258       }
2259     }
2260     tailf:use-in "list";
2261     tailf:use-in "refine";
2262     description
2263       "Specifies a template string to be printed before all list entries are
2264        printed.
2265
2266        See the defintion of cli-template-string for more info.
2267
2268        Used in J-, I- and C-style CLIs.";
2269   }
2270
2271   extension cli-show-template-enter {
2272     argument value {
2273       yin-element true;
2274       tailf:arg-type {
2275         type tailf:cli-template-string;
2276       }
2277     }
2278     tailf:use-in "list";
2279     tailf:use-in "tailf:symlink";
2280     tailf:use-in "refine";
2281     description
2282       "Specifies a template string to be printed before each list entry is
2283        printed.
2284
2285        See the defintion of cli-template-string for more info.
2286
2287        Used in J-, I- and C-style CLIs.";
2288   }
2289
2290   extension cli-show-template-footer {
2291     argument value {
2292       yin-element true;
2293       tailf:arg-type {
2294         type tailf:cli-template-string;
2295       }
2296     }
2297     tailf:use-in "list";
2298     tailf:use-in "tailf:symlink";
2299     tailf:use-in "refine";
2300     description
2301       "Specifies a template string to be printed after all list entries are
2302        printed.
2303
2304        See the defintion of cli-template-string for more info.
2305
2306        Used in J-, I- and C-style CLIs.";
2307   }
2308
2309   extension cli-run-template {
2310     argument value {
2311       yin-element true;
2312       tailf:arg-type {
2313         type tailf:cli-template-string;
2314       }
2315     }
2316     tailf:use-in "leaf";
2317     tailf:use-in "leaf-list";
2318     tailf:use-in "tailf:symlink";
2319     tailf:use-in "refine";
2320     description
2321       "Specifies a template string to be used by the 'show running-config'
2322        command in operational mode.  It is primarily intended for displaying
2323        config data but non-config data may be included in the template
2324        as well.
2325
2326        See the defintion of cli-template-string for more info.
2327
2328        Used in I- and C-style CLIs.";
2329   }
2330
2331   extension cli-run-template-legend {
2332     argument value {
2333       yin-element true;
2334       tailf:arg-type {
2335         type tailf:cli-template-string;
2336       }
2337     }
2338     tailf:use-in "list";
2339     tailf:use-in "tailf:symlink";
2340     tailf:use-in "refine";
2341     description
2342       "Specifies a template string to be printed before all list entries are
2343        printed.
2344
2345        See the defintion of cli-template-string for more info.
2346
2347        Used in I- and C-style CLIs.";
2348   }
2349
2350   extension cli-run-template-enter {
2351     argument value {
2352       yin-element true;
2353       tailf:arg-type {
2354         type tailf:cli-template-string;
2355       }
2356     }
2357     tailf:use-in "list";
2358     tailf:use-in "container";
2359     tailf:use-in "tailf:symlink";
2360     tailf:use-in "refine";
2361     description
2362       "Specifies a template string to be printed before each list entry is
2363        printed.
2364
2365        When used on a container it only has effect when the container
2366        also has a tailf:cli-add-mode, and when tailf:cli-show-no isn't
2367        used on the container.
2368
2369        See the defintion of cli-template-string for more info.
2370
2371        The variable .reenter is set to 'true' when the 'show configuration'
2372        command is executed and the list or container isn't created. This
2373        allow, for example, to display
2374
2375           create foo
2376
2377        when an instance is created
2378
2379           edit foo
2380
2381        when something inside the instance is modified.
2382
2383        Used in I- and C-style CLIs.";
2384   }
2385
2386   extension cli-run-template-footer {
2387     argument value {
2388       yin-element true;
2389       tailf:arg-type {
2390         type tailf:cli-template-string;
2391       }
2392     }
2393     tailf:use-in "list";
2394     tailf:use-in "tailf:symlink";
2395     tailf:use-in "refine";
2396     description
2397       "Specifies a template string to be printed after all list entries are
2398        printed.
2399
2400        See the defintion of cli-template-string for more info.
2401
2402        Used in I- and C-style CLIs.";
2403   }
2404
2405   typedef cli-template-string {
2406     type string;
2407     description
2408       "A template is a text string which is expanded by the CLI engine,
2409        and then displayed to the user.
2410
2411        The template may contain a mix of text and expandable entries.
2412        Expandable entries all start with $( and end with a matching ).
2413        Parentheses and dollar signs need to be quoted in plain text.
2414
2415        The template is expanded as follows:
2416
2417        A parameter is either a relative or absolute path to a leaf
2418        element (eg /foo/bar, foo/bar), or one of the builtin variables:
2419        .selected, .entered, .legend_shown, .user, .groups, .ip,
2420        .display_groups, .path, .ipath or .licounter. In addition the
2421        variables .spath and  .ispath are available when a command
2422        is executed from a show path.
2423
2424        .selected
2425
2426            The .selected variable contains the list of selected paths
2427            to be shown. The show template can inspect this element to
2428            determine if a given element should be displayed or
2429            not. For example:
2430
2431                $(.selected~=hwaddr?HW Address)
2432
2433        .entered
2434
2435            The .entered variable is true if the \"entered\" text has
2436            been displayed (either the auto generated text or a
2437            showTemplateEnter). This is useful when having a non-table
2438            template where each instance should have a text.
2439
2440                $(.entered?:host $(name))
2441
2442        .legend_shown
2443
2444            The .legend_shown variable is true if the \"legend\" text has
2445            been displayed (either the auto generated table header or
2446            a showTemplateLegend). This is useful to inspect when
2447            displaying a table row. If the user enteres the path to a
2448            specific instance the builtin table header will not be
2449            displayed and the showTemplateLegend will not be invoked
2450            and it may be useful to render the legend specifically
2451            for this instance.
2452
2453                $(.legend_shown!=true?Address         Interface)
2454
2455        .user
2456
2457            The .user variable contains the name of the current
2458            user. This can be used for differentiating the content
2459            displayed for a specific user, or in paths. For exapmle:
2460
2461                $(user{$(.user)}/settings)
2462
2463        .groups
2464
2465            The .groups variable contains the a list of groups that the
2466            user belongs to.
2467
2468        .display_groups
2469
2470            The .display_groups variable contains a list of selected
2471            display groups. This can be used to display different
2472            content depending on the selected display group. For
2473            example:
2474
2475                $(.display_groups~=details?details...)
2476
2477        .ip
2478
2479            The .ip variable contains the ip address that the user
2480            connected from.
2481
2482        .path
2483
2484            The .path variable contains the path to the entry,
2485            formated in CLI style.
2486
2487        .ipath
2488
2489            The .ipath variable contains the path to the entry,
2490            formated in template style.
2491
2492        .spath
2493
2494            The .spath variable contains the show path,
2495            formated in CLI style.
2496
2497        .ispath
2498
2499            The .ispath variable contains the show path,
2500            formated in template style.
2501
2502        .licounter
2503
2504            The .licounter variable contains a counter that is
2505            incremented for each instance in a list. This means that
2506            it will be 0 in the legend, contain the total number of
2507            list instances in the footer and something in between in
2508            the basic show template.
2509
2510        $(parameter)
2511
2512         The value of 'parameter' is substituted.
2513
2514        $(cond?word1:word2)
2515
2516         The expansion of 'word1' is substituted if 'cond'
2517         evaluates to true, otherwise the expansion of 'word2' is
2518         substituted.
2519
2520         'cond' may be one of
2521
2522           parameter
2523
2524             Evaluates to true if the node exists.
2525
2526           parameter == <value>
2527
2528             Evaluates to true if the value of the parameter equals
2529             <value>.
2530
2531           parameter != <value>
2532
2533             Evalutes to true if the value of the parameter does not
2534             equal <value>
2535
2536           parameter ~= <value>
2537
2538             Provided that the value of the parameter is a list
2539             (i.e., the node that the parameter refers to is a
2540             leaf-list), this expression evaluates to true if <value>
2541             is a member of the list.
2542
2543        $(parameter|filter)
2544
2545         The value of 'parameter' processed by 'filter' is
2546         substituted. Filters may be either one of the
2547         built-ins or a customized filter defined in a
2548         callback. See /confdConfig/cli/templateFilter.
2549
2550         A built-in 'filter' may be one of:
2551
2552           capfirst
2553
2554             Capitalizes the first character of the value.
2555
2556           lower
2557
2558             Converts the value into lowercase.
2559
2560           upper
2561
2562             Converts the value into uppercase.
2563
2564           filesizeformat
2565
2566             Formats the value in a human-readable format (e.g.,
2567             '13 KB', '4.10 MB',  '102 bytes' etc), where  K
2568              means 1024, M means 1024*1024 etc.
2569
2570             When used without argument the default number of
2571             decimals displayed is 2. When used with a numeric
2572             integer argument, filesizeformat will display the
2573             given number of decimal places.
2574
2575           humanreadable
2576
2577             Similar to filesizeformat except no bytes suffix
2578             is added  (e.g., '13.00 k', '4.10 M' '102' etc),
2579             where k means 1000, M means 1000*1000 etc.
2580
2581             When used without argument the default number of
2582             decimals displayed is 2. When used with a numeric
2583             integer argument, humanreadable will display the
2584             given number of decimal places.
2585
2586           commasep
2587
2588             Separate the numerical values into groups of three
2589             digits using a comma (e.g., 1234567 -> 1,234,567)
2590
2591           hex
2592
2593             Display integer as hex number. An argument can be
2594             used to indicate how many digits should be used in
2595             the output. If the hex number is too long it will
2596             be truncated at the front, if it is too short it will
2597             be padded with zeros at the front. If the width is
2598             a negative number then at most that number of digits
2599             will be used, but short numbers will not be padded
2600             with zeroes. Another argument can be given to indicate
2601             if the hex numbers should be written with lower
2602             or upper case.
2603
2604             For example:
2605
2606               value            Template                       Output
2607               12345           {{ value|hex }}                 3039
2608               12345           {{ value|hex:2 }}               39
2609               12345           {{ value|hex:8 }}               00003039
2610               12345           {{ value|hex:-8 }}              3039
2611               14911           {{ value|hex:-8:upper }}        3A3F
2612               14911           {{ value|hex:-8:lower }}        3a3f
2613
2614           hexlist
2615
2616             Display integer as hex number with : between pairs. An
2617             argument can be used to indicate how many digits should
2618             be used in the output. If the hex number is too long it
2619             will be truncated at the front, if it is too short it will
2620             be padded with zeros at the front. If the width is
2621             a negative number then at most that number of digits
2622             will be used, but short numbers will not be padded
2623             with zeroes. Another argument can be given to indicate
2624             if the hex numbers should be written with lower
2625             or upper case.
2626
2627             For example:
2628
2629               value            Template                       Output
2630               12345           {{ value|hexlist }}             30:39
2631               12345           {{ value|hexlist:2 }}           39
2632               12345           {{ value|hexlist:8 }}           00:00:30:39
2633               12345           {{ value|hexlist:-8 }}          30:39
2634               14911           {{ value|hexlist:-8:upper }}    3A:3F
2635               14911           {{ value|hexlist:-8:lower }}    3a:3f
2636
2637           floatformat
2638
2639             Used for type 'float' in tailf-xsd-types. We recommend
2640             that the YANG built-in type 'decimal64' is used instead of
2641             'float'.
2642
2643             When used without an argument, rounds a floating-point
2644             number to one decimal place -- but only if there is a
2645             decimal part to be displayed.
2646
2647             For example:
2648
2649               value           Template                        Output
2650               34.23234        {{ value|floatformat }}         34.2
2651               34.00000        {{ value|floatformat }}         34
2652               34.26000        {{ value|floatformat }}         34.3
2653
2654             If used with a numeric integer argument, floatformat
2655             rounds a number to that many decimal places. For example:
2656
2657               value           Template                        Output
2658               34.23234        {{ value|floatformat:3 }}       34.232
2659               34.00000        {{ value|floatformat:3 }}       34.000
2660               34.26000        {{ value|floatformat:3 }}       34.260
2661
2662             If the argument passed to floatformat is negative, it will
2663             round a number to that many decimal places -- but only if
2664             there's a decimal part to be displayed. For example:
2665
2666               value           Template                        Output
2667               34.23234        {{ value|floatformat:-3 }}      34.232
2668               34.00000        {{ value|floatformat:-3 }}      34
2669               34.26000        {{ value|floatformat:-3 }}      34.260
2670
2671             Using floatformat with no argument is equivalent to using
2672             floatformat with an argument of -1.
2673
2674           ljust:width
2675
2676             Left-align the value given a width.
2677
2678           rjust:width
2679
2680             Right-align the value given a width.
2681
2682           trunc:width
2683
2684             Truncate value to a given width.
2685
2686           lower
2687
2688             Convert the value into lowercase.
2689
2690           upper
2691
2692             Convert the value into uppercase.
2693
2694           show:<dictionary>
2695
2696             Substitutes the result of invoking the default display
2697             function for the parameter. The dictionary can be used
2698             for introducing own variables that can be accessed in
2699             the same manner as builtin variables. The user defined
2700             variables overrides builtin variables. The dictionary
2701             is specified as a string on the following form:
2702
2703               (key=value)(:key=value)*
2704
2705             For example, with the following expression:
2706
2707               $(foo|show:myvar1=true:myvar2=Interface)
2708
2709             the user defined variables can be accessed like this:
2710
2711               $(.myvar1!=true?Address) $(.myvar2)
2712
2713             A special case is the dict variable 'indent'. It
2714             controls the indentation level of the displayed path.
2715             The current indent level can be incremented and
2716             decremented using =+ and =-.
2717
2718             For example:
2719
2720               $(foobar|show:indent=+2)
2721               $(foobar|show:indent=-1)
2722               $(foobar|show:indent=10)
2723
2724             Another special case is he dict variable 'noalign'.
2725             It  may be used to suppress the default aligning that
2726             may occur when displaying an element.
2727
2728             For example:
2729
2730               $(foobar|show:noalign)
2731
2732           dict:<dictionary>
2733
2734             Translates the value using the dictionary. Can for
2735             example be used for displaying on/off instead of
2736             true/false. The dictionary is specified as a string on
2737             the following form:
2738
2739               (key=value)(:key=value)*
2740
2741             For example, with the following expression:
2742
2743               $(foo|dict:true=on:false=off)
2744
2745             if the leaf 'foo' has value 'true', it is displayed as 'on', and
2746             if its value is 'false' it is displayed as 'off'.
2747
2748         Nested invocations are allowed, ie it is possible to have expressions
2749         like $((state|dict:yes=Yes:no=No)|rjust:14), or $(/foo{$(../bar)})
2750
2751
2752        For example:
2753
2754         list interface {
2755           key name;
2756           leaf name { ... }
2757           leaf status { ... }
2758           container line {
2759             leaf status { ... }
2760           }
2761           leaf mtu { ... }
2762           leaf bw { ... }
2763           leaf encapsulation { ... }
2764           leaf loopback { ... }
2765           tailf:cli-show-template
2766             '$(name) is administratively $(status),'
2767           + ' line protocol is $(line/status)\\n'
2768           + 'MTU $(mtu) bytes, BW $(bw|humanreadable)bit, \\n'
2769           + 'Encap $(encapsulation|upper), $(loopback?:loopback not set)\\n';
2770         }";
2771   }
2772 }