네이티브
1. 레이아웃 설정
Native Ad의 경우, 광고에 사용 될 레이아웃을 직접 구성해야 합니다. 필수 구성 요소들은 다음과 같습니다.
Title :
UILabelBody :
UILabelCall To Action :
UIButtonProfile Name :
UILabelProfile Icon Image :
UIImageViewMedia View :
AdWhaleMediaView
import UIKit
import AdWhaleSDK
class NativeAdView: AdWhaleNativeAdView {
@IBOutlet var titleLabel: UILabel!
@IBOutlet var bodyLabel: UILabel!
@IBOutlet var callToActionButton: UIButton!
@IBOutlet var profileNameLabel: UILabel!
@IBOutlet var profileIconView: UIImageView!
@IBOutlet var adWhaleMediaView: AdWhaleMediaView!
override func adTitleLabel() -> UILabel {
return titleLabel
}
override func adBodyLabel() -> UILabel {
return bodyLabel
}
override func adCallToActionButton() -> UIButton {
return callToActionButton
}
override func adProfileNameLabel() -> UILabel {
return profileNameLabel
}
override func adProfileIconView() -> UIImageView {
return profileIconView
}
override func adMediaView() -> AdWhaleMediaView {
return adWhaleMediaView
}
}2. 구현
Last updated