WooCommerce Code Reference

TransformerInterface

An interface to define a transformer.

Interface TransformerInterface

Table of Contents

transform()  : mixed|null
Transform given value to a different value.
validate()  : mixed
Validate Transformer arguments.

Methods

transform()

Transform given value to a different value.

public transform(mixed $value[, stdClass|null $arguments = null ][, string|null $default_value = null ]) : mixed|null
Parameters
$value : mixed

a value to transform.

$arguments : stdClass|null = null

arguments.

$default_value : string|null = null

default value.

Return values
mixed|null