public function run() 
	{
		if ($this->documentor) {
			$this->documentor->setMethodData( $this->methods );
		}
		$request_xml = file_get_contents( 'php://input' );
		if ( !$request_xml ) 
		{
			if ( ( $query = $_SERVER['QUERY_STRING'] ) 
				&& isset($this->wsdl[$query]) && $this->wsdl[$query] )
			{
				header('Content-type: text/xml');
				header('Access-Control-Allow-Origin: *');
				echo $this->wsdl[$query];
			}
			else if ( $this->documentor )
			{
				header('Content-type: text/html; charset=' . $this->outputOptions['encoding']);
				$this->documentor->handle( $this, $this->methods );
			}
			else
			{
				// FIXME: add check for json-rpc protocol, if set and none of the xml protocols are set, use that
				header('Content-type: text/xml');
				header('Access-Control-Allow-Origin: *');
				echo xmlrpc_encode_request(
					null,  
					ripcord::fault( -1, 'No request xml found.' ),
					$this->outputOptions
				);
			}
		}
		else 
		{
			// FIXME: add check for the protocol of the request, could be json-rpc, then check if it is supported.
			header('Content-type: text/xml');
			header('Access-Control-Allow-Origin: *');
			echo $this->handle( $request_xml );
		}
	}