commit | author | age
|
a0a843
|
1 |
// |
H |
2 |
// TWTRVideoMetaData.h |
|
3 |
// TwitterKit |
|
4 |
// |
|
5 |
// Copyright © 2016 Twitter. All rights reserved. |
|
6 |
// |
|
7 |
|
|
8 |
#import <TwitterKit/TWTRJSONConvertible.h> |
|
9 |
#import <UIKit/UIKit.h> |
|
10 |
|
|
11 |
NS_ASSUME_NONNULL_BEGIN |
|
12 |
|
|
13 |
FOUNDATION_EXTERN NSString *const TWTRMediaTypeMP4; |
|
14 |
FOUNDATION_EXTERN NSString *const TWTRMediaTypeM3u8; |
|
15 |
|
|
16 |
@interface TWTRVideoMetaDataVariant : NSObject <NSCoding, NSCopying, TWTRJSONConvertible> |
|
17 |
|
|
18 |
/** |
|
19 |
* The bitrate of the entitity |
|
20 |
*/ |
|
21 |
@property (nonatomic, readonly) NSInteger bitrate; |
|
22 |
|
|
23 |
/** |
|
24 |
* The content type of the video entity. |
|
25 |
*/ |
|
26 |
@property (nonatomic, copy, readonly) NSString *contentType; |
|
27 |
|
|
28 |
/** |
|
29 |
* The URL for the entity. |
|
30 |
*/ |
|
31 |
@property (nonatomic, readonly) NSURL *URL; |
|
32 |
|
|
33 |
@end |
|
34 |
|
|
35 |
@interface TWTRVideoMetaData : NSObject <NSCoding, NSCopying, TWTRJSONConvertible> |
|
36 |
|
|
37 |
/** |
|
38 |
* The URL of the video if the video is an mp4. This value is provided as a convenience |
|
39 |
* method but user's should query the `variants` property to have finer grained control |
|
40 |
* over which video they play. |
|
41 |
*/ |
|
42 |
@property (nonatomic, readonly, nullable) NSURL *videoURL; |
|
43 |
|
|
44 |
/** |
|
45 |
* Returns the array of variants. |
|
46 |
*/ |
|
47 |
@property (nonatomic, readonly) NSArray *variants; |
|
48 |
|
|
49 |
/** |
|
50 |
* The video's aspect ratio. |
|
51 |
*/ |
|
52 |
@property (nonatomic, readonly) CGFloat aspectRatio; |
|
53 |
|
|
54 |
/** |
|
55 |
* The video's duration in seconds. |
|
56 |
*/ |
|
57 |
@property (nonatomic, readonly) NSTimeInterval duration; |
|
58 |
|
|
59 |
@end |
|
60 |
|
|
61 |
NS_ASSUME_NONNULL_END |