Piwik\Columns\

DimensionSegmentFactory

A factory to create segments from a dimension.

Methods

The class defines the following methods:

__construct()

Generates a new dimension segment factory.

Signature

  • It accepts the following parameter(s):
    • $dimension (Dimension) — A dimension instance the created segments should be based on.

createSegment()

Creates a segment based on the dimension properties

Signature

  • It accepts the following parameter(s):
    • $segment (Segment) — optional Segment to enrich with dimension data (if properties not already set)
  • It returns a Segment value.
  • It throws one of the following exceptions: