iOS Developer Library

Developer

CoreMotion Framework Reference CMLogItem Class Reference

Options
Deployment Target:

On This Page
Language:

CMLogItem

The CMLogItem class is a base class for Core Motion classes that handle specific types of motion events. Objects of this class represent a piece of time-tagged data that can be logged to a file.

CMLogItem defines a read-only timestamp property that records the time a motion-event measurement was taken.

Import Statement


Swift

import CoreMotion

Objective-C

@import CoreMotion;

Availability


Available in iOS 4.0 and later.
  • timestamp timestamp Property

    The time when the logged item is valid. (read-only)

    Declaration

    Swift

    var timestamp: NSTimeInterval { get }

    Objective-C

    @property(readonly, nonatomic) NSTimeInterval timestamp

    Discussion

    The time stamp is the amount of time in seconds since the phone booted.

    Import Statement

    Objective-C

    @import CoreMotion;

    Swift

    import CoreMotion

    Availability

    Available in iOS 4.0 and later.