al
Aeline
2021-03-08 ce4eaddf9eb835f01e6bf5845a063d306f322b24
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
//
//  BUPlayerPublicDefine.h
//  BUAdSDK
//
//  Copyright © 2018年 bytedance. All rights reserved.
//
 
#ifndef BUPlayerPublicDefine_h
#define BUPlayerPublicDefine_h
 
typedef NS_ENUM(NSInteger, BUPlayerPlayState) {
    BUPlayerStateFailed    = 0,
    BUPlayerStateBuffering = 1,
    BUPlayerStatePlaying   = 2,
    BUPlayerStateStopped   = 3,
    BUPlayerStatePause     = 4,
    BUPlayerStateDefalt    = 5
};
 
@class BUPlayer;
 
@protocol BUPlayerDelegate <NSObject>
 
@optional
/**
 This method is called when the player status changes.
 */
- (void)player:(BUPlayer *)player stateDidChanged:(BUPlayerPlayState)playerState;
/**
 This method is called when the player is ready.
 */
- (void)playerReadyToPlay:(BUPlayer *)player;
/**
 This method is called when the player plays completion or occurrs error.
 */
- (void)playerDidPlayFinish:(BUPlayer *)player error:(NSError *)error;
 
/**
 This method is called when the player is clicked.
 */
- (void)player:(BUPlayer *)player recognizeTapGesture:(UITapGestureRecognizer *)gesture;
 
 
/**
 This method is called when the view is clicked during ad play.
 */
- (void)playerTouchesBegan:(BUPlayer *)player;
 
@end
 
#endif /* BUPlayerPublicDefine_h */