File tree Expand file tree Collapse file tree 1 file changed +15
-15
lines changed
hibernate-core/src/main/java/org/hibernate/annotations Expand file tree Collapse file tree 1 file changed +15
-15
lines changed Original file line number Diff line number Diff line change 1818 * Allows to specify the target of a foreign-key using a "target attribute" as opposed to
1919 * join column(s). E.g.
2020 * <pre>
21- * {@code @ Entity}
21+ * @ Entity
2222 * class Employee {
23- * {@code @Id}
23+ * @Id
2424 * Integer id;
25- * {@code @ Column(name="ssn") }
25+ * @ Column(name="ssn")
2626 * String socialSecurityNumber;
2727 * }
28- * {@code @ Entity}
28+ * @ Entity
2929 * class TaxDetails {
30- * {@code @ Id Integer id;}
31- * {@code @ OneToOne}
32- * {@code @ PropertyRef("socialSecurityNumber")}
30+ * @ Id Integer id;
31+ * @ OneToOne
32+ * @ PropertyRef("socialSecurityNumber")
3333 * Employee employee;
3434 * }
3535 * </pre>
3636 * Generally more useful with composite keys:
3737 * <pre>
38- * {@code @ Embeddable}
38+ * @ Embeddable
3939 * class Name {
4040 * String first;
4141 * String last;
4242 * }
43- * {@code @ Entity}
43+ * @ Entity
4444 * class Employee {
45- * {@code @Id}
45+ * @Id
4646 * Integer id;
47- * {@code @ Embedded}
47+ * @ Embedded
4848 * Name name;
4949 * }
50- * {@code @ Entity}
50+ * @ Entity
5151 * class TaxDetails {
52- * {@code @ Id Integer id;}
53- * {@code @ OneToOne}
54- * {@code @ PropertyRef("name")}
52+ * @ Id Integer id;
53+ * @ OneToOne
54+ * @ PropertyRef("name")
5555 * Employee employee;
5656 * }
5757 * </pre>
You can’t perform that action at this time.
0 commit comments