Place.java 1.89 KB
package fi.insomnia.intra.db;

import fi.insomnia.intra.db.BaseEntity;
import fi.insomnia.intra.db.Usergroup;
import fi.insomnia.intra.db.User;
import java.io.Serializable;
import java.lang.String;
import javax.persistence.*;

import org.eclipse.persistence.annotations.Cache;

/**
 * Entity implementation class for Entity: Place
 *
 */
@Entity
@Cache(alwaysRefresh=true)

@NamedQuery(name = "findAllPlaces", query = "select p from Place p")
public class Place extends BaseEntity implements Serializable {


    /**
     * 
     */
    private static final long serialVersionUID = -5764729988681758345L;

    @ManyToOne
    private Usergroup group;
    @ManyToOne
    private User user;
    private String place;
    private int coordX;
    private int coordY;
    private int type;
    @Lob
    private String description;
    
    @ManyToOne
    private Discount code;

    public Place() {
	super();
    }   
    public Usergroup getGroup() {
	return this.group;
    }

    public void setGroup(Usergroup group) {
	this.group = group;
    }   
    public User getUser() {
	return this.user;
    }

    public void setUser(User user) {
	this.user = user;
    }   
    public String getPlace() {
	return this.place;
    }

    public void setPlace(String place) {
	this.place = place;
    }   
    public int getCoordX() {
	return this.coordX;
    }

    public void setCoordX(int coordX) {
	this.coordX = coordX;
    }   
    public int getCoordY() {
	return this.coordY;
    }

    public void setCoordY(int coordY) {
	this.coordY = coordY;
    }
    public void setDescription(String description) {
	this.description = description;
    }
    public String getDescription() {
	return description;
    }
    public void setCode(Discount code) {
	this.code = code;
    }
    public Discount getCode() {
	return code;
    }
    public void setType(int type) {
	this.type = type;
    }
    public int getType() {
	return type;
    }

}