git-svn-id: http://ncclient.googlecode.com/svn/trunk@122 6dbcf712-26ac-11de-a2f3...
[ncclient] / ncclient / operations / __init__.py
1 # Copyright 2009 Shikhar Bhushan
2 #
3 # Licensed under the Apache License, Version 2.0 (the "License");
4 # you may not use this file except in compliance with the License.
5 # You may obtain a copy of the License at
6 #
7 #    http://www.apache.org/licenses/LICENSE-2.0
8 #
9 # Unless required by applicable law or agreed to in writing, software
10 # distributed under the License is distributed on an "AS IS" BASIS,
11 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12 # See the License for the specific language governing permissions and
13 # limitations under the License.
14
15 from errors import OperationError, MissingCapabilityError
16 from rpc import RPC, RPCReply, RPCError
17 from retrieve import Get, GetConfig, GetReply
18 from edit import EditConfig, CopyConfig, DeleteConfig, Validate, Commit, DiscardChanges, ConfirmedCommit
19 from session import CloseSession, KillSession
20 from lock import Lock, Unlock, LockContext
21 #from subscribe import CreateSubscription
22
23 OPERATIONS = {
24     'get': Get,
25     'get-config': GetConfig,
26     'edit-config': EditConfig,
27     'copy-config': CopyConfig,
28     'validate': Validate,
29     'commit': Commit,
30     'discard-changes': DiscardChanges,
31     'delete-config': DeleteConfig,
32     'lock': Lock,
33     'unlock': Unlock,
34     'close_session': CloseSession,
35     'kill-session': KillSession,
36 }
37
38 __all__ = [
39     'RPC',
40     'RPCReply',
41     'RPCError',
42     'OPERATIONS',
43     'Get',
44     'GetConfig',
45     'GetReply',
46     'EditConfig',
47     'CopyConfig',
48     'Validate',
49     'Commit',
50     'ConfirmedCommit'
51     'DiscardChanges',
52     'DeleteConfig',
53     'Lock',
54     'Unlock',
55     'LockContext',
56     'CloseSession',
57     'KillSession'
58 ]