1 <rpc-reply xmlns="urn:ietf:params:xml:ns:netconf:base:1.0" message-id="m-1">
2 <data xmlns="urn:ietf:params:xml:ns:yang:ietf-netconf-monitoring">module ietf-yang-metadata {
3 namespace "urn:ietf:params:xml:ns:yang:ietf-yang-metadata";
7 "IETF NETMOD (NETCONF Data Modeling Language) Working Group";
9 "WG Web: <https://datatracker.ietf.org/wg/netmod/>
11 WG List: <mailto:netmod@ietf.org>
14 <mailto:lberger@labn.net>
17 <mailto:kwatsen@juniper.net>
19 Editor: Ladislav Lhotka
20 <mailto:lhotka@nic.cz>";
22 "This YANG module defines an 'extension' statement that allows
23 for defining metadata annotations.
25 Copyright (c) 2016 IETF Trust and the persons identified as
26 authors of the code. All rights reserved.
28 Redistribution and use in source and binary forms, with or
29 without modification, is permitted pursuant to, and subject to
30 the license terms contained in, the Simplified BSD License set
31 forth in Section 4.c of the IETF Trust's Legal Provisions
32 Relating to IETF Documents
33 (http://trustee.ietf.org/license-info).
35 This version of this YANG module is part of RFC 7952
36 (http://www.rfc-editor.org/info/rfc7952); see the RFC itself
37 for full legal notices.";
43 "RFC 7952: Defining and Using Metadata with YANG";
46 extension annotation {
49 "This extension allows for defining metadata annotations in
50 YANG modules. The 'md:annotation' statement can appear only
51 at the top level of a YANG module or submodule, i.e., it
52 becomes a new alternative in the ABNF production rule for
53 'body-stmts' (Section 14 in RFC 7950).
55 The argument of the 'md:annotation' statement defines the name
56 of the annotation. Syntactically, it is a YANG identifier as
57 defined in Section 6.2 of RFC 7950.
59 An annotation defined with this 'extension' statement inherits
60 the namespace and other context from the YANG module in which
63 The data type of the annotation value is specified in the same
64 way as for a leaf data node using the 'type' statement.
66 The semantics of the annotation and other documentation can be
67 specified using the following standard YANG substatements (all
68 are optional): 'description', 'if-feature', 'reference',
69 'status', and 'units'.
71 A server announces support for a particular annotation by
72 including the module in which the annotation is defined among
73 the advertised YANG modules, e.g., in a NETCONF <hello>
74 message or in the YANG library (RFC 7950). The annotation can
75 then be attached to any instance of a data node defined in any
76 YANG module that is advertised by the server.
78 XML encoding and JSON encoding of annotations are defined in