function emailRecipient() { $self = $this; return (string) Event::result('user.recipient', $this, function ($result) use($self) { if (strpos($result, $self->email) === false) { return 'a string without the actual e-mail address'; } }); }
static function generateID() { return (int) Event::result('file.new.id', function ($id) { return (is_numeric($id) and $id) ? true : 'a non-integer or zero'; }); }
static function generatePassword() { return (string) Event::result('order.new.password', function ($password) { return strlen($password) < 1 ? 'a blank string' : true; }); }