예제 #1
0
        public string getName()
        {
            ConfiguratorItem temp = findConfigutaorItemById(resultId);

            return(temp.getName());
        }
예제 #2
0
        public string getName()
        {
            switch (type)
            {
            case 0:
                switch (typeOfMath)
                {
                case 0:
                    return("(" + it1.getName() + " И " + it2.getName() + ")");

                    break;

                case 1:
                    return("(" + it1.getName() + " ИЛИ " + it2.getName() + ")");

                    break;

                case 2:
                    return("НЕ(" + it1.getName() + ")");

                    break;

                case 3:
                    return("(" + it1.getName() + " + " + it2.getName() + ")");

                    break;

                case 4:
                    return("(" + it1.getName() + " - " + it2.getName() + ")");

                    break;

                case 5:
                    return("(" + it1.getName() + " / " + it2.getName() + ")");

                    break;

                case 6:
                    return("(" + it1.getName() + " * " + it2.getName() + ")");

                    break;

                case 7:
                    return("(" + it1.getName() + "=" + it2.getName() + ")");

                    break;

                case 8:
                    return("(" + it1.getName() + ">" + it2.getName() + ")");

                    break;

                case 9:
                    return("(" + it1.getName() + "<" + it2.getName() + ")");

                    break;

                case 10:
                    return("(" + it1.getName() + ">=" + it2.getName() + ")");

                    break;

                case 11:
                    return("(" + it1.getName() + "<=" + it2.getName() + ")");

                    break;
                }
                break;

            case 1:
                return(valueOfConst.ToString());

                break;

            case 2:
                try
                {
                    return(getNameOfSensor(idOfSensor));
                }
                catch { return("Fatal"); }
                break;

            case 3:
                return(time.ToString());

                break;

            default:
                return("");

                break;
            }
            return("");
        }