コード例 #1
0
ファイル: TisController.cs プロジェクト: belsoft/traingraph
        private StateDataViewModel GetStateData(GetStateResponseBody webResponse)
        {
            var model = new StateDataViewModel();

            model.StateResult          = webResponse.GetStateResult;
            model.strOut               = DCSerializer.DeserializeWithDCS <TISWebServiceGetStateSupportOUT>(webResponse.strOut);
            model.onlineTrains         = DCSerializer.DeserializeWithDCS <List <TrainWebData> >(webResponse.onlineTrainsData);
            model.offlineTrains        = DCSerializer.DeserializeWithDCS <List <TrainWebData> >(webResponse.offlineTrainsData);
            model.onlineButNotOnTheMap = DCSerializer.DeserializeWithDCS <List <TrainWebData> >(webResponse.onlineButNotOnTheMapTrainsData);
            model.trainGraphData       = DCSerializer.DeserializeWithDCS <TrainGraphData>(webResponse.trainGraphData);
            model.Error = webResponse.strError;

            return(model);
        }
コード例 #2
0
ファイル: TisController.cs プロジェクト: belsoft/traingraph
        private StateDataViewModel GetStateData(GetStateResponseBody webResponse) 
        {
            var model = new StateDataViewModel();

            model.StateResult = webResponse.GetStateResult;
            model.strOut = DCSerializer.DeserializeWithDCS<TISWebServiceGetStateSupportOUT>(webResponse.strOut);
            model.onlineTrains = DCSerializer.DeserializeWithDCS<List<TrainWebData>>(webResponse.onlineTrainsData);
            model.offlineTrains = DCSerializer.DeserializeWithDCS<List<TrainWebData>>(webResponse.offlineTrainsData);
            model.onlineButNotOnTheMap = DCSerializer.DeserializeWithDCS<List<TrainWebData>>(webResponse.onlineButNotOnTheMapTrainsData);
            model.trainGraphData = DCSerializer.DeserializeWithDCS<TrainGraphData>(webResponse.trainGraphData);
            model.Error = webResponse.strError;

            return model;
        }