UIAccelerometerDelegate protocol defines a single method for receiving acceleration-related data from the system. Implementation of this method is optional, but expected.
- accelerometer:didAccelerate:(iOS 5.0)
Delivers the latest acceleration data to the delegate.
The application-wide accelerometer object.
The most recent acceleration data.
UIAccelerometerobject invokes this method at the desired interval, providing your delegate with updated acceleration data each time.
This method is always invoked on your application’s main thread when it is in the
NSDefaultRunLoopModerun loop mode.
Available in iOS 2.0 and later.
Deprecated in iOS 5.0.