Exemplo n.º 1
0
        public double GetHeight()
        {
            DiveHeight a = this.Height;

            switch (a)
            {
            case DiveHeight._1M:
                return(1);

            case DiveHeight._3M:
                return(3);

            case DiveHeight._5M:
                return(5);

            case DiveHeight._7_5M:
                return(7.5);

            case DiveHeight._10M:
                return(10);

            default:
                return(-1);
            }
        }
Exemplo n.º 2
0
        public void SetHeight(double h)
        {
            switch (h.ToString())
            {
            case "1.0":
                this.Height = DiveHeight._1M;
                break;

            case "3.0":
                this.Height = DiveHeight._3M;
                break;

            case "5.0":
                this.Height = DiveHeight._5M;
                break;

            case "7.5":
                this.Height = DiveHeight._7_5M;
                break;

            case "10.0":
                this.Height = DiveHeight._10M;
                break;

            default:
                break;
            }
        }
Exemplo n.º 3
0
        public DiveType(int no, DivePosition position, DiveHeight height)
        {
            if (_dd == null)
                LoadDDTable();

            _no = no;
            Position = position;
            Height = height;
        }
Exemplo n.º 4
0
        public DiveType(int no, DivePosition position, DiveHeight height)
        {
            if (_dd == null)
            {
                LoadDDTable();
            }

            _no      = no;
            Position = position;
            Height   = height;
        }