266325815b6d3707013c8b2151d8adf48be2ca55
[hc2vpp.git] /
1 /*
2  * Copyright (c) 2016 Cisco and/or its affiliates.
3  *
4  * Licensed under the Apache License, Version 2.0 (the "License");
5  * you may not use this file except in compliance with the License.
6  * You may obtain a copy of the License at:
7  *
8  *     http://www.apache.org/licenses/LICENSE-2.0
9  *
10  * Unless required by applicable law or agreed to in writing, software
11  * distributed under the License is distributed on an "AS IS" BASIS,
12  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13  * See the License for the specific language governing permissions and
14  * limitations under the License.
15  */
16
17 package io.fd.honeycomb.v3po.translate.util.write;
18
19 import io.fd.honeycomb.v3po.translate.spi.write.RootWriterCustomizer;
20 import io.fd.honeycomb.v3po.translate.Context;
21 import javax.annotation.Nonnull;
22 import org.opendaylight.yangtools.yang.binding.DataObject;
23 import org.opendaylight.yangtools.yang.binding.InstanceIdentifier;
24
25 /**
26  * Customizer not performing any changes on current level. Suitable for nodes that don't have any leaves and all of
27  * its child nodes are managed by dedicated writers
28  */
29 public class NoopWriterCustomizer<D extends DataObject> implements RootWriterCustomizer<D> {
30
31     @Override
32     public void writeCurrentAttributes(@Nonnull final InstanceIdentifier<D> id, @Nonnull final D dataAfter,
33                                        @Nonnull final Context ctx) {
34
35     }
36
37     @Override
38     public void updateCurrentAttributes(@Nonnull final InstanceIdentifier<D> id, @Nonnull final D dataBefore,
39                                         @Nonnull final D dataAfter,
40                                         @Nonnull final Context ctx) {
41
42     }
43
44     @Override
45     public void deleteCurrentAttributes(@Nonnull final InstanceIdentifier<D> id, @Nonnull final D dataBefore,
46                                         @Nonnull final Context ctx) {
47
48     }
49 }