DBFILESMediaInfo
Objective-C
@interface DBFILESMediaInfo : NSObject <DBSerializable, NSCopying>
                Swift
class DBFILESMediaInfo : NSObject, DBSerializable, NSCopying
                The MediaInfo union.
This class implements the DBSerializable protocol (serialize and
deserialize instance methods), which is required for all Obj-C SDK API route
objects.
- 
                  
                  
Represents the union’s current tag state.
Declaration
Objective-C
@property (nonatomic, readonly) DBFILESMediaInfoTag tag;Swift
var tag: DBFILESMediaInfoTag { get } - 
                  
                  
The metadata for the photo/video. - note: Ensure the
isMetadatamethod returns true before accessing, otherwise a runtime exception will be raised.Declaration
Objective-C
@property (nonatomic, readonly) DBFILESMediaMetadata *_Nonnull metadata;Swift
var metadata: DBFILESMediaMetadata { get } 
- 
                  
                  
Initializes union class with tag state of “pending”.
Description of the “pending” tag state: Indicate the photo/video is still under processing and metadata is not available yet.
Declaration
Objective-C
- (nonnull instancetype)initWithPending;Swift
init(pending: ())Return Value
An initialized instance.
 - 
                  
                  
Initializes union class with tag state of “metadata”.
Description of the “metadata” tag state: The metadata for the photo/video.
Declaration
Objective-C
- (nonnull instancetype)initWithMetadata: (nonnull DBFILESMediaMetadata *)metadata;Swift
init(metadata: DBFILESMediaMetadata)Parameters
metadataThe metadata for the photo/video.
Return Value
An initialized instance.
 
- 
                  
                  
Retrieves whether the union’s current tag state has value “pending”.
Declaration
Objective-C
- (BOOL)isPending;Swift
func isPending() -> BoolReturn Value
Whether the union’s current tag state has value “pending”.
 - 
                  
                  
Retrieves whether the union’s current tag state has value “metadata”.
Note
Call this method and ensure it returns true before accessing the
metadataproperty, otherwise a runtime exception will be thrown.Declaration
Objective-C
- (BOOL)isMetadata;Swift
func isMetadata() -> BoolReturn Value
Whether the union’s current tag state has value “metadata”.
 - 
                  
                  
Retrieves string value of union’s current tag state.
Declaration
Objective-C
- (nonnull NSString *)tagName;Swift
func tagName() -> StringReturn Value
A human-readable string representing the union’s current tag state.
 
View on GitHub
        DBFILESMediaInfo Class Reference