Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- /*
- * To change this license header, choose License Headers in Project Properties.
- * To change this template file, choose Tools | Templates
- * and open the template in the editor.
- */
- package prueba2sem2018;
- /**
- *
- * @author gatob
- */
- public class Animal {
- //Declaración Variables de Instancia
- private String nombreA;
- private String tipoA;
- private int meses;
- private int cantVacunas;
- //Constructor
- public Animal(String nombreA, String tipoA, int meses, int cantVacunas){
- this.nombreA = nombreA;
- this.tipoA = tipoA;
- this.meses = meses;
- this.cantVacunas = cantVacunas;
- }
- //Set and Get
- public void setNombreA(String nombreA){
- this.nombreA = nombreA;
- }
- public String getNombreA(){
- return nombreA;
- }
- public void setTipoA(String tipoA){
- this.tipoA = tipoA;
- }
- public String getTipoA(){
- return tipoA;
- }
- public void setMeses(int meses){
- this.meses = meses;
- }
- public int getMeses(){
- return meses;
- }
- public void setCantVacunas(int cantVacunas){
- this.cantVacunas = cantVacunas;
- }
- public int getCantVacunas(){
- return cantVacunas;
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment