:arg default_operation: optional; one of {'merge', 'replace', 'none'}
:type default_operation: `string`
- :arg test_option: optional; one of {'stop-on-error', 'continue-on-error', 'rollback-on-error'}. Last option depends on the *:rollback-on-error* capability
+ :arg error_option: optional; one of {'stop-on-error', 'continue-on-error', 'rollback-on-error'}. Last option depends on the *:rollback-on-error* capability
+ :type error_option: string
+
+ :arg test_option: optional; one of {'test-then-set', 'set'}. Depends on *:validate* capability.
:type test_option: string
:seealso: :ref:`return`
spec = deepcopy(EditConfig.SPEC)
subtree = spec['subtree']
subtree.append(util.store_or_url('target', target, self._assert))
- subtree.append(content.validated_element(config, ('config', content.qualify('config'))))
if default_operation is not None:
subtree.append({
'tag': 'default-operation',
'tag': 'error-option',
'text': error_option
})
+ subtree.append(content.validated_element(config, ('config', content.qualify('config'))))
return self._request(spec)
class DeleteConfig(RPC):
+++ /dev/null
-from ncclient import manager
-
-import logging
-logging.basicConfig(level=logging.DEBUG)
-
-with manager.connect('broccoli', 22, username='sbhushan') as m:
- with m.locked('candidate'):
- reply = m.copy_config(source='running', target='candidate')
-
-print reply