Modified bgp file name according to naming convention.
Change-Id: I403139b53fbc1a2dba894dfd39720707a52ba7cd
diff --git a/bgp/api/src/main/java/org/onosproject/bgp/controller/BGPCfg.java b/bgp/api/src/main/java/org/onosproject/bgp/controller/BgpCfg.java
similarity index 96%
rename from bgp/api/src/main/java/org/onosproject/bgp/controller/BGPCfg.java
rename to bgp/api/src/main/java/org/onosproject/bgp/controller/BgpCfg.java
index 46165d8..6f64d2b 100755
--- a/bgp/api/src/main/java/org/onosproject/bgp/controller/BGPCfg.java
+++ b/bgp/api/src/main/java/org/onosproject/bgp/controller/BgpCfg.java
@@ -20,7 +20,7 @@
/**
* Abstraction of an BGP configuration. Manages the BGP configuration from CLI to the BGP controller.
*/
-public interface BGPCfg {
+public interface BgpCfg {
enum State {
/**
@@ -233,7 +233,7 @@
*
* @return return the tree map with IP as key and BGPPeerCfg as object
*/
- TreeMap<String, BGPPeerCfg> displayPeers();
+ TreeMap<String, BgpPeerCfg> displayPeers();
/**
* Return the BGP Peer information with this matching IP.
@@ -242,7 +242,7 @@
*
* @return BGPPeerCfg object
*/
- BGPPeerCfg displayPeers(String routerid);
+ BgpPeerCfg displayPeers(String routerid);
/**
* Check if this BGP peer is configured.
@@ -267,7 +267,7 @@
*
* @return return the tree map with IP as key and BGPPeerCfg as object
*/
- TreeMap<String, BGPPeerCfg> getPeerTree();
+ TreeMap<String, BgpPeerCfg> getPeerTree();
/**
* Set the current connection state information.
@@ -275,7 +275,7 @@
* @param routerid router IP address in string format
* @param state state information
*/
- void setPeerConnState(String routerid, BGPPeerCfg.State state);
+ void setPeerConnState(String routerid, BgpPeerCfg.State state);
/**
* Check if the peer can be connected or not.
@@ -293,5 +293,5 @@
*
* @return state information
*/
- BGPPeerCfg.State getPeerConnState(String routerid);
+ BgpPeerCfg.State getPeerConnState(String routerid);
}
diff --git a/bgp/api/src/main/java/org/onosproject/bgp/controller/BGPController.java b/bgp/api/src/main/java/org/onosproject/bgp/controller/BgpController.java
similarity index 86%
rename from bgp/api/src/main/java/org/onosproject/bgp/controller/BGPController.java
rename to bgp/api/src/main/java/org/onosproject/bgp/controller/BgpController.java
index 9d44041..79677e9 100755
--- a/bgp/api/src/main/java/org/onosproject/bgp/controller/BGPController.java
+++ b/bgp/api/src/main/java/org/onosproject/bgp/controller/BgpController.java
@@ -19,21 +19,21 @@
import java.util.Map;
import java.util.Set;
-import org.onosproject.bgpio.exceptions.BGPParseException;
-import org.onosproject.bgpio.protocol.BGPMessage;
+import org.onosproject.bgpio.exceptions.BgpParseException;
+import org.onosproject.bgpio.protocol.BgpMessage;
/**
* Abstraction of an BGP controller. Serves as a one stop shop for obtaining BGP devices and (un)register listeners on
* bgp events
*/
-public interface BGPController {
+public interface BgpController {
/**
* Returns list of bgp peers connected to this BGP controller.
*
* @return Iterable of BGPPeer elements
*/
- Iterable<BGPPeer> getPeers();
+ Iterable<BgpPeer> getPeers();
/**
* Returns the actual bgp peer for the given ip address.
@@ -41,7 +41,7 @@
* @param bgpId the id of the bgp peer to fetch
* @return the interface to this bgp peer
*/
- BGPPeer getPeer(BGPId bgpId);
+ BgpPeer getPeer(BgpId bgpId);
/**
* Register a listener for BGP message events.
@@ -77,16 +77,16 @@
* @param bgpId the id of the peer to send message.
* @param msg the message to send
*/
- void writeMsg(BGPId bgpId, BGPMessage msg);
+ void writeMsg(BgpId bgpId, BgpMessage msg);
/**
* Process a message and notify the appropriate listeners.
*
* @param bgpId id of the peer the message arrived on
* @param msg the message to process.
- * @throws BGPParseException on data processing error
+ * @throws BgpParseException on data processing error
*/
- void processBGPPacket(BGPId bgpId, BGPMessage msg) throws BGPParseException;
+ void processBGPPacket(BgpId bgpId, BgpMessage msg) throws BgpParseException;
/**
* Close all connected BGP peers.
@@ -99,7 +99,7 @@
*
* @return configuration object
*/
- BGPCfg getConfig();
+ BgpCfg getConfig();
/**
* Get the BGP connected peers to this controller.
@@ -120,7 +120,7 @@
*
* @return connectedPeers connected peers
*/
- Map<BGPId, BGPPeer> connectedPeers();
+ Map<BgpId, BgpPeer> connectedPeers();
/**
* Return BGP node listener.
diff --git a/bgp/api/src/main/java/org/onosproject/bgp/controller/BgpDpid.java b/bgp/api/src/main/java/org/onosproject/bgp/controller/BgpDpid.java
index 9004216..71117c2 100755
--- a/bgp/api/src/main/java/org/onosproject/bgp/controller/BgpDpid.java
+++ b/bgp/api/src/main/java/org/onosproject/bgp/controller/BgpDpid.java
@@ -18,9 +18,9 @@
import java.net.URI;
import java.net.URISyntaxException;
-import org.onosproject.bgpio.exceptions.BGPParseException;
+import org.onosproject.bgpio.exceptions.BgpParseException;
import org.onosproject.bgpio.protocol.linkstate.BgpLinkLsNlriVer4;
-import org.onosproject.bgpio.protocol.linkstate.BGPNodeLSNlriVer4;
+import org.onosproject.bgpio.protocol.linkstate.BgpNodeLSNlriVer4;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
@@ -61,7 +61,7 @@
} else if (nodeDescriptorType == NODE_DESCRIPTOR_REMOTE) {
add(linkNlri.remoteNodeDescriptors().toString());
}
- } catch (BGPParseException e) {
+ } catch (BgpParseException e) {
log.info("Exception BgpId string: " + e.toString());
}
@@ -72,7 +72,7 @@
*
* @param nodeNlri node Nlri.
*/
- public BgpDpid(final BGPNodeLSNlriVer4 nodeNlri) {
+ public BgpDpid(final BgpNodeLSNlriVer4 nodeNlri) {
this.stringBuilder = new StringBuilder("bgpls://");
if (nodeNlri.getRouteDistinguisher() != null) {
@@ -89,7 +89,7 @@
add(nodeNlri.getLocalNodeDescriptors().toString());
- } catch (BGPParseException e) {
+ } catch (BgpParseException e) {
log.info("Exception node string: " + e.toString());
}
}
diff --git a/bgp/api/src/main/java/org/onosproject/bgp/controller/BGPId.java b/bgp/api/src/main/java/org/onosproject/bgp/controller/BgpId.java
similarity index 87%
rename from bgp/api/src/main/java/org/onosproject/bgp/controller/BGPId.java
rename to bgp/api/src/main/java/org/onosproject/bgp/controller/BgpId.java
index 636e72f..7a6c625 100755
--- a/bgp/api/src/main/java/org/onosproject/bgp/controller/BGPId.java
+++ b/bgp/api/src/main/java/org/onosproject/bgp/controller/BgpId.java
@@ -27,7 +27,7 @@
* The class representing a network peer bgp ip.
* This class is immutable.
*/
-public final class BGPId {
+public final class BgpId {
private static final String SCHEME = "bgp";
private static final long UNKNOWN = 0;
@@ -36,7 +36,7 @@
/**
* Private constructor.
*/
- private BGPId(IpAddress ipAddress) {
+ private BgpId(IpAddress ipAddress) {
this.ipAddress = ipAddress;
}
@@ -46,8 +46,8 @@
* @param ipAddress IP address
* @return object of BGPId
*/
- public static BGPId bgpId(IpAddress ipAddress) {
- return new BGPId(ipAddress);
+ public static BgpId bgpId(IpAddress ipAddress) {
+ return new BgpId(ipAddress);
}
/**
@@ -71,11 +71,11 @@
@Override
public boolean equals(Object other) {
- if (!(other instanceof BGPId)) {
+ if (!(other instanceof BgpId)) {
return false;
}
- BGPId otherBGPid = (BGPId) other;
+ BgpId otherBGPid = (BgpId) other;
return Objects.equals(ipAddress, otherBGPid.ipAddress);
}
@@ -90,9 +90,9 @@
* @param uri device URI
* @return object of BGPId
*/
- public static BGPId bgpId(URI uri) {
+ public static BgpId bgpId(URI uri) {
checkArgument(uri.getScheme().equals(SCHEME), "Unsupported URI scheme");
- return new BGPId(IpAddress.valueOf(uri.getSchemeSpecificPart()));
+ return new BgpId(IpAddress.valueOf(uri.getSchemeSpecificPart()));
}
/**
@@ -101,7 +101,7 @@
* @param bgpId device bgpId
* @return device URI
*/
- public static URI uri(BGPId bgpId) {
+ public static URI uri(BgpId bgpId) {
return uri(bgpId.ipAddress());
}
diff --git a/bgp/api/src/main/java/org/onosproject/bgp/controller/BgpLocalRib.java b/bgp/api/src/main/java/org/onosproject/bgp/controller/BgpLocalRib.java
index 9ecebc5..636c1c8 100755
--- a/bgp/api/src/main/java/org/onosproject/bgp/controller/BgpLocalRib.java
+++ b/bgp/api/src/main/java/org/onosproject/bgp/controller/BgpLocalRib.java
@@ -13,7 +13,7 @@
package org.onosproject.bgp.controller;
-import org.onosproject.bgpio.protocol.BGPLSNlri;
+import org.onosproject.bgpio.protocol.BgpLSNlri;
import org.onosproject.bgpio.protocol.linkstate.PathAttrNlriDetails;
import org.onosproject.bgpio.types.RouteDistinguisher;
@@ -29,14 +29,14 @@
* @param nlri network layer reach info
* @param details nlri details
*/
- void add(BgpSessionInfo sessionInfo, BGPLSNlri nlri, PathAttrNlriDetails details);
+ void add(BgpSessionInfo sessionInfo, BgpLSNlri nlri, PathAttrNlriDetails details);
/**
* Removes NLRI identifier if it exists.
*
* @param nlri info
*/
- void delete(BGPLSNlri nlri);
+ void delete(BgpLSNlri nlri);
/**
* Update NLRI identifier mapped with route distinguisher if it exists in tree otherwise add NLRI infomation mapped
@@ -47,7 +47,7 @@
* @param details has pathattribute, protocol id and identifier
* @param routeDistinguisher unique for each VPN
*/
- void add(BgpSessionInfo sessionInfo, BGPLSNlri nlri, PathAttrNlriDetails details,
+ void add(BgpSessionInfo sessionInfo, BgpLSNlri nlri, PathAttrNlriDetails details,
RouteDistinguisher routeDistinguisher);
/**
@@ -56,5 +56,5 @@
* @param nlri info
* @param routeDistinguisher unique for each VPN
*/
- void delete(BGPLSNlri nlri, RouteDistinguisher routeDistinguisher);
+ void delete(BgpLSNlri nlri, RouteDistinguisher routeDistinguisher);
}
diff --git a/bgp/api/src/main/java/org/onosproject/bgp/controller/BgpNodeListener.java b/bgp/api/src/main/java/org/onosproject/bgp/controller/BgpNodeListener.java
index 37d849c..726d931 100755
--- a/bgp/api/src/main/java/org/onosproject/bgp/controller/BgpNodeListener.java
+++ b/bgp/api/src/main/java/org/onosproject/bgp/controller/BgpNodeListener.java
@@ -12,7 +12,7 @@
*/
package org.onosproject.bgp.controller;
-import org.onosproject.bgpio.protocol.linkstate.BGPNodeLSNlriVer4;
+import org.onosproject.bgpio.protocol.linkstate.BgpNodeLSNlriVer4;
/**
* Allows for providers interested in node events to be notified.
@@ -24,12 +24,12 @@
*
* @param nodeNlri node rechability info
*/
- void addNode(BGPNodeLSNlriVer4 nodeNlri);
+ void addNode(BgpNodeLSNlriVer4 nodeNlri);
/**
* Notifies that the node was removed.
*
* @param nodeNlri node rechability info
*/
- void deleteNode(BGPNodeLSNlriVer4 nodeNlri);
+ void deleteNode(BgpNodeLSNlriVer4 nodeNlri);
}
diff --git a/bgp/api/src/main/java/org/onosproject/bgp/controller/BGPPacketStats.java b/bgp/api/src/main/java/org/onosproject/bgp/controller/BgpPacketStats.java
similarity index 97%
rename from bgp/api/src/main/java/org/onosproject/bgp/controller/BGPPacketStats.java
rename to bgp/api/src/main/java/org/onosproject/bgp/controller/BgpPacketStats.java
index 95f83a2..8fd3c68 100755
--- a/bgp/api/src/main/java/org/onosproject/bgp/controller/BGPPacketStats.java
+++ b/bgp/api/src/main/java/org/onosproject/bgp/controller/BgpPacketStats.java
@@ -21,7 +21,7 @@
* to the event if blocked has been called. This packet context can be used to react to the packet in event with a
* packet out.
*/
-public interface BGPPacketStats {
+public interface BgpPacketStats {
/**
* Returns the count for no of packets sent out.
*
diff --git a/bgp/api/src/main/java/org/onosproject/bgp/controller/BGPPeer.java b/bgp/api/src/main/java/org/onosproject/bgp/controller/BgpPeer.java
similarity index 91%
rename from bgp/api/src/main/java/org/onosproject/bgp/controller/BGPPeer.java
rename to bgp/api/src/main/java/org/onosproject/bgp/controller/BgpPeer.java
index aafaf06..df16346 100755
--- a/bgp/api/src/main/java/org/onosproject/bgp/controller/BGPPeer.java
+++ b/bgp/api/src/main/java/org/onosproject/bgp/controller/BgpPeer.java
@@ -16,14 +16,14 @@
package org.onosproject.bgp.controller;
import java.util.List;
import org.jboss.netty.channel.Channel;
-import org.onosproject.bgpio.protocol.BGPFactory;
-import org.onosproject.bgpio.protocol.BGPMessage;
+import org.onosproject.bgpio.protocol.BgpFactory;
+import org.onosproject.bgpio.protocol.BgpMessage;
/**
* Represents the peer side of an BGP peer.
*
*/
-public interface BGPPeer {
+public interface BgpPeer {
/**
* Sets the associated Netty channel for this bgp peer.
@@ -58,21 +58,21 @@
*
* @param msg the message to write
*/
- void sendMessage(BGPMessage msg);
+ void sendMessage(BgpMessage msg);
/**
* Writes the BGPMessage list to the peer.
*
* @param msgs the messages to be written
*/
- void sendMessage(List<BGPMessage> msgs);
+ void sendMessage(List<BgpMessage> msgs);
/**
* Provides the factory for BGP version.
*
* @return BGP version specific factory.
*/
- BGPFactory factory();
+ BgpFactory factory();
/**
* Checks if the bgp peer is still connected.
diff --git a/bgp/api/src/main/java/org/onosproject/bgp/controller/BGPPeerCfg.java b/bgp/api/src/main/java/org/onosproject/bgp/controller/BgpPeerCfg.java
similarity index 99%
rename from bgp/api/src/main/java/org/onosproject/bgp/controller/BGPPeerCfg.java
rename to bgp/api/src/main/java/org/onosproject/bgp/controller/BgpPeerCfg.java
index e7c5d9b..2fb970f 100755
--- a/bgp/api/src/main/java/org/onosproject/bgp/controller/BGPPeerCfg.java
+++ b/bgp/api/src/main/java/org/onosproject/bgp/controller/BgpPeerCfg.java
@@ -18,7 +18,7 @@
/**
* BGP Peer configuration information.
*/
-public interface BGPPeerCfg {
+public interface BgpPeerCfg {
enum State {
diff --git a/bgp/api/src/main/java/org/onosproject/bgp/controller/BgpPeerManager.java b/bgp/api/src/main/java/org/onosproject/bgp/controller/BgpPeerManager.java
index d223096..895cc14 100755
--- a/bgp/api/src/main/java/org/onosproject/bgp/controller/BgpPeerManager.java
+++ b/bgp/api/src/main/java/org/onosproject/bgp/controller/BgpPeerManager.java
@@ -26,7 +26,7 @@
*
* @return false if peer already exist, otherwise true
*/
- public boolean addConnectedPeer(BGPId bgpId, BGPPeer bgpPeer);
+ public boolean addConnectedPeer(BgpId bgpId, BgpPeer bgpPeer);
/**
* Validate wheather peer is connected.
@@ -35,14 +35,14 @@
*
* @return true if peer exist, otherwise false
*/
- public boolean isPeerConnected(BGPId bgpId);
+ public boolean isPeerConnected(BgpId bgpId);
/**
* Remove connected peer.
*
* @param bgpId BGP ID
*/
- public void removeConnectedPeer(BGPId bgpId);
+ public void removeConnectedPeer(BgpId bgpId);
/**
* Gets connected peer.
@@ -50,5 +50,5 @@
* @param bgpId BGP ID
* @return BGPPeer the connected peer, otherwise null
*/
- public BGPPeer getPeer(BGPId bgpId);
+ public BgpPeer getPeer(BgpId bgpId);
}
diff --git a/bgp/api/src/main/java/org/onosproject/bgp/controller/BgpSessionInfo.java b/bgp/api/src/main/java/org/onosproject/bgp/controller/BgpSessionInfo.java
index 17753ff..a21a23d 100755
--- a/bgp/api/src/main/java/org/onosproject/bgp/controller/BgpSessionInfo.java
+++ b/bgp/api/src/main/java/org/onosproject/bgp/controller/BgpSessionInfo.java
@@ -13,7 +13,7 @@
package org.onosproject.bgp.controller;
-import org.onosproject.bgpio.protocol.BGPVersion;
+import org.onosproject.bgpio.protocol.BgpVersion;
/**
* Abstraction of an BGP session info. Maintian session parameters obtained during session creation.
@@ -38,14 +38,14 @@
*
* @return bgp ID.
*/
- BGPId remoteBgpId();
+ BgpId remoteBgpId();
/**
* Gets the BGP version of peer.
*
* @return bgp version.
*/
- BGPVersion remoteBgpVersion();
+ BgpVersion remoteBgpVersion();
/**
* Gets the BGP remote bgp AS number.