BUAdSlot.h 3.7 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192
  1. //
  2. // BUAdSlot.h
  3. // BUAdSDK
  4. //
  5. // Copyright © 2017 bytedance. All rights reserved.
  6. //
  7. #import <UIKit/UIKit.h>
  8. #import "BUSize.h"
  9. typedef NS_ENUM(NSInteger, BUAdSlotAdType) {
  10. BUAdSlotAdTypeUnknown = 0,
  11. BUAdSlotAdTypeBanner = 1, // banner ads
  12. BUAdSlotAdTypeInterstitial = 2, // interstitial ads
  13. BUAdSlotAdTypeSplash = 3, // splash ads
  14. BUAdSlotAdTypeSplash_Cache = 4, // cache splash ads
  15. BUAdSlotAdTypeFeed = 5, // feed ads
  16. BUAdSlotAdTypePaster = 6, // paster ads
  17. BUAdSlotAdTypeRewardVideo = 7, // rewarded video ads
  18. BUAdSlotAdTypeFullscreenVideo = 8, // full-screen video ads
  19. BUAdSlotAdTypeDrawVideo = 9, // vertical (immersive) video ads
  20. };
  21. typedef NS_ENUM(NSInteger, BUAdSlotPosition) {
  22. BUAdSlotPositionTop = 1,
  23. BUAdSlotPositionBottom = 2,
  24. BUAdSlotPositionFeed = 3,
  25. BUAdSlotPositionMiddle = 4, // for interstitial ad only
  26. BUAdSlotPositionFullscreen = 5,
  27. };
  28. @interface BUAdSlot : NSObject
  29. /// required. The unique identifier of a native ad.
  30. @property (nonatomic, copy) NSString *ID;
  31. /// required. Ad type.
  32. @property (nonatomic, assign) BUAdSlotAdType AdType;
  33. /// optional. Ad display location. defaults is BUAdSlotPositionTop
  34. @property (nonatomic, assign) BUAdSlotPosition position;
  35. /// Accept a set of image sizes, please pass in the BUSize object.
  36. @property (nonatomic, strong) NSMutableArray<BUSize *> *imgSizeArray;
  37. /// required. Image size.
  38. @property (nonatomic, strong) BUSize *imgSize;
  39. /// Icon size.
  40. @property (nonatomic, strong) BUSize *iconSize;
  41. /// Maximum length of the title.
  42. @property (nonatomic, assign) NSInteger titleLengthLimit;
  43. /// Maximum length of description.
  44. @property (nonatomic, assign) NSInteger descLengthLimit;
  45. /// optional. Whether to support deeplink.defaults is true
  46. @property (nonatomic, assign) BOOL isSupportDeepLink DEPRECATED_MSG_ATTRIBUTE("This property is deprecated,Settings are no longer required after version 3300");
  47. /// Native banner ads and native interstitial ads are set to 1, other ad types are 0, the default is 0.
  48. @property (nonatomic, assign) BOOL isOriginAd;
  49. /// optional. Whether to support render control
  50. @property (nonatomic, assign) BOOL supportRenderControl;
  51. //adload_seq:(针对聚合广告位)传递本次请求是为“自然日内某设备某广告位置第N次展示机会”发出的广告请求,同物理位置在自然日从1开始计数,不同物理位置独立计数;example:某原生广告位置,当天第5次产生展示机会,这次展示机向穿山甲发送了4次广告请求,则这4次广告请求的"adload_seq"的值应为5。第二天重新开始计数。
  52. @property (nonatomic, assign) NSInteger adloadSeq;
  53. // Valid only in Native Banner and Native Interstitial
  54. @property (nonatomic, assign) CGSize adSize;
  55. //prime_rit:(针对聚合广告位)广告物理位置对应的固定穿山甲广告位id,可以使用第一层的广告位id也可以为某一层的广告位id,但要求同一物理位置在该字段固定上报同一广告位id,不频繁更换;example:某原生广告位,当天共发出了1000个请求,这1000个请求中使用了5个不同target的穿山甲rit,用某X rit来作为该位置的标记rit,则这1000次请求的prime_rit都需要上报X rit的rit id。
  56. @property (nonatomic, copy) NSString *primeRit;
  57. /// optional. AD id for preview
  58. @property (nonatomic, copy) NSString *previewAdID;
  59. /// optional. AD creative id for preview
  60. @property (nonatomic, copy) NSString *previewCreativeID;
  61. /// optional. extend msg
  62. @property (nonatomic, copy) NSDictionary *ext;
  63. /// optional. additional user information
  64. @property (nonatomic, copy) NSString *userData;
  65. - (NSDictionary *)dictionaryValue;
  66. @end