Ejemplo n.º 1
0
        internal string GetInfoZone(string zoneName)
        {
            bool[] filters = filterControl.GetFiltersInformation();

            IZone zone = parkSystem.GetZone(zoneName);

            string infoZone = GetDefaultInfoZone(zone);
            IPark  park     = (IPark)zone;

            if (filters[FilterControl.COST])
            {
                infoZone += "Precio total: " + "\n" + park.GetCost() + "\n";
            }

            if (filters[FilterControl.SCHEDULE])
            {
                infoZone += "Horario de apertura: " + park.GetSchedule() + "\n";
            }

            if (filters[FilterControl.VISITS])
            {
                infoZone += "Visitas Ultimos dos años: " + (park.GetVisits().GetTotalVisits((DateTime.Now.Year - 6) + "") + park.GetVisits().GetTotalVisits((DateTime.Now.Year - 7) + ""))
                            + "\n";
            }

            if (filters[FilterControl.FORECAST])
            {
                infoZone += "Pronostico de visitas: " + park.GetVisits().GetForecastVisits("2018") + "\n";
            }


            infoZone += GetDefaultInfoPolygon(zone.GetPolygonArea());



            return(infoZone);
        }