Fix imports after Lisp model update in honeycomb
[groupbasedpolicy.git] / renderers / vpp / src / main / java / org / opendaylight / groupbasedpolicy / renderer / vpp / commands / lisp / dom / GbpGpeEntryDom.java
1 /*
2  * Copyright (c) 2017 Cisco Systems. 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 package org.opendaylight.groupbasedpolicy.renderer.vpp.commands.lisp.dom;
9
10 import com.google.common.base.Preconditions;
11 import org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.gpe.rev170801.gpe.entry.table.grouping.gpe.entry.table.GpeEntry;
12 import org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.gpe.rev170801.gpe.entry.table.grouping.gpe.entry.table.GpeEntryBuilder;
13 import org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.gpe.rev170801.gpe.entry.table.grouping.gpe.entry.table.GpeEntryKey;
14 import org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.gpe.rev170801.gpe.entry.table.grouping.gpe.entry.table.gpe.entry.LocalEid;
15 import org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.gpe.rev170801.gpe.entry.table.grouping.gpe.entry.table.gpe.entry.RemoteEid;
16 import org.opendaylight.yang.gen.v1.urn.opendaylight.params.xml.ns.yang.lisp.rev170808.MapReplyAction;
17
18 /**
19  * Created by Shakib Ahmed on 6/1/17.
20  */
21 public class GbpGpeEntryDom implements CommandModel{
22     private String id;
23     private Long vrf;
24     private Long vni;
25     private LocalEid localEid;
26     private RemoteEid remoteEid;
27     private MapReplyAction action;
28
29     public String getId() {
30         return id;
31     }
32
33     public void setId(String id) {
34         this.id = id;
35     }
36
37     public Long getVrf() {
38         return vrf;
39     }
40
41     public void setVrf(Long vrf) {
42         this.vrf = vrf;
43     }
44
45     public Long getVni() {
46         return vni;
47     }
48
49     public void setVni(Long vni) {
50         this.vni = vni;
51     }
52
53     public RemoteEid getRemoteEid() {
54         return remoteEid;
55     }
56
57     public void setRemoteEid(RemoteEid remoteEid) {
58         this.remoteEid = remoteEid;
59     }
60
61     public MapReplyAction getAction() {
62         return action;
63     }
64
65     public LocalEid getLocalEid() {
66         return localEid;
67     }
68
69     public void setLocalEid(LocalEid localEid) {
70         this.localEid = localEid;
71     }
72
73     public void setAction(MapReplyAction action) {
74         this.action = action;
75     }
76
77     @Override
78     public GpeEntry getSALObject() {
79         Preconditions.checkNotNull(id, "Gpe Entry Id need to be set!");
80         return new GpeEntryBuilder()
81                     .setKey(new GpeEntryKey(id))
82                     .setId(id)
83                     .setDpTable(vrf)
84                     .setVni(vni)
85                     .setRemoteEid(remoteEid)
86                     .setLocalEid(localEid)
87                     .setAction(action).build();
88     }
89 }