X-Git-Url: https://gerrit.o-ran-sc.org/r/gitweb?a=blobdiff_plain;f=pkg%2Fsbi%2Ftypes.go;h=094a8adc2c19655b727f3b8e59b09cc04550ac96;hb=refs%2Fchanges%2F86%2F10286%2F14;hp=1254e93adbf96d2b504c65a438bfe0d863739ac8;hpb=871fa393844ce1b61b8d5218d27687d9fc05803a;p=ric-plt%2Frtmgr.git diff --git a/pkg/sbi/types.go b/pkg/sbi/types.go index 1254e93..094a8ad 100644 --- a/pkg/sbi/types.go +++ b/pkg/sbi/types.go @@ -14,30 +14,47 @@ 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). + ================================================================================== */ /* Mnemonic: sbi/types.go - Abstract: Containes SBI (SouthBound Interface) specific types + Abstract: Contains SBI (SouthBound Interface) specific types Date: 16 March 2019 */ package sbi -type distributeAll func(*[]string) error -type openSocket func(string) error -type closeSocket func() error +import "routing-manager/pkg/rtmgr" -type SbiEngine struct { - Name string - Version string - Protocol string +type EngineConfig struct { + Name string + Version string + Protocol string + Instance Engine + IsAvailable bool } -type SbiEngineConfig struct { - Engine SbiEngine - OpenSocket openSocket - CloseSocket closeSocket - DistributeAll distributeAll - IsAvailable bool +type Engine interface { + Initialize(string) error + Terminate() error + DistributeAll(*[]string) error + AddEndpoint(*rtmgr.Endpoint) error + DeleteEndpoint(*rtmgr.Endpoint) error + UpdateEndpoints(*rtmgr.RicComponents) + CheckEndpoint(string) *rtmgr.Endpoint + CreateEndpoint(string) (*string, int) + DistributeToEp(*[]string, string, int) error } + +/*type NngSocket interface { + Listen(string) error + Send([]byte) error + Close() error + DialOptions(string, map[string]interface{}) error +} + +type CreateNewNngSocketHandler func() (NngSocket, error)*/