Protocol

UIInteraction

The protocol that an interaction implements to access the view that owns it.

Declaration

protocol UIInteraction

Topics

Getting the View

var view: UIView?

The view that owns the interaction.

Required.

Tracking the Movements

func didMove(to: UIView?)

Tells the interaction that a view added or removed it from the view's interactions array.

Required.

func willMove(to: UIView?)

Tells the interaction that a view will add or remove it from the view's interactions array.

Required.

See Also

Adding and Removing Interactions

func addInteraction(UIInteraction)

Adds an interaction to the view.

func removeInteraction(UIInteraction)

Removes an interaction from the view.

var interactions: [UIInteraction]

The array of interactions for the view.