Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 11 additions & 0 deletions .project
Original file line number Diff line number Diff line change
Expand Up @@ -14,4 +14,15 @@
<natures>
<nature>org.eclipse.jdt.core.javanature</nature>
</natures>
<filteredResources>
<filter>
<id>1669251721908</id>
<name></name>
<type>30</type>
<matcher>
<id>org.eclipse.core.resources.regexFilterMatcher</id>
<arguments>node_modules|\.git|__CREATED_BY_JAVA_LANGUAGE_SERVER__</arguments>
</matcher>
</filter>
</filteredResources>
</projectDescription>
Binary file added bin/module-info.class
Binary file not shown.
Binary file added bin/primeiroRefactoring/Endereco.class
Binary file not shown.
Binary file added bin/primeiroRefactoring/Pessoa.class
Binary file not shown.
Binary file added bin/segundoRefactoring/Quicksort.class
Binary file not shown.
Binary file added bin/terceiroRefactoring/Discente.class
Binary file not shown.
Binary file added bin/terceiroRefactoring/Docente.class
Binary file not shown.
Binary file added bin/terceiroRefactoring/Pessoa.class
Binary file not shown.
37 changes: 37 additions & 0 deletions src/primeiroRefactoring/Endereco.java
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
package primeiroRefactoring;

public class Endereco {
private String logradouro;
private String complemento;
private String cep;

public Endereco(String logradouro, String complemento, String cep) {
this.logradouro = logradouro;
this.complemento = complemento;
this.cep = cep;
}

public String getLogradouro() {
return logradouro;
}

public void setLogradouro(String logradouro) {
this.logradouro = logradouro;
}

public String getComplemento() {
return complemento;
}

public void setComplemento(String complemento) {
this.complemento = complemento;
}

public String getCep() {
return cep;
}

public void setCep(String cep) {
this.cep = cep;
}
}
26 changes: 22 additions & 4 deletions src/segundoRefactoring/Quicksort.java
Original file line number Diff line number Diff line change
Expand Up @@ -8,13 +8,31 @@ public static void main(String[] args) throws IOException {
int quantidade = 10000;
int[] vetor = new int[quantidade];

System.out.println("Vetor desordenado: ");
vetor = preencherTextoVetorAleatorio(vetor);

textVetor(vetor, "Vetor desordenado: ");
quickSort(vetor, 0, vetor.length - 1);
textVetor(vetor, "Vetor ordenado: ");

}

private static int[] preencherTextoVetorAleatorio(int[] vetor) {
return null;
}

private static void textVetor(int[] vetor, String string) {
}

private static int[] preencherTextoVetorAleatorio(int[] vetorvetor, int[] vetor, double quantidade) {
for (int i = 0; i < vetor.length; i++) {
vetor[i] = (int) (Math.random() * quantidade);
System.out.print(i + " ");
}
quickSort(vetor, 0, vetor.length - 1);
System.out.println("\nVetor ordenado: ");

return vetor;
}

private static void printVetor(vetor, texto) {
System.out.print(texto);
for (int i : vetor) {
System.out.print(i + " ");
}
Expand Down
29 changes: 21 additions & 8 deletions src/terceiroRefactoring/Discente.java
Original file line number Diff line number Diff line change
Expand Up @@ -7,14 +7,18 @@ public class Discente {
private String[] disciplinasCursadas;
private Date dataIngresso;
private int numeroPeriodosCursados;
private String emailPessoal;

public Discente(String[] disciplinasCursadas, Date dataIngresso, int numeroPeriodosCursados, String emailPessoal) {
private String matricula;
private double coeficienteRendimento;

public Discente(String[] disciplinasCursadas, Date dataIngresso, int numeroPeriodosCursados, String matricula,
double coeficienteRendimento) {
super();
this.disciplinasCursadas = disciplinasCursadas;
this.dataIngresso = dataIngresso;
this.numeroPeriodosCursados = numeroPeriodosCursados;
this.emailPessoal = emailPessoal;
this.matricula = matricula;
this.coeficienteRendimento = coeficienteRendimento;

}

public String[] getDisciplinasCursadas() {
Expand All @@ -41,11 +45,20 @@ public void setNumeroPeriodosCursados(int numeroPeriodosCursados) {
this.numeroPeriodosCursados = numeroPeriodosCursados;
}

public String getEmailPessoal() {
return emailPessoal;
public String getMatricula() {
return matricula;
}

public void setMatricula(String matricula) {
this.matricula = matricula;
}

public void setEmailPessoal(String emailPessoal) {
this.emailPessoal = emailPessoal;
public double getCoeficienteRendimento() {
return coeficienteRendimento;
}

public void setCoeficienteRendimento(double coeficienteRendimento) {
this.coeficienteRendimento = coeficienteRendimento;
}

}
15 changes: 13 additions & 2 deletions src/terceiroRefactoring/Docente.java
Original file line number Diff line number Diff line change
Expand Up @@ -8,13 +8,16 @@ public class Docente {
private Date dataAdmissao;
private String emailInstitucional;
private double remuneracao;

public Docente(String[] disciplinasMinistradas, Date dataAdmissao, String emailInstitucional, double remuneracao) {
private String siape;

public Docente(String[] disciplinasMinistradas, Date dataAdmissao, String emailInstitucional, double remuneracao,
String siape) {
super();
this.disciplinasMinistradas = disciplinasMinistradas;
this.dataAdmissao = dataAdmissao;
this.emailInstitucional = emailInstitucional;
this.remuneracao = remuneracao;
this.siape = siape;
}

public String[] getDisciplinasMinistradas() {
Expand Down Expand Up @@ -48,4 +51,12 @@ public double getRemuneracao() {
public void setRemuneracao(double remuneracao) {
this.remuneracao = remuneracao;
}

public String getSiape() {
return siape;
}

public void setSiape(String siape) {
this.siape = siape;
}
}
37 changes: 9 additions & 28 deletions src/terceiroRefactoring/Pessoa.java
Original file line number Diff line number Diff line change
Expand Up @@ -10,22 +10,19 @@ public class Pessoa {
private Date dataNascimento;
private String nomePai;
private String nomeMae;
private String siape;
private String matricula;
private double coeficienteRendimento;

private String emailPessoal;

public Pessoa(String nomeCompleto, String cpf, String registroGeral, Date dataNascimento, String nomePai,
String nomeMae, String siape, String matricula, double coeficienteRendimento) {
String nomeMae, String emailPessoal) {
super();
this.nomeCompleto = nomeCompleto;
this.cpf = cpf;
this.registroGeral = registroGeral;
this.dataNascimento = dataNascimento;
this.nomePai = nomePai;
this.nomeMae = nomeMae;
this.siape = siape;
this.matricula = matricula;
this.coeficienteRendimento = coeficienteRendimento;
this.emailPessoal = emailPessoal;

}

public String getNomeCompleto() {
Expand Down Expand Up @@ -76,27 +73,11 @@ public void setNomeMae(String nomeMae) {
this.nomeMae = nomeMae;
}

public String getSiape() {
return siape;
}

public void setSiape(String siape) {
this.siape = siape;
}

public String getMatricula() {
return matricula;
}

public void setMatricula(String matricula) {
this.matricula = matricula;
}

public double getCoeficienteRendimento() {
return coeficienteRendimento;
public String getEmailPessoal() {
return emailPessoal;
}

public void setCoeficienteRendimento(double coeficienteRendimento) {
this.coeficienteRendimento = coeficienteRendimento;
public void setEmailPessoal(String emailPessoal) {
this.emailPessoal = emailPessoal;
}
}