//public GsaElement1d(Element element, LineCurve line)
        //{
        //    m_element = element;
        //    m_line = line;
        //}

        public GsaElement1d Duplicate()
        {
            GsaElement1d dup = new GsaElement1d
            {
                m_element = m_element //add clone or duplicate if available
            };

            if (m_line != null)
            {
                dup.m_line = (LineCurve)m_line.Duplicate();
            }
            dup.ID = m_id;

            if (m_rel1 != null)
            {
                dup.ReleaseStart = m_rel1.Duplicate();
            }
            if (m_rel2 != null)
            {
                dup.ReleaseEnd = m_rel2.Duplicate();
            }
            if (m_section != null)
            {
                dup.Section = m_section.Duplicate();
            }

            return(dup);
        }
        public GsaMember1d Duplicate()
        {
            GsaMember1d dup = new GsaMember1d
            {
                m_member = m_member //add clone or duplicate if available
            };

            if (m_crv != null)
            {
                dup.m_crv = m_crv.DuplicatePolyCurve();
            }

            Point3dList point3Ds = new Point3dList(m_topo);

            dup.Topology     = new List <Point3d>(point3Ds.Duplicate());
            dup.TopologyType = m_topoType.ToList();

            dup.ID = m_id;

            if (m_rel1 != null)
            {
                dup.ReleaseStart = m_rel1.Duplicate();
            }
            if (m_rel2 != null)
            {
                dup.ReleaseEnd = m_rel2.Duplicate();
            }
            if (m_section != null)
            {
                dup.Section = m_section.Duplicate();
            }

            return(dup);
        }
        //public GsaElement1d(Element element, LineCurve line)
        //{
        //    m_element = element;
        //    m_line = line;
        //}

        public GsaElement1d Duplicate()
        {
            if (this == null)
            {
                return(null);
            }
            GsaElement1d dup = new GsaElement1d();

            dup.m_element = new Element()
            {
                Group            = m_element.Group,
                IsDummy          = m_element.IsDummy,
                Name             = m_element.Name.ToString(),
                Offset           = m_element.Offset,
                OrientationAngle = m_element.OrientationAngle,
                OrientationNode  = m_element.OrientationNode,
                ParentMember     = m_element.ParentMember,
                Property         = m_element.Property,
                Topology         = new ReadOnlyCollection <int>(m_element.Topology.ToList()),
                Type             = m_element.Type //GsaToModel.Element1dType((int)Element.Type)
            };


            if ((System.Drawing.Color)m_element.Colour != System.Drawing.Color.FromArgb(0, 0, 0)) // workaround to handle that System.Drawing.Color is non-nullable type
            {
                dup.m_element.Colour = m_element.Colour;
            }

            dup.Element.Offset.X1 = m_element.Offset.X1;
            dup.Element.Offset.X2 = m_element.Offset.X2;
            dup.Element.Offset.Y  = m_element.Offset.Y;
            dup.Element.Offset.Z  = m_element.Offset.Z;

            if (m_line != null)
            {
                dup.m_line = (LineCurve)m_line.Duplicate();
            }
            dup.ID = m_id;

            if (m_rel1 != null)
            {
                dup.ReleaseStart = m_rel1.Duplicate();
            }
            if (m_rel2 != null)
            {
                dup.ReleaseEnd = m_rel2.Duplicate();
            }
            if (m_section != null)
            {
                dup.Section = m_section.Duplicate();
            }

            return(dup);
        }
        public GsaMember1d Duplicate()
        {
            if (this == null)
            {
                return(null);
            }

            GsaMember1d dup = new GsaMember1d
            {
                Member = new Member
                {
                    Group            = m_member.Group,
                    IsDummy          = m_member.IsDummy,
                    MeshSize         = m_member.MeshSize,
                    Name             = m_member.Name.ToString(),
                    Offset           = m_member.Offset,
                    OrientationAngle = m_member.OrientationAngle,
                    OrientationNode  = m_member.OrientationNode,
                    Property         = m_member.Property,
                    Topology         = m_member.Topology.ToString(),
                    Type             = m_member.Type,  //GsaToModel.Member1dType((int)Member.Type),
                    Type1D           = m_member.Type1D //GsaToModel.Element1dType((int)Member.Type1D)
                }
            };

            if ((System.Drawing.Color)m_member.Colour != System.Drawing.Color.FromArgb(0, 0, 0)) // workaround to handle that System.Drawing.Color is non-nullable type
            {
                dup.m_member.Colour = m_member.Colour;
            }

            dup.Member.Offset.X1 = m_member.Offset.X1;
            dup.Member.Offset.X2 = m_member.Offset.X2;
            dup.Member.Offset.Y  = m_member.Offset.Y;
            dup.Member.Offset.Z  = m_member.Offset.Z;

            if (m_crv != null)
            {
                dup.m_crv = m_crv.DuplicatePolyCurve();
            }

            Point3dList point3Ds = new Point3dList(m_topo);

            dup.Topology     = new List <Point3d>(point3Ds.Duplicate());
            dup.TopologyType = m_topoType.ToList();

            dup.ID = m_id;

            if (m_rel1 != null)
            {
                dup.ReleaseStart = m_rel1.Duplicate();
            }
            if (m_rel2 != null)
            {
                dup.ReleaseEnd = m_rel2.Duplicate();
            }
            if (m_section != null)
            {
                dup.Section = m_section.Duplicate();
            }

            return(dup);
        }