var ViewBuilder = require('./ViewBuilder')
var NATIVE_BRIDGE_NAME = "GetSocialCordova";
var SmartInviteViewBuilder = function() {
this.subject = null;
this.text = null;
this.referralData = null;
this.imagePath = null;
}
SmartInviteViewBuilder.prototype.setSubject = function(subject) {
this.subject = subject;
return this;
}
SmartInviteViewBuilder.prototype.setText = function(text) {
this.text = text;
return this;
}
SmartInviteViewBuilder.prototype.setReferralData = function(referralData) {
this.referralData = referralData;
return this;
}
SmartInviteViewBuilder.prototype.setImagePath = function(imagePath) {
this.imagePath = imagePath;
return this;
}
SmartInviteViewBuilder.prototype.show = function() {
var option = this.toJson();
if(this.subject != null) {
option.subject = this.subject;
}
if(this.text != null) {
option.text = this.text;
}
if(this.referralData != null) {
option.referralData = this.referralData;
}
if(this.imagePath != null) {
option.imagePath = this.imagePath;
}
cordova.exec(null, null, NATIVE_BRIDGE_NAME, "createSmartInviteView", [option]);
}
SmartInviteViewBuilder.prototype.close = function() {
var option = {}
cordova.exec(null, null, NATIVE_BRIDGE_NAME, "closeSmartInviteView", [option]);
}
SmartInviteViewBuilder.prototype.__proto__ = ViewBuilder.prototype;
module.exports = SmartInviteViewBuilder;
h