Contents

isDescendant(of:)

Returns a Boolean value indicating whether the receiver is a subview of a given view or identical to that view.

Declaration

func isDescendant(of view: UIView) -> Bool

Parameters

  • view:

    The view to test against the receiver’s view hierarchy.

Return Value

true if the receiver is an immediate or distant subview of view or if view is the receiver itself; otherwise false.

See Also

Managing the view hierarchy