AbAssignmentsTableName
Rasuvaeff\Yii3AbTestingDb\AbAssignmentsTableName
Class · rasuvaeff/yii3-ab-testing-db · Source
The sticky-assignment table's name, as a type.
Separate from AbExperimentsTableName because the two tables are configured independently and hold different things: definitions versus per-subject assignments. Sharing one value object would let a rename of one silently retarget the other.
The type exists for the same reason as the experiments one: migrations are built through Injector::make(), which cannot resolve a scalar constructor argument, so a string $table is unconfigurable in practice.
Constructor
php
new AbAssignmentsTableName(string $value = 'ab_assignments')Properties
| Property | Type | Readonly | Description |
|---|---|---|---|
value | string | yes |
Methods
__toString()
php
__toString(): stringforIndexName()
php
forIndexName(): stringBase for index names: a schema-qualified table cannot appear verbatim in an index name, so schema.table becomes schema_table.