Moodle PHP Documentation 4.4
Moodle 4.4.1 (Build: 20240610) (db07c09afc5)
Laravel\SerializableClosure\SerializableClosure Class Reference

Public Member Functions

 __construct (Closure $closure)
 Creates a new serializable closure instance.
 
 __invoke ()
 Resolve the closure with the given arguments.
 
 __serialize ()
 Get the serializable representation of the closure.
 
 __unserialize ($data)
 Restore the closure after serialization.
 
 getClosure ()
 Gets the closure.
 

Static Public Member Functions

static resolveUseVariablesUsing ($resolver)
 Sets the serializable closure secret key.
 
static setSecretKey ($secret)
 Sets the serializable closure secret key.
 
static transformUseVariablesUsing ($transformer)
 Sets the serializable closure secret key.
 
static unsigned (Closure $closure)
 Create a new unsigned serializable closure instance.
 

Protected Attributes

Laravel SerializableClosure Contracts Serializable $serializable
 

Constructor & Destructor Documentation

◆ __construct()

Laravel\SerializableClosure\SerializableClosure::__construct ( Closure $closure)

Creates a new serializable closure instance.

Parameters
Closure$closure
Return values
void

Member Function Documentation

◆ __invoke()

Laravel\SerializableClosure\SerializableClosure::__invoke ( )

Resolve the closure with the given arguments.

Return values
mixed

◆ __serialize()

Laravel\SerializableClosure\SerializableClosure::__serialize ( )

Get the serializable representation of the closure.

Return values
array

◆ __unserialize()

Laravel\SerializableClosure\SerializableClosure::__unserialize ( $data)

Restore the closure after serialization.

Parameters
array$data
Return values
void
Exceptions
Laravel\SerializableClosure\Exceptions\InvalidSignatureException

◆ getClosure()

Laravel\SerializableClosure\SerializableClosure::getClosure ( )

Gets the closure.

Return values
Closure

◆ resolveUseVariablesUsing()

static Laravel\SerializableClosure\SerializableClosure::resolveUseVariablesUsing ( $resolver)
static

Sets the serializable closure secret key.

Parameters
Closure | null$resolver
Return values
void

◆ setSecretKey()

static Laravel\SerializableClosure\SerializableClosure::setSecretKey ( $secret)
static

Sets the serializable closure secret key.

Parameters
string | null$secret
Return values
void

◆ transformUseVariablesUsing()

static Laravel\SerializableClosure\SerializableClosure::transformUseVariablesUsing ( $transformer)
static

Sets the serializable closure secret key.

Parameters
Closure | null$transformer
Return values
void

◆ unsigned()

static Laravel\SerializableClosure\SerializableClosure::unsigned ( Closure $closure)
static

Create a new unsigned serializable closure instance.

Parameters
Closure$closure
Return values
Laravel\SerializableClosure\UnsignedSerializableClosure

The documentation for this class was generated from the following file: