interface TrustedCallbackInterface (View source)

Interface to declare trusted callbacks.

Constants

THROW_EXCEPTION

Untrusted callbacks throw exceptions.

TRIGGER_WARNING

Untrusted callbacks trigger E_USER_WARNING errors.

TRIGGER_SILENCED_DEPRECATION

Untrusted callbacks trigger silenced E_USER_DEPRECATION errors.

Methods

static string[]
trustedCallbacks()

Lists the trusted callbacks provided by the implementing class.

Details

static string[] trustedCallbacks()

Lists the trusted callbacks provided by the implementing class.

Trusted callbacks are public methods on the implementing class and can be invoked via \Drupal\Core\Security\DoTrustedCallbackTrait::doTrustedCallback().

Return Value

string[]

List of method names implemented by the class that can be used as trusted callbacks.

See also

DoTrustedCallbackTrait::doTrustedCallback