iOS Developer Library

Developer

CoreTelephony Framework Reference CTCall Class Reference

Options
Deployment Target:

On This Page
Language:

CTCall

Inherits From


Conforms To


Import Statement


Swift

import CoreTelephony

Objective-C

@import CoreTelephony;

Availability


Available in iOS 4.0 and later

Use a cellular call’s CTCall object to obtain an identifier for the call and to determine the call’s state.

  • callID callID Property

    A unique identifier for the cellular call. (read-only)

    Declaration

    Swift

    var callID: String! { get }

    Objective-C

    @property(nonatomic, readonly, copy) NSString *callID

    Discussion

    Use this value to differentiate multiple active cellular calls.

    Import Statement

    Objective-C

    @import CoreTelephony;

    Swift

    import CoreTelephony

    Availability

    Available in iOS 4.0 and later

  • callState callState Property

    The state of the cellular call. (read-only)

    Declaration

    Swift

    var callState: String! { get }

    Objective-C

    @property(nonatomic, readonly, copy) NSString *callState

    Discussion

    A cellular call’s initial state is either CTCallStateDialing or CTCallStateIncoming. When the call is fully established for all parties involved, the state transitions to CTCallStateConnected. When the call is terminated, the state transitions to CTCallStateDisconnected.

    Import Statement

    Objective-C

    @import CoreTelephony;

    Swift

    import CoreTelephony

    Availability

    Available in iOS 4.0 and later

  • States of cellular calls; one of dialing, incoming, connected, or disconnected.

    Declaration

    Swift

    let CTCallStateDialing: String let CTCallStateIncoming: String let CTCallStateConnected: String let CTCallStateDisconnected: String

    Objective-C

    extern NSString const *CTCallStateDialing; extern NSString const *CTCallStateIncoming; extern NSString const *CTCallStateConnected; extern NSString const *CTCallStateDisconnected;

    Constants

    • CTCallStateDialing

      CTCallStateDialing

      The call state, before connection is established, when the user initiates the call.

      Available in iOS 4.0 and later

    • CTCallStateIncoming

      CTCallStateIncoming

      The call state, before connection is established, when a call is incoming but not yet answered by the user.

      Available in iOS 4.0 and later

    • CTCallStateConnected

      CTCallStateConnected

      The call state when the call is fully established for all parties involved.

      Available in iOS 4.0 and later

    • CTCallStateDisconnected

      CTCallStateDisconnected

      The call state upon call termination.

      Available in iOS 4.0 and later