protected Session createSession(SessionFactory sessionFactory, InputStream in, PrintStream out, PrintStream err, Terminal terminal) throws Exception {
return sessionFactory.create(in, out, err, terminal, null, null);
}
protected SessionFactory createSessionFactory(ThreadIO threadio) {
SessionFactoryImpl sessionFactory = new SessionFactoryImpl(threadio);
sessionFactory.register(new ManagerImpl(sessionFactory, sessionFactory));
return sessionFactory;
}