Conditional
class Conditional extends CommonTransformation
Class Condition
Represents conditional transformation.
Methods
ifCondition(BaseExpressionComponent|string $expression, BaseAction|Transformation $action)
Condition named constructor.
setIfCondition(BaseExpressionComponent|string $expression)
Specifies a condition to be met before applying a transformation.
otherwise(Action|Transformation $action)
Specifies a transformation that is applied in the case that the initial condition is evaluated as false.
Details
static Conditional
ifCondition(BaseExpressionComponent|string $expression, BaseAction|Transformation $action)
Condition named constructor.
Conditional
setIfCondition(BaseExpressionComponent|string $expression)
Specifies a condition to be met before applying a transformation.
Conditional
otherwise(Action|Transformation $action)
Specifies a transformation that is applied in the case that the initial condition is evaluated as false.
string
toUrl(ImageTransformation|string|null $withTransformation = null)
Serializes transformation to URL.