Documentation
¶
Overview ¶
Package diskarbitration provides Go bindings for the DiskArbitration framework.
Provides mechanisms to register and block disk mount or unmount events.
For related documentation, see [Mac Technology Overview](<https://developer.apple.com/library/archive/documentation/MacOSX/Conceptual/OSX_Technology_Overview/About/About.html#//apple_ref/doc/uid/TP40001067>).
Variables ¶
- kDADiskDescriptionFSKitPrefix
- kDADiskDescriptionRepairRunningKey
- kDADiskMountOptionNoFollow
Code generated from Apple documentation. DO NOT EDIT.
Index ¶
- Variables
- func DAApprovalSessionGetTypeID() uint
- func DAApprovalSessionScheduleWithRunLoop(session DAApprovalSessionRef, runLoop corefoundation.CFRunLoopRef, ...)
- func DAApprovalSessionUnscheduleFromRunLoop(session DAApprovalSessionRef, runLoop corefoundation.CFRunLoopRef, ...)
- func DADiskClaim(disk DADiskRef, options DADiskClaimOptions, release DADiskClaimReleaseCallback, ...)
- func DADiskCopyDescription(disk DADiskRef) corefoundation.CFDictionaryRef
- func DADiskCopyIOMedia(disk DADiskRef) uintptr
- func DADiskEject(disk DADiskRef, options uint, callback DADiskEjectCallback, ...)
- func DADiskGetBSDName(disk DADiskRef) *byte
- func DADiskGetTypeID() uint
- func DADiskIsClaimed(disk DADiskRef) bool
- func DADiskMount(disk DADiskRef, path corefoundation.CFURLRef, options DADiskMountOptions, ...)
- func DADiskMountWithArguments(disk DADiskRef, path corefoundation.CFURLRef, options DADiskMountOptions, ...)
- func DADiskRename(disk DADiskRef, name corefoundation.CFStringRef, options DADiskRenameOptions, ...)
- func DADiskUnclaim(disk DADiskRef)
- func DADiskUnmount(disk DADiskRef, options DADiskUnmountOptions, callback DADiskUnmountCallback, ...)
- func DADissenterGetStatusString(dissenter DADissenterRef) corefoundation.CFStringRef
- func DARegisterDiskAppearedCallback(session DASessionRef, match corefoundation.CFDictionaryRef, ...)
- func DARegisterDiskDescriptionChangedCallback(session DASessionRef, match corefoundation.CFDictionaryRef, ...)
- func DARegisterDiskDisappearedCallback(session DASessionRef, match corefoundation.CFDictionaryRef, ...)
- func DARegisterDiskEjectApprovalCallback(session DASessionRef, match corefoundation.CFDictionaryRef, ...)
- func DARegisterDiskMountApprovalCallback(session DASessionRef, match corefoundation.CFDictionaryRef, ...)
- func DARegisterDiskPeekCallback(session DASessionRef, match corefoundation.CFDictionaryRef, order int, ...)
- func DARegisterDiskUnmountApprovalCallback(session DASessionRef, match corefoundation.CFDictionaryRef, ...)
- func DASessionGetTypeID() uint
- func DASessionScheduleWithRunLoop(session DASessionRef, runLoop corefoundation.CFRunLoopRef, ...)
- func DASessionSetDispatchQueue(session DASessionRef, queue dispatch.Queue)
- func DASessionUnscheduleFromRunLoop(session DASessionRef, runLoop corefoundation.CFRunLoopRef, ...)
- func DAUnregisterApprovalCallback(session DASessionRef, callback unsafe.Pointer, context unsafe.Pointer)
- func DAUnregisterCallback(session DASessionRef, callback unsafe.Pointer, context unsafe.Pointer)
- type DAApprovalSessionRef
- type DADiskAppearedCallback
- type DADiskClaimCallback
- type DADiskClaimOptions
- type DADiskClaimReleaseCallback
- type DADiskDescriptionChangedCallback
- type DADiskDisappearedCallback
- type DADiskEjectApprovalCallback
- type DADiskEjectCallback
- type DADiskMountApprovalCallback
- type DADiskMountCallback
- type DADiskMountOptions
- type DADiskOptions
- type DADiskPeekCallback
- type DADiskRef
- func DADiskCopyWholeDisk(disk DADiskRef) DADiskRef
- func DADiskCreateFromBSDName(allocator corefoundation.CFAllocatorRef, session DASessionRef, name string) DADiskRef
- func DADiskCreateFromIOMedia(allocator corefoundation.CFAllocatorRef, session DASessionRef, media uintptr) DADiskRef
- func DADiskCreateFromVolumePath(allocator corefoundation.CFAllocatorRef, session DASessionRef, ...) DADiskRef
- type DADiskRenameCallback
- type DADiskRenameOptions
- type DADiskUnmountApprovalCallback
- type DADiskUnmountCallback
- type DADiskUnmountOptions
- type DADissenterRef
- type DAReturn
- type DASessionRef
- type KDADiskClaimOption
- type KDADiskMountOption
- type KDADiskOption
- type KDADiskRenameOption
- type KDADiskUnmountOption
- type KDAReturn
Constants ¶
This section is empty.
Variables ¶
var ( // See: https://developer.apple.com/documentation/DiskArbitration/kDADiskDescriptionBusNameKey KDADiskDescriptionBusNameKey string // See: https://developer.apple.com/documentation/DiskArbitration/kDADiskDescriptionBusPathKey KDADiskDescriptionBusPathKey string // See: https://developer.apple.com/documentation/DiskArbitration/kDADiskDescriptionDeviceGUIDKey KDADiskDescriptionDeviceGUIDKey string // See: https://developer.apple.com/documentation/DiskArbitration/kDADiskDescriptionDeviceInternalKey KDADiskDescriptionDeviceInternalKey string // See: https://developer.apple.com/documentation/DiskArbitration/kDADiskDescriptionDeviceModelKey KDADiskDescriptionDeviceModelKey string // See: https://developer.apple.com/documentation/DiskArbitration/kDADiskDescriptionDevicePathKey KDADiskDescriptionDevicePathKey string // See: https://developer.apple.com/documentation/DiskArbitration/kDADiskDescriptionDeviceProtocolKey KDADiskDescriptionDeviceProtocolKey string // See: https://developer.apple.com/documentation/DiskArbitration/kDADiskDescriptionDeviceRevisionKey KDADiskDescriptionDeviceRevisionKey string // See: https://developer.apple.com/documentation/DiskArbitration/kDADiskDescriptionDeviceTDMLockedKey KDADiskDescriptionDeviceTDMLockedKey string // See: https://developer.apple.com/documentation/DiskArbitration/kDADiskDescriptionDeviceUnitKey KDADiskDescriptionDeviceUnitKey string // See: https://developer.apple.com/documentation/DiskArbitration/kDADiskDescriptionDeviceVendorKey KDADiskDescriptionDeviceVendorKey string // See: https://developer.apple.com/documentation/DiskArbitration/kDADiskDescriptionFSKitPrefix KDADiskDescriptionFSKitPrefix string // See: https://developer.apple.com/documentation/DiskArbitration/kDADiskDescriptionMediaBSDMajorKey KDADiskDescriptionMediaBSDMajorKey string // See: https://developer.apple.com/documentation/DiskArbitration/kDADiskDescriptionMediaBSDMinorKey KDADiskDescriptionMediaBSDMinorKey string // See: https://developer.apple.com/documentation/DiskArbitration/kDADiskDescriptionMediaBSDNameKey KDADiskDescriptionMediaBSDNameKey string // See: https://developer.apple.com/documentation/DiskArbitration/kDADiskDescriptionMediaBSDUnitKey KDADiskDescriptionMediaBSDUnitKey string // See: https://developer.apple.com/documentation/DiskArbitration/kDADiskDescriptionMediaBlockSizeKey KDADiskDescriptionMediaBlockSizeKey string // See: https://developer.apple.com/documentation/DiskArbitration/kDADiskDescriptionMediaContentKey KDADiskDescriptionMediaContentKey string // See: https://developer.apple.com/documentation/DiskArbitration/kDADiskDescriptionMediaEjectableKey KDADiskDescriptionMediaEjectableKey string // See: https://developer.apple.com/documentation/DiskArbitration/kDADiskDescriptionMediaEncryptedKey KDADiskDescriptionMediaEncryptedKey string // See: https://developer.apple.com/documentation/DiskArbitration/kDADiskDescriptionMediaEncryptionDetailKey KDADiskDescriptionMediaEncryptionDetailKey string // See: https://developer.apple.com/documentation/DiskArbitration/kDADiskDescriptionMediaIconKey KDADiskDescriptionMediaIconKey string // See: https://developer.apple.com/documentation/DiskArbitration/kDADiskDescriptionMediaKindKey KDADiskDescriptionMediaKindKey string // See: https://developer.apple.com/documentation/DiskArbitration/kDADiskDescriptionMediaLeafKey KDADiskDescriptionMediaLeafKey string // See: https://developer.apple.com/documentation/DiskArbitration/kDADiskDescriptionMediaNameKey KDADiskDescriptionMediaNameKey string // See: https://developer.apple.com/documentation/DiskArbitration/kDADiskDescriptionMediaPathKey KDADiskDescriptionMediaPathKey string // See: https://developer.apple.com/documentation/DiskArbitration/kDADiskDescriptionMediaRemovableKey KDADiskDescriptionMediaRemovableKey string // See: https://developer.apple.com/documentation/DiskArbitration/kDADiskDescriptionMediaSizeKey KDADiskDescriptionMediaSizeKey string // See: https://developer.apple.com/documentation/DiskArbitration/kDADiskDescriptionMediaTypeKey KDADiskDescriptionMediaTypeKey string // See: https://developer.apple.com/documentation/DiskArbitration/kDADiskDescriptionMediaUUIDKey KDADiskDescriptionMediaUUIDKey string // See: https://developer.apple.com/documentation/DiskArbitration/kDADiskDescriptionMediaWholeKey KDADiskDescriptionMediaWholeKey string // See: https://developer.apple.com/documentation/DiskArbitration/kDADiskDescriptionMediaWritableKey KDADiskDescriptionMediaWritableKey string // See: https://developer.apple.com/documentation/DiskArbitration/kDADiskDescriptionRepairRunningKey KDADiskDescriptionRepairRunningKey string // See: https://developer.apple.com/documentation/DiskArbitration/kDADiskDescriptionVolumeKindKey KDADiskDescriptionVolumeKindKey string // See: https://developer.apple.com/documentation/DiskArbitration/kDADiskDescriptionVolumeMountableKey KDADiskDescriptionVolumeMountableKey string // See: https://developer.apple.com/documentation/DiskArbitration/kDADiskDescriptionVolumeNameKey KDADiskDescriptionVolumeNameKey string // See: https://developer.apple.com/documentation/DiskArbitration/kDADiskDescriptionVolumeNetworkKey KDADiskDescriptionVolumeNetworkKey string // See: https://developer.apple.com/documentation/DiskArbitration/kDADiskDescriptionVolumePathKey KDADiskDescriptionVolumePathKey string // See: https://developer.apple.com/documentation/DiskArbitration/kDADiskDescriptionVolumeTypeKey KDADiskDescriptionVolumeTypeKey string // See: https://developer.apple.com/documentation/DiskArbitration/kDADiskDescriptionVolumeUUIDKey KDADiskDescriptionVolumeUUIDKey string )
var ( // See: https://developer.apple.com/documentation/DiskArbitration/kDADiskDescriptionMatchMediaUnformatted KDADiskDescriptionMatchMediaUnformatted corefoundation.CFDictionaryRef // See: https://developer.apple.com/documentation/DiskArbitration/kDADiskDescriptionMatchMediaWhole KDADiskDescriptionMatchMediaWhole corefoundation.CFDictionaryRef // See: https://developer.apple.com/documentation/DiskArbitration/kDADiskDescriptionMatchVolumeMountable KDADiskDescriptionMatchVolumeMountable corefoundation.CFDictionaryRef // See: https://developer.apple.com/documentation/DiskArbitration/kDADiskDescriptionMatchVolumeUnrecognized KDADiskDescriptionMatchVolumeUnrecognized corefoundation.CFDictionaryRef )
var ( // See: https://developer.apple.com/documentation/DiskArbitration/kDADiskDescriptionWatchVolumeName KDADiskDescriptionWatchVolumeName corefoundation.CFArrayRef // See: https://developer.apple.com/documentation/DiskArbitration/kDADiskDescriptionWatchVolumePath KDADiskDescriptionWatchVolumePath corefoundation.CFArrayRef )
Functions ¶
func DAApprovalSessionGetTypeID ¶
func DAApprovalSessionGetTypeID() uint
DAApprovalSessionGetTypeID.
See: https://developer.apple.com/documentation/DiskArbitration/DAApprovalSessionGetTypeID
func DAApprovalSessionScheduleWithRunLoop ¶
func DAApprovalSessionScheduleWithRunLoop(session DAApprovalSessionRef, runLoop corefoundation.CFRunLoopRef, runLoopMode corefoundation.CFStringRef)
DAApprovalSessionScheduleWithRunLoop.
See: https://developer.apple.com/documentation/DiskArbitration/DAApprovalSessionScheduleWithRunLoop
func DAApprovalSessionUnscheduleFromRunLoop ¶
func DAApprovalSessionUnscheduleFromRunLoop(session DAApprovalSessionRef, runLoop corefoundation.CFRunLoopRef, runLoopMode corefoundation.CFStringRef)
DAApprovalSessionUnscheduleFromRunLoop.
See: https://developer.apple.com/documentation/DiskArbitration/DAApprovalSessionUnscheduleFromRunLoop
func DADiskClaim ¶
func DADiskClaim(disk DADiskRef, options DADiskClaimOptions, release DADiskClaimReleaseCallback, releaseContext unsafe.Pointer, callback DADiskClaimCallback, callbackContext unsafe.Pointer)
DADiskClaim claims the specified disk object for exclusive use.
See: https://developer.apple.com/documentation/DiskArbitration/DADiskClaim(_:_:_:_:_:_:)
func DADiskCopyDescription ¶
func DADiskCopyDescription(disk DADiskRef) corefoundation.CFDictionaryRef
DADiskCopyDescription obtains the Disk Arbitration description of the specified disk.
See: https://developer.apple.com/documentation/DiskArbitration/DADiskCopyDescription(_:)
func DADiskCopyIOMedia ¶
DADiskCopyIOMedia obtains the I/O Kit media object for the specified disk.
See: https://developer.apple.com/documentation/DiskArbitration/DADiskCopyIOMedia(_:)
func DADiskEject ¶
func DADiskEject(disk DADiskRef, options uint, callback DADiskEjectCallback, context unsafe.Pointer)
DADiskEject ejects the specified disk object.
See: https://developer.apple.com/documentation/DiskArbitration/DADiskEject(_:_:_:_:)
func DADiskGetBSDName ¶
DADiskGetBSDName obtains the BSD device name for the specified disk.
See: https://developer.apple.com/documentation/DiskArbitration/DADiskGetBSDName(_:)
func DADiskGetTypeID ¶
func DADiskGetTypeID() uint
DADiskGetTypeID returns the type identifier of all DADisk instances.
See: https://developer.apple.com/documentation/DiskArbitration/DADiskGetTypeID()
func DADiskIsClaimed ¶
DADiskIsClaimed reports whether or not the disk is claimed.
See: https://developer.apple.com/documentation/DiskArbitration/DADiskIsClaimed(_:)
func DADiskMount ¶
func DADiskMount(disk DADiskRef, path corefoundation.CFURLRef, options DADiskMountOptions, callback DADiskMountCallback, context unsafe.Pointer)
DADiskMount mounts the volume at the specified disk object.
See: https://developer.apple.com/documentation/DiskArbitration/DADiskMount(_:_:_:_:_:)
func DADiskMountWithArguments ¶
func DADiskMountWithArguments(disk DADiskRef, path corefoundation.CFURLRef, options DADiskMountOptions, callback DADiskMountCallback, context unsafe.Pointer, arguments corefoundation.CFStringRef)
DADiskMountWithArguments mounts the volume at the specified disk object, with the specified mount options.
See: https://developer.apple.com/documentation/DiskArbitration/DADiskMountWithArguments(_:_:_:_:_:_:)
func DADiskRename ¶
func DADiskRename(disk DADiskRef, name corefoundation.CFStringRef, options DADiskRenameOptions, callback DADiskRenameCallback, context unsafe.Pointer)
DADiskRename renames the volume at the specified disk object.
See: https://developer.apple.com/documentation/DiskArbitration/DADiskRename(_:_:_:_:_:)
func DADiskUnclaim ¶
func DADiskUnclaim(disk DADiskRef)
DADiskUnclaim unclaims the specified disk object.
See: https://developer.apple.com/documentation/DiskArbitration/DADiskUnclaim(_:)
func DADiskUnmount ¶
func DADiskUnmount(disk DADiskRef, options DADiskUnmountOptions, callback DADiskUnmountCallback, context unsafe.Pointer)
DADiskUnmount unmounts the volume at the specified disk object.
See: https://developer.apple.com/documentation/DiskArbitration/DADiskUnmount(_:_:_:_:)
func DADissenterGetStatusString ¶
func DADissenterGetStatusString(dissenter DADissenterRef) corefoundation.CFStringRef
DADissenterGetStatusString obtains the return code string.
See: https://developer.apple.com/documentation/DiskArbitration/DADissenterGetStatusString(_:)
func DARegisterDiskAppearedCallback ¶
func DARegisterDiskAppearedCallback(session DASessionRef, match corefoundation.CFDictionaryRef, callback DADiskAppearedCallback, context unsafe.Pointer)
DARegisterDiskAppearedCallback registers a callback function to be called whenever a disk has appeared.
See: https://developer.apple.com/documentation/DiskArbitration/DARegisterDiskAppearedCallback(_:_:_:_:)
func DARegisterDiskDescriptionChangedCallback ¶
func DARegisterDiskDescriptionChangedCallback(session DASessionRef, match corefoundation.CFDictionaryRef, watch corefoundation.CFArrayRef, callback DADiskDescriptionChangedCallback, context unsafe.Pointer)
DARegisterDiskDescriptionChangedCallback registers a callback function to be called whenever a disk description has changed.
func DARegisterDiskDisappearedCallback ¶
func DARegisterDiskDisappearedCallback(session DASessionRef, match corefoundation.CFDictionaryRef, callback DADiskDisappearedCallback, context unsafe.Pointer)
DARegisterDiskDisappearedCallback registers a callback function to be called whenever a disk has disappeared.
func DARegisterDiskEjectApprovalCallback ¶
func DARegisterDiskEjectApprovalCallback(session DASessionRef, match corefoundation.CFDictionaryRef, callback DADiskEjectApprovalCallback, context unsafe.Pointer)
DARegisterDiskEjectApprovalCallback registers a callback function to be called whenever a volume is to be ejected.
func DARegisterDiskMountApprovalCallback ¶
func DARegisterDiskMountApprovalCallback(session DASessionRef, match corefoundation.CFDictionaryRef, callback DADiskMountApprovalCallback, context unsafe.Pointer)
DARegisterDiskMountApprovalCallback registers a callback function to be called whenever a volume is to be mounted.
func DARegisterDiskPeekCallback ¶
func DARegisterDiskPeekCallback(session DASessionRef, match corefoundation.CFDictionaryRef, order int, callback DADiskPeekCallback, context unsafe.Pointer)
DARegisterDiskPeekCallback registers a callback function to be called whenever a disk has been probed.
See: https://developer.apple.com/documentation/DiskArbitration/DARegisterDiskPeekCallback(_:_:_:_:_:)
func DARegisterDiskUnmountApprovalCallback ¶
func DARegisterDiskUnmountApprovalCallback(session DASessionRef, match corefoundation.CFDictionaryRef, callback DADiskUnmountApprovalCallback, context unsafe.Pointer)
DARegisterDiskUnmountApprovalCallback registers a callback function to be called whenever a volume is to be unmounted.
func DASessionGetTypeID ¶
func DASessionGetTypeID() uint
DASessionGetTypeID returns the type identifier of all DASession instances.
See: https://developer.apple.com/documentation/DiskArbitration/DASessionGetTypeID()
func DASessionScheduleWithRunLoop ¶
func DASessionScheduleWithRunLoop(session DASessionRef, runLoop corefoundation.CFRunLoopRef, runLoopMode corefoundation.CFStringRef)
DASessionScheduleWithRunLoop schedules the session on a run loop.
See: https://developer.apple.com/documentation/DiskArbitration/DASessionScheduleWithRunLoop(_:_:_:)
func DASessionSetDispatchQueue ¶
func DASessionSetDispatchQueue(session DASessionRef, queue dispatch.Queue)
DASessionSetDispatchQueue schedules the session on a dispatch queue.
See: https://developer.apple.com/documentation/DiskArbitration/DASessionSetDispatchQueue(_:_:)
func DASessionUnscheduleFromRunLoop ¶
func DASessionUnscheduleFromRunLoop(session DASessionRef, runLoop corefoundation.CFRunLoopRef, runLoopMode corefoundation.CFStringRef)
DASessionUnscheduleFromRunLoop unschedules the session from a run loop.
See: https://developer.apple.com/documentation/DiskArbitration/DASessionUnscheduleFromRunLoop(_:_:_:)
func DAUnregisterApprovalCallback ¶
func DAUnregisterApprovalCallback(session DASessionRef, callback unsafe.Pointer, context unsafe.Pointer)
DAUnregisterApprovalCallback unregisters a registered callback function.
See: https://developer.apple.com/documentation/DiskArbitration/DAUnregisterApprovalCallback
func DAUnregisterCallback ¶
func DAUnregisterCallback(session DASessionRef, callback unsafe.Pointer, context unsafe.Pointer)
DAUnregisterCallback unregisters a registered callback function.
See: https://developer.apple.com/documentation/DiskArbitration/DAUnregisterCallback(_:_:_:)
Types ¶
type DAApprovalSessionRef ¶
type DAApprovalSessionRef uintptr
See: https://developer.apple.com/documentation/DiskArbitration/DAApprovalSessionRef
func DAApprovalSessionCreate ¶
func DAApprovalSessionCreate(allocator corefoundation.CFAllocatorRef) DAApprovalSessionRef
DAApprovalSessionCreate.
See: https://developer.apple.com/documentation/DiskArbitration/DAApprovalSessionCreate
type DADiskAppearedCallback ¶
DADiskAppearedCallback is type of the callback function used by DARegisterDiskAppearedCallback().
See: https://developer.apple.com/documentation/DiskArbitration/DADiskAppearedCallback
type DADiskClaimCallback ¶
DADiskClaimCallback is type of the callback function used by DADiskClaim().
See: https://developer.apple.com/documentation/DiskArbitration/DADiskClaimCallback
type DADiskClaimOptions ¶ added in v0.5.1
type DADiskClaimOptions = uint32
DADiskClaimOptions is options for DADiskClaim().
See: https://developer.apple.com/documentation/DiskArbitration/DADiskClaimOptions
type DADiskClaimReleaseCallback ¶
DADiskClaimReleaseCallback is type of the callback function used by DADiskClaim().
See: https://developer.apple.com/documentation/DiskArbitration/DADiskClaimReleaseCallback
type DADiskDescriptionChangedCallback ¶
DADiskDescriptionChangedCallback is type of the callback function used by DARegisterDiskDescriptionChangedCallback().
See: https://developer.apple.com/documentation/DiskArbitration/DADiskDescriptionChangedCallback
type DADiskDisappearedCallback ¶
DADiskDisappearedCallback is type of the callback function used by DARegisterDiskDisappearedCallback().
See: https://developer.apple.com/documentation/DiskArbitration/DADiskDisappearedCallback
type DADiskEjectApprovalCallback ¶
DADiskEjectApprovalCallback is type of the callback function used by DARegisterDiskEjectApprovalCallback().
See: https://developer.apple.com/documentation/DiskArbitration/DADiskEjectApprovalCallback
type DADiskEjectCallback ¶
DADiskEjectCallback is type of the callback function used by DADiskEject().
See: https://developer.apple.com/documentation/DiskArbitration/DADiskEjectCallback
type DADiskMountApprovalCallback ¶
DADiskMountApprovalCallback is type of the callback function used by DARegisterDiskMountApprovalCallback().
See: https://developer.apple.com/documentation/DiskArbitration/DADiskMountApprovalCallback
type DADiskMountCallback ¶
DADiskMountCallback is type of the callback function used by DADiskMount().
See: https://developer.apple.com/documentation/DiskArbitration/DADiskMountCallback
type DADiskMountOptions ¶
type DADiskMountOptions = uint32
DADiskMountOptions is options for DADiskMount().
See: https://developer.apple.com/documentation/DiskArbitration/DADiskMountOptions
type DADiskOptions ¶
type DADiskOptions = uint32
DADiskOptions is options for DADiskGetOptions() and DADiskSetOptions().
See: https://developer.apple.com/documentation/DiskArbitration/DADiskOptions
func DADiskGetOptions ¶
func DADiskGetOptions(disk DADiskRef) DADiskOptions
DADiskGetOptions obtains the options for the specified disk.
See: https://developer.apple.com/documentation/DiskArbitration/DADiskGetOptions(_:)
type DADiskPeekCallback ¶
DADiskPeekCallback is type of the callback function used by DARegisterDiskPeekCallback().
See: https://developer.apple.com/documentation/DiskArbitration/DADiskPeekCallback
type DADiskRef ¶
type DADiskRef uintptr
DADiskRef is type of a reference to DADisk instances.
See: https://developer.apple.com/documentation/DiskArbitration/DADisk
func DADiskCopyWholeDisk ¶
DADiskCopyWholeDisk obtain the associated whole disk object for the specified disk.
See: https://developer.apple.com/documentation/DiskArbitration/DADiskCopyWholeDisk(_:)
func DADiskCreateFromBSDName ¶
func DADiskCreateFromBSDName(allocator corefoundation.CFAllocatorRef, session DASessionRef, name string) DADiskRef
DADiskCreateFromBSDName creates a new disk object.
See: https://developer.apple.com/documentation/DiskArbitration/DADiskCreateFromBSDName(_:_:_:)
func DADiskCreateFromIOMedia ¶
func DADiskCreateFromIOMedia(allocator corefoundation.CFAllocatorRef, session DASessionRef, media uintptr) DADiskRef
DADiskCreateFromIOMedia creates a new disk object.
See: https://developer.apple.com/documentation/DiskArbitration/DADiskCreateFromIOMedia(_:_:_:)
func DADiskCreateFromVolumePath ¶
func DADiskCreateFromVolumePath(allocator corefoundation.CFAllocatorRef, session DASessionRef, path corefoundation.CFURLRef) DADiskRef
DADiskCreateFromVolumePath creates a new disk object.
See: https://developer.apple.com/documentation/DiskArbitration/DADiskCreateFromVolumePath(_:_:_:)
type DADiskRenameCallback ¶
DADiskRenameCallback is type of the callback function used by DADiskRename().
See: https://developer.apple.com/documentation/DiskArbitration/DADiskRenameCallback
type DADiskRenameOptions ¶
type DADiskRenameOptions = uint32
DADiskRenameOptions is options for DADiskRename().
See: https://developer.apple.com/documentation/DiskArbitration/DADiskRenameOptions
type DADiskUnmountApprovalCallback ¶
DADiskUnmountApprovalCallback is type of the callback function used by DARegisterDiskUnmountApprovalCallback().
See: https://developer.apple.com/documentation/DiskArbitration/DADiskUnmountApprovalCallback
type DADiskUnmountCallback ¶
DADiskUnmountCallback is type of the callback function used by DADiskUnmount().
See: https://developer.apple.com/documentation/DiskArbitration/DADiskUnmountCallback
type DADiskUnmountOptions ¶
type DADiskUnmountOptions = uint32
DADiskUnmountOptions is options for DADiskUnmount().
See: https://developer.apple.com/documentation/DiskArbitration/DADiskUnmountOptions
type DADissenterRef ¶
type DADissenterRef uintptr
DADissenterRef is type of a reference to DADissenter instances.
See: https://developer.apple.com/documentation/DiskArbitration/DADissenter
func DADissenterCreate ¶
func DADissenterCreate(allocator corefoundation.CFAllocatorRef, status DAReturn, string_ corefoundation.CFStringRef) DADissenterRef
DADissenterCreate creates a new dissenter object.
See: https://developer.apple.com/documentation/DiskArbitration/DADissenterCreate(_:_:_:)
type DAReturn ¶
type DAReturn = kernel.Mach_error_t
DAReturn is a return code.
See: https://developer.apple.com/documentation/DiskArbitration/DAReturn
func DADiskSetOptions ¶
func DADiskSetOptions(disk DADiskRef, options DADiskOptions, value bool) DAReturn
DADiskSetOptions sets the options for the specified disk.
See: https://developer.apple.com/documentation/DiskArbitration/DADiskSetOptions(_:_:_:)
func DADissenterGetStatus ¶
func DADissenterGetStatus(dissenter DADissenterRef) DAReturn
DADissenterGetStatus obtains the return code.
See: https://developer.apple.com/documentation/DiskArbitration/DADissenterGetStatus(_:)
type DASessionRef ¶
type DASessionRef uintptr
DASessionRef is type of a reference to DASession instances.
See: https://developer.apple.com/documentation/DiskArbitration/DASession
func DASessionCreate ¶
func DASessionCreate(allocator corefoundation.CFAllocatorRef) DASessionRef
DASessionCreate creates a new session.
See: https://developer.apple.com/documentation/DiskArbitration/DASessionCreate(_:)
type KDADiskClaimOption ¶ added in v0.5.1
type KDADiskClaimOption uint
const (
KDADiskClaimOptionDefault KDADiskClaimOption = 0
)
func (KDADiskClaimOption) String ¶ added in v0.5.1
func (e KDADiskClaimOption) String() string
type KDADiskMountOption ¶
type KDADiskMountOption uint
const ( KDADiskMountOptionDefault KDADiskMountOption = 0 KDADiskMountOptionNoFollow KDADiskMountOption = 0 // KDADiskMountOptionWhole: Mount the volumes tied to the whole disk object. KDADiskMountOptionWhole KDADiskMountOption = 0 )
func (KDADiskMountOption) String ¶
func (e KDADiskMountOption) String() string
type KDADiskOption ¶ added in v0.5.1
type KDADiskOption uint
const (
KDADiskOptionDefault KDADiskOption = 0
)
func (KDADiskOption) String ¶ added in v0.5.1
func (e KDADiskOption) String() string
type KDADiskRenameOption ¶ added in v0.5.1
type KDADiskRenameOption uint
const (
KDADiskRenameOptionDefault KDADiskRenameOption = 0
)
func (KDADiskRenameOption) String ¶ added in v0.5.1
func (e KDADiskRenameOption) String() string
type KDADiskUnmountOption ¶
type KDADiskUnmountOption uint
const ( KDADiskUnmountOptionDefault KDADiskUnmountOption = 0 // KDADiskUnmountOptionForce: Unmount the volume even if files are still active. KDADiskUnmountOptionForce KDADiskUnmountOption = 0 // KDADiskUnmountOptionWhole: Unmount the volumes tied to the whole disk object. KDADiskUnmountOptionWhole KDADiskUnmountOption = 0 )
func (KDADiskUnmountOption) String ¶
func (e KDADiskUnmountOption) String() string
type KDAReturn ¶
type KDAReturn uint
const ( KDAReturnBadArgument KDAReturn = 0 KDAReturnBusy KDAReturn = 0 KDAReturnError KDAReturn = 0 KDAReturnExclusiveAccess KDAReturn = 0 KDAReturnNoResources KDAReturn = 0 KDAReturnNotFound KDAReturn = 0 KDAReturnNotMounted KDAReturn = 0 KDAReturnNotPermitted KDAReturn = 0 KDAReturnNotPrivileged KDAReturn = 0 KDAReturnNotReady KDAReturn = 0 KDAReturnNotWritable KDAReturn = 0 KDAReturnSuccess KDAReturn = 0 KDAReturnUnsupported KDAReturn = 0 )