Skip to content

Merging 50 commit to remote repository #4

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 66 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
66 commits
Select commit Hold shift + click to select a range
1b8e70b
A few more changes.
Ste452 Sep 8, 2023
7d13312
A more work
Ste452 Sep 9, 2023
2b2c183
Problem fixed.
Ste452 Sep 9, 2023
a237e75
A small correction.
Ste452 Sep 9, 2023
6784d5e
Others corrections.
Ste452 Sep 9, 2023
a15bc11
Exercise mod9.
Ste452 Sep 9, 2023
903661b
Some changes in the probability.java file
Ste452 Sep 9, 2023
7f458ea
Some changes
Ste452 Sep 9, 2023
13961a5
Exercise mod10
Ste452 Sep 9, 2023
790e85b
Changing the calculation of grades.
Ste452 Sep 9, 2023
e8bdde5
Modifying some errors.
Ste452 Sep 10, 2023
cee4fa8
Printing the primitive and wrapper type
Ste452 Sep 10, 2023
9f1ccd1
Writing some more.
Ste452 Sep 10, 2023
8e83671
Adding some changes.
Ste452 Sep 11, 2023
01167cb
Introducing some modifications.
Ste452 Sep 12, 2023
979ede8
A more modification!
Ste452 Sep 12, 2023
1130dc4
Some modifications
Ste452 Sep 17, 2023
4b1d841
A some modifications at the course of mod11
Ste452 Sep 18, 2023
864e697
A some works in the my course to my gitHub.
Ste452 Sep 21, 2023
bb947e3
Remove entities
Ste452 Sep 21, 2023
947dca1
A more modification
Ste452 Sep 21, 2023
d6429db
Rename Exercise_mod11
Ste452 Sep 21, 2023
cbdbb22
Rename Exercise_mod11
Ste452 Sep 21, 2023
7360eef
Update README.md
Ste452 Sep 22, 2023
6719e1d
A more exercises ¯⁠\⁠_⁠(⁠ツ⁠)⁠_⁠/⁠¯
Ste452 Sep 22, 2023
6382959
Merge branch 'main' of https://github.com/Ste452/backend-java-ebac
Ste452 Sep 22, 2023
480ec45
Finished module_13
Ste452 Sep 29, 2023
0689a17
Correcting some errors ¯⁠\⁠_⁠(⁠ツ⁠)⁠_⁠/⁠¯
Ste452 Sep 29, 2023
476cf1a
Un changement supplémentaire
Ste452 Oct 4, 2023
fb62474
Mod15 terminé
Ste452 Oct 5, 2023
2089d67
A little bit modification.
Ste452 Oct 8, 2023
1958180
Saving some changes
Ste452 Oct 13, 2023
3dd286b
Modifying once again
Ste452 Oct 13, 2023
1040e54
Modifying once again
Ste452 Oct 13, 2023
4bd6985
Again
Ste452 Oct 13, 2023
0081ea3
Again modifying the package
Ste452 Oct 13, 2023
9c5dfdd
Restoring everything.
Ste452 Oct 20, 2023
3f8fea0
A some alterations
Ste452 Oct 22, 2023
3a608d9
A more alterations
Ste452 Oct 25, 2023
c5fa237
A more one
Ste452 Oct 25, 2023
4153983
Exercise_mod19 finished
Ste452 Oct 25, 2023
de7f5db
Update README.md
Ste452 Oct 25, 2023
69999eb
Removing Readme (2).md
Ste452 Oct 25, 2023
e8cc59d
Finished
Ste452 Oct 29, 2023
a0e79b9
Mod23 terminé
Ste452 Nov 1, 2023
1ab12de
A lot modfications in Junit in mod24
Ste452 Nov 6, 2023
23c11c9
A lot modifications in junit in the mod24
Ste452 Nov 6, 2023
d71b885
A some implemetentions
Ste452 Nov 9, 2023
2ebbcb8
A lot modifications about a error in module 23
Ste452 Dec 1, 2023
129610a
A lot modifications about a error in module 23
Ste452 Dec 1, 2023
bad390b
Modifications in the files and the classes
Ste452 Dec 21, 2023
0155e5f
Modifications in the files and the classes
Ste452 Dec 21, 2023
b32f3fe
Exercise mod30 finished
Ste452 Dec 26, 2023
ea03a3c
Finished exercise mod32
Ste452 Dec 30, 2023
bd6d091
Implementing a more robust foundation for the completion of mod32
Ste452 Jan 1, 2024
e5fcdc1
Finished mod34
Ste452 Jan 7, 2024
e1e6aee
Finished mod35
Ste452 Jan 7, 2024
861ebd5
Finished mod36
Ste452 Jan 7, 2024
8808506
Finished mod37
Ste452 Jan 8, 2024
e8df91a
Finished mod 38
Ste452 Jan 16, 2024
8cc6ec1
Finished mod 39
Ste452 Jan 17, 2024
2afccc6
Resolving a problems
Ste452 Jan 17, 2024
7a979aa
Solving other problems from other classes
Ste452 Jan 17, 2024
8884a03
Finished mod40
Ste452 Jan 18, 2024
6e06f8e
Finished exercise mod33
Ste452 Jan 22, 2024
37c22e5
Finished mod 42
Ste452 Jan 24, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
81 changes: 81 additions & 0 deletions (2).gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,81 @@
# Compiled class file
*.class

# Log file
*.log

# BlueJ files
*.ctxt

# Mobile Tools for Java (J2ME)
.mtj.tmp/

# Package Files #
*.jar
*.war
*.nar
*.ear
*.zip
*.tar.gz
*.rar

# virtual machine crash logs, see http://www.java.com/en/download/help/error_hotspot.xml
hs_err_pid*

build/
target
target/*
target/**
.mvn
.mvn/*

# compiled output
/dist
/tmp
/out-tsc
# Only exists if Bazel was run
/bazel-out

# dependencies
/node_modules

# profiling files
chrome-profiler-events*.json

# IDEs and editors
/.idea
.project
.classpath
.c9/
*.launch
.settings/
*.sublime-workspace

# IDE - VSCode
.vscode/*
!.vscode/settings.json
!.vscode/tasks.json
!.vscode/launch.json
!.vscode/extensions.json
.history/*

# misc
/.sass-cache
/connect.lock
/coverage
/libpeerconnection.log
npm-debug.log
yarn-error.log
testem.log
/typings

# System Files
.DS_Store
Thumbs.db

.idea/*
.idea/**
*.iml
*/.idea

/.metadata/
28 changes: 28 additions & 0 deletions (2).hintrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
{
"extends": [
"development"
],
"hints": {
"axe/name-role-value": [
"default",
{
"button-name": "off"
}
],
"button-type": "off",
"axe/text-alternatives": [
"default",
{
"document-title": "off"
}
],
"axe/language": [
"default",
{
"html-has-lang": "off"
}
],
"meta-charset-utf-8": "off",
"meta-viewport": "off"
}
}
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
# Compiled class file
*bin
*.class

# Log file
Expand Down Expand Up @@ -78,3 +79,4 @@ Thumbs.db
*.iml
*/.idea

/.metadata/
28 changes: 28 additions & 0 deletions .hintrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
{
"extends": [
"development"
],
"hints": {
"axe/name-role-value": [
"default",
{
"button-name": "off"
}
],
"button-type": "off",
"axe/text-alternatives": [
"default",
{
"document-title": "off"
}
],
"axe/language": [
"default",
{
"html-has-lang": "off"
}
],
"meta-charset-utf-8": "off",
"meta-viewport": "off"
}
}
11 changes: 11 additions & 0 deletions .run/Template Java Scratch.run (2).xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
<component name="ProjectRunConfigurationManager">
<configuration default="true" type="Java Scratch">
<option name="ALTERNATIVE_JRE_PATH" value="17" />
<option name="ALTERNATIVE_JRE_PATH_ENABLED" value="true" />
<module name="backend-java-ebac" />
<shortenClasspath name="NONE" />
<method v="2">
<option name="Make" enabled="true" />
</method>
</configuration>
</component>
11 changes: 11 additions & 0 deletions .run/Template Java Scratch.run.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
<component name="ProjectRunConfigurationManager">
<configuration default="true" type="Java Scratch">
<option name="ALTERNATIVE_JRE_PATH" value="17" />
<option name="ALTERNATIVE_JRE_PATH_ENABLED" value="true" />
<module name="backend-java-ebac" />
<shortenClasspath name="NONE" />
<method v="2">
<option name="Make" enabled="true" />
</method>
</configuration>
</component>
3 changes: 2 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
# backend-java-ebac
Exemplos dos projetos para o curso de Backend Java da Ebac.

- Classes taught by professor Rodrigo Pires. EBAC.

9 changes: 6 additions & 3 deletions docker/postgresl/docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,19 +4,22 @@ services:
ebac-postgres-compose:
image: postgres
environment:
POSTGRES_PASSWORD: "admin"
PGADMIN_DEFAULT_EMAIL: "[email protected]"
PGADMIN_DEFAULT_PASSWORD: "admin"
PGADMIN_DEFAULT_USERNAME: "steve"
ports:
- "15432:5432"
volumes:
- /Users/rodrigo.pires/dev/docker/volumes/PostgreSQL:/var/lib/postgresql/data
- C:\Users\Micro\IdeaProjects\Java_EBAC\backend-java-ebac\docker\postgresl:/var/lib/postgresql/data2
networks:
- postgres-ebac-network

ebac-pgadmin-compose:
image: dpage/pgadmin4
environment:
PGADMIN_DEFAULT_EMAIL: "[email protected]"
PGADMIN_DEFAULT_PASSWORD: "admin"
PGADMIN_DEFAULT_USERNAME: "steve"
ports:
- "16543:80"
depends_on:
Expand Down
4 changes: 4 additions & 0 deletions mod1/TesteAPI/Untitled 1
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-web</artifactId>
</dependency>
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
package br.com.rpires.TesteAPI;

public @interface GetMapping {

String value();

}
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
package br.com.rpires.TesteAPI;

public @interface PathVariable {

}
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
package br.com.rpires.TesteAPI;

public @interface ResponseBody {

}
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
package br.com.rpires.TesteAPI;

public class ResponseEntity<T> {

public static void main(String[] args) {
// TODO Auto-generated method stub

}

public static ResponseEntity<String> ok(String string) {
// TODO Auto-generated method stub
return null;
}

}
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
package br.com.rpires.TesteAPI;

public @interface RestController {

}
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
package br.com.rpires.TesteAPI;

public @interface SpringBootApplication {

}
Original file line number Diff line number Diff line change
@@ -1,13 +1,12 @@
package br.com.rpires.TesteAPI;

import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import br.com.rpires.ebac.Springbootjsp.SpringbootJspApplication;

@SpringBootApplication
public class TesteApiApplication {

public static void main(String[] args) {
SpringApplication.run(TesteApiApplication.class, args);
SpringbootJspApplication.run(TesteApiApplication.class, args);
}

}
Original file line number Diff line number Diff line change
@@ -1,14 +1,13 @@
package br.com.rpires.TesteAPI;

import org.springframework.http.ResponseEntity;
import org.springframework.web.bind.annotation.*;

import javax.servlet.http.HttpServletResponse;
import java.io.IOException;
import java.net.http.HttpResponse;

import org.springframework.web.bind.annotation.RequestMapping;

/**
* @author rodrigo.pires
* @author Steve.Vaz
*/
@RestController
@RequestMapping(value = "/api/v1/teste")
Expand All @@ -19,13 +18,16 @@ public ResponseEntity<String> teste1() {
return ResponseEntity.ok("Teste");
}

@GetMapping(value = "/teste2")
public void teste2(HttpServletResponse response) throws IOException {
response.getWriter().write("<html>");
response.getWriter().write(" <body>");
response.getWriter().write(" <h1>Olá </h1>");
response.getWriter().write(" </body>");
response.getWriter().write("</html>");
@GetMapping(value = "/api/v1/teste/teste2")
@ResponseBody
public String teste2(HttpResponse<?> response) throws IOException {
StringBuilder html = new StringBuilder();
html.append("<html>");
html.append(" <body>");
html.append(" <h1>Olá </h1>");
html.append(" </body>");
html.append("</html>");
return html.toString();
}

@GetMapping(value = "/teste3/{nome}")
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
package br.com.rpires.TesteAPI;

public @interface SpringBootTest {

}
Original file line number Diff line number Diff line change
@@ -1,12 +1,9 @@
package br.com.rpires.TesteAPI;

import org.junit.jupiter.api.Test;
import org.springframework.boot.test.context.SpringBootTest;

@SpringBootTest
class TesteApiApplicationTests {

@Test

void contextLoads() {
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,16 +3,18 @@
import java.util.Scanner;

/**
* @author rodrigo.pires
* @author Steve.Vaz
*/
public class ExemploScanner {

public static void main(String args[]) {
Scanner s = new Scanner(System.in);
Scanner sc = new Scanner(System.in);

System.out.println("Digite sua idade: ");
int idade = s.nextInt();
int idade = sc.nextInt();
System.out.println("Vc tem " + idade + " anos.");

sc.close();
}


Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,19 +3,21 @@
import java.util.Scanner;

/**
* @author rodrigo.pires
* @author Steve.Vaz
*/
public class ExemploScanner1 {

public static void main(String args[]) {
Scanner s = new Scanner(System.in);
Scanner sc = new Scanner(System.in);

System.out.println("Digite seu nome: ");
String nome = s.nextLine();
String nome = sc.nextLine();

System.out.println("\nDigite sua altura: ");
double altura = s.nextDouble();
double altura = sc.nextDouble();

System.out.println(nome + " tem " + altura + " de altura.");

sc.close();
}
}
Loading