logSelectPromotion method

Future<void> logSelectPromotion({
  1. String? creativeName,
  2. String? creativeSlot,
  3. List<AnalyticsEventItem>? items,
  4. String? locationId,
  5. String? promotionId,
  6. String? promotionName,
  7. Map<String, Object?>? parameters,
  8. AnalyticsCallOptions? callOptions,
})

Logs the standard select_promotion event.

This event signifies that a user has selected a promotion offer.

See: https://firebase.google.com/docs/reference/android/com/google/firebase/analytics/FirebaseAnalytics.Event.html#SELECT_PROMOTION

Implementation

Future<void> logSelectPromotion({
  String? creativeName,
  String? creativeSlot,
  List<AnalyticsEventItem>? items,
  String? locationId,
  String? promotionId,
  String? promotionName,
  Map<String, Object?>? parameters,
  AnalyticsCallOptions? callOptions,
}) {
  _assertParameterTypesAreCorrect(parameters);
  _assertItemsParameterTypesAreCorrect(items);

  return _delegate.logEvent(
    name: 'select_promotion',
    parameters: filterOutNulls(<String, Object?>{
      _CREATIVE_NAME: creativeName,
      _CREATIVE_SLOT: creativeSlot,
      _ITEMS: _marshalItems(items),
      _LOCATION_ID: locationId,
      _PROMOTION_ID: promotionId,
      _PROMOTION_NAME: promotionName,
      if (parameters != null) ...parameters,
    }),
    callOptions: callOptions,
  );
}