Statistics
| Branch: | Tag: | Revision:

root / ncclient / operations / __init__.py @ 216bb34c

History | View | Annotate | Download (1.7 kB)

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, TimeoutExpiredError, 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
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
    'DiscardChanges',
51
    'DeleteConfig',
52
    'Lock',
53
    'Unlock',
54
    'LockContext',
55
    'CloseSession',
56
    'KillSession',
57
    'OperationError',
58
    'TimeoutExpiredError',
59
    'MissingCapabilityError'
60
]