Esempio n. 1
0
        public ISection GetShape(string ShapeId, ShapeTypeSteel shapeType, AngleOrientation AngleOrientation = AngleOrientation.LongLegVertical, AngleRotation AngleRotation = AngleRotation.FlatLegBottom)
        {
            string           DEFAULT_EXCEPTION_STRING = "Selected shape is not supported. Specify a different shape.";
            AiscCatalogShape cs  = new AiscCatalogShape(ShapeId, null);
            CalcLog          log = new CalcLog();
            ISection         sec = null;

            switch (shapeType)
            {
            case ShapeTypeSteel.IShapeRolled:
                sec = new PredefinedSectionI(cs);
                break;

            case ShapeTypeSteel.IShapeBuiltUp:
                throw new Exception(DEFAULT_EXCEPTION_STRING);
                break;

            case ShapeTypeSteel.Channel:
                sec = new PredefinedSectionChannel(cs);
                break;

            case ShapeTypeSteel.Angle:
                sec = new PredefinedSectionAngle(cs, AngleOrientation, AngleRotation);
                break;

            case ShapeTypeSteel.TeeRolled:
                throw new Exception(DEFAULT_EXCEPTION_STRING);
                break;

            case ShapeTypeSteel.TeeBuiltUp:
                throw new Exception(DEFAULT_EXCEPTION_STRING);
                break;

            case ShapeTypeSteel.DoubleAngle:
                throw new Exception(DEFAULT_EXCEPTION_STRING);
                break;

            case ShapeTypeSteel.CircularHSS:
                sec = new PredefinedSectionCHS(cs);
                break;

            case ShapeTypeSteel.RectangularHSS:
                sec = new PredefinedSectionRHS(cs);
                break;

            case ShapeTypeSteel.Box:
                throw new Exception(DEFAULT_EXCEPTION_STRING);
                break;

            case ShapeTypeSteel.Rectangular:
                throw new Exception(DEFAULT_EXCEPTION_STRING);
                break;

            case ShapeTypeSteel.Circular:
                throw new Exception(DEFAULT_EXCEPTION_STRING);
                break;

            case ShapeTypeSteel.IShapeAsym:
                throw new Exception(DEFAULT_EXCEPTION_STRING);
                break;

            default:
                break;
            }

            return(sec);
        }
Esempio n. 2
0
        public ISliceableSection GetSliceableSection(string ShapeId, ShapeTypeSteel shapeType)
        {
            ISection          section = this.GetShape(ShapeId, ShapeTypeSteel.IShapeRolled);
            ISliceableSection sec;

            switch (shapeType)
            {
            case ShapeTypeSteel.IShapeRolled:
                PredefinedSectionI catI = section as PredefinedSectionI;
                sec = new SectionIRolled("", catI.d, catI.b_fTop, catI.t_f, catI.t_w, catI.k);
                break;

            case ShapeTypeSteel.IShapeBuiltUp:
                throw new ShapeTypeNotSupportedException("ISliceableSection property ");
                break;

            case ShapeTypeSteel.Channel:
                throw new ShapeTypeNotSupportedException("ISliceableSection property ");
                break;

            case ShapeTypeSteel.Angle:
                throw new ShapeTypeNotSupportedException("ISliceableSection property ");
                break;

            case ShapeTypeSteel.TeeRolled:
                throw new ShapeTypeNotSupportedException("ISliceableSection property ");
                break;

            case ShapeTypeSteel.TeeBuiltUp:
                throw new ShapeTypeNotSupportedException("ISliceableSection property ");
                break;

            case ShapeTypeSteel.DoubleAngle:
                throw new ShapeTypeNotSupportedException("ISliceableSection property ");
                break;

            case ShapeTypeSteel.CircularHSS:
                throw new ShapeTypeNotSupportedException("ISliceableSection property ");
                break;

            case ShapeTypeSteel.RectangularHSS:
                throw new ShapeTypeNotSupportedException("ISliceableSection property ");
                break;

            case ShapeTypeSteel.Box:
                throw new ShapeTypeNotSupportedException("ISliceableSection property ");
                break;

            case ShapeTypeSteel.Rectangular:
                throw new ShapeTypeNotSupportedException("ISliceableSection property ");
                break;

            case ShapeTypeSteel.Circular:
                throw new ShapeTypeNotSupportedException("ISliceableSection property ");
                break;

            case ShapeTypeSteel.IShapeAsym:
                throw new ShapeTypeNotSupportedException("ISliceableSection property ");
                break;

            default:
                throw new ShapeTypeNotSupportedException("ISliceableSection property ");
                break;
            }

            return(sec);
        }