AudioPlugIn
public class AudioPlugIn : AudioObject
A HAL audio plug-in object
This class has a single scope (kAudioObjectPropertyScopeGlobal
) and a single element (kAudioObjectPropertyElementMaster
)
Remark
This class correponds to objects of typekAudioPlugInClassID
-
Returns the available audio plug-ins
Remark
This corresponds to the propertykAudioHardwarePropertyPlugInList
onkAudioObjectSystemObject
Declaration
Swift
public class func plugIns() throws -> [AudioPlugIn]
-
Returns an initialized
AudioPlugIn
withbundleID
ornil
if unknownRemark
This corresponds to the propertykAudioHardwarePropertyTranslateBundleIDToPlugIn
onkAudioObjectSystemObject
Declaration
Swift
public class func makePlugIn(forBundleID bundleID: String) throws -> AudioPlugIn?
Parameters
bundleID
The bundle ID of the desired plug-in
-
Undocumented
Declaration
Swift
public override var debugDescription: String { get }
-
Returns the plug-in’s bundle ID
Remark
This corresponds to the propertykAudioPlugInPropertyBundleID
Declaration
Swift
public func bundleID() throws -> String
-
Returns the audio devices provided by the plug-in
Remark
This corresponds to the propertykAudioPlugInPropertyDeviceList
Declaration
Swift
public func deviceList() throws -> [AudioDevice]
-
Returns the audio device provided by the plug-in with the specified UID or
nil
if unknownRemark
This corresponds to the propertykAudioPlugInPropertyTranslateUIDToDevice
Declaration
Swift
public func device(forUID uid: String) throws -> AudioDevice?
Parameters
uid
The UID of the desired device
-
Returns the audio boxes provided by the plug-in
Remark
This corresponds to the propertykAudioPlugInPropertyBoxList
Declaration
Swift
public func boxList() throws -> [AudioBox]
-
Returns the audio box provided by the plug-in with the specified UID or
nil
if unknownRemark
This corresponds to the propertykAudioPlugInPropertyTranslateUIDToBox
Declaration
Swift
public func box(forUID uid: String) throws -> AudioBox?
Parameters
uid
The UID of the desired box
-
Returns the clock devices provided by the plug-in
Remark
This corresponds to the propertykAudioPlugInPropertyClockDeviceList
Declaration
Swift
public func clockDeviceList() throws -> [AudioClockDevice]
-
Returns the audio clock device provided by the plug-in with the specified UID or
nil
if unknownRemark
This corresponds to the propertykAudioPlugInPropertyTranslateUIDToClockDevice
Declaration
Swift
public func clockDevice(forUID uid: String) throws -> AudioClockDevice?
Parameters
uid
The UID of the desired clock device
-
Returns
true
ifself
hasselector
Declaration
Swift
public func hasSelector(_ selector: AudioObjectSelector<AudioPlugIn>) -> Bool
Parameters
selector
The selector of the desired property
-
Returns
true
ifselector
is settableThrows
An error ifself
does not have the requested propertyDeclaration
Swift
public func isSelectorSettable(_ selector: AudioObjectSelector<AudioPlugIn>) throws -> Bool
Parameters
selector
The selector of the desired property
-
Registers
block
to be performed whenselector
changesThrows
An error if the property listener could not be registeredDeclaration
Swift
public func whenSelectorChanges(_ selector: AudioObjectSelector<AudioPlugIn>, perform block: PropertyChangeNotificationBlock?) throws
Parameters
selector
The selector of the desired property
block
A closure to invoke when the property changes or
nil
to remove the previous value