Revision 6625258b ncclient/content/common.py
b/ncclient/content/common.py | ||
---|---|---|
13 | 13 |
# limitations under the License. |
14 | 14 |
|
15 | 15 |
BASE_NS = 'urn:ietf:params:xml:ns:netconf:base:1.0' |
16 |
CISCO_BS = 'urn:ietf:params:netconf:base:1.0' |
|
16 | 17 |
|
17 | 18 |
def qualify(tag, namespace=None): |
18 | 19 |
'Returns qualified name of form `{namespace}tag`' |
19 |
if namespace is None: |
|
20 |
return tag |
|
21 |
else: |
|
20 |
if namespace is not None: |
|
22 | 21 |
return '{%s}%s' % (namespace, tag) |
22 |
else: |
|
23 |
return tag |
|
24 |
|
|
25 |
unqualify = lambda tag: tag[tag.rfind('}')+1:] |
Also available in: Unified diff