public function init(string $scheme, string $host, int $port): self
    {
        return $this
            ->setServerOrigin($scheme, $host, $port)
            ->setPreFlightCacheMaxAge(0)
            ->setCredentialsNotSupported()
            ->enableAllOriginsAllowed()
            ->setAllowedOrigins([])
            ->enableAllMethodsAllowed()
            ->setAllowedMethods([])
            ->enableAllHeadersAllowed()
            ->setAllowedHeaders([])
            ->setExposedHeaders([])
            ->disableAddAllowedMethodsToPreFlightResponse()
            ->disableAddAllowedHeadersToPreFlightResponse()
            ->disableCheckHost();
    }
public function init(string $scheme, string $host, int $port): self
    {
        return $this
            ->setServerOrigin($scheme, $host, $port)
            ->setPreFlightCacheMaxAge(0)
            ->setCredentialsNotSupported()
            ->enableAllOriginsAllowed()
            ->setAllowedOrigins([])
            ->enableAllMethodsAllowed()
            ->setAllowedMethods([])
            ->enableAllHeadersAllowed()
            ->setAllowedHeaders([])
            ->setExposedHeaders([])
            ->disableAddAllowedMethodsToPreFlightResponse()
            ->disableAddAllowedHeadersToPreFlightResponse()
            ->disableCheckHost();
    }
public function init ( string $ scheme , string $ host , int $ port ) : self { return $ this -> setServerOrigin ( $ scheme , $ host , $ port ) -> setPreFlightCacheMaxAge ( 0 ) -> setCredentialsNotSupported ( ) -> enableAllOriginsAllowed ( ) -> setAllowedOrigins ( [ ] ) -> enableAllMethodsAllowed ( ) -> setAllowedMethods ( [ ] ) -> enableAllHeadersAllowed ( ) -> setAllowedHeaders ( [ ] ) -> setExposedHeaders ( [ ] ) -> disableAddAllowedMethodsToPreFlightResponse ( ) -> disableAddAllowedHeadersToPreFlightResponse ( ) -> disableCheckHost ( ) ; }
Sort of default constructor, though made separate to be used optionally when no cached data available.

@param string $scheme
@param string $host
@param int    $port

@return self
Sort of default constructor though made separate to be used optionally when no cached data available .