Share

Rebar.RebarShapeMatchesCurvesHooksAndEndTreatment Method

Note: This API is now obsolete.

Checks if rebarShape matches curves, hooks and end treatment. If the RebarShapeDefinesHooks flag in ReinforcementSettings has been set to false, then this method will ignore the hook information. If the RebarShapeDefinesEndTreatment flag in ReinforcementSettings has been set to false, then this method will ignore the end treatment information.


Namespace: Autodesk.Revit.DB.Structure
Assembly: RevitAPI (in RevitAPI.dll) Version: 26.1.0.0 (26.1.0.34)

Syntax

C#

[ObsoleteAttribute("This method is deprecated in Revit 2026 and may be removed in a later version of Revit. Please use RebarShape.RebarShapeMatchesCurvesAndTerminationsData(RebarShape rebarShape, RebarBarType barType, XYZ norm, IList<Curve> curves, BarTerminationsData barTerminationsData) instead.")]
public static bool RebarShapeMatchesCurvesHooksAndEndTreatment(
	RebarShape rebarShape,
	RebarBarType barType,
	XYZ norm,
	IList<Curve> curves,
	RebarHookType startHook,
	RebarHookType endHook,
	RebarHookOrientation startHookOrient,
	RebarHookOrientation endHookOrient,
	double terminationRotationAngleAtStart,
	double terminationRotationAngleAtEnd,
	ElementId endTreatmentTypeIdAtStart,
	ElementId endTreatmentTypeIdAtEnd
)

Parameters

rebarShape  RebarShape
A RebarShape element that defines the shape of the rebar.
barType  RebarBarType
A RebarBarType element that defines bar diameter, bend radius and material of the rebar.
norm  XYZ
The normal to the plane that the rebar curves lie on.
curves  IList<Curve>
An array of curves that define the shape of the rebar curves. They must belong to the plane defined by the normal and origin. Bends and hooks should not be included in the array of curves.
startHook  RebarHookType
A RebarHookType element that defines the hook for the start of the bar.
endHook  RebarHookType
A RebarHookType element that defines the hook for the end of the bar.
startHookOrient  RebarHookOrientation
Defines the orientation of the hook plane at the start of the rebar with respect to the orientation of the first curve and the plane normal. Only two values are permitted: Value = Right: The hook is on your right as you stand at the end of the bar, with the bar behind you, taking the bar's normal as "up." Value = Left: The hook is on your left as you stand at the end of the bar, with the bar behind you, taking the bar's normal as "up."
endHookOrient  RebarHookOrientation
Defines the orientation of the hook plane at the end of the rebar with respect to the orientation of the last curve and the plane normal. Only two values are permitted: Value = Right: The hook is on your right as you stand at the end of the bar, with the bar behind you, taking the bar's normal as "up." Value = Left: The hook is on your left as you stand at the end of the bar, with the bar behind you, taking the bar's normal as "up."
terminationRotationAngleAtStart  Double
The terminations's (e.g. hook) out of plane rotation angle at the start of the bar.
terminationRotationAngleAtEnd  Double
The terminations's (e.g. hook) out of plane rotation angle at the end of the bar.
endTreatmentTypeIdAtStart  ElementId
The end treatment type id at the start of the bar.
endTreatmentTypeIdAtEnd  ElementId
The end treatment type id at the end of the bar.

Return Value

Boolean
True if rebarShape matches curves and hooks.

Exceptions

ExceptionCondition
ArgumentException The input curves is empty. -or- The input curves contains at least one curve which is not a bound Line or bound Arc and is not supported for this operation. -or- curves do not form a valid CurveLoop. -or- The input curves contains at least one helical curve and is not supported for this operation. -or- the parameter endTreatmentTypeIdAtStart is not an EndTreatmentType element. -or- the parameter endTreatmentTypeIdAtEnd is not an EndTreatmentType element. -or- The given value for terminationRotationAngleAtStart is not finite -or- The given value for terminationRotationAngleAtEnd is not finite
ArgumentNullException A non-optional argument was null
ArgumentOutOfRangeException norm has zero length. -or- A value passed for an enumeration argument is not a member of that enumeration

See Also

Reference

Was this information helpful?