--- /dev/null
+module yang-ext {\r
+ yang-version 1;\r
+ namespace "urn:opendaylight:yang:extension:yang-ext";\r
+ prefix "ext";\r
+ \r
+ contact "Anton Tkacik <ttkacik@cisco.com>";\r
+\r
+ revision "2013-07-09" {\r
+ description "";\r
+ }\r
+\r
+ // Augmentation name\r
+\r
+ extension "augment-identifier" {\r
+ description \r
+ "YANG language extension which assigns an identifier to \r
+ augmentation. Augment identifier is used to identify\r
+ specific augment statement by name. \r
+\r
+ The identifier syntax is defined formally defined by the rule\r
+ 'identifier' in Section 12 of RFC 6020.\r
+\r
+ All augment identifiers defined in a namespace MUST be unique.\r
+ The namespace of augment identifiers is shared by module and\r
+ its submodules. \r
+ ";\r
+ /*\r
+ Discussion:\r
+ This extension allows for ease of development / debug\r
+ of YANG modules and it is suitable for code generation,\r
+ where each augment statement is nicely identified by\r
+ unique name instead of combination of augment target\r
+ and when condition. \r
+ */\r
+ argument "identifier";\r
+ }\r
+\r
+\r
+ // Context-aware RPCs\r
+\r
+ grouping rpc-context-ref {\r
+ description \r
+ "A reference to RPC context.";\r
+ leaf context-instance {\r
+ type instance-identifier;\r
+ description "Pointer to the context. ";\r
+ }\r
+ }\r
+\r
+ extension "rpc-context-instance" {\r
+ description\r
+ "YANG language extension which defines enclosing (parent) \r
+ schema node as referencable context for RPCs.\r
+\r
+ The argument is identity which is used to identify RPC context\r
+ type.";\r
+\r
+ argument "context-type";\r
+ }\r
+\r
+ extension "context-reference" {\r
+ argument "context-type";\r
+ }\r
+\r
+ extension "context-instance" {\r
+ argument "context-type";\r
+ }\r
+ \r
+ extension "instance-target" {\r
+ argument "path";\r
+ }\r
+}
\ No newline at end of file