WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
+
+
+ This source code is part of the near-RT RIC (RAN Intelligent Controller)
+ platform project (RICP).
+
==================================================================================
*/
/*
Rpe
}
-type RmrPub struct {
- Rmr
-}
-
type RmrPush struct {
Rmr
}
-func NewRmrPub() *RmrPub {
- instance := new(RmrPub)
- return instance
-}
-
func NewRmrPush() *RmrPush {
instance := new(RmrPush)
return instance
*/
func (r *Rmr) generateRMRPolicies(eps rtmgr.Endpoints, key string) *[]string {
rawrt := []string{key + "newrt|start\n"}
- rt := r.getRouteTable(eps)
+ rt := r.generateRouteTable(eps)
for _, rte := range *rt {
- rawrte := key //+ "rte|" + rte.MessageType
- if rte.SubID == -1 {
- rawrte += "rte|"
- } else {
- rawrte += "mse|"
- }
- rawrte += rte.MessageType
+ rawrte := key + "mse|" + rte.MessageType
for _, tx := range rte.TxList {
rawrte += "," + tx.Ip + ":" + strconv.Itoa(int(tx.Port))
}
return &rawrt
}
-func (r *RmrPub) GeneratePolicies(eps rtmgr.Endpoints) *[]string {
- rtmgr.Logger.Debug("Invoked rmr.GeneratePolicies, args: %v: ", eps)
- return r.generateRMRPolicies(eps, "00000 ")
-}
-
func (r *RmrPush) GeneratePolicies(eps rtmgr.Endpoints) *[]string {
rtmgr.Logger.Debug("Invoked rmr.GeneratePolicies, args: %v: ", eps)
return r.generateRMRPolicies(eps, "")
}
-func (r *RmrPub) GetRouteTable(eps rtmgr.Endpoints) *rtmgr.RouteTable {
- return r.getRouteTable(eps)
-}
-
-func (r *RmrPush) GetRouteTable(eps rtmgr.Endpoints) *rtmgr.RouteTable {
- return r.getRouteTable(eps)
+func (r *RmrPush) GenerateRouteTable(eps rtmgr.Endpoints) *rtmgr.RouteTable {
+ return r.generateRouteTable(eps)
}
-