GoogleAnalyticsProductImpressionCollection
in package
Class GoogleAnalyticsProductImpressionCollection
Table of Contents
- $items : array<string|int, GoogleAnalyticsProductImpressionInterface>
- collect() : static|GoogleAnalyticsProductImpressionCollection
- Named constructor of GoogleAnalyticsProductsDataSetCollection.
- toArray() : array<string|int, GoogleAnalyticsProductImpressionInterface>
- Returns the collected product list items.
- __construct() : mixed
- GoogleAnalyticsProductDataSetCollection constructor.
- add() : $this|GoogleAnalyticsProductImpressionCollection
- Adds a GoogleAnalyticsProductImpressionInterface item to the collection.
Properties
$items
private
array<string|int, GoogleAnalyticsProductImpressionInterface>
$items
Methods
collect()
Named constructor of GoogleAnalyticsProductsDataSetCollection.
public
static collect(array<string|int, GoogleAnalyticsProductImpressionInterface> $products) : static|GoogleAnalyticsProductImpressionCollection
Parameters
- $products : array<string|int, GoogleAnalyticsProductImpressionInterface>
-
Products data.
Return values
static|GoogleAnalyticsProductImpressionCollection —New instance.
toArray()
Returns the collected product list items.
public
toArray() : array<string|int, GoogleAnalyticsProductImpressionInterface>
Return values
array<string|int, GoogleAnalyticsProductImpressionInterface> —__construct()
GoogleAnalyticsProductDataSetCollection constructor.
protected
__construct(array<string|int, GoogleAnalyticsProductImpressionInterface> $products) : mixed
Protected to enforce usage of named constructor.
Parameters
- $products : array<string|int, GoogleAnalyticsProductImpressionInterface>
-
Products data.
Return values
mixed —add()
Adds a GoogleAnalyticsProductImpressionInterface item to the collection.
protected
add(GoogleAnalyticsProductImpressionInterface $productImpression) : $this|GoogleAnalyticsProductImpressionCollection
Parameters
- $productImpression : GoogleAnalyticsProductImpressionInterface
Return values
$this|GoogleAnalyticsProductImpressionCollection —Same instance for chained method calls.