Statistics
| Branch: | Tag: | Revision:

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

History | View | Annotate | Download (1006 Bytes)

1 5858a82c Shikhar Bhushan
# Copyright 2009 Shikhar Bhushan
2 5858a82c Shikhar Bhushan
#
3 5858a82c Shikhar Bhushan
# Licensed under the Apache License, Version 2.0 (the "License");
4 5858a82c Shikhar Bhushan
# you may not use this file except in compliance with the License.
5 5858a82c Shikhar Bhushan
# You may obtain a copy of the License at
6 5858a82c Shikhar Bhushan
#
7 5858a82c Shikhar Bhushan
#    http://www.apache.org/licenses/LICENSE-2.0
8 5858a82c Shikhar Bhushan
#
9 5858a82c Shikhar Bhushan
# Unless required by applicable law or agreed to in writing, software
10 5858a82c Shikhar Bhushan
# distributed under the License is distributed on an "AS IS" BASIS,
11 5858a82c Shikhar Bhushan
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12 5858a82c Shikhar Bhushan
# See the License for the specific language governing permissions and
13 5858a82c Shikhar Bhushan
# limitations under the License.
14 5858a82c Shikhar Bhushan
15 4de03d63 Shikhar Bhushan
from rpc import RPC
16 5858a82c Shikhar Bhushan
17 1fca349b Shikhar Bhushan
from ncclient.content import qualify as _
18 4f650d54 Shikhar Bhushan
from ncclient.transport import SessionListener
19 4f650d54 Shikhar Bhushan
20 4f650d54 Shikhar Bhushan
NOTIFICATION_NS = 'urn:ietf:params:xml:ns:netconf:notification:1.0'
21 3e022b7b Shikhar Bhushan
22 179b00d4 Shikhar Bhushan
# TODO when can actually test it...
23 179b00d4 Shikhar Bhushan
24 5858a82c Shikhar Bhushan
class CreateSubscription(RPC):    
25 179b00d4 Shikhar Bhushan
    # tested: no
26 3e022b7b Shikhar Bhushan
    
27 1fca349b Shikhar Bhushan
    SPEC = {
28 179b00d4 Shikhar Bhushan
        'tag': _('create-subscription', NOTIFICATION_NS)
29 1fca349b Shikhar Bhushan
    }
30 5858a82c Shikhar Bhushan
31 179b00d4 Shikhar Bhushan
class Notification: pass
32 3e022b7b Shikhar Bhushan
33 4f650d54 Shikhar Bhushan
class NotificationListener(SessionListener): pass