Substr
Less than 1 minute
Substr
class Substr extends \Hazaar\Model\Attribute\BaseExtends: Hazaar\Model\Attribute\Base
Properties
offset
The offset from which to start the substring.
private int $offsetType: int
length
The maximum length of the substring.
private int $lengthType: int
Methods
__construct
Constructor for the Substr attribute.
public __construct(int $offset, int $length): voidParameters
| Parameter | Type | Description |
|---|---|---|
$offset | int | the offset from which to start the substring |
$length | int | the maximum length of the substring |
evaluate
Applies the substring operation to the property value.
public evaluate(mixed $propertyValue, \ReflectionProperty $property): boolReturns: bool
Parameters
| Parameter | Type | Description |
|---|---|---|
$propertyValue | mixed | the value of the property to substring (passed by reference) |
$property | ReflectionProperty | the reflection property instance for metadata (passed by reference) |
getOffset
Gets the offset from which to start the substring.
public getOffset(): intReturns: int
getLength
Gets the maximum length of the substring.
public getLength(): intReturns: int
Generated by Hazaar API Doc Generator on Fri, 04 Sep 2026 23:32:17 +0000