814d141629d939830dd56d5ade30efb750508ee6
[netvirt.git] / sfc / translator / src / main / java / org / opendaylight / netvirt / sfc / translator / INeutronSfcDataProcessor.java
1 /*
2  * Copyright (c) 2016, 2017 Brocade Communications Systems, Inc. and others.  All rights reserved.
3  *
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
7  */
8
9 package org.opendaylight.netvirt.sfc.translator;
10
11 import org.opendaylight.yangtools.yang.binding.DataObject;
12 import org.opendaylight.yangtools.yang.binding.InstanceIdentifier;
13
14 /**
15  * Neutron SFC yang model processor.
16  */
17 public interface INeutronSfcDataProcessor<D extends DataObject> {
18
19     /**
20      * Method removes DataObject which is identified by InstanceIdentifier.
21      *
22      * @param identifier - the whole path to DataObject
23      * @param del - DataObject for removing
24      */
25     void remove(InstanceIdentifier<D> identifier, D del);
26
27     /**
28      * Method updates the original DataObject to the update DataObject.
29      * Both are identified by same InstanceIdentifier.
30      *
31      * @param identifier - the whole path to DataObject
32      * @param original - original DataObject (for update)
33      * @param update - changed DataObject (contain updates)
34      */
35     void update(InstanceIdentifier<D> identifier, D original, D update);
36
37     /**
38      * Method adds the DataObject which is identified by InstanceIdentifier
39      * to device.
40      *
41      * @param identifier - the whole path to new DataObject
42      * @param add - new DataObject
43      */
44     void add(InstanceIdentifier<D> identifier, D add);
45
46 }