Google Analytics Measurement Protocol 1.2.2
Google Analytics plugin for Unreal Engine, using a native cross-platform implementation of the Measurement Protocol.
Loading...
Searching...
No Matches
Public Member Functions | Public Attributes | List of all members
FGoogleAnalyticsMPPurchaseInfo Struct Reference

Information for an economic transaction, consisting of the purchase of one or more items. More...

#include <GAMPPurchaseInfo.h>

Public Member Functions

 FGoogleAnalyticsMPPurchaseInfo ()
 Default constructor. More...
 
 FGoogleAnalyticsMPPurchaseInfo (const FString &InTransactionId, const TArray< FGoogleAnalyticsMPPurchaseItemInfo > &InItems, const FString &InCurrency, const TMap< FString, FString > &InAttributes)
 Construct a transaction with a known Transaction ID. More...
 
 FGoogleAnalyticsMPPurchaseInfo (const TArray< FGoogleAnalyticsMPPurchaseItemInfo > &InItems, const FString &InCurrency, const TMap< FString, FString > &InAttributes)
 Construct a transaction with an undefined Transaction ID (an proper unique value will be logged for it). More...
 
float GetTotalValue () const
 Return the total price of the purchased items. More...
 

Public Attributes

FString Affiliation
 A product affiliation to designate a supplying company or brick and mortar store location. More...
 
TMap< FString, FString > Attributes
 Optional auxiliary Google Analytics Measurement Protocol attributes sent with the corresponding "transaction". More...
 
FString Currency
 Currency used in the transaction (3-letter ISO 4217 alphabetic code format). More...
 
TArray< FGoogleAnalyticsMPPurchaseItemInfoItems
 The purchased items. More...
 
FString TransactionId
 Unique Transaction ID (if empty, a new UUID will be generated automatically). More...
 

Detailed Description

Information for an economic transaction, consisting of the purchase of one or more items.

Constructor & Destructor Documentation

◆ FGoogleAnalyticsMPPurchaseInfo() [1/3]

FGoogleAnalyticsMPPurchaseInfo::FGoogleAnalyticsMPPurchaseInfo ( )
inline

Default constructor.

◆ FGoogleAnalyticsMPPurchaseInfo() [2/3]

FGoogleAnalyticsMPPurchaseInfo::FGoogleAnalyticsMPPurchaseInfo ( const TArray< FGoogleAnalyticsMPPurchaseItemInfo > &  InItems,
const FString &  InCurrency,
const TMap< FString, FString > &  InAttributes 
)
inline

Construct a transaction with an undefined Transaction ID (an proper unique value will be logged for it).

Parameters
InItemsPurchased items in the transaction.
InCurrencyThe currency used in the transaction (3-letter ISO 4217 alphabetic code format)
InAttributesOptional auxiliary Google Analytics Measurement Protocol attributes sent with the corresponding "transaction" ( for GA4 see https://developers.google.com/analytics/devguides/collection/ga4/reference/events?client_type=gtag; for UA see https://developers.google.com/analytics/devguides/collection/protocol/v1/parameters).

◆ FGoogleAnalyticsMPPurchaseInfo() [3/3]

FGoogleAnalyticsMPPurchaseInfo::FGoogleAnalyticsMPPurchaseInfo ( const FString &  InTransactionId,
const TArray< FGoogleAnalyticsMPPurchaseItemInfo > &  InItems,
const FString &  InCurrency,
const TMap< FString, FString > &  InAttributes 
)
inline

Construct a transaction with a known Transaction ID.

If you don't have a known Transaction ID, use the constructor with no Transaction ID parameter.

Parameters
InTransactionIdUnique Transaction ID as reported by the used transaction system. For GA4 see transaction_id at https://developers.google.com/analytics/devguides/collection/ga4/reference/events?client_type=gtag#purchase; for UA see ti at https://developers.google.com/analytics/devguides/collection/protocol/v1/parameters#ti.
InItemsPurchased items in the transaction.
InCurrencyThe currency used in the transaction (3-letter ISO 4217 alphabetic code format)
InAttributesOptional auxiliary Google Analytics Measurement Protocol attributes sent with the corresponding "transaction". For GA4 see https://developers.google.com/analytics/devguides/collection/ga4/reference/events?client_type=gtag; for UA see https://developers.google.com/analytics/devguides/collection/protocol/v1/parameters.

Member Function Documentation

◆ GetTotalValue()

float FGoogleAnalyticsMPPurchaseInfo::GetTotalValue ( ) const
inline

Return the total price of the purchased items.

Member Data Documentation

◆ Affiliation

FString FGoogleAnalyticsMPPurchaseInfo::Affiliation

A product affiliation to designate a supplying company or brick and mortar store location.

◆ Attributes

TMap<FString, FString> FGoogleAnalyticsMPPurchaseInfo::Attributes

Optional auxiliary Google Analytics Measurement Protocol attributes sent with the corresponding "transaction".

◆ Currency

FString FGoogleAnalyticsMPPurchaseInfo::Currency

Currency used in the transaction (3-letter ISO 4217 alphabetic code format).

◆ Items

TArray<FGoogleAnalyticsMPPurchaseItemInfo> FGoogleAnalyticsMPPurchaseInfo::Items

The purchased items.

◆ TransactionId

FString FGoogleAnalyticsMPPurchaseInfo::TransactionId

Unique Transaction ID (if empty, a new UUID will be generated automatically).


The documentation for this struct was generated from the following file: