2 * Copyright (c) 2017 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
9 package org.opendaylight.mdsal.binding.javav2.spec.base;
13 * ListAction provides support for YANG actions defined under List statement.
15 * The "action" statement is used to define an operation connected to a
16 * specific container or list data node. The "action" statement defines
17 * an action node in the schema tree. Under the action node, a schema node
18 * with the name "input" and a schema node with the name "output" are also
19 * defined. The nodes "input" and "output" are defined in the module’s namespace.
21 * The difference between an action and an rpc is that an action is tied
22 * to a node in the datastore, whereas an rpc is not.
24 * Action replaces concept of routed RPC and comes up with implicit InstanceIdentifier
25 * context, whereas routed RPC defines explicit leaf for this purpose.
29 public interface ListAction<P extends TreeNode, I extends Input<I> & Instantiable<I>, O extends Output<O> & Instantiable<O>> {
32 * @param input Action input schema node
33 * @param kii implicit KeyedInstanceIdentifier connected to action, according to https://tools.ietf.org/html/rfc7950
34 * @param callback on success/failure callback
35 * @param <K> target key type
37 <K> void invoke(I input, KeyedInstanceIdentifier<P, K> kii, RpcCallback<O> callback);