serviceException = $serviceException; $this->metadata = $metadata; parent::__construct($message, $code); } /** * If $serviceException is set, return true. * * @return bool */ public function hasServiceException() { return (bool) $this->serviceException; } /** * Return the service exception object. * * @return Exception */ public function getServiceException() { return $this->serviceException; } /** * Get exception metadata. */ public function getMetadata() { return $this->metadata; } }