Skip to content

RebarShapeDrivenAccessor

Public Class

A class that is used to access the properties and capabilities of shape-driven Rebar.

Inheritance Hierarchy

System.Object
Autodesk.Revit.DB.Structure.RebarShapeDrivenAccessor

Namespace: Autodesk.Revit.DB.Structure

Assembly: RevitAPI (in RevitAPI.dll) Version: 25.0.0.0 (25.0.0.0)

Syntax

public class RebarShapeDrivenAccessor : IDisposable

The RebarShapeDrivenAccessor type exposes the following members.

Properties

Name

Description


Public Property

Identifies the distribution path length of rebar set.


Public Property

Identifies if the bars of the rebar set are on the same side of the rebar plane indicated by the normal.


Public Property
BaseFinishingTurns

For a spiral, the number of finishing turns at the lower end of the spiral.


Public Property
Height

For a spiral, the overall height.


Public Property
IsValidObject

Specifies whether the .NET object represents a valid Revit entity.


Public Property
MultiplanarDepth

For a multiplanar rebar, the depth of the instance.


Public Property

A unit-length vector normal to the plane of the rebar


Public Property
Pitch

For a spiral, the pitch, or vertical distance traveled in one rotation.


Public Property
TopFinishingTurns

For a spiral, the number of finishing turns at the upper end of the spiral.


Public Property
UseRebarConstraintsToProduceVaryingBars

Identifies if the rebar constraints should be used to compute each bar in set (which can produce varying length bars).


Methods

Name

Description


Public Method
ComputeDrivingCurves

Compute the driving curves.


Public Method

Releases all resources used by the RebarShapeDrivenAccessor


Public Method

Equals

Determines whether the specified object is equal to the current object.
(Inherited from Object)


Public Method

Flips the rebar set by changing the RebarPlane with the OutOfPlaneExtent and vice versa.


Public Method
GetBarPositionTransform

Return a transform representing the relative position of any individual bar in the set.


Public Method

The distribution path of a rebar set.


Public Method

GetHashCode

Serves as the default hash function.
(Inherited from Object)


Public Method

GetType

Gets the Type of the current instance.
(Inherited from Object)


Public Method

Move and resize the bar to fit within a specified box. The arguments are interpreted as an arbitrary rectangle in 3D with vertices: origin, origin+xVec, origin+xVec+yVec, origin+yVec. The algorithm then proceeds as follows. First the bar is given the default values of the shape parameters from the shape definition. Then, if it is possible to do so without violating the shape definition, the parameter values are scaled so that the width and height of the shape (including bar thickness) match the lengths of xVec and yVec. If there is no way to do this within the shape definition due to overconstraining, a compromise is attempted, such as scaling the whole shape until either the width or the height is correct. Finally the shape is rotated to match the coordinate system of the box. The algorithm is the same one used in one-click placement.


Public Method

Move and resize a spiral or multiplanar instance to fit within a specified box. The arguments are interpreted as an arbitrary rectangle in 3D with vertices: origin, origin+xVec, origin+xVec+yVec, origin+yVec. One end of the rebar shape is inscribed in this rectangle following the procedure described for the ScaleToBox method. The other end is placed in the parallel plane at distance (center-to-center) given by the height argument, in the direction of (xVec x yVec). Note that spiral shapes interpret the input arguments using a different convention than multiplanar shapes. For spiral shapes, the spiral start will be placed in the rectangle defined by origin, xVec, yVec, and the end of the spiral will be placed in the parallel plane. For multiplanar shapes, the rebar is placed with its primary shape definition located in the parallel plane defined by the height argument, and its connector segments extending in the direction opposite (xVec x yVec). This method replaces ScaleToBoxForSpiral() from prior releases.


Public Method
SetLayoutAsFixedNumber

Sets the Layout Rule property of rebar set to FixedNumber.


Public Method
SetLayoutAsMaximumSpacing

Sets the Layout Rule property of rebar set to MaximumSpacing


Public Method
SetLayoutAsMinimumClearSpacing

Sets the Layout Rule property of rebar set to MinimumClearSpacing


Public Method
SetLayoutAsNumberWithSpacing

Sets the Layout Rule property of rebar set to NumberWithSpacing


Public Method
SetLayoutAsSingle

Sets the Layout Rule property of rebar set to Single.


Public Method

Changes the RebarShape element that defines the shape of the rebar. Changing the value of this member causes the Rebar instance to choose values for its shape parameters to preserve its previous shape as closely as possible


Public Method

ToString

Returns a string that represents the current object.
(Inherited from Object)


Remarks

Obtain an instance of this class from

. The accessor includes a reference to the Rebar element. If the referenced Rebar element is deleted, using the methods form this class will throw exception.