public function send()
    {
        $data = $this->parseDataToString($this->data);
        $format = $this->allowedFormats[$this->format];

        // Send status header
        header($this->getStatus(), true, $this->getStatus());

        foreach(self::$headers as $key => $value) {
            header($key.": ".$value);
        }

        // Send content type header
        header("Content-Type: ".$format['mimetype']."; charset=utf-8");

		// Set content length header
		header("Content-Length: ".strlen($data));

        if(function_exists("ginger_log")) {
            ginger_log($this);
        }

        echo $data;

        die();
    }