Advertisement
Guest User

Untitled

a guest
May 28th, 2015
260
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Java 0.99 KB | None | 0 0
  1. import java.text.ParseException;
  2.  
  3. public class Utente extends Persona{
  4.    
  5.     private String numeroAlbo;
  6.     private String specialista;
  7.  
  8.     public Utente(String nome, String cognome, String dataNascita,
  9.             String luogoNascita, String telefono, String genere,
  10.             String codiceFiscale, String numeroAlbo, String specialista) throws ParseException {
  11.         super(nome, cognome, dataNascita, luogoNascita, telefono, genere, codiceFiscale);
  12.         this.numeroAlbo=numeroAlbo;
  13.         this.specialista=specialista;
  14.     }
  15.  
  16.     public Utente(String nome, String cognome, String dataNascita,
  17.             String luogoNascita, String telefono, String genere,
  18.             String codiceFiscale, String numeroAlbo) throws ParseException {
  19.         super(nome, cognome, dataNascita, luogoNascita, telefono, genere, codiceFiscale);
  20.         this.numeroAlbo=numeroAlbo;
  21.         this.specialista="generico";
  22.     }
  23.     public String toString(){
  24.         return String.format(nome, cognome, dataNascita, luogoNascita, telefono, genere, codiceFiscale, numeroAlbo, specialista);
  25.     }
  26.  
  27. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement