References

Public classes and protocols for callbacks.

Classes

  • FPSdk

Protocol

  • FPSdkListener
  • FPSdkSessionListener
  • FPSdkCartListener
  • FPSdkCheckoutListener
  • FPSdkEventListener
  • FPSdkActionListener

FPSdk

The top level Flux Panda SDK singleton that provides methods for initialize player, open player and get data from player.

Public Method

  • Initialize the Flux Panda SDK
//Last parameter handler is a callback when SDK initialized and ready to use. App should call all other method after this callback.
public func initialize(domain: String = "", channelId: String, apiKey:String, userName: String = "", handler: @escaping (Bool) -> Void)
  • Open the player using sessionId
public func open(sessionId: String)
  • Open the player using sessionId and timeIndex
public func open(sessionId: String, timeIndex: String)
  • Close the player
public func close()
  • Minimize the player
public func minimize()
  • Maximize the player
public func maximize()
  • Clear the shopping cart
public func clearShoppingCart()
  • Get sessions
public func getSessions()

FPSdkListener

Flux Panda SDK protocol that provides callbacks.

Public Method

  • Callback method of close
func onClose()
  • Callback method of minimize
func onMinimize()
  • Callback method of maximize
func onMaximize()
  • Callback method of getSessions
func onGetSessions(data: [String: Any])
  • Callback method of clearShoppingCart
func onClearShoppingCart()
  • Flux Panda SDK call this callback method when user click checkout from player
func onCheckout(data: [String: Any])
  • Flux Panda SDK call this callback method for specific events
func onEvent(data: [String: Any])

FPSdkActionListener

Flux Panda SDK Action protocol that provides callbacks.

Public Method

  • Callback method of close
func onClose()
  • Callback method of minimize
func onMinimize()
  • Callback method of maximize
func onMaximize()

FPSdkSessionListener

Flux Panda SDK Session protocol that provides callbacks.

Public Method

  • Callback method of getSessions
func onGetSessions(data: [String: Any])

FPSdkCartListener

Flux Panda SDK Cart protocol that provides callbacks.

Public Method

  • Callback method of clearShoppingCart
func onClearShoppingCart()

FPSdkCheckoutListener

Flux Panda SDK Checkout protocol that provides callbacks.

Public Method

  • Flux Panda SDK call this callback method when user click checkout from player
func onCheckout(data: [String: Any])

FPSdkEventListener

Flux Panda SDK Event protocol that provides callbacks.

Public Method

  • Flux Panda SDK call this callback method for specific events
func onEvent(data: [String: Any])