-
Data representation of the
SoundMedia
. 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 Voucher server.
Declaration
Objective-C
@property (readonly, atomic) BOOL isCannedSound;
Swift
var isCannedSound: Bool { get }
-
Static Initializer to create a
SoundMedia
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
VoucherMedia
.url
- the title of the
VoucherMedia
.Return Value
Instance of
SoundMedia
. -
Static Initializer to create a
SoundMedia
from an NSDictionary.Declaration
Objective-C
+ (instancetype)soundMediaWithDictionary:(NSDictionary *)dictionary;
Swift
convenience init!(dictionary: [AnyHashable : Any]!)
Parameters
dictionary
- the dictionary representation of a
SoundMedia
.Return Value
Instance of
SoundMedia
.