InAppMessage

public struct InAppMessage : Codable, Equatable, Sendable

In-App Message

  • Display behavior

    See more

    Declaration

    Swift

    public enum DisplayBehavior : String, Codable, Equatable, Sendable
  • The name.

    Declaration

    Swift

    public var name: String
  • Display content

    Declaration

    Swift

    public var displayContent: InAppMessageDisplayContent
  • Any message extras.

    Declaration

    Swift

    public var extras: AirshipJSON?
  • Display actions.

    Declaration

    Swift

    public var actions: AirshipJSON?
  • If reporting is enabled or not for the message.

    Declaration

    Swift

    public var isReportingEnabled: Bool?
  • Display behavior

    Declaration

    Swift

    public var displayBehavior: DisplayBehavior?
  • In-app message constructor

    Declaration

    Swift

    public init(
        name: String,
        displayContent: InAppMessageDisplayContent,
        extras: AirshipJSON? = nil,
        actions: AirshipJSON? = nil,
        isReportingEnabled: Bool? = nil,
        displayBehavior: DisplayBehavior? = nil
    )

    Parameters

    name

    Name of the message

    displayContent

    Content model to be displayed in the message

    extras

    Extras payload as JSON

    actions

    Actions to be executed by the message as JSON

    isReportingEnabled

    Reporting enabled flag

    displayBehavior

    Display behavior

  • Declaration

    Swift

    public init(from decoder: Decoder) throws
  • Declaration

    Swift

    public func encode(to encoder: Encoder) throws