(Quick Reference)

create-hibernate-cfg-xml

Purpose

The create-hibernate-cfg-xml command will create a hibernate.cfg.xml file for custom Hibernate mappings.

Examples

Propósito

El comando create-hibernate-cfg-xml creará un fichero hibernate.cfg.xml para personalizar el mapeo Hibernate.

Ejemplos


grails create-hibernate-cfg-xml

Description

Creates a hibernate.cfg.xml file in the grails-app/conf/hibernate directory. You can add <mapping> elements there to reference annotated Java domain classes, classes mapped by hbm.xml files, or hbm.xml files containing <database-object> elements defining custom DDL that's not supported by GORM.

Usage:

Descripción

Crea un fichero hibernate.cfg.xml en el directorio grails-app/conf/hibernate. Puede añadir el elemento de anotación Java <mapping> para referirse al dominio de clase, clases mapeadas por ficheros hbm.xml o ficheros hbm.xml contenidos en elementos <database-object> que definien el DLL a medida que no es apoyada por GORM.

Uso:

grails create-hibernate-cfg-xml

Fired Events:

  • CreatedFile - When the file is created

  • CreatedFile - Cuando el fichero es creado