Module

public protocol Module : AnyObject

A Module is the generic protocol that any plugin added to tealium must conform.

Each module, then, can conform to each of the following protocols as well to add extra functionality:

A module used by the Tealium SDK to provide some plugin functionality.

  • The version of this module

    Declaration

    Swift

    var version: String { get }
  • id

    The unique id for this module, used to uniquely identify each module instance.

    Declaration

    Swift

    var id: String { get }
  • canBeDisabled Default implementation

    Returns true if the module is optional and can be disabled, or false otherwise. Default is true.

    Default Implementation

    Declaration

    Swift

    static var canBeDisabled: Bool { get }
  • updateConfiguration(_:) Default implementation

    Updates the configuration and, if the configuration is valid, return the same class otherwise return nil and the module is considered disabled.

    Default Implementation

    Declaration

    Swift

    func updateConfiguration(_ configuration: DataObject) -> Self?
  • shutdown() Default implementation

    Called when a previously created module needs to shut down, to allow it to perform some final cleanup before removing it form the available modules.

    Default Implementation

    Declaration

    Swift

    func shutdown()