Example #1
0
        /// <summary>
        /// add the next city location to the list of cities
        /// </summary>
        private void Travel()
        {
            string nextCity;

            nextCity = _consoleView.DisplayGetNextCity();

            _salesperson.CitiesVisited.Add(nextCity);
        }
        public void Travel()
        {
            string nextCity = _consoleView.DisplayGetNextCity();

            if (nextCity != "")
            {
                _salesperson.CitiesVisited.Add(nextCity);
            }
        }
        private void Travel()
        {
            string nextCity = _consoleView.DisplayGetNextCity();

            //if nextCity is NOT blank, then add it to the list.
            if (nextCity != "")
            {
                _salesperson.CitiesVisited.Add(nextCity);
            }
        }
Example #4
0
        /// <summary>
        /// add the next city location to the list of cities
        /// </summary>
        private void Travel()
        {
            string nextCity = _consoleview.DisplayGetNextCity();

            //
            // add next city to list only if the string isn't empty
            //
            if (nextCity != "")
            {
                _salesperson.CitiesVisited.Add(nextCity);
            }
        }
Example #5
0
        /// <summary>
        /// add the next city location to the list of cities
        /// </summary>
        private void Travel()
        {
            string nextCity = _consoleView.DisplayGetNextCity();

            //
            // do not add empty strings to list for city names
            //
            if (nextCity != "")
            {
                _salesperson.CitiesVisited.Add(nextCity);
            }
        }
Example #6
0
        /// <summary>
        /// add the next city location to the list of cities
        /// </summary>
        private void Travel()
        {
            ConsoleUtil.HeaderText = "Traveling";
            ConsoleUtil.DisplayReset();

            string nextCity = _consoleView.DisplayGetNextCity();

            if (nextCity != "")
            {
                _salesperson.CitiesVisited.Add(nextCity);
            }
        }