jpaOne to One mapping


Parameters

AnnotationPurpose
@TableGeneratorSpecifies generator name and table name where generator can be found
@GeneratedValueSpecifies generation strategy and refers to name of generator
@OneToOneSpecifies one to one relationship between employee and desk, here Employee is owner of relation
mappedByThis element is provided on reverse side of relation. This enables bidirectional relationship