From f0ae221b894fdd02f697f4fb6994623082e2175e Mon Sep 17 00:00:00 2001 From: FUJITA Tomonori Date: Tue, 3 Mar 2015 12:23:43 +0900 Subject: update the whole code for the latest openconfig yang files The modified openconfig yang files are available at: https://github.com/osrg/yang/tree/gobgp Signed-off-by: FUJITA Tomonori --- server/server.go | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) (limited to 'server/server.go') diff --git a/server/server.go b/server/server.go index 8fa743bd..39f5fe48 100644 --- a/server/server.go +++ b/server/server.go @@ -56,10 +56,10 @@ type peerMapInfo struct { } type BgpServer struct { - bgpConfig config.BgpType - globalTypeCh chan config.GlobalType - addedPeerCh chan config.NeighborType - deletedPeerCh chan config.NeighborType + bgpConfig config.Bgp + globalTypeCh chan config.Global + addedPeerCh chan config.Neighbor + deletedPeerCh chan config.Neighbor RestReqCh chan *api.RestRequest listenPort int peerMap map[string]peerMapInfo @@ -67,9 +67,9 @@ type BgpServer struct { func NewBgpServer(port int) *BgpServer { b := BgpServer{} - b.globalTypeCh = make(chan config.GlobalType) - b.addedPeerCh = make(chan config.NeighborType) - b.deletedPeerCh = make(chan config.NeighborType) + b.globalTypeCh = make(chan config.Global) + b.addedPeerCh = make(chan config.Neighbor) + b.deletedPeerCh = make(chan config.Neighbor) b.RestReqCh = make(chan *api.RestRequest, 1) b.listenPort = port return &b @@ -203,15 +203,15 @@ func sendServerMsgToAll(peerMap map[string]peerMapInfo, msg *serverMsg) { } } -func (server *BgpServer) SetGlobalType(g config.GlobalType) { +func (server *BgpServer) SetGlobalType(g config.Global) { server.globalTypeCh <- g } -func (server *BgpServer) PeerAdd(peer config.NeighborType) { +func (server *BgpServer) PeerAdd(peer config.Neighbor) { server.addedPeerCh <- peer } -func (server *BgpServer) PeerDelete(peer config.NeighborType) { +func (server *BgpServer) PeerDelete(peer config.Neighbor) { server.deletedPeerCh <- peer } -- cgit v1.2.3