2 * Copyright (c) 2013 Cisco Systems, Inc. and others. All rights reserved.
4 * This program and the accompanying materials are made available under the
5 * terms of the Eclipse Public License v1.0 which accompanies this distribution,
6 * and is available at http://www.eclipse.org/legal/epl-v10.html
8 package org.opendaylight.controller.netconf.api.monitoring;
10 import com.google.common.base.Optional;
11 import org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.netconf.monitoring.rev101004.NetconfState;
12 import org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.netconf.monitoring.rev101004.netconf.state.Capabilities;
13 import org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.netconf.monitoring.rev101004.netconf.state.Schemas;
14 import org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.netconf.monitoring.rev101004.netconf.state.Sessions;
16 public interface NetconfMonitoringService extends CapabilityListener, SessionListener {
18 Sessions getSessions();
22 String getSchemaForCapability(String moduleName, Optional<String> revision);
24 Capabilities getCapabilities();
27 * Allows push based state information transfer. After the listener is registered, current state is pushed to the listener.
29 AutoCloseable registerListener(MonitoringListener listener);
31 interface MonitoringListener {
33 // TODO more granular updates would make sense
34 void onStateChanged(NetconfState state);