private function handleRequest()
    {
        //check if it's a legal webservice class
        if (!in_array($this->name, $this->classNameArr)) {
            throw new Exception('No valid webservice class.');
        }

        //check cache
        if (!file_exists($this->wsdlfile)) {
            $this->createWSDL();
        }

        $options = array('soap_version' => SOAP_1_1,
                         'actor' => $this->actor,
                         'classmap' => $this->structureMap, );

        header('Content-type: text/xml');
        $this->server = new SoapServer($this->wsdlfile, $options);
        $this->server->setClass($this->name);
        $this->server->setPersistence($this->persistence);

        use_soap_error_handler(true);
        $this->server->handle();
    }