public static function createSessionManager(ContainerInterface $container): SessionManager
    {
        $manager = new SessionManager($container->get('config'));

        if ($container->has(CacheManagerContract::class)) {
            $manager->setCacheManager($container->get(CacheManagerContract::class));
        }

        if ($container->has(JarContract::class)) {
            $manager->setCookieJar($container->get(JarContract::class));
        }

        return $manager;
    }
public static function createSessionManager(ContainerInterface $container): SessionManager
    {
        $manager = new SessionManager($container->get('config'));

        if ($container->has(CacheManagerContract::class)) {
            $manager->setCacheManager($container->get(CacheManagerContract::class));
        }

        if ($container->has(JarContract::class)) {
            $manager->setCookieJar($container->get(JarContract::class));
        }

        return $manager;
    }
public static function createSessionManager ( ContainerInterface $ container ) : SessionManager { $ manager = new SessionManager ( $ container -> get ( 'config' ) ) ; if ( $ container -> has ( CacheManagerContract :: class ) ) { $ manager -> setCacheManager ( $ container -> get ( CacheManagerContract :: class ) ) ; } if ( $ container -> has ( JarContract :: class ) ) { $ manager -> setCookieJar ( $ container -> get ( JarContract :: class ) ) ; } return $ manager ; }
Create new session manager instance.

@param \Psr\Container\ContainerInterface $container

@return \Viserio\Component\Session\SessionManager
Create new session manager instance .