Adds a collision boundary, specified as a line segment, to the collision behavior.
- iOS 7.0+
- Mac Catalyst 13.0+
- tvOS 9.0+
An arbitrary identifier for the boundary you are adding.
The starting point for the boundary line segment.
The ending point for the boundary line segment.
This is a convenience method based on the
add method. The coordinate system and origin point for the
p2 parameters depend on how you’ve initialized the dynamic animator (that you’re adding the behavior to). See the overview in
UIDynamic for more information.