package br.com.senacagil.springmvc.model;

import javax.persistence.Column;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;

/**
 * (c) 2007, D George
 * Spring / JPA / Maven Example Code
 * 
 * reference: http://www.ibm.com/developerworks/edu/j-dw-java-spring2-i.html
 */
@Entity
public class Address {
	@Id
	@GeneratedValue(strategy = GenerationType.TABLE)
	private long id;

	@Column(name = "HOUSENUM")
	private int number;

	@Column(name = "STNAME", length = 25)
	private String street;

	public long getId() {
		return id;
	}

	public int getNumber() {
		return number;
	}

	public void setNumber(int number) {
		this.number = number;
	}

	public String getStreet() {
		return street;
	}

	public void setStreet(String street) {
		this.street = street;
	}

	public Address(int number, String street) {
		this.number = number;
		this.street = street;
	}

	public Address() {
	}

}
