Skip to content

Instantly share code, notes, and snippets.

@parzibyte
Created August 27, 2019 01:13
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save parzibyte/aab9575c6fb9c36fb9ef00086ecbd402 to your computer and use it in GitHub Desktop.
Save parzibyte/aab9575c6fb9c36fb9ef00086ecbd402 to your computer and use it in GitHub Desktop.
package hello;
import javax.persistence.Entity;
import javax.persistence.GeneratedValue;
import javax.persistence.GenerationType;
import javax.persistence.Id;
@Entity
public class Producto {
@Id
@GeneratedValue(strategy = GenerationType.AUTO)
private Integer id;
private String nombre, codigo;
private Float precio, existencia;
public String getCodigo() {
return codigo;
}
public void setCodigo(String codigo) {
this.codigo = codigo;
}
public Float getPrecio() {
return precio;
}
public void setPrecio(Float precio) {
this.precio = precio;
}
public Float getExistencia() {
return existencia;
}
public void setExistencia(Float existencia) {
this.existencia = existencia;
}
public String getNombre() {
return nombre;
}
public void setNombre(String nombre) {
this.nombre = nombre;
}
public Integer getId() {
return id;
}
public void setId(Integer id) {
this.id = id;
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment