Submgr restart improvement
[ric-plt/submgr.git] / pkg / control / types.go
index 64fd15f..c8c09dc 100644 (file)
 package control
 
 import (
-       "strconv"
+       "gerrit.o-ran-sc.org/r/ric-plt/e2ap/pkg/e2ap"
 )
 
-type RmrDatagram struct {
-       MessageType    int
-       SubscriptionId uint16
-       Payload        []byte
+//-----------------------------------------------------------------------------
+//
+//-----------------------------------------------------------------------------
+type RequestId struct {
+       e2ap.RequestId
 }
 
-type SubRouteInfo struct {
-       Command Action
-       Address string
-       Port    uint16
-       SubID   uint16
+func (rid *RequestId) String() string {
+       return "reqid(" + rid.RequestId.String() + ")"
 }
 
-type RmrEndpoint struct {
-       Addr string // xapp addr
-       Port uint16 // xapp port
+type Sdlnterface interface {
+       Set(pairs ...interface{}) error
+       Get(keys []string) (map[string]interface{}, error)
+       GetAll() ([]string, error)
+       Remove(keys []string) error
+       RemoveAll() error
 }
-
-func (endpoint RmrEndpoint) String() string {
-       return endpoint.Addr + ":" + strconv.FormatUint(uint64(endpoint.Port), 10)
-}
-
-type Action int