RemoveUnserializeForInternalSerializableClassesPass
in package
Internal classes can not be instantiated with the newInstanceWithoutArgs reflection method, so need the serialization hack. If the class also implements Serializable, we need to replace the standard unserialize method definition with a dummy
Table of Contents
- DUMMY_METHOD_DEFINITION = 'public function unserialize($string) {} '
- apply() : mixed
- appendToClass() : mixed
Constants
DUMMY_METHOD_DEFINITION
public
mixed
DUMMY_METHOD_DEFINITION
= 'public function unserialize($string) {} '
Methods
apply()
public
apply(mixed $code, MockConfiguration $config) : mixed
Parameters
- $code : mixed
- $config : MockConfiguration
Return values
mixed —appendToClass()
protected
appendToClass(mixed $class, mixed $code) : mixed
Parameters
- $class : mixed
- $code : mixed