VOSoundMedia

@interface VOSoundMedia : VOVoucherMedia

VOSoundMedia is a VOVoucherMedia for sounds.

  • Data representation of the VOSoundMedia. This can be used for caching or to save the data of a sound before it has been uploaded.

    Declaration

    Objective-C

    @property (readonly, nonatomic) NSData *soundData;

    Swift

    var soundData: Data! { get }
  • Whether the sound is locally stored.

    Declaration

    Objective-C

    @property (readonly, atomic) BOOL isLocalFile;

    Swift

    var isLocalFile: Bool { get }
  • Whether the sound is coming from the VOVoucher server.

    Declaration

    Objective-C

    @property (readonly, atomic) BOOL isCannedSound;

    Swift

    var isCannedSound: Bool { get }
  • Static Initializer to create a VOSoundMedia from properties.

    Declaration

    Objective-C

    + (instancetype)soundMediaWithData:(NSData *)soundData soundUrl:(NSString *)url;

    Swift

    convenience init!(data soundData: Data!, soundUrl url: String!)

    Parameters

    soundData

    - the type of VOVoucherMedia.

    url

    - the title of the VOVoucherMedia.

    Return Value

    Instance of VOSoundMedia.

  • Static Initializer to create a VOSoundMedia from an NSDictionary.

    Declaration

    Objective-C

    + (instancetype)soundMediaWithDictionary:(NSDictionary *)dictionary;

    Swift

    convenience init!(dictionary: [AnyHashable : Any]!)

    Parameters

    dictionary

    - the dictionary representation of a VOSoundMedia.

    Return Value

    Instance of VOSoundMedia.