SASNativeAdViewBinderBuilder
Objective-C
@interface SASNativeAdViewBinderBuilder : NSObject
                  Swift
class SASNativeAdViewBinderBuilder : NSObject
                  Builder than can be use to instantiate a SASNativeAdViewBinder instance.
- 
                    
                    
Initialize a new instance of SASNativeAdViewBinderBuilder.
Declaration
Objective-C
- (nonnull instancetype)initWithBaseView:(nonnull UIView *)baseView;Swift
init(baseView: UIView)Parameters
baseViewThe view containing of the other views of the native ad.
Return Value
An initialized instance of SASNativeAdViewBinderBuilder.
 - 
                    
                    
Build an instance of SASNativeAdViewBinder.
Declaration
Objective-C
- (nonnull SASNativeAdViewBinder *)build;Swift
func build() -> SASNativeAdViewBinderReturn Value
An initialized instance of SASNativeAdViewBinder.
 - 
                    
                    
Set the label displaying the ad title on the builder.
Declaration
Objective-C
- (nonnull SASNativeAdViewBinderBuilder *)withTitleLabel: (nonnull UILabel *)titleLabel;Swift
func withTitleLabel(_ titleLabel: UILabel) -> SASNativeAdViewBinderBuilderParameters
titleLabelThe label displaying the ad title.
Return Value
This instance of SASNativeAdViewBinderBuilder.
 - 
                    
                    
Set the label displaying the ad body on the builder.
Declaration
Objective-C
- (nonnull SASNativeAdViewBinderBuilder *)withBodyLabel: (nonnull UILabel *)bodyLabel;Swift
func withBodyLabel(_ bodyLabel: UILabel) -> SASNativeAdViewBinderBuilderParameters
bodyLabelThe label displaying the ad body.
Return Value
This instance of SASNativeAdViewBinderBuilder.
 - 
                    
                    
Set the button displaying the ad call to action on the builder.
Declaration
Objective-C
- (nonnull SASNativeAdViewBinderBuilder *)withCallToActionButton: (nonnull UIButton *)callToActionButton;Swift
func withCallToActionButton(_ callToActionButton: UIButton) -> SASNativeAdViewBinderBuilderParameters
callToActionButtonThe button displaying the ad call to action.
Return Value
This instance of SASNativeAdViewBinderBuilder.
 - 
                    
                    
Set the label displaying the ad advertiser on the builder.
Declaration
Objective-C
- (nonnull SASNativeAdViewBinderBuilder *)withAdvertiserLabel: (nonnull UILabel *)advertiserLabel;Swift
func withAdvertiserLabel(_ advertiserLabel: UILabel) -> SASNativeAdViewBinderBuilderParameters
advertiserLabelThe label displaying the ad advertiser.
Return Value
This instance of SASNativeAdViewBinderBuilder.
 - 
                    
                    
Set the rating bar displaying the ad rating on the builder.
Declaration
Objective-C
- (nonnull SASNativeAdViewBinderBuilder *)withRatingBar: (nonnull UIView<SASRatingBar> *)ratingBar;Swift
func withRatingBar(_ ratingBar: any UIView & SASRatingBar) -> SASNativeAdViewBinderBuilderParameters
ratingBarThe rating bar displaying the ad rating.
Return Value
This instance of SASNativeAdViewBinderBuilder.
 - 
                    
                    
Set the view displaying the ad icon on the builder.
Declaration
Objective-C
- (nonnull SASNativeAdViewBinderBuilder *)withIconView: (nonnull UIView *)iconView;Swift
func withIconView(_ iconView: UIView) -> SASNativeAdViewBinderBuilderParameters
iconViewThe view displaying the ad icon.
Return Value
This instance of SASNativeAdViewBinderBuilder.
 - 
                    
                    
Set the view displaying the ad main content on the builder.
Declaration
Objective-C
- (nonnull SASNativeAdViewBinderBuilder *)withMainView: (nonnull UIView *)mainView;Swift
func withMainView(_ mainView: UIView) -> SASNativeAdViewBinderBuilderParameters
mainViewThe view displaying the ad main content.
Return Value
This instance of SASNativeAdViewBinderBuilder.
 - 
                    
                    
Set the view that will contain the ad customer feedback button on the builder.
Note
Displaying the customer feedback button is mandatory. If no container is set, the customer feedback button will be added in the top right corner of the base view.
Declaration
Objective-C
- (nonnull SASNativeAdViewBinderBuilder *)withCustomerFeedbackContainerView: (nonnull UIView *)customerFeedbackContainerView;Swift
func withCustomerFeedbackContainerView(_ customerFeedbackContainerView: UIView) -> SASNativeAdViewBinderBuilderParameters
customerFeedbackContainerViewThe view that will contain the ad customer feedback button.
Return Value
This instance of SASNativeAdViewBinderBuilder.