protected function handle($fn)
    {
        $this->handled = true;

        // Converts string to array
        $content = $fn($this, $this->wei) ?: '';
        if ($content && !is_array($content)) {
            $content = $this->sendText($content);
        }
        $this->beforeSend && call_user_func_array($this->beforeSend, array($this, &$content, $this->wei));

        return $content ? $this->arrayToXml($content)->asXML() : '';
    }