SCPBuzzerVolumeParameters

Objective-C


@interface SCPBuzzerVolumeParameters : NSObject <SCPReaderSettingsParameters>

Swift

class BuzzerVolumeParameters : NSObject, ReaderSettingsParameters

Parameters for setting the buzzer (beep) volume on a reader via [SCPTerminal setReaderSettings:completion:].

Use initWithLevel: for Low or High, or initWithVolume: for a specific custom volume in the range 1...maxVolume.

Passing these parameters to a reader that does not support buzzer volume control returns SCPErrorFeatureNotAvailableWithConnectedReader.

  • The volume level to apply.

    Declaration

    Objective-C

    @property (nonatomic, readonly) SCPBuzzerVolumeLevel level;

    Swift

    var level: BuzzerVolumeLevel { get }
  • The custom volume to set. Only meaningful when level is SCPBuzzerVolumeLevelCustom — must be in the range 1...maxVolume, where maxVolume comes from SCPBuzzerVolume.maxVolume. When level is Low or High, this value is undefined and must not be used.

    Declaration

    Objective-C

    @property (nonatomic, readonly) NSInteger volume;

    Swift

    var volume: Int { get }
  • Create parameters for Low or High volume.

    Declaration

    Objective-C

    - (nonnull instancetype)initWithLevel:(SCPBuzzerVolumeLevel)level;

    Swift

    init(level: BuzzerVolumeLevel)

    Parameters

    level

    SCPBuzzerVolumeLevelLow or SCPBuzzerVolumeLevelHigh. Passing SCPBuzzerVolumeLevelCustom is a programmer error; use initWithVolume: instead.

  • Create parameters for a specific custom volume.

    Sets level to SCPBuzzerVolumeLevelCustom automatically. The volume must be in the range 1...maxVolume (from SCPBuzzerVolume.maxVolume); passing a value outside that range causes setReaderSettings:completion: to return SCPErrorInvalidRequiredParameter.

    Declaration

    Objective-C

    - (nonnull instancetype)initWithVolume:(NSInteger)volume;

    Swift

    init(volume: Int)

    Parameters

    volume

    The target volume. Must be >= 1 and <= maxVolume.

  • Unavailable

    Use initWithLevel: or initWithVolume: instead.

    Declaration

    Objective-C

    - (nonnull instancetype)init;
  • Unavailable

    Use initWithLevel: or initWithVolume: instead.

    Declaration

    Objective-C

    + (nonnull instancetype)new;