Created
May 1, 2012 14:17
-
-
Save gbougeard/2568203 to your computer and use it in GitHub Desktop.
FormationItem entity
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@Entity | |
@Table(name = FormationItem.TABLE_NAME) | |
public class FormationItem implements Serializable { | |
private static final long serialVersionUID = 1L; | |
public static final String TABLE_NAME = "formation_item"; | |
public static final String COL_ID = "id_formation_item"; | |
@Id | |
@GeneratedValue(strategy = GenerationType.IDENTITY) | |
@Column(name = COL_ID) | |
private Long idFormationItem; | |
public static final String PROP_NUM = "numItem"; | |
public static final String COL_NUM = "num_item"; | |
@Basic(optional = false) | |
@NotNull(message = "Numero obligatoire") | |
@Column(name = COL_NUM) | |
private Integer numItem; | |
public static final String PROP_COORD = "coord"; | |
@Basic(optional = false) | |
@Column(name = PROP_COORD) | |
private Integer coord; | |
public static final String COL_ID_FORMATION = "id_formation"; | |
public static final String PROP_FORMATION = "formation"; | |
@ManyToOne(cascade= CascadeType.ALL) | |
@JoinColumn(name = COL_ID_FORMATION) | |
private Formation formation; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment