hs.lang = { cssDirection: 'ltr', loadingText: 'loading...', loadingTitle: 'click to cancel', focusTitle: 'click to bring to front', fullExpandTitle: 'expand to original size', creditsText: 'powered by Highslide JS', creditsTitle: 'visit Highslide JS website', previousText: 'previous', nextText: 'next', moveText: 'move', closeText: 'close', closeTitle: 'close (ESC)', resizeTitle: 'resize', playText: 'play', playTitle: 'play slideshow (SPACEBAR)', pauseText: 'pause', pauseTitle: 'pause slideshow (SPACEBAR)', previousTitle: 'previous (ARROW LEFT)', nextTitle: 'next (ARROW RIGHT)', moveTitle: 'move', fullExpandText: 'fullscreen', number: 'picture %1 of %2', restoreTitle: 'Click to close image, click und drag to move. Use ARROW keys for previous and next.' };
Inicio > General > HibernateUtil.java

HibernateUtil.java

martes, 12 de enero de 2010 Dejar un comentario Ir a comentarios

Con esta clase tenemos al objeto SessionFactory.

package clases;

import org.hibernate.cfg.AnnotationConfiguration;
import org.hibernate.SessionFactory;

public class HibernateUtil {
private static final SessionFactory sessionFactory;

static {
try {
sessionFactory = new AnnotationConfiguration().configure().buildSessionFactory();
} catch (Throwable ex) {
// Log the exception.
System.err.println(«Initial SessionFactory creation failed.» + ex);
throw new ExceptionInInitializerError(ex);
}
}
public static SessionFactory getSessionFactory() {
return sessionFactory;
}
}

Categories: General Tags:
  1. Sin comentarios aún.
  1. Sin trackbacks aún.


Ir a la barra de herramientas