예제 #1
0
        private void Stream( ArrayList data, Rebar rebar )
        {
            data.Add( new Snoop.Data.ClassSeparator( typeof( Rebar ) ) );

              data.Add( new Snoop.Data.ElementId( "Bar type", rebar.GetTypeId(), rebar.Document ) );
              data.Add( new Snoop.Data.ElementId( "Rebar shape", rebar.RebarShapeId, rebar.Document ) );
              data.Add( new Snoop.Data.ElementId( "Host", rebar.GetHostId(), rebar.Document ) );
              data.Add( new Snoop.Data.Object( "Distribution path", rebar.GetDistributionPath() ) );
              data.Add( new Snoop.Data.Enumerable( "GetCenterlineCurves(false, false, false)", rebar.GetCenterlineCurves( false, false, false ) ) );
              data.Add( new Snoop.Data.String( "LayoutRule", rebar.LayoutRule.ToString() ) );
              if( rebar.LayoutRule != RebarLayoutRule.Single )
              {
            data.Add( new Snoop.Data.Double( "Distribution path length", rebar.ArrayLength ) );
            data.Add( new Snoop.Data.Int( "Quantity", rebar.Quantity ) );
            data.Add( new Snoop.Data.Int( "NumberOfBarPositions", rebar.NumberOfBarPositions ) );
            data.Add( new Snoop.Data.Double( "MaxSpacing", rebar.MaxSpacing ) );
              }

              //TF
              data.Add( new Snoop.Data.Object( "ConstraintsManager", rebar.GetRebarConstraintsManager() ) );
              //TFEND
        }
        private void Stream( ArrayList data, Rebar rebar )
        {
            data.Add( new Snoop.Data.ClassSeparator( typeof( Rebar ) ) );

              data.Add( new Snoop.Data.ElementId( "Bar type", rebar.GetTypeId(), rebar.Document ) );
              data.Add( new Snoop.Data.ElementId( "Rebar shape", rebar.RebarShapeId, rebar.Document ) );
              data.Add( new Snoop.Data.ElementId( "Host", rebar.GetHostId(), rebar.Document ) );
              data.Add( new Snoop.Data.Object( "Distribution path", rebar.GetDistributionPath() ) );
              data.Add( new Snoop.Data.Enumerable( "GetCenterlineCurves(false, false, false)", rebar.GetCenterlineCurves( false, false, false, MultiplanarOption.IncludeOnlyPlanarCurves, 0 ) ) );
              data.Add( new Snoop.Data.String( "LayoutRule", rebar.LayoutRule.ToString() ) );
              if( rebar.LayoutRule != RebarLayoutRule.Single )
              {
            data.Add( new Snoop.Data.Double( "Distribution path length", rebar.ArrayLength ) );
            data.Add( new Snoop.Data.Int( "Quantity", rebar.Quantity ) );
            data.Add( new Snoop.Data.Int( "NumberOfBarPositions", rebar.NumberOfBarPositions ) );
            data.Add( new Snoop.Data.Double( "MaxSpacing", rebar.MaxSpacing ) );
            data.Add( new Snoop.Data.Bool( "BarsOnNormalSide", rebar.BarsOnNormalSide ) );
              }

              data.Add( new Snoop.Data.String( "ScheduleMark", rebar.ScheduleMark ) );
              data.Add( new Snoop.Data.Double( "Volume", rebar.Volume ) );
              data.Add( new Snoop.Data.Double( "TotalLength", rebar.TotalLength ) );
              data.Add( new Snoop.Data.Object( "Normal", rebar.Normal ) );

              //TF
              data.Add( new Snoop.Data.Object( "ConstraintsManager", rebar.GetRebarConstraintsManager() ) );
              //TFEND

              // Bending data
              data.Add( new Snoop.Data.Object( "Bending Data", rebar.GetBendData() ) );

              // Hook information
              addHookInformation2Rebar( data, rebar, 0 );
              addHookInformation2Rebar( data, rebar, 1 );
        }