-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #25 from solid-titans/beta
Atualização semanal do CRUD
- Loading branch information
Showing
63 changed files
with
4,530 additions
and
2,326 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
runner = button.sh | ||
cleaner = limparAmbiente.sh | ||
safeCleaner = limparJava.sh | ||
compiler = compile.sh | ||
makeJar = makeJar.sh | ||
|
||
run: | ||
sh $(runner) | ||
|
||
clean: | ||
sh $(cleaner) | ||
|
||
safeClean: | ||
sh $(safeCleaner) | ||
|
||
compile: | ||
sh $(compiler) | ||
|
||
jar: compile | ||
sh $(makeJar) |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
cd 'src' | ||
javac -d . Main.java |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,6 @@ | ||
#!/bin/bash | ||
|
||
# Programa para limpar a área de trabalho do Crud de forma segura | ||
# Programa para limpar a área de trabalho do Crud de forma segura e seu banco de dados | ||
|
||
find . -name *.class -type f -delete | ||
rm -rf src/Dados |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
#!/bin/bash | ||
|
||
# Programa para limpar a área de trabalho do Crud de forma segura | ||
|
||
find . -name *.class -type f -delete |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
#!/bin/bash | ||
|
||
cd src/ | ||
|
||
jar cvfm Crud.jar MANIFEST.txt * |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
Manifest-Version: 1.0 | ||
Created-By: Solid Titans | ||
Main-Class: Main |
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,15 +1,78 @@ | ||
import java.io.File; | ||
|
||
import menu.Menu; | ||
import menu.*; | ||
import menu.api.*; | ||
import menu.backend.cruds.*; | ||
import menu.backend.input.*; | ||
import menu.frontend.*; | ||
import menu.frontend.graficos.*; | ||
|
||
public class Main { | ||
|
||
/** | ||
* Função maestro para orquestrar todos os objetos usados no programa | ||
* @param args | ||
*/ | ||
public static void main(String[] args) { | ||
|
||
// Verificar se o directorio de dados existe, caso nao exista crie-o | ||
File directorioDados = new File("Dados"); | ||
if(!directorioDados.exists()) directorioDados.mkdir(); | ||
if (!directorioDados.exists()) | ||
directorioDados.mkdir(); | ||
|
||
// Comum a todos | ||
Input input = new Input(); | ||
|
||
//Destaques | ||
ANSILibrary destaqueTam = new ANSILibrary(15, 124, ANSILibrary.TEXTO_SUBLINHADO); | ||
ANSILibrary destaqueTitulo = new ANSILibrary(15, 9, ANSILibrary.TEXTO_SUBLINHADO); | ||
ANSILibrary destaqueObs = new ANSILibrary(15, 234, ANSILibrary.TEXTO_SUBLINHADO); | ||
ANSILibrary destaqueData = new ANSILibrary(15, 232, ANSILibrary.TEXTO_SUBLINHADO); | ||
|
||
//Interfaces ASCII | ||
ASCIInterface usuariosGraficos = new ASCIInterface(92, 226, 93, 232); | ||
ASCIInterface perguntasGraficos = new ASCIInterface(21, 111, 232, 15); | ||
ASCIInterface respostasGraficos = new ASCIInterface(40, 121, 232, 15); | ||
|
||
//CustomPrints | ||
CustomPrint usuariosPrint = new CustomPrint(usuariosGraficos,destaqueTitulo,destaqueObs); | ||
CustomPrint perguntasPrint = new CustomPrint(perguntasGraficos,destaqueTitulo,destaqueObs); | ||
CustomPrint respostasPrint = new CustomPrint(respostasGraficos,destaqueTitulo,destaqueObs); | ||
|
||
CustomPrint usuariosInputPrint = new CustomPrint(usuariosGraficos,destaqueTitulo,destaqueTam); | ||
CustomPrint perguntasInputPrint = new CustomPrint(perguntasGraficos,destaqueTitulo,destaqueTam); | ||
CustomPrint respostasInputPrint = new CustomPrint(respostasGraficos,destaqueTitulo,destaqueTam); | ||
|
||
// Definicoes | ||
CustomInput usuariosCustomInput = new CustomInput(usuariosInputPrint); | ||
CustomInput perguntasCustomInput = new CustomInput(perguntasInputPrint); | ||
CustomInput respostasCustomInput = new CustomInput(respostasInputPrint); | ||
|
||
// Interface | ||
UsuariosFrontEnd usuariosFrontEnd = new UsuariosFrontEnd(usuariosPrint, usuariosCustomInput); | ||
PerguntasFrontEnd perguntasFrontEnd = new PerguntasFrontEnd(perguntasPrint, input); | ||
RespostasFrontEnd respostasFrontEnd = new RespostasFrontEnd(respostasPrint, input); | ||
|
||
// APIS | ||
UsuariosAPI usuariosAPI = new UsuariosAPI(usuariosFrontEnd, usuariosCustomInput); | ||
PerguntasAPI perguntasAPI = new PerguntasAPI(perguntasFrontEnd, perguntasCustomInput); | ||
RespostasAPI respostasAPI = new RespostasAPI(respostasFrontEnd, respostasCustomInput); | ||
|
||
// Cruds | ||
UsuariosCRUD usuariosCRUD = new UsuariosCRUD(); | ||
PerguntasCRUD perguntasCRUD = new PerguntasCRUD("Dados"); | ||
RespostasCRUD respostasCRUD = new RespostasCRUD("Dados"); | ||
|
||
// Menu | ||
ASCIInterface graficos = new ASCIInterface(27,255 , 232, 232); | ||
CustomPrint myPrint = new CustomPrint(graficos,destaqueData,destaqueObs); | ||
|
||
Selecao selecao = new Selecao(myPrint, input); | ||
APIControle minhaAPI = new APIControle(usuariosAPI, perguntasAPI, respostasAPI, usuariosCRUD, perguntasCRUD, | ||
respostasCRUD); | ||
|
||
Menu m = new Menu(); | ||
m.Inicio(); | ||
//Iniciar ao menu | ||
Menu m = new Menu(myPrint, minhaAPI, selecao); | ||
m.Inicio(); //Começar efetivamente o programa | ||
} | ||
|
||
} |
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
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
Oops, something went wrong.