Documentation ¶
Index ¶
- Constants
- type CategoryLoads
- type GridMapTable
- type PoaLoads
- type TrafficMgr
- func (tm *TrafficMgr) CreateDb(name string) (err error)
- func (tm *TrafficMgr) CreateGridMap(area string, category string, grid string) (err error)
- func (tm *TrafficMgr) CreatePoaLoad(poaName string, category string) (err error)
- func (tm *TrafficMgr) CreateTables() (err error)
- func (tm *TrafficMgr) DeleteAllGridMap() (err error)
- func (tm *TrafficMgr) DeleteAllPoaLoad() (err error)
- func (tm *TrafficMgr) DeleteTable(tableName string) (err error)
- func (tm *TrafficMgr) DeleteTables() (err error)
- func (tm *TrafficMgr) DeleteTrafficMgr() (err error)
- func (tm *TrafficMgr) DestroyDb(name string) (err error)
- func (tm *TrafficMgr) GetAllGridMap() (gridMaps map[string]*GridMapTable, err error)
- func (tm *TrafficMgr) GetAllPoaLoad() (poaLoadMap map[string]*PoaLoads, err error)
- func (tm *TrafficMgr) GetGridMap(area string) (gridMaps *GridMapTable, err error)
- func (tm *TrafficMgr) GetPoaCategory(longitude float32, latitude float32) (category string, err error)
- func (tm *TrafficMgr) GetPoaLoad(poaName string) (poaLoads *PoaLoads, err error)
- func (tm *TrafficMgr) PopulateGridMapTable() (err error)
- func (tm *TrafficMgr) PopulatePoaLoad(poaNameList []string, gpsCoordinates [][]float32) (err error)
- func (tm *TrafficMgr) PredictQosPerTrafficLoad(hour int32, inRsrp int32, inRsrq int32, poaName string) (outRsrp int32, outRsrq int32, err error)
Constants ¶
const ( DbHost = "meep-postgis.default.svc.cluster.local" DbPort = "5432" DbUser = "" DbPassword = "" DbDefault = "postgres" DbMaxRetryCount int = 2 )
DB Config
const ( FieldCategory = "category" FieldPoaName = "poaName" FieldZeroToThree = "0000-0300" FieldThreeToSix = "0300-0600" FieldSixToNine = "0600-0900" FieldNineToTwelve = "0900-1200" FieldTwelveToFifteen = "1200-1500" FieldFifteenToEighteen = "1500-1800" FieldEighteenToTwentyOne = "1800-2100" FieldTwentyOneToTwentyFour = "2100-2400" )
const ( CategoryCommercial = "commercial" CategoryResidential = "residential" CategoryCoastal = "coastal" )
const (
GridTable = "grid_map"
)
DB Table Names
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type CategoryLoads ¶
type GridMapTable ¶
type GridMapTable struct {
// contains filtered or unexported fields
}
type TrafficMgr ¶
type TrafficMgr struct { GridFileExists bool // contains filtered or unexported fields }
VIS Traffic Manager
func NewTrafficMgr ¶
func NewTrafficMgr(name, namespace, user, pwd, host, port string) (tm *TrafficMgr, err error)
NewTrafficMgr - Creates and initializes a new VIS Traffic Manager
func (*TrafficMgr) CreateDb ¶
func (tm *TrafficMgr) CreateDb(name string) (err error)
CreateDb -- Create new DB with provided name
func (*TrafficMgr) CreateGridMap ¶
func (tm *TrafficMgr) CreateGridMap(area string, category string, grid string) (err error)
CreateGridMap - Create new Grid Map
func (*TrafficMgr) CreatePoaLoad ¶
func (tm *TrafficMgr) CreatePoaLoad(poaName string, category string) (err error)
CreatePoaLoad - Create new POA Load
func (*TrafficMgr) CreateTables ¶
func (tm *TrafficMgr) CreateTables() (err error)
func (*TrafficMgr) DeleteAllGridMap ¶
func (tm *TrafficMgr) DeleteAllGridMap() (err error)
DeleteAllGridMap - Delete all GridMap entries
func (*TrafficMgr) DeleteAllPoaLoad ¶
func (tm *TrafficMgr) DeleteAllPoaLoad() (err error)
DeleteAllPoaLoads - Delete all POA entries
func (*TrafficMgr) DeleteTable ¶
func (tm *TrafficMgr) DeleteTable(tableName string) (err error)
DeleteTable - Delete postgis table with provided name
func (*TrafficMgr) DeleteTables ¶
func (tm *TrafficMgr) DeleteTables() (err error)
DeleteTables - Delete all postgis traffic tables
func (*TrafficMgr) DeleteTrafficMgr ¶
func (tm *TrafficMgr) DeleteTrafficMgr() (err error)
DeleteTrafficMgr -
func (*TrafficMgr) DestroyDb ¶
func (tm *TrafficMgr) DestroyDb(name string) (err error)
DestroyDb -- Destroy DB with provided name
func (*TrafficMgr) GetAllGridMap ¶
func (tm *TrafficMgr) GetAllGridMap() (gridMaps map[string]*GridMapTable, err error)
GetAllGridMap - Get GridMap information
func (*TrafficMgr) GetAllPoaLoad ¶
func (tm *TrafficMgr) GetAllPoaLoad() (poaLoadMap map[string]*PoaLoads, err error)
GetAllPoaLoad - Get all POA information
func (*TrafficMgr) GetGridMap ¶
func (tm *TrafficMgr) GetGridMap(area string) (gridMaps *GridMapTable, err error)
GetGridMap - Get GridMap information
func (*TrafficMgr) GetPoaCategory ¶
func (tm *TrafficMgr) GetPoaCategory(longitude float32, latitude float32) (category string, err error)
GetPoaCategory - Get the category for a PoA
func (*TrafficMgr) GetPoaLoad ¶
func (tm *TrafficMgr) GetPoaLoad(poaName string) (poaLoads *PoaLoads, err error)
GetPoaLoad - Get POA Load information
func (*TrafficMgr) PopulateGridMapTable ¶
func (tm *TrafficMgr) PopulateGridMapTable() (err error)
PopulateGridMapTable - Populate the grid_map table
func (*TrafficMgr) PopulatePoaLoad ¶
func (tm *TrafficMgr) PopulatePoaLoad(poaNameList []string, gpsCoordinates [][]float32) (err error)
PopulatePoaLoad - Populate the Traffic Load table
func (*TrafficMgr) PredictQosPerTrafficLoad ¶
func (tm *TrafficMgr) PredictQosPerTrafficLoad(hour int32, inRsrp int32, inRsrq int32, poaName string) (outRsrp int32, outRsrq int32, err error)
Returns Predicted QoS in terms of RSRQ and RSRP values based on Traffic Load patterns