You have not specified whether you insist to have one-to-one relationship or you don't care , and also if you prefer using Enum instead of a Class.
This Link provides some useful information on one-to-one mapping in hibernate, if you want to have such relationship between your tables:
one-to-one example
However hibernate one-to-one mapping is not much recommended, and you could simply use a one-to-many mapping just like this:
@Entity
@Table(name = "Person")
public class Person {
@Id
@GeneratedValue
int id;
@OneToMany(mappedBy = "Person", cascade = CascadeType.ALL, fetch = FetchType.LAZY)
Private MaritalStatus;
}
@Entity
@Table(name = "MaritalStatus")
public class Person {
@Id
@GeneratedValue
int id;
@ManyToOne
Person person = new Person();
}
This approach is much simple , but you may prefer to have an Enum instead of class and map your tables using enums. That approach is a bit more difficult to implement and this post provides you all the stuff you need : Mapping enum to a table