The base class for all value objects and structs.
Supports read-only properties by marking them as protected.
In this case they will only be writable using constructor, and need to be documented
using @property-read <type> <$var>
annotation in class doc in addition to inline property doc.
Writable properties must be public and must be documented inline.
Properties
Human-readable description of the customer group.
|
public array<int, string> $descriptions = []
|
The structure of this field is:
[2 => '', 4 => ''];
Human-readable name of the customer group.
|
public array<int, string> $names = []
|
The structure of this field is:
[2 => '', 4 => ''];
Methods
Construct object optionally with a set of properties.
|
public __construct(string $identifier, array<int, string> $names, array<int, string> $descriptions[, numeric-string $globalPriceRate = '100.0' ])
|
Parameters
Name |
Type |
Default value |
Description |
$identifier
|
string
|
-
|
-
|
$names
|
array<int, string>
|
-
|
-
|
$descriptions
|
array<int, string>
|
-
|
-
|
$globalPriceRate
|
numeric-string
|
'100.0'
|
-
|
|
public addDescription(int $languageId, string $description) : void
|
Parameters
Name |
Type |
Default value |
Description |
$languageId
|
int
|
-
|
-
|
$description
|
string
|
-
|
-
|
|
public addName(int $languageId, string $name) : void
|
Parameters
Name |
Type |
Default value |
Description |
$languageId
|
int
|
-
|
-
|
$name
|
string
|
-
|
-
|
|
public getDescription(int $languageId) : string
|
Parameters
Name |
Type |
Default value |
Description |
$languageId
|
int
|
-
|
-
|
Return values
string
|
public getDescriptions() : array<int, string>
|
Return values
array<int, string>
|
public getGlobalPriceRate() : numeric-string
|
Return values
numeric-string
|
public getIdentifier() : string
|
Return values
string
|
public getName(int $languageId) : string
|
Parameters
Name |
Type |
Default value |
Description |
$languageId
|
int
|
-
|
-
|
Return values
string
|
public getNames() : array<int, string>
|
Return values
array<int, string>
Returns list of available properties' names.
|
protected getProperties([array<int, string> $dynamicProperties = [] ]) : array<int, string>
|
Override to add dynamic properties.
Parameters
Name |
Type |
Default value |
Description |
$dynamicProperties
|
array<int, string>
|
[]
|
Additional dynamic properties exposed on the object
|
Return values
array<int, string>
Tags
-
Serializerignore
-