Exemple #1
0
        private Boolean IsInStationsString(String StationName, String StationsString)
        {
            Boolean     retVal = false;
            StationData actSD  = this.getStationData(StationName);

            Array ar_stationIndexes = StationsString.Split(';');

            foreach (String actStationIndex in ar_stationIndexes)
            {
                if (actSD.Identifier == actStationIndex)
                {
                    return(true);
                }
            }

            return(retVal);
        }
Exemple #2
0
        public Boolean IsStationInList(String StationName)
        {
            Boolean retval = false;

            XmlNode myXMLStNode = myXMLDoc.SelectSingleNode("NewLoginConfiguration/Stations");

            foreach (XmlNode actStationNode in myXMLStNode.ChildNodes)
            {
                StationData actSD = this.getStationData(actStationNode);
                if (actSD.Name == StationName)
                {
                    retval = true;
                    break;
                }
            }

            return(retval);
        }
Exemple #3
0
        public void SaveOperatorData(OperatorData Operator, Array StationNames)
        {
            Operator.Stations = "";
            foreach (String actStationName in StationNames)
            {
                if (!IsStationInList(actStationName))
                {
                    this.saveNewStation(actStationName);
                }
                StationData actSD = getStationData(actStationName);
                if (Operator.Stations == "")
                {
                    Operator.Stations = actSD.Identifier;
                }
                else
                {
                    Operator.Stations = String.Concat(Operator.Stations, ";", actSD.Identifier);
                }
            }

            this.saveOperatorData(Operator);
        }