예제 #1
0
        public static async Task <Trajet> GettrajetDetailsToShowOnScreen(IFileAccessManager logFileManager, int itrajetLocalID)
        {
            return(await Task.Factory.StartNew(() =>
            {
                Trajet res = LocalDatabase.Get().Gettrajet(logFileManager, itrajetLocalID);

                return GettrajetDetailsToShowOnScreen(logFileManager, res);
            }));
        }
예제 #2
0
파일: Arret.cs 프로젝트: espritm/TrajetTram
        public override string ToString()
        {
            Trajet trajet = LocalDatabase.Get().Gettrajet(null, m_iLocalIDtrajet);

            StringBuilder sb = new StringBuilder();

            sb.AppendLine("Arret {");
            sb.AppendLine("   m_iLocalID = " + m_iLocalID + ", ");
            sb.AppendLine("   m_iLocalIDtrajet = " + m_iLocalIDtrajet + ", ");
            sb.AppendLine("   trajet's ref number = " + trajet?.m_sRefNumber ?? "null" + ", ");
            sb.AppendLine("   m_sName = " + m_sName + ", ");
            sb.AppendLine("   m_dPente = " + m_dPente + ", ");
            sb.AppendLine("   m_sTime = " + m_sTime + ", ");
            sb.AppendLine("   m_lat = " + m_lat + ", ");
            sb.AppendLine("   m_lon = " + m_lon + ", ");
            sb.AppendLine("   m_bIsStopPoint = " + m_bIsStopPoint + ", ");
            sb.AppendLine("   m_sStopTime = " + m_sStopTime + ", ");
            sb.AppendLine("   m_sRadioCanal = " + m_sRadioCanal + ", ");
            sb.AppendLine("}");

            return(sb.ToString());
        }
예제 #3
0
        private static Trajet GettrajetDetailsToShowOnScreen(IFileAccessManager logFileManager, Trajet trajet)
        {
            if (trajet == null)
            {
                return(null);
            }

            List <Arret> lsarret = LocalDatabase.Get().GetArretOftrajet(logFileManager, trajet);

            trajet.m_lsarret = new List <Arret>();


            if (lsarret != null && lsarret.Count > 0)
            {
                trajet.m_lsarret.AddRange(lsarret);
            }

            return(trajet);
        }