⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 vets.java

📁 随书光盘:精通Sping 2.0 的随书源代码
💻 JAVA
字号:
package org.springframework.samples.annotations;
// Generated 2006-10-27 18:36:22 by Hibernate Tools 3.2.0.beta8


import java.util.HashSet;
import java.util.Set;
import javax.persistence.CascadeType;
import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.FetchType;
import javax.persistence.Id;
import javax.persistence.ManyToMany;
import javax.persistence.Table;

/**
 * Vets generated by hbm2java
 */
@Entity
@Table(name="VETS"
    , uniqueConstraints = {  }
)
public class Vets  implements java.io.Serializable {

    // Fields    

     private int id;
     private String firstName;
     private String lastName;
     private Set<Specialties> specialtieses = new HashSet<Specialties>(0);

     // Constructors

    /** default constructor */
    public Vets() {
    }

	/** minimal constructor */
    public Vets(int id) {
        this.id = id;
    }
    /** full constructor */
    public Vets(int id, String firstName, String lastName, Set<Specialties> specialtieses) {
       this.id = id;
       this.firstName = firstName;
       this.lastName = lastName;
       this.specialtieses = specialtieses;
    }
   
    // Property accessors
     @Id
    
    @Column(name="ID", unique=true, nullable=false, insertable=true, updatable=true)
    public int getId() {
        return this.id;
    }
    
    public void setId(int id) {
        this.id = id;
    }
    
    @Column(name="FIRST_NAME", unique=false, nullable=true, insertable=true, updatable=true, length=30)
    public String getFirstName() {
        return this.firstName;
    }
    
    public void setFirstName(String firstName) {
        this.firstName = firstName;
    }
    
    @Column(name="LAST_NAME", unique=false, nullable=true, insertable=true, updatable=true, length=30)
    public String getLastName() {
        return this.lastName;
    }
    
    public void setLastName(String lastName) {
        this.lastName = lastName;
    }
    @ManyToMany(cascade={CascadeType.ALL}, fetch=FetchType.LAZY, mappedBy="vetses")
    public Set<Specialties> getSpecialtieses() {
        return this.specialtieses;
    }
    
    public void setSpecialtieses(Set<Specialties> specialtieses) {
        this.specialtieses = specialtieses;
    }




}


⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -