MoEngageProperties

@objc
public class MoEngageProperties : NSObject

Class responsible to build attributes for event

Initializer

  • Create MoEngageProperties instance with given attributedDict

    Declaration

    Swift

    @objc
    public init(withAttributes attributesDict: [String : Any]? = nil)

    Parameters

    attributesDict

    attributes dict for the event

Insert Attribute

  • Add an attribute to MoEngageProperties

    Declaration

    Swift

    @objc
    public func addAttribute(_ attrVal: Any?, withName attrName: String)

    Parameters

    attrVal

    attribute value

    attrName

    attribute name

  • Add Location attribute to MoEngageProperties

    Declaration

    Swift

    @objc
    public func addLocationAttribute(_ attrVal: MoEngageGeoLocation, withName attrName: String)

    Parameters

    attrVal

    location attribute of type MoEngageGeoLocation

    attrVal

    location attribute of type MoEngageGeoLocation

    attrName

    attribute name

  • Add date attribute to MoEngageProperties

    Declaration

    Swift

    @objc
    public func addDateAttribute(_ attrVal: Date, withName attrName: String)

    Parameters

    attrVal

    value of type Date

    attrName

    attribute name

  • Add ISO date attribute to MoEngageProperties

    Note

    ISO format accepted yyyy-MM-dd’T'HH:mm:ss.SSS'Z’ / yyyy-MM-dd’T'HH:mm:ss'Z’

    Declaration

    Swift

    @objc
    public func addDateISOStringAttribute(_ dateString: String, withName attrName: String)

    Parameters

    dateString

    ISO date string

    attrName

    attribute value

  • Add Epoch Date attribute to MoEngageProperties

    Declaration

    Swift

    @objc
    public func addDateEpochAttribute(_ epoch: Double, withName attrName: String)

    Parameters

    epoch

    Date attribute of type Double

    attrName

    attribute name

Non-Interactive

  • Set the event as non-interactive.

    Declaration

    Swift

    @objc
    public func setNonInteractive()