Created
April 10, 2014 12:24
-
-
Save luizventurote/10376218 to your computer and use it in GitHub Desktop.
Exercício de diagrama de classes - Aula de UML para código.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package escola; | |
import java.util.ArrayList; | |
public class Aluno extends Pessoa { | |
private int numeroMatricula; | |
private int anoInicioCurso; | |
private Bolsa bolsa; | |
private ArrayList<Disciplina> disciplinas; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package escola; | |
public class Bolsa { | |
private int numeroBolsa; | |
private float valor; | |
private Aluno aluno; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package escola; | |
import java.util.ArrayList; | |
public class Disciplina { | |
private String descricao; | |
private int ano; | |
private ArrayList<Aluno> alunos; | |
private Professor professor; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package escola; | |
public abstract class Pessoa { | |
private String nome; | |
private String endereco; | |
private String cidade; | |
private String estado; | |
private String bairro; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package escola; | |
import java.util.ArrayList; | |
public class Professor extends Pessoa { | |
private int MatriculaSiap; | |
private ArrayList<Disciplina> disciplinas; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment