Exemple #1
0
        public static CdmaCompoundCellView ConstructView(this CdmaCell onexCell, CdmaCell evdoCell, IBtsRepository repository)
        {
            CdmaCompoundCellView view = null;

            if (onexCell != null)
            {
                view = Mapper.Map <CdmaCell, CdmaCompoundCellView>(onexCell);
                view.OnexFrequencyList = onexCell.FrequencyList;
                if (evdoCell != null)
                {
                    view.EvdoFrequencyList = evdoCell.FrequencyList;
                }
            }
            else if (evdoCell != null)
            {
                view = Mapper.Map <CdmaCell, CdmaCompoundCellView>(evdoCell);
                view.EvdoFrequencyList = evdoCell.FrequencyList;
            }

            if (view != null)
            {
                var bts = repository.GetByBtsId(view.BtsId);
                view.BtsName = bts?.Name;
            }

            return(view);
        }
Exemple #2
0
        public CdmaCompoundCellView QueryCell(int btsId, byte sectorId)
        {
            var onexCell = _repository.GetBySectorIdAndCellType(btsId, sectorId, "1X");
            var evdoCell = _repository.GetBySectorIdAndCellType(btsId, sectorId, "DO");

            return(CdmaCompoundCellView.ConstructView(onexCell, evdoCell, _btsRepository));
        }