Mac Developer Library

Developer

DRCoreErrors.h Reference

Options
Deployment Target:

On This Page
Language:

DRCoreErrors.h Reference

Inheritance


Not Applicable

Conforms To


Not Applicable

Import Statement


Swift

import DiscRecording

Objective-C

@import DiscRecording;

Disc Recording error codes and descriptions.

Disc Recording provides functions to map OS errors it defines and sense information returned from device command errors to localized string representations.

Included Headers

  • <CoreServices/CoreServices.h>

  • <AvailabilityMacros.h>

Functions

  • Maps the Additional Sense Code (ASC) and Additional Sense Key Qualifier (ASCQ) to a localized string.

    Declaration

    Swift

    func DRCopyLocalizedStringForAdditionalSense(_ ASC: UInt8, _ ASCQ: UInt8) -> Unmanaged<CFString>!

    Objective-C

    CFStringRef DRCopyLocalizedStringForAdditionalSense ( UInt8 ASC, UInt8 ASCQ );

    Parameters

    ASC

    The Additional Sense Code generated by a device conforming the SCSI standard.

    ASCQ

    The Additional Sense Code Qualifier generated by a device conforming to the SCSI standard.

    Return Value

    A value of type CFStringRef containing the localized string. This reference is implicitly retained by the caller.

    Discussion

    This function takes an ASC/ASCQ pair and finds the correct localized string corresponding to that pair. The function attempts to find the exact pair, followed by one of the range ASC codes. If neither of those can be found, it will determine if the pair is reserved or is a vendor specific pair and will return a string indicating that. If a localized string cannot be found, it will return the ASC and ASCQ codes as a string.

    Import Statement

    Objective-C

    @import DiscRecording;

    Swift

    import DiscRecording

    Availability

    Available in OS X v10.2 and later.

  • Maps an operating system error code to a localized string.

    Declaration

    Swift

    func DRCopyLocalizedStringForDiscRecordingError(_ osError: OSStatus) -> Unmanaged<CFString>!

    Objective-C

    CFStringRef DRCopyLocalizedStringForDiscRecordingError ( OSStatus osError );

    Parameters

    osError

    The OS error code.

    Return Value

    A value of type CFStringRef which contains the localized string. This reference is implicitly retained by the caller.

    Discussion

    If a localized string cannot be found, this function returns the error code as a string.

    Import Statement

    Objective-C

    @import DiscRecording;

    Swift

    import DiscRecording

    Availability

    Available in OS X v10.2 and later.

  • Maps a SCSI sense code to a localized string.

    Declaration

    Swift

    func DRCopyLocalizedStringForSenseCode(_ senseCode: UInt8) -> Unmanaged<CFString>!

    Objective-C

    CFStringRef DRCopyLocalizedStringForSenseCode ( UInt8 senseCode );

    Parameters

    senseCode

    A sense code generated by a device conforming to the SCSI standard.

    Return Value

    A value of type CFStringRef containing the localized string. This reference is implicitly retained by the caller.

    Discussion

    This function takes a sense code and finds the corresponding localized string. If a localized string cannot be found, it returns the sense code as a string.

    Import Statement

    Objective-C

    @import DiscRecording;

    Swift

    import DiscRecording

    Availability

    Available in OS X v10.2 and later.

Constants

See the Overview section above for header-level documentation.

  • Declaration

    Swift

    let kDRErrorStatusAdditionalSenseStringKey: CFString! let kDRErrorStatusErrorInfoStringKey: CFString! let kDRErrorStatusErrorKey: CFString! let kDRErrorStatusErrorStringKey: CFString! let kDRErrorStatusKey: CFString! let kDRErrorStatusSenseCodeStringKey: CFString! let kDRErrorStatusSenseKey: CFString!

    Objective-C

    extern const CFStringRef kDRErrorStatusAdditionalSenseStringKey; extern const CFStringRef kDRErrorStatusErrorInfoStringKey; extern const CFStringRef kDRErrorStatusErrorKey; extern const CFStringRef kDRErrorStatusErrorStringKey; extern const CFStringRef kDRErrorStatusKey; extern const CFStringRef kDRErrorStatusSenseCodeStringKey; extern const CFStringRef kDRErrorStatusSenseKey;

    Constants

    • kDRErrorStatusAdditionalSenseStringKey

      kDRErrorStatusAdditionalSenseStringKey

      A key for the DRErrorStatus dictionary. The value of this key is a CFString object containing the localized string describing the additonal sense from the sense data for the failure. This value is optional and will not be present if the kDRErrorStatusSenseKey key is not present or if a suitable string does not exist to describe the failure.

      Available in OS X v10.2 and later.

    • kDRErrorStatusErrorInfoStringKey

      kDRErrorStatusErrorInfoStringKey

      A key for the DRErrorStatus dictionary. The value of this key is a CFString object containing a string providing additional information for the error. This value is optional and may not be present if a suitable string does not exist to describe the failure.

      Available in OS X v10.4 and later.

    • kDRErrorStatusErrorKey

      kDRErrorStatusErrorKey

      A key for the DRErrorStatus dictionary. The value of this key is a CFNumber object containing the OSStatus value corresponding to the failure.

      Available in OS X v10.2 and later.

    • kDRErrorStatusErrorStringKey

      kDRErrorStatusErrorStringKey

      A key for the DRErrorStatus dictionary. The value of this key is a CFString object containing the localized string describing the kDRErrorStatusErrorKey key. This value is optional and may not be present if a suitable string does not exist to describe the failure.

      Available in OS X v10.2 and later.

    • kDRErrorStatusKey

      kDRErrorStatusKey

      A key for the DRErrorStatus dictionary, returned by any of the DRxxxCopyStatus calls or kDRxxxStatusChangedNotifications, to describe a failure. The value of this key is a CFDictionary object containing error code and device sense information.

      Available in OS X v10.2 and later.

    • kDRErrorStatusSenseCodeStringKey

      kDRErrorStatusSenseCodeStringKey

      A key for the DRErrorStatus dictionary. The value of this key is a CFString object containing the localized string describing the sense key from the sense data for the failure. This value is optional and will not be present if the kDRErrorStatusSenseKey key is not present or if a suitable string does not exist to describe the failure.

      Available in OS X v10.2 and later.

    • kDRErrorStatusSenseKey

      kDRErrorStatusSenseKey

      A key for the DRErrorStatus dictionary. The value of this key is a CFData object containing the device sense data describing the failure. This value is optional and may not be present if the failure was not device-related, or if the device failed in a way which did not provide meaningful sense data.

      Available in OS X v10.2 and later.

  • Declaration

    Swift

    var kDRInternalErr: UInt32 { get } var kDRDeviceAccessErr: UInt32 { get } var kDRDeviceBusyErr: UInt32 { get } var kDRDeviceCommunicationErr: UInt32 { get } var kDRDeviceInvalidErr: UInt32 { get } var kDRDeviceNotReadyErr: UInt32 { get } var kDRDeviceNotSupportedErr: UInt32 { get } var kDRMediaBusyErr: UInt32 { get } var kDRMediaNotPresentErr: UInt32 { get } var kDRMediaNotWritableErr: UInt32 { get } var kDRMediaNotSupportedErr: UInt32 { get } var kDRMediaNotBlankErr: UInt32 { get } var kDRMediaNotErasableErr: UInt32 { get } var kDRMediaInvalidErr: UInt32 { get } var kDRBurnUnderrunErr: UInt32 { get } var kDRBurnNotAllowedErr: UInt32 { get } var kDRDataProductionErr: UInt32 { get } var kDRVerificationFailedErr: UInt32 { get } var kDRTooManyTracksForDVDErr: UInt32 { get } var kDRBadLayoutErr: UInt32 { get } var kDRUserCanceledErr: UInt32 { get } var kDRFunctionNotSupportedErr: UInt32 { get } var kDRSpeedTestAlreadyRunningErr: UInt32 { get } var kDRInvalidIndexPointsErr: UInt32 { get } var kDRDoubleLayerL0DataZoneBlocksParamErr: UInt32 { get } var kDRDoubleLayerL0AlreadySpecifiedErr: UInt32 { get } var kDRAudioFileNotSupportedErr: UInt32 { get } var kDRBurnPowerCalibrationErr: UInt32 { get } var kDRBurnMediaWriteFailureErr: UInt32 { get } var kDRTrackReusedErr: UInt32 { get } var kDRFileModifiedDuringBurnErr: UInt32 { get } var kDRFileLocationConflictErr: UInt32 { get } var kDRTooManyNameConflictsErr: UInt32 { get } var kDRFilesystemsNotSupportedErr: UInt32 { get } var kDRDeviceCantWriteCDTextErr: UInt32 { get } var kDRDeviceBurnStrategyNotAvailableErr: UInt32 { get } var kDRDeviceCantWriteIndexPointsErr: UInt32 { get } var kDRDeviceCantWriteISRCErr: UInt32 { get } var kDRDeviceCantWriteSCMSErr: UInt32 { get } var kDRDevicePreGapLengthNotValidErr: UInt32 { get }

    Objective-C

    enum { kDRFirstErr = 0x80020000, kDRInternalErr = kDRFirstErr, /* device errors */ kDRDeviceAccessErr = 0x80020020, kDRDeviceBusyErr = 0x80020021, kDRDeviceCommunicationErr = 0x80020022, kDRDeviceInvalidErr = 0x80020023, kDRDeviceNotReadyErr = 0x80020024, kDRDeviceNotSupportedErr = 0x80020025, /* media errors */ kDRMediaBusyErr = 0x80020040, kDRMediaNotPresentErr = 0x80020041, kDRMediaNotWritableErr = 0x80020042, kDRMediaNotSupportedErr = 0x80020043, kDRMediaNotBlankErr = 0x80020044, kDRMediaNotErasableErr = 0x80020045, kDRMediaInvalidErr = 0x80020046, /* burn errors */ kDRBurnUnderrunErr = 0x80020060, kDRBurnNotAllowedErr = 0x80020061, kDRDataProductionErr = 0x80020062, kDRVerificationFailedErr = 0x80020063, kDRTooManyTracksForDVDErr = 0x80020064, kDRBadLayoutErr = 0x80020065, kDRUserCanceledErr = 0x80020066, kDRFunctionNotSupportedErr = 0x80020067, kDRSpeedTestAlreadyRunningErr = 0x80020068, kDRInvalidIndexPointsErr = 0x80020069, kDRDoubleLayerL0DataZoneBlocksParamErr = 0x8002006A, kDRDoubleLayerL0AlreadySpecifiedErr = 0x8002006B, kDRAudioFileNotSupportedErr = 0x8002006C, kDRBurnPowerCalibrationErr = 0x8002006D, kDRBurnMediaWriteFailureErr = 0x8002006E, kDRTrackReusedErr = 0x8002006F, /* content errors */ kDRFileModifiedDuringBurnErr = 0x80020100, kDRFileLocationConflictErr = 0x80020101, kDRTooManyNameConflictsErr = 0x80020102, kDRFilesystemsNotSupportedErr = 0x80020103, /* drive feature errors */ kDRDeviceBurnStrategyNotAvailableErr = 0x80020200, kDRDeviceCantWriteCDTextErr = 0x80020201, kDRDeviceCantWriteIndexPointsErr = 0x80020202, kDRDeviceCantWriteISRCErr = 0x80020203, kDRDeviceCantWriteSCMSErr = 0x80020204, kDRDevicePreGapLengthNotValidErr = 0x80020205 };

    Constants

    • kDRInternalErr

      kDRInternalErr

      Internal Disc Recording error.

      Available in OS X v10.2 and later.

    • kDRDeviceAccessErr

      kDRDeviceAccessErr

      Device is not accessible, hardware is disconnected, etc.

      Available in OS X v10.2 and later.

    • kDRDeviceBusyErr

      kDRDeviceBusyErr

      Device is in use by another process

      Available in OS X v10.2 and later.

    • kDRDeviceCommunicationErr

      kDRDeviceCommunicationErr

      Device failed to respond properly, unable to recover or retry.

      Available in OS X v10.2 and later.

    • kDRDeviceInvalidErr

      kDRDeviceInvalidErr

      Attempt was made to use an invalid DRDeviceRef.

      Available in OS X v10.2 and later.

    • kDRDeviceNotReadyErr

      kDRDeviceNotReadyErr

      Device is unable to respond now, please try again later.

      Available in OS X v10.2 and later.

    • kDRDeviceNotSupportedErr

      kDRDeviceNotSupportedErr

      Device is not supported for the requested burn operation.

      Available in OS X v10.2 and later.

    • kDRMediaBusyErr

      kDRMediaBusyErr

      Disc is busy, usually indicating the volume is unmountable.

      Available in OS X v10.2 and later.

    • kDRMediaNotPresentErr

      kDRMediaNotPresentErr

      Disc isn't present, and needs to be.

      Available in OS X v10.2 and later.

    • kDRMediaNotWritableErr

      kDRMediaNotWritableErr

      Disc isn't writable, and needs to be.

      Available in OS X v10.2 and later.

    • kDRMediaNotSupportedErr

      kDRMediaNotSupportedErr

      Disc isn't supported for the requested burn operation.

      Available in OS X v10.2 and later.

    • kDRMediaNotBlankErr

      kDRMediaNotBlankErr

      Disc isn't blank, and the requested operation needs it to be.

      Available in OS X v10.2 and later.

    • kDRMediaNotErasableErr

      kDRMediaNotErasableErr

      Disc isn't erasable, and the requested operation needs it to be.

      Available in OS X v10.3 and later.

    • kDRMediaInvalidErr

      kDRMediaInvalidErr

      Requested operation attempted on invalid media.

      Available in OS X v10.5 and later.

    • kDRBurnUnderrunErr

      kDRBurnUnderrunErr

      The burn failed because the device drained its buffer without burn underrun protection.

      Available in OS X v10.2 and later.

    • kDRBurnNotAllowedErr

      kDRBurnNotAllowedErr

      User is not allowed to burn to this device on this system.

      Available in OS X v10.2 and later.

    • kDRDataProductionErr

      kDRDataProductionErr

      Error while producing data for the burn

      Available in OS X v10.2 and later.

    • kDRVerificationFailedErr

      kDRVerificationFailedErr

      Data verification failed

      Available in OS X v10.2 and later.

    • kDRTooManyTracksForDVDErr

      kDRTooManyTracksForDVDErr

      DVD discs can contain only one track

      Available in OS X v10.2 and later.

    • kDRBadLayoutErr

      kDRBadLayoutErr

      Too many tracks or sessions

      Available in OS X v10.2 and later.

    • kDRUserCanceledErr

      kDRUserCanceledErr

      User canceled the burn

      Available in OS X v10.2 and later.

    • kDRFunctionNotSupportedErr

      kDRFunctionNotSupportedErr

      Track producer cannot perform requested function

      Available in OS X v10.2 and later.

    • kDRSpeedTestAlreadyRunningErr

      kDRSpeedTestAlreadyRunningErr

      Speed test is already running on requested track

      Available in OS X v10.5 and later.

    • kDRInvalidIndexPointsErr

      kDRInvalidIndexPointsErr

      Index points were invalid (overlap, out-of-range, etc)

      Available in OS X v10.5 and later.

    • kDRDoubleLayerL0DataZoneBlocksParamErr

      kDRDoubleLayerL0DataZoneBlocksParamErr

      Layer 0 transition point is invalid

      Available in OS X v10.5 and later.

    • kDRDoubleLayerL0AlreadySpecifiedErr

      kDRDoubleLayerL0AlreadySpecifiedErr

      Layer 0 transition point is already specified for this media

      Available in OS X v10.5 and later.

    • kDRAudioFileNotSupportedErr

      kDRAudioFileNotSupportedErr

      The audio file producer does not support the requested file.

      Available in OS X v10.5 and later.

    • kDRBurnPowerCalibrationErr

      kDRBurnPowerCalibrationErr

      The device failed to calibrate the laser power level for this media.

      Available in OS X v10.5 and later.

    • kDRBurnMediaWriteFailureErr

      kDRBurnMediaWriteFailureErr

      The burn failed because of a medium write error.

      Available in OS X v10.5 and later.

    • kDRTrackReusedErr

      kDRTrackReusedErr

      One or more tracks were included multiple times in the burn

      Available in OS X v10.4 and later.

    • kDRFileModifiedDuringBurnErr

      kDRFileModifiedDuringBurnErr

      File changed during flatten or burn

      Available in OS X v10.2 and later.

    • kDRFileLocationConflictErr

      kDRFileLocationConflictErr

      Conflicting locations specified for two files

      Available in OS X v10.2 and later.

    • kDRTooManyNameConflictsErr

      kDRTooManyNameConflictsErr

      Too many filename conflicts to resolve (10,000,000 or more)

      Available in OS X v10.2 and later.

    • kDRFilesystemsNotSupportedErr

      kDRFilesystemsNotSupportedErr

      The selected filesystems are not valid for use on this media

      Available in OS X v10.5 and later.

    • kDRDeviceCantWriteCDTextErr

      kDRDeviceCantWriteCDTextErr

      Device does not support writing CD-Text

      Available in OS X v10.4 and later.

    • kDRDeviceBurnStrategyNotAvailableErr

      kDRDeviceBurnStrategyNotAvailableErr

      Device does not support the required burn strategy for this burn

      Available in OS X v10.3 and later.

    • kDRDeviceCantWriteIndexPointsErr

      kDRDeviceCantWriteIndexPointsErr

      Device does not support writing index points

      Available in OS X v10.3 and later.

    • kDRDeviceCantWriteISRCErr

      kDRDeviceCantWriteISRCErr

      Device does not support writing ISRC

      Available in OS X v10.3 and later.

    • kDRDeviceCantWriteSCMSErr

      kDRDeviceCantWriteSCMSErr

      Device does not support writing SCMS

      Available in OS X v10.3 and later.

    • kDRDevicePreGapLengthNotValidErr

      kDRDevicePreGapLengthNotValidErr

      Device does not support the required pregap length for the track

      Available in OS X v10.4 and later.

    Discussion

    Errors returned from the Disc Recording framework. All errors returned by the Disc Recording framework will fall into the range of 0x80020000 -> 0x8002FFFF.