From 2653aa8736683c7d4632c551e84801eb602c4179 Mon Sep 17 00:00:00 2001 From: Kevin Gilmore Date: Sat, 1 Dec 2018 07:06:17 -0600 Subject: [PATCH 01/24] BAEL-2246: add link back to article --- java-strings/README.md | 1 + 1 file changed, 1 insertion(+) diff --git a/java-strings/README.md b/java-strings/README.md index 222b28e8ad20..11893e68a296 100644 --- a/java-strings/README.md +++ b/java-strings/README.md @@ -38,3 +38,4 @@ - [Java Base64 Encoding and Decoding](https://www.baeldung.com/java-base64-encode-and-decode) - [Generate a Secure Random Password in Java](https://www.baeldung.com/java-generate-secure-password) - [Removing Repeated Characters from a String](https://www.baeldung.com/java-remove-repeated-char) +- [Join Array of Primitives with Separator in Java](https://www.baeldung.com/java-join-primitive-array) From 75cf9c0bc41084b59675bba167589d1557441546 Mon Sep 17 00:00:00 2001 From: Kevin Gilmore Date: Mon, 3 Dec 2018 21:58:23 -0600 Subject: [PATCH 02/24] BAEL-2174: rename core-java-net module to core-java-networking --- {core-java-net => core-java-networking}/.gitignore | 0 {core-java-net => core-java-networking}/README.md | 0 {core-java-net => core-java-networking}/pom.xml | 6 +++--- .../baeldung/networking/proxies/CommandLineProxyDemo.java | 0 .../com/baeldung/networking/proxies/DirectProxyDemo.java | 0 .../com/baeldung/networking/proxies/SocksProxyDemo.java | 0 .../networking/proxies/SystemPropertyProxyDemo.java | 0 .../com/baeldung/networking/proxies/UrlConnectionUtils.java | 0 .../java/com/baeldung/networking/proxies/WebProxyDemo.java | 0 .../src/test/resources/.gitignore | 0 pom.xml | 4 ++-- 11 files changed, 5 insertions(+), 5 deletions(-) rename {core-java-net => core-java-networking}/.gitignore (100%) rename {core-java-net => core-java-networking}/README.md (100%) rename {core-java-net => core-java-networking}/pom.xml (80%) rename {core-java-net => core-java-networking}/src/main/java/com/baeldung/networking/proxies/CommandLineProxyDemo.java (100%) rename {core-java-net => core-java-networking}/src/main/java/com/baeldung/networking/proxies/DirectProxyDemo.java (100%) rename {core-java-net => core-java-networking}/src/main/java/com/baeldung/networking/proxies/SocksProxyDemo.java (100%) rename {core-java-net => core-java-networking}/src/main/java/com/baeldung/networking/proxies/SystemPropertyProxyDemo.java (100%) rename {core-java-net => core-java-networking}/src/main/java/com/baeldung/networking/proxies/UrlConnectionUtils.java (100%) rename {core-java-net => core-java-networking}/src/main/java/com/baeldung/networking/proxies/WebProxyDemo.java (100%) rename {core-java-net => core-java-networking}/src/test/resources/.gitignore (100%) diff --git a/core-java-net/.gitignore b/core-java-networking/.gitignore similarity index 100% rename from core-java-net/.gitignore rename to core-java-networking/.gitignore diff --git a/core-java-net/README.md b/core-java-networking/README.md similarity index 100% rename from core-java-net/README.md rename to core-java-networking/README.md diff --git a/core-java-net/pom.xml b/core-java-networking/pom.xml similarity index 80% rename from core-java-net/pom.xml rename to core-java-networking/pom.xml index 28d5766a9a1b..178295e1ecde 100644 --- a/core-java-net/pom.xml +++ b/core-java-networking/pom.xml @@ -1,10 +1,10 @@ 4.0.0 - core-java-net + core-java-networking 0.1.0-SNAPSHOT jar - core-java-net + core-java-networking com.baeldung @@ -14,6 +14,6 @@ - core-java-net + core-java-networking diff --git a/core-java-net/src/main/java/com/baeldung/networking/proxies/CommandLineProxyDemo.java b/core-java-networking/src/main/java/com/baeldung/networking/proxies/CommandLineProxyDemo.java similarity index 100% rename from core-java-net/src/main/java/com/baeldung/networking/proxies/CommandLineProxyDemo.java rename to core-java-networking/src/main/java/com/baeldung/networking/proxies/CommandLineProxyDemo.java diff --git a/core-java-net/src/main/java/com/baeldung/networking/proxies/DirectProxyDemo.java b/core-java-networking/src/main/java/com/baeldung/networking/proxies/DirectProxyDemo.java similarity index 100% rename from core-java-net/src/main/java/com/baeldung/networking/proxies/DirectProxyDemo.java rename to core-java-networking/src/main/java/com/baeldung/networking/proxies/DirectProxyDemo.java diff --git a/core-java-net/src/main/java/com/baeldung/networking/proxies/SocksProxyDemo.java b/core-java-networking/src/main/java/com/baeldung/networking/proxies/SocksProxyDemo.java similarity index 100% rename from core-java-net/src/main/java/com/baeldung/networking/proxies/SocksProxyDemo.java rename to core-java-networking/src/main/java/com/baeldung/networking/proxies/SocksProxyDemo.java diff --git a/core-java-net/src/main/java/com/baeldung/networking/proxies/SystemPropertyProxyDemo.java b/core-java-networking/src/main/java/com/baeldung/networking/proxies/SystemPropertyProxyDemo.java similarity index 100% rename from core-java-net/src/main/java/com/baeldung/networking/proxies/SystemPropertyProxyDemo.java rename to core-java-networking/src/main/java/com/baeldung/networking/proxies/SystemPropertyProxyDemo.java diff --git a/core-java-net/src/main/java/com/baeldung/networking/proxies/UrlConnectionUtils.java b/core-java-networking/src/main/java/com/baeldung/networking/proxies/UrlConnectionUtils.java similarity index 100% rename from core-java-net/src/main/java/com/baeldung/networking/proxies/UrlConnectionUtils.java rename to core-java-networking/src/main/java/com/baeldung/networking/proxies/UrlConnectionUtils.java diff --git a/core-java-net/src/main/java/com/baeldung/networking/proxies/WebProxyDemo.java b/core-java-networking/src/main/java/com/baeldung/networking/proxies/WebProxyDemo.java similarity index 100% rename from core-java-net/src/main/java/com/baeldung/networking/proxies/WebProxyDemo.java rename to core-java-networking/src/main/java/com/baeldung/networking/proxies/WebProxyDemo.java diff --git a/core-java-net/src/test/resources/.gitignore b/core-java-networking/src/test/resources/.gitignore similarity index 100% rename from core-java-net/src/test/resources/.gitignore rename to core-java-networking/src/test/resources/.gitignore diff --git a/pom.xml b/pom.xml index dabb4a9628bf..b92471d0fe0d 100644 --- a/pom.xml +++ b/pom.xml @@ -366,7 +366,7 @@ core-java - core-java-net + core-java-networking dozer disruptor @@ -920,7 +920,7 @@ core-java - core-java-net + core-java-networking dozer disruptor From aadecf2f666d728bed6d0b2c1f13dcd39046efbf Mon Sep 17 00:00:00 2001 From: Kevin Gilmore Date: Tue, 11 Dec 2018 18:14:45 -0600 Subject: [PATCH 03/24] BAEL-2174: add link back to article --- core-java-networking/README.md | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/core-java-networking/README.md b/core-java-networking/README.md index b7a142ea273c..626ea794e65f 100644 --- a/core-java-networking/README.md +++ b/core-java-networking/README.md @@ -1,3 +1,7 @@ ========= -## Core Java Net +## Core Java Networking + +### Relevant Articles + +- [Connecting Through Proxy Servers in Core Java](https://www.baeldung.com/java-connect-via-proxy-server) From 6b8f5ab3195c3699144302129865a3a67b43d595 Mon Sep 17 00:00:00 2001 From: Kevin Gilmore Date: Sat, 22 Dec 2018 10:58:27 -0600 Subject: [PATCH 04/24] BAEL-2363 BAEL-2337 BAEL-1996 BAEL-2277 add links back to articles --- algorithms-miscellaneous-1/README.md | 4 +++- jhipster/README.md | 1 + spring-5-reactive/README.md | 2 +- 3 files changed, 5 insertions(+), 2 deletions(-) diff --git a/algorithms-miscellaneous-1/README.md b/algorithms-miscellaneous-1/README.md index a04874c4d2b0..a725bbd14165 100644 --- a/algorithms-miscellaneous-1/README.md +++ b/algorithms-miscellaneous-1/README.md @@ -10,4 +10,6 @@ - [Multi-Swarm Optimization Algorithm in Java](http://www.baeldung.com/java-multi-swarm-algorithm) - [String Search Algorithms for Large Texts](http://www.baeldung.com/java-full-text-search-algorithms) - [Check If a String Contains All The Letters of The Alphabet](https://www.baeldung.com/java-string-contains-all-letters) -- [Find the Middle Element of a Linked List](http://www.baeldung.com/java-linked-list-middle-element) \ No newline at end of file +- [Find the Middle Element of a Linked List](http://www.baeldung.com/java-linked-list-middle-element) +- [Calculate Factorial in Java](https://www.baeldung.com/java-calculate-factorial) +- [Find Substrings That Are Palindromes in Java](https://www.baeldung.com/java-palindrome-substrings) \ No newline at end of file diff --git a/jhipster/README.md b/jhipster/README.md index f3655f8ec13a..91ba54bf6089 100644 --- a/jhipster/README.md +++ b/jhipster/README.md @@ -2,3 +2,4 @@ - [JHipster with a Microservice Architecture](http://www.baeldung.com/jhipster-microservices) - [Intro to JHipster](http://www.baeldung.com/jhipster) +- [Building a Basic UAA-Secured JHipster Microservice](https://www.baeldung.com/jhipster-uaa-secured-micro-service) diff --git a/spring-5-reactive/README.md b/spring-5-reactive/README.md index fc898a56dcff..2a4ee017f49c 100644 --- a/spring-5-reactive/README.md +++ b/spring-5-reactive/README.md @@ -17,4 +17,4 @@ The "REST With Spring" Classes: http://bit.ly/restwithspring - [A Guide to Spring Session Reactive Support: WebSession](https://www.baeldung.com/spring-session-reactive) - [Validation for Functional Endpoints in Spring 5](https://www.baeldung.com/spring-functional-endpoints-validation) - [Logging a Reactive Sequence](https://www.baeldung.com/spring-reactive-sequence-logging) - +- [Testing Reactive Streams Using StepVerifier and TestPublisher](https://www.baeldung.com/reactive-streams-step-verifier-test-publisher) From ee394b6068b26c4a2d90df44dfe71677f61599cc Mon Sep 17 00:00:00 2001 From: Kevin Gilmore Date: Thu, 27 Dec 2018 23:51:18 -0600 Subject: [PATCH 05/24] BAEL-2367: add link back to article --- java-strings/README.md | 1 + 1 file changed, 1 insertion(+) diff --git a/java-strings/README.md b/java-strings/README.md index cbc32d001501..4d735490ce7c 100644 --- a/java-strings/README.md +++ b/java-strings/README.md @@ -43,3 +43,4 @@ - [Pad a String with Zeros or Spaces in Java](https://www.baeldung.com/java-pad-string) - [Adding a Newline Character to a String in Java](https://www.baeldung.com/java-string-newline) - [Remove or Replace part of a String in Java](https://www.baeldung.com/java-remove-replace-string-part) +- [Replace a Character at a Specific Index in a String in Java](https://www.baeldung.com/java-replace-character-at-index) From bc2d6b5ba0cd96a516729bfd84e3576927f17e5b Mon Sep 17 00:00:00 2001 From: Kevin Gilmore Date: Wed, 16 Jan 2019 07:06:30 -0600 Subject: [PATCH 06/24] BAEL-2335: add link back to article --- core-java-collections-list/README.md | 1 + 1 file changed, 1 insertion(+) diff --git a/core-java-collections-list/README.md b/core-java-collections-list/README.md index a35e714006ab..d1112047ba83 100644 --- a/core-java-collections-list/README.md +++ b/core-java-collections-list/README.md @@ -26,3 +26,4 @@ - [ClassCastException: Arrays$ArrayList cannot be cast to ArrayList](https://www.baeldung.com/java-classcastexception-arrays-arraylist) - [Flattening Nested Collections in Java](http://www.baeldung.com/java-flatten-nested-collections) - [Intersection of Two Lists in Java](https://www.baeldung.com/java-lists-intersection) +- [Multi Dimensional ArrayList in Java](https://www.baeldung.com/java-multi-dimensional-arraylist) From 00e435c2e7a57079c38b71bbe643aedb83dbc928 Mon Sep 17 00:00:00 2001 From: Kevin Gilmore Date: Wed, 16 Jan 2019 07:09:18 -0600 Subject: [PATCH 07/24] BAEL-2413: add link back to article --- persistence-modules/spring-boot-persistence/README.MD | 1 + 1 file changed, 1 insertion(+) diff --git a/persistence-modules/spring-boot-persistence/README.MD b/persistence-modules/spring-boot-persistence/README.MD index 8988fb4ebdde..a883b2d21cec 100644 --- a/persistence-modules/spring-boot-persistence/README.MD +++ b/persistence-modules/spring-boot-persistence/README.MD @@ -5,3 +5,4 @@ - [Quick Guide on data.sql and schema.sql Files in Spring Boot](http://www.baeldung.com/spring-boot-data-sql-and-schema-sql) - [Configuring a Tomcat Connection Pool in Spring Boot](https://www.baeldung.com/spring-boot-tomcat-connection-pool) - [Hibernate Field Naming with Spring Boot](https://www.baeldung.com/hibernate-field-naming-spring-boot) +- [Integrating Spring Boot with HSQLDB](https://www.baeldung.com/spring-boot-hsqldb) From a965f3b1fff00b3cd22c64975375968d6ae0dd00 Mon Sep 17 00:00:00 2001 From: Loredana Crusoveanu Date: Thu, 17 Jan 2019 23:25:07 +0200 Subject: [PATCH 08/24] Update README.MD --- persistence-modules/spring-boot-persistence/README.MD | 1 + 1 file changed, 1 insertion(+) diff --git a/persistence-modules/spring-boot-persistence/README.MD b/persistence-modules/spring-boot-persistence/README.MD index a883b2d21cec..cab6be1ec832 100644 --- a/persistence-modules/spring-boot-persistence/README.MD +++ b/persistence-modules/spring-boot-persistence/README.MD @@ -6,3 +6,4 @@ - [Configuring a Tomcat Connection Pool in Spring Boot](https://www.baeldung.com/spring-boot-tomcat-connection-pool) - [Hibernate Field Naming with Spring Boot](https://www.baeldung.com/hibernate-field-naming-spring-boot) - [Integrating Spring Boot with HSQLDB](https://www.baeldung.com/spring-boot-hsqldb) + From 4472998d2f3b1db8ee35c61a7d3712482b5f3b73 Mon Sep 17 00:00:00 2001 From: Kevin Gilmore Date: Wed, 6 Feb 2019 19:27:03 -0600 Subject: [PATCH 09/24] BAEL-2577: add link back to article --- spring-boot/README.MD | 1 + 1 file changed, 1 insertion(+) diff --git a/spring-boot/README.MD b/spring-boot/README.MD index 2a6a935cc11d..28123687fd34 100644 --- a/spring-boot/README.MD +++ b/spring-boot/README.MD @@ -35,3 +35,4 @@ The "REST With Spring" Classes: http://bit.ly/restwithspring - [Load Spring Boot Properties From a JSON File](https://www.baeldung.com/spring-boot-json-properties) - [Display Auto-Configuration Report in Spring Boot](https://www.baeldung.com/spring-boot-auto-configuration-report) - [Injecting Git Information Into Spring](https://www.baeldung.com/spring-git-information) +- [Validation in Spring Boot](https://www.baeldung.com/spring-boot-bean-validation) From 4ced174460a36d6b07f3385f9c707a4004d96549 Mon Sep 17 00:00:00 2001 From: Kevin Gilmore Date: Sun, 3 Mar 2019 08:45:07 -0600 Subject: [PATCH 10/24] BAEL-2490: add link back to article --- testing-modules/spring-testing/README.md | 1 + 1 file changed, 1 insertion(+) diff --git a/testing-modules/spring-testing/README.md b/testing-modules/spring-testing/README.md index 02ab7b24bd82..8eb282643a5a 100644 --- a/testing-modules/spring-testing/README.md +++ b/testing-modules/spring-testing/README.md @@ -3,3 +3,4 @@ - [Mockito.mock() vs @Mock vs @MockBean](http://www.baeldung.com/java-spring-mockito-mock-mockbean) - [A Quick Guide to @TestPropertySource](https://www.baeldung.com/spring-test-property-source) - [Guide to ReflectionTestUtils for Unit Testing](https://www.baeldung.com/spring-reflection-test-utils) +- [How to Test the @Scheduled Annotation](https://www.baeldung.com/spring-testing-scheduled-annotation) From ce4def8a4d08ef9706085ed293e5dfc9cfbde8f4 Mon Sep 17 00:00:00 2001 From: Kevin Gilmore Date: Sun, 3 Mar 2019 08:47:09 -0600 Subject: [PATCH 11/24] BAEL-2471: add link back to article --- java-collections-maps/README.md | 1 + 1 file changed, 1 insertion(+) diff --git a/java-collections-maps/README.md b/java-collections-maps/README.md index 5d65e961de06..2eeb2c884319 100644 --- a/java-collections-maps/README.md +++ b/java-collections-maps/README.md @@ -20,3 +20,4 @@ - [Comparing Two HashMaps in Java](https://www.baeldung.com/java-compare-hashmaps) - [Immutable Map Implementations in Java](https://www.baeldung.com/java-immutable-maps) - [Map to String Conversion in Java](https://www.baeldung.com/java-map-to-string-conversion) +- [Guide to Apache Commons MultiValuedMap](https://www.baeldung.com/apache-commons-multi-valued-map) From 130c6e5db5e06459d133420ae33abce051d18bfd Mon Sep 17 00:00:00 2001 From: Kevin Gilmore Date: Sun, 3 Mar 2019 08:48:58 -0600 Subject: [PATCH 12/24] BAEL-2583: add link back to article --- testing-modules/junit-5/README.md | 1 + 1 file changed, 1 insertion(+) diff --git a/testing-modules/junit-5/README.md b/testing-modules/junit-5/README.md index 4ed01e7fa9a3..d46f8bf1cfff 100644 --- a/testing-modules/junit-5/README.md +++ b/testing-modules/junit-5/README.md @@ -17,3 +17,4 @@ - [Testing an Abstract Class With JUnit](https://www.baeldung.com/junit-test-abstract-class) - [A Quick JUnit vs TestNG Comparison](http://www.baeldung.com/junit-vs-testng) - [Guide to JUnit 5 Parameterized Tests](https://www.baeldung.com/parameterized-tests-junit-5) +- [JUnit 5 Conditional Test Execution with Annotations](https://www.baeldung.com/junit-5-conditional-test-execution) From cccf505bded609c3a2107da7374edc767679f836 Mon Sep 17 00:00:00 2001 From: Kevin Gilmore Date: Sun, 3 Mar 2019 08:50:36 -0600 Subject: [PATCH 13/24] BAEL-2738: add link back to article --- gson/README.md | 1 + 1 file changed, 1 insertion(+) diff --git a/gson/README.md b/gson/README.md index 4edd7158d4ff..02b06eac20d4 100644 --- a/gson/README.md +++ b/gson/README.md @@ -10,3 +10,4 @@ - [Save Data to a JSON File with Gson](https://www.baeldung.com/gson-save-file) - [Convert JSON to a Map Using Gson](https://www.baeldung.com/gson-json-to-map) - [Working with Primitive Values in Gson](https://www.baeldung.com/java-gson-primitives) +- [Convert String to JsonObject with Gson](https://www.baeldung.com/gson-string-to-jsonobject) From 8fac5632dce9dc481315961f7c5e28c62a6a0963 Mon Sep 17 00:00:00 2001 From: Kevin Gilmore Date: Sat, 9 Mar 2019 07:54:39 -0600 Subject: [PATCH 14/24] BAEL-2711: Add spring-boot-angular module to root pom --- pom.xml | 2 ++ 1 file changed, 2 insertions(+) diff --git a/pom.xml b/pom.xml index d26b96ea8ea0..84a7c5e2ffa3 100644 --- a/pom.xml +++ b/pom.xml @@ -587,6 +587,7 @@ spring-boot spring-boot-admin + spring-boot-angular spring-boot-angular-ecommerce spring-boot-autoconfiguration spring-boot-bootstrap @@ -1218,6 +1219,7 @@ spring-boot spring-boot-admin + spring-boot-angular spring-boot-angular-ecommerce spring-boot-autoconfiguration spring-boot-bootstrap From 18cd44eb1a986b1b4bee42fd4bca99d676df82b8 Mon Sep 17 00:00:00 2001 From: Kevin Gilmore Date: Sat, 16 Mar 2019 11:51:27 -0500 Subject: [PATCH 15/24] BAEL-2544 BAEL-2711 BAEL-2575 BAEL-2657 Add links back to articles --- core-kotlin-2/README.md | 2 ++ java-streams-2/README.md | 3 +++ persistence-modules/spring-boot-persistence/README.MD | 1 + spring-boot-angular/README.md | 3 +++ 4 files changed, 9 insertions(+) create mode 100644 java-streams-2/README.md create mode 100644 spring-boot-angular/README.md diff --git a/core-kotlin-2/README.md b/core-kotlin-2/README.md index 8d22c4f1a85f..da2f7548d911 100644 --- a/core-kotlin-2/README.md +++ b/core-kotlin-2/README.md @@ -2,3 +2,5 @@ - [Void Type in Kotlin](https://www.baeldung.com/kotlin-void-type) - [How to use Kotlin Range Expressions](https://www.baeldung.com/kotlin-ranges) +- [Split a List into Parts in Kotlin](https://www.baeldung.com/kotlin-split-list-into-parts) + diff --git a/java-streams-2/README.md b/java-streams-2/README.md new file mode 100644 index 000000000000..83ef97686faf --- /dev/null +++ b/java-streams-2/README.md @@ -0,0 +1,3 @@ +### Relevant Articles: +- [Guide to Stream.reduce()](https://www.baeldung.com/java-stream-reduce) + diff --git a/persistence-modules/spring-boot-persistence/README.MD b/persistence-modules/spring-boot-persistence/README.MD index f62ca57a1923..ee7c2e298ee0 100644 --- a/persistence-modules/spring-boot-persistence/README.MD +++ b/persistence-modules/spring-boot-persistence/README.MD @@ -7,3 +7,4 @@ - [Hibernate Field Naming with Spring Boot](https://www.baeldung.com/hibernate-field-naming-spring-boot) - [Integrating Spring Boot with HSQLDB](https://www.baeldung.com/spring-boot-hsqldb) - [Configuring a DataSource Programmatically in Spring Boot](https://www.baeldung.com/spring-boot-configure-data-source-programmatic) +- [Resolving “Failed to Configure a DataSource” Error](https://www.baeldung.com/spring-boot-failed-to-configure-data-source) diff --git a/spring-boot-angular/README.md b/spring-boot-angular/README.md new file mode 100644 index 000000000000..cfc1ea69f4a8 --- /dev/null +++ b/spring-boot-angular/README.md @@ -0,0 +1,3 @@ +### Relevant Articles: +- [Building a Web Application with Spring Boot and Angular](https://www.baeldung.com/spring-boot-angular-web) + From 9e0ec74a15a36de18ec6c00a49660e629f91a223 Mon Sep 17 00:00:00 2001 From: Kevin Gilmore Date: Tue, 2 Apr 2019 22:14:27 -0500 Subject: [PATCH 16/24] BAEL-2736: Add link back to article --- testing-modules/rest-assured/README.md | 1 + 1 file changed, 1 insertion(+) diff --git a/testing-modules/rest-assured/README.md b/testing-modules/rest-assured/README.md index 50f36f61eb49..de15515f9db1 100644 --- a/testing-modules/rest-assured/README.md +++ b/testing-modules/rest-assured/README.md @@ -1,2 +1,3 @@ ###Relevant Articles: - [A Guide to REST-assured](http://www.baeldung.com/rest-assured-tutorial) +- [REST-assured Support for Spring MockMvc](https://www.baeldung.com/spring-mock-mvc-rest-assured) From 036432cb086c87762fd219f81b64977efdba6f46 Mon Sep 17 00:00:00 2001 From: Kevin Gilmore Date: Sat, 6 Apr 2019 20:20:56 -0500 Subject: [PATCH 17/24] BAEL-2789: Add link back to article --- patterns/README.md | 1 + 1 file changed, 1 insertion(+) diff --git a/patterns/README.md b/patterns/README.md index 1c9a59ea2141..b3ece5e52b02 100644 --- a/patterns/README.md +++ b/patterns/README.md @@ -2,3 +2,4 @@ - [A Guide to the Front Controller Pattern in Java](http://www.baeldung.com/java-front-controller-pattern) - [Introduction to Intercepting Filter Pattern in Java](http://www.baeldung.com/intercepting-filter-pattern-in-java) - [Introduction to the Null Object Pattern](https://www.baeldung.com/java-null-object-pattern) +- [The Dependency Inversion Principle in Java](https://www.baeldung.com/java-dependency-inversion-principle) From e1ab8e36c31aab686294a9a087baf86dd379a111 Mon Sep 17 00:00:00 2001 From: Kevin Gilmore Date: Sat, 13 Apr 2019 09:37:06 -0500 Subject: [PATCH 18/24] BAEL-2489: add link back to article --- patterns/README.md | 1 + 1 file changed, 1 insertion(+) diff --git a/patterns/README.md b/patterns/README.md index b3ece5e52b02..f627251aa403 100644 --- a/patterns/README.md +++ b/patterns/README.md @@ -3,3 +3,4 @@ - [Introduction to Intercepting Filter Pattern in Java](http://www.baeldung.com/intercepting-filter-pattern-in-java) - [Introduction to the Null Object Pattern](https://www.baeldung.com/java-null-object-pattern) - [The Dependency Inversion Principle in Java](https://www.baeldung.com/java-dependency-inversion-principle) +- [Avoid Check for Null Statement in Java](https://www.baeldung.com/java-avoid-null-check) From 2490b3d3848e46f49f860cb7de571b9543566287 Mon Sep 17 00:00:00 2001 From: Kevin Gilmore Date: Tue, 23 Apr 2019 22:05:31 -0500 Subject: [PATCH 19/24] BAEL-2840: add link back to article --- spring-data-rest/README.md | 1 + 1 file changed, 1 insertion(+) diff --git a/spring-data-rest/README.md b/spring-data-rest/README.md index 1624a3abfd79..abbacb69cc67 100644 --- a/spring-data-rest/README.md +++ b/spring-data-rest/README.md @@ -22,3 +22,4 @@ To view the running application, visit [http://localhost:8080](http://localhost: - [Spring Data REST Events with @RepositoryEventHandler](http://www.baeldung.com/spring-data-rest-events) - [Customizing HTTP Endpoints in Spring Data REST](https://www.baeldung.com/spring-data-rest-customize-http-endpoints) - [Spring Boot with SQLite](https://www.baeldung.com/spring-boot-sqlite) +- [Spring Data Web Support](https://www.baeldung.com/spring-data-web-support) From d44dc9956a8f7695b3e63396ac05e5644e0e3da9 Mon Sep 17 00:00:00 2001 From: Kevin Gilmore Date: Wed, 1 May 2019 18:24:25 -0500 Subject: [PATCH 20/24] BAEL-2655: add link back to article --- core-kotlin-io/README.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/core-kotlin-io/README.md b/core-kotlin-io/README.md index c085c0653fbd..cb4dac7e4d86 100644 --- a/core-kotlin-io/README.md +++ b/core-kotlin-io/README.md @@ -1,3 +1,5 @@ ## Relevant articles: - [InputStream to String in Kotlin](https://www.baeldung.com/kotlin-inputstream-to-string) +- [Console I/O in Kotlin](https://www.baeldung.com/kotlin-console-io) + From fc7c61b00757d381cf7338d4349e4a45f0f0843c Mon Sep 17 00:00:00 2001 From: Kevin Gilmore Date: Sat, 4 May 2019 22:49:53 -0500 Subject: [PATCH 21/24] BAEL-2884: add link back to article --- core-java-modules/README.md | 3 +++ 1 file changed, 3 insertions(+) create mode 100644 core-java-modules/README.md diff --git a/core-java-modules/README.md b/core-java-modules/README.md new file mode 100644 index 000000000000..a90535a44fc6 --- /dev/null +++ b/core-java-modules/README.md @@ -0,0 +1,3 @@ +## Relevant articles: + +- [Multi-Module Maven Application with Java Modules](https://www.baeldung.com/maven-multi-module-project-java-jpms) From ca20fd0265d4a5f97d8bc3f5ded74a9257277fdc Mon Sep 17 00:00:00 2001 From: Kevin Gilmore Date: Sun, 30 Jun 2019 10:46:38 -0500 Subject: [PATCH 22/24] BAEL-2985: Fix Spring Boot Apps in spring-data-rest module --- .../{ => books}/SpringDataRestApplication.java | 2 +- .../com/baeldung/{ => books}/config/DbConfig.java | 6 +++--- .../com/baeldung/{ => books}/config/MvcConfig.java | 7 ++++--- .../com/baeldung/{ => books}/config/RestConfig.java | 7 ++++--- .../{ => books}/config/ValidatorEventRegister.java | 2 +- .../baeldung/{ => books}/dialect/SQLiteDialect.java | 2 +- .../dialect/SQLiteIdentityColumnSupport.java | 2 +- .../{ => books}/events/AuthorEventHandler.java | 7 ++++--- .../{ => books}/events/BookEventHandler.java | 8 +++++--- .../handlers/RestResponseEntityExceptionHandler.java | 2 +- .../com/baeldung/{ => books}/models/Address.java | 2 +- .../java/com/baeldung/{ => books}/models/Author.java | 2 +- .../java/com/baeldung/{ => books}/models/Book.java | 2 +- .../com/baeldung/{ => books}/models/Library.java | 2 +- .../com/baeldung/{ => books}/models/Subject.java | 2 +- .../com/baeldung/{ => books}/models/WebsiteUser.java | 2 +- .../baeldung/{ => books}/projections/CustomBook.java | 6 +++--- .../{ => books}/repositories/AddressRepository.java | 4 ++-- .../{ => books}/repositories/AuthorRepository.java | 4 ++-- .../{ => books}/repositories/BookRepository.java | 6 +++--- .../{ => books}/repositories/LibraryRepository.java | 4 ++-- .../{ => books}/repositories/SubjectRepository.java | 5 +++-- .../{ => books}/repositories/UserRepository.java | 5 +++-- .../{ => books}/validators/WebsiteUserValidator.java | 4 ++-- .../events/AuthorEventHandlerUnitTest.java | 6 ++++-- .../{ => books}/events/BookEventHandlerUnitTest.java | 8 +++++--- .../projections}/SpringDataProjectionLiveTest.java | 12 ++++++------ .../SpringDataRestValidatorIntegrationTest.java | 6 +++--- .../test/UserControllerIntegrationTest.java | 2 +- .../org/baeldung/SpringContextIntegrationTest.java | 2 +- 30 files changed, 71 insertions(+), 60 deletions(-) rename spring-data-rest/src/main/java/com/baeldung/{ => books}/SpringDataRestApplication.java (91%) rename spring-data-rest/src/main/java/com/baeldung/{ => books}/config/DbConfig.java (94%) rename spring-data-rest/src/main/java/com/baeldung/{ => books}/config/MvcConfig.java (85%) rename spring-data-rest/src/main/java/com/baeldung/{ => books}/config/RestConfig.java (86%) rename spring-data-rest/src/main/java/com/baeldung/{ => books}/config/ValidatorEventRegister.java (94%) rename spring-data-rest/src/main/java/com/baeldung/{ => books}/dialect/SQLiteDialect.java (98%) rename spring-data-rest/src/main/java/com/baeldung/{ => books}/dialect/SQLiteIdentityColumnSupport.java (94%) rename spring-data-rest/src/main/java/com/baeldung/{ => books}/events/AuthorEventHandler.java (89%) rename spring-data-rest/src/main/java/com/baeldung/{ => books}/events/BookEventHandler.java (86%) rename spring-data-rest/src/main/java/com/baeldung/{ => books}/exception/handlers/RestResponseEntityExceptionHandler.java (94%) rename spring-data-rest/src/main/java/com/baeldung/{ => books}/models/Address.java (96%) rename spring-data-rest/src/main/java/com/baeldung/{ => books}/models/Author.java (97%) rename spring-data-rest/src/main/java/com/baeldung/{ => books}/models/Book.java (97%) rename spring-data-rest/src/main/java/com/baeldung/{ => books}/models/Library.java (97%) rename spring-data-rest/src/main/java/com/baeldung/{ => books}/models/Subject.java (94%) rename spring-data-rest/src/main/java/com/baeldung/{ => books}/models/WebsiteUser.java (95%) rename spring-data-rest/src/main/java/com/baeldung/{ => books}/projections/CustomBook.java (77%) rename spring-data-rest/src/main/java/com/baeldung/{ => books}/repositories/AddressRepository.java (62%) rename spring-data-rest/src/main/java/com/baeldung/{ => books}/repositories/AuthorRepository.java (62%) rename spring-data-rest/src/main/java/com/baeldung/{ => books}/repositories/BookRepository.java (67%) rename spring-data-rest/src/main/java/com/baeldung/{ => books}/repositories/LibraryRepository.java (62%) rename spring-data-rest/src/main/java/com/baeldung/{ => books}/repositories/SubjectRepository.java (85%) rename spring-data-rest/src/main/java/com/baeldung/{ => books}/repositories/UserRepository.java (91%) rename spring-data-rest/src/main/java/com/baeldung/{ => books}/validators/WebsiteUserValidator.java (87%) rename spring-data-rest/src/test/java/com/baeldung/{ => books}/events/AuthorEventHandlerUnitTest.java (86%) rename spring-data-rest/src/test/java/com/baeldung/{ => books}/events/BookEventHandlerUnitTest.java (81%) rename spring-data-rest/src/test/java/com/baeldung/{projection => books/projections}/SpringDataProjectionLiveTest.java (91%) rename spring-data-rest/src/test/java/com/baeldung/{ => books}/validator/SpringDataRestValidatorIntegrationTest.java (97%) diff --git a/spring-data-rest/src/main/java/com/baeldung/SpringDataRestApplication.java b/spring-data-rest/src/main/java/com/baeldung/books/SpringDataRestApplication.java similarity index 91% rename from spring-data-rest/src/main/java/com/baeldung/SpringDataRestApplication.java rename to spring-data-rest/src/main/java/com/baeldung/books/SpringDataRestApplication.java index 702acb5b6591..097a6aabd79b 100644 --- a/spring-data-rest/src/main/java/com/baeldung/SpringDataRestApplication.java +++ b/spring-data-rest/src/main/java/com/baeldung/books/SpringDataRestApplication.java @@ -1,4 +1,4 @@ -package com.baeldung; +package com.baeldung.books; import org.springframework.boot.SpringApplication; import org.springframework.boot.autoconfigure.SpringBootApplication; diff --git a/spring-data-rest/src/main/java/com/baeldung/config/DbConfig.java b/spring-data-rest/src/main/java/com/baeldung/books/config/DbConfig.java similarity index 94% rename from spring-data-rest/src/main/java/com/baeldung/config/DbConfig.java rename to spring-data-rest/src/main/java/com/baeldung/books/config/DbConfig.java index 3ca728ec9432..20008eb58302 100644 --- a/spring-data-rest/src/main/java/com/baeldung/config/DbConfig.java +++ b/spring-data-rest/src/main/java/com/baeldung/books/config/DbConfig.java @@ -1,4 +1,4 @@ -package com.baeldung.config; +package com.baeldung.books.config; import java.util.Properties; @@ -16,7 +16,7 @@ import org.springframework.orm.jpa.vendor.HibernateJpaVendorAdapter; @Configuration -@EnableJpaRepositories(basePackages = "com.baeldung.repositories") +@EnableJpaRepositories(basePackages = "com.baeldung.books.repositories") // @PropertySource("persistence-h2.properties") // @PropertySource("persistence-hsqldb.properties") // @PropertySource("persistence-derby.properties") @@ -40,7 +40,7 @@ public DataSource dataSource() { public LocalContainerEntityManagerFactoryBean entityManagerFactory() { final LocalContainerEntityManagerFactoryBean em = new LocalContainerEntityManagerFactoryBean(); em.setDataSource(dataSource()); - em.setPackagesToScan(new String[] { "com.baeldung.models" }); + em.setPackagesToScan(new String[] { "com.baeldung.books.models" }); em.setJpaVendorAdapter(new HibernateJpaVendorAdapter()); em.setJpaProperties(additionalProperties()); return em; diff --git a/spring-data-rest/src/main/java/com/baeldung/config/MvcConfig.java b/spring-data-rest/src/main/java/com/baeldung/books/config/MvcConfig.java similarity index 85% rename from spring-data-rest/src/main/java/com/baeldung/config/MvcConfig.java rename to spring-data-rest/src/main/java/com/baeldung/books/config/MvcConfig.java index 9d0d3a668784..69e984ad067c 100644 --- a/spring-data-rest/src/main/java/com/baeldung/config/MvcConfig.java +++ b/spring-data-rest/src/main/java/com/baeldung/books/config/MvcConfig.java @@ -1,13 +1,14 @@ -package com.baeldung.config; +package com.baeldung.books.config; -import com.baeldung.events.AuthorEventHandler; -import com.baeldung.events.BookEventHandler; import org.springframework.context.annotation.Bean; import org.springframework.context.annotation.Configuration; import org.springframework.web.servlet.config.annotation.DefaultServletHandlerConfigurer; import org.springframework.web.servlet.config.annotation.EnableWebMvc; import org.springframework.web.servlet.config.annotation.WebMvcConfigurer; +import com.baeldung.books.events.AuthorEventHandler; +import com.baeldung.books.events.BookEventHandler; + @Configuration @EnableWebMvc public class MvcConfig implements WebMvcConfigurer { diff --git a/spring-data-rest/src/main/java/com/baeldung/config/RestConfig.java b/spring-data-rest/src/main/java/com/baeldung/books/config/RestConfig.java similarity index 86% rename from spring-data-rest/src/main/java/com/baeldung/config/RestConfig.java rename to spring-data-rest/src/main/java/com/baeldung/books/config/RestConfig.java index 47cb95693b89..1c6f04331eab 100644 --- a/spring-data-rest/src/main/java/com/baeldung/config/RestConfig.java +++ b/spring-data-rest/src/main/java/com/baeldung/books/config/RestConfig.java @@ -1,7 +1,8 @@ -package com.baeldung.config; +package com.baeldung.books.config; + +import com.baeldung.books.models.WebsiteUser; +import com.baeldung.books.projections.CustomBook; -import com.baeldung.models.WebsiteUser; -import com.baeldung.projections.CustomBook; import org.springframework.context.annotation.Configuration; import org.springframework.data.rest.core.config.RepositoryRestConfiguration; import org.springframework.data.rest.core.mapping.ExposureConfiguration; diff --git a/spring-data-rest/src/main/java/com/baeldung/config/ValidatorEventRegister.java b/spring-data-rest/src/main/java/com/baeldung/books/config/ValidatorEventRegister.java similarity index 94% rename from spring-data-rest/src/main/java/com/baeldung/config/ValidatorEventRegister.java rename to spring-data-rest/src/main/java/com/baeldung/books/config/ValidatorEventRegister.java index 632ad9183aba..bbaf9a2771e2 100644 --- a/spring-data-rest/src/main/java/com/baeldung/config/ValidatorEventRegister.java +++ b/spring-data-rest/src/main/java/com/baeldung/books/config/ValidatorEventRegister.java @@ -1,4 +1,4 @@ -package com.baeldung.config; +package com.baeldung.books.config; import java.util.Arrays; import java.util.List; diff --git a/spring-data-rest/src/main/java/com/baeldung/dialect/SQLiteDialect.java b/spring-data-rest/src/main/java/com/baeldung/books/dialect/SQLiteDialect.java similarity index 98% rename from spring-data-rest/src/main/java/com/baeldung/dialect/SQLiteDialect.java rename to spring-data-rest/src/main/java/com/baeldung/books/dialect/SQLiteDialect.java index 4512f7d34d80..6e840eec43f1 100644 --- a/spring-data-rest/src/main/java/com/baeldung/dialect/SQLiteDialect.java +++ b/spring-data-rest/src/main/java/com/baeldung/books/dialect/SQLiteDialect.java @@ -1,4 +1,4 @@ -package com.baeldung.dialect; +package com.baeldung.books.dialect; import org.hibernate.dialect.Dialect; import org.hibernate.dialect.identity.IdentityColumnSupport; diff --git a/spring-data-rest/src/main/java/com/baeldung/dialect/SQLiteIdentityColumnSupport.java b/spring-data-rest/src/main/java/com/baeldung/books/dialect/SQLiteIdentityColumnSupport.java similarity index 94% rename from spring-data-rest/src/main/java/com/baeldung/dialect/SQLiteIdentityColumnSupport.java rename to spring-data-rest/src/main/java/com/baeldung/books/dialect/SQLiteIdentityColumnSupport.java index cf6e3a9a97d9..682d82c6f10a 100644 --- a/spring-data-rest/src/main/java/com/baeldung/dialect/SQLiteIdentityColumnSupport.java +++ b/spring-data-rest/src/main/java/com/baeldung/books/dialect/SQLiteIdentityColumnSupport.java @@ -1,4 +1,4 @@ -package com.baeldung.dialect; +package com.baeldung.books.dialect; import org.hibernate.MappingException; import org.hibernate.dialect.identity.IdentityColumnSupportImpl; diff --git a/spring-data-rest/src/main/java/com/baeldung/events/AuthorEventHandler.java b/spring-data-rest/src/main/java/com/baeldung/books/events/AuthorEventHandler.java similarity index 89% rename from spring-data-rest/src/main/java/com/baeldung/events/AuthorEventHandler.java rename to spring-data-rest/src/main/java/com/baeldung/books/events/AuthorEventHandler.java index 485dc8e2217b..b390a529baac 100644 --- a/spring-data-rest/src/main/java/com/baeldung/events/AuthorEventHandler.java +++ b/spring-data-rest/src/main/java/com/baeldung/books/events/AuthorEventHandler.java @@ -1,9 +1,10 @@ -package com.baeldung.events; +package com.baeldung.books.events; -import com.baeldung.models.Author; -import com.baeldung.models.Book; import org.springframework.data.rest.core.annotation.*; +import com.baeldung.books.models.Author; +import com.baeldung.books.models.Book; + import java.util.logging.Logger; @RepositoryEventHandler diff --git a/spring-data-rest/src/main/java/com/baeldung/events/BookEventHandler.java b/spring-data-rest/src/main/java/com/baeldung/books/events/BookEventHandler.java similarity index 86% rename from spring-data-rest/src/main/java/com/baeldung/events/BookEventHandler.java rename to spring-data-rest/src/main/java/com/baeldung/books/events/BookEventHandler.java index 36ae62b92603..0afb3a627904 100644 --- a/spring-data-rest/src/main/java/com/baeldung/events/BookEventHandler.java +++ b/spring-data-rest/src/main/java/com/baeldung/books/events/BookEventHandler.java @@ -1,13 +1,15 @@ -package com.baeldung.events; +package com.baeldung.books.events; import java.util.logging.Logger; -import com.baeldung.models.Author; -import com.baeldung.models.Book; + import org.apache.commons.logging.Log; import org.springframework.data.rest.core.annotation.HandleAfterDelete; import org.springframework.data.rest.core.annotation.HandleBeforeCreate; import org.springframework.data.rest.core.annotation.RepositoryEventHandler; +import com.baeldung.books.models.Author; +import com.baeldung.books.models.Book; + @RepositoryEventHandler public class BookEventHandler { Logger logger = Logger.getLogger("Class BookEventHandler"); diff --git a/spring-data-rest/src/main/java/com/baeldung/exception/handlers/RestResponseEntityExceptionHandler.java b/spring-data-rest/src/main/java/com/baeldung/books/exception/handlers/RestResponseEntityExceptionHandler.java similarity index 94% rename from spring-data-rest/src/main/java/com/baeldung/exception/handlers/RestResponseEntityExceptionHandler.java rename to spring-data-rest/src/main/java/com/baeldung/books/exception/handlers/RestResponseEntityExceptionHandler.java index a3ef91f6d60d..4a961e5250dd 100644 --- a/spring-data-rest/src/main/java/com/baeldung/exception/handlers/RestResponseEntityExceptionHandler.java +++ b/spring-data-rest/src/main/java/com/baeldung/books/exception/handlers/RestResponseEntityExceptionHandler.java @@ -1,4 +1,4 @@ -package com.baeldung.exception.handlers; +package com.baeldung.books.exception.handlers; import org.springframework.data.rest.core.RepositoryConstraintViolationException; import org.springframework.http.HttpHeaders; diff --git a/spring-data-rest/src/main/java/com/baeldung/models/Address.java b/spring-data-rest/src/main/java/com/baeldung/books/models/Address.java similarity index 96% rename from spring-data-rest/src/main/java/com/baeldung/models/Address.java rename to spring-data-rest/src/main/java/com/baeldung/books/models/Address.java index 713af58ae627..3c36db0f3c64 100644 --- a/spring-data-rest/src/main/java/com/baeldung/models/Address.java +++ b/spring-data-rest/src/main/java/com/baeldung/books/models/Address.java @@ -1,4 +1,4 @@ -package com.baeldung.models; +package com.baeldung.books.models; import javax.persistence.Column; import javax.persistence.Entity; diff --git a/spring-data-rest/src/main/java/com/baeldung/models/Author.java b/spring-data-rest/src/main/java/com/baeldung/books/models/Author.java similarity index 97% rename from spring-data-rest/src/main/java/com/baeldung/models/Author.java rename to spring-data-rest/src/main/java/com/baeldung/books/models/Author.java index 3f43af9c4704..aec2e62ebf8c 100644 --- a/spring-data-rest/src/main/java/com/baeldung/models/Author.java +++ b/spring-data-rest/src/main/java/com/baeldung/books/models/Author.java @@ -1,4 +1,4 @@ -package com.baeldung.models; +package com.baeldung.books.models; import java.util.List; diff --git a/spring-data-rest/src/main/java/com/baeldung/models/Book.java b/spring-data-rest/src/main/java/com/baeldung/books/models/Book.java similarity index 97% rename from spring-data-rest/src/main/java/com/baeldung/models/Book.java rename to spring-data-rest/src/main/java/com/baeldung/books/models/Book.java index 07b0d08b842c..7451b04b3b47 100644 --- a/spring-data-rest/src/main/java/com/baeldung/models/Book.java +++ b/spring-data-rest/src/main/java/com/baeldung/books/models/Book.java @@ -1,4 +1,4 @@ -package com.baeldung.models; +package com.baeldung.books.models; import java.util.List; diff --git a/spring-data-rest/src/main/java/com/baeldung/models/Library.java b/spring-data-rest/src/main/java/com/baeldung/books/models/Library.java similarity index 97% rename from spring-data-rest/src/main/java/com/baeldung/models/Library.java rename to spring-data-rest/src/main/java/com/baeldung/books/models/Library.java index 091975f5d0cc..5f95169a9b42 100644 --- a/spring-data-rest/src/main/java/com/baeldung/models/Library.java +++ b/spring-data-rest/src/main/java/com/baeldung/books/models/Library.java @@ -1,4 +1,4 @@ -package com.baeldung.models; +package com.baeldung.books.models; import java.util.List; diff --git a/spring-data-rest/src/main/java/com/baeldung/models/Subject.java b/spring-data-rest/src/main/java/com/baeldung/books/models/Subject.java similarity index 94% rename from spring-data-rest/src/main/java/com/baeldung/models/Subject.java rename to spring-data-rest/src/main/java/com/baeldung/books/models/Subject.java index 4e5fa82148b1..11a4425fdde6 100644 --- a/spring-data-rest/src/main/java/com/baeldung/models/Subject.java +++ b/spring-data-rest/src/main/java/com/baeldung/books/models/Subject.java @@ -1,4 +1,4 @@ -package com.baeldung.models; +package com.baeldung.books.models; import javax.persistence.Column; import javax.persistence.Entity; diff --git a/spring-data-rest/src/main/java/com/baeldung/models/WebsiteUser.java b/spring-data-rest/src/main/java/com/baeldung/books/models/WebsiteUser.java similarity index 95% rename from spring-data-rest/src/main/java/com/baeldung/models/WebsiteUser.java rename to spring-data-rest/src/main/java/com/baeldung/books/models/WebsiteUser.java index 4eb9773e3689..e6326230195b 100644 --- a/spring-data-rest/src/main/java/com/baeldung/models/WebsiteUser.java +++ b/spring-data-rest/src/main/java/com/baeldung/books/models/WebsiteUser.java @@ -1,4 +1,4 @@ -package com.baeldung.models; +package com.baeldung.books.models; import javax.persistence.Entity; import javax.persistence.GeneratedValue; diff --git a/spring-data-rest/src/main/java/com/baeldung/projections/CustomBook.java b/spring-data-rest/src/main/java/com/baeldung/books/projections/CustomBook.java similarity index 77% rename from spring-data-rest/src/main/java/com/baeldung/projections/CustomBook.java rename to spring-data-rest/src/main/java/com/baeldung/books/projections/CustomBook.java index 3dc6938f5c92..5fe78c869d7e 100644 --- a/spring-data-rest/src/main/java/com/baeldung/projections/CustomBook.java +++ b/spring-data-rest/src/main/java/com/baeldung/books/projections/CustomBook.java @@ -1,12 +1,12 @@ -package com.baeldung.projections; +package com.baeldung.books.projections; import java.util.List; import org.springframework.beans.factory.annotation.Value; import org.springframework.data.rest.core.config.Projection; -import com.baeldung.models.Author; -import com.baeldung.models.Book; +import com.baeldung.books.models.Author; +import com.baeldung.books.models.Book; @Projection(name = "customBook", types = { Book.class }) public interface CustomBook { diff --git a/spring-data-rest/src/main/java/com/baeldung/repositories/AddressRepository.java b/spring-data-rest/src/main/java/com/baeldung/books/repositories/AddressRepository.java similarity index 62% rename from spring-data-rest/src/main/java/com/baeldung/repositories/AddressRepository.java rename to spring-data-rest/src/main/java/com/baeldung/books/repositories/AddressRepository.java index 1cc7527e8042..5e3900f43911 100644 --- a/spring-data-rest/src/main/java/com/baeldung/repositories/AddressRepository.java +++ b/spring-data-rest/src/main/java/com/baeldung/books/repositories/AddressRepository.java @@ -1,8 +1,8 @@ -package com.baeldung.repositories; +package com.baeldung.books.repositories; import org.springframework.data.repository.CrudRepository; -import com.baeldung.models.Address; +import com.baeldung.books.models.Address; public interface AddressRepository extends CrudRepository { diff --git a/spring-data-rest/src/main/java/com/baeldung/repositories/AuthorRepository.java b/spring-data-rest/src/main/java/com/baeldung/books/repositories/AuthorRepository.java similarity index 62% rename from spring-data-rest/src/main/java/com/baeldung/repositories/AuthorRepository.java rename to spring-data-rest/src/main/java/com/baeldung/books/repositories/AuthorRepository.java index 2d470367ef74..837e13b1d20e 100644 --- a/spring-data-rest/src/main/java/com/baeldung/repositories/AuthorRepository.java +++ b/spring-data-rest/src/main/java/com/baeldung/books/repositories/AuthorRepository.java @@ -1,8 +1,8 @@ -package com.baeldung.repositories; +package com.baeldung.books.repositories; import org.springframework.data.repository.CrudRepository; -import com.baeldung.models.Author; +import com.baeldung.books.models.Author; public interface AuthorRepository extends CrudRepository { diff --git a/spring-data-rest/src/main/java/com/baeldung/repositories/BookRepository.java b/spring-data-rest/src/main/java/com/baeldung/books/repositories/BookRepository.java similarity index 67% rename from spring-data-rest/src/main/java/com/baeldung/repositories/BookRepository.java rename to spring-data-rest/src/main/java/com/baeldung/books/repositories/BookRepository.java index eee44f35d43a..5d7e277526ff 100644 --- a/spring-data-rest/src/main/java/com/baeldung/repositories/BookRepository.java +++ b/spring-data-rest/src/main/java/com/baeldung/books/repositories/BookRepository.java @@ -1,10 +1,10 @@ -package com.baeldung.repositories; +package com.baeldung.books.repositories; import org.springframework.data.repository.CrudRepository; import org.springframework.data.rest.core.annotation.RepositoryRestResource; -import com.baeldung.models.Book; -import com.baeldung.projections.CustomBook; +import com.baeldung.books.models.Book; +import com.baeldung.books.projections.CustomBook; @RepositoryRestResource(excerptProjection = CustomBook.class) public interface BookRepository extends CrudRepository { diff --git a/spring-data-rest/src/main/java/com/baeldung/repositories/LibraryRepository.java b/spring-data-rest/src/main/java/com/baeldung/books/repositories/LibraryRepository.java similarity index 62% rename from spring-data-rest/src/main/java/com/baeldung/repositories/LibraryRepository.java rename to spring-data-rest/src/main/java/com/baeldung/books/repositories/LibraryRepository.java index c00787f03c5b..92518339a093 100644 --- a/spring-data-rest/src/main/java/com/baeldung/repositories/LibraryRepository.java +++ b/spring-data-rest/src/main/java/com/baeldung/books/repositories/LibraryRepository.java @@ -1,8 +1,8 @@ -package com.baeldung.repositories; +package com.baeldung.books.repositories; import org.springframework.data.repository.CrudRepository; -import com.baeldung.models.Library; +import com.baeldung.books.models.Library; public interface LibraryRepository extends CrudRepository { diff --git a/spring-data-rest/src/main/java/com/baeldung/repositories/SubjectRepository.java b/spring-data-rest/src/main/java/com/baeldung/books/repositories/SubjectRepository.java similarity index 85% rename from spring-data-rest/src/main/java/com/baeldung/repositories/SubjectRepository.java rename to spring-data-rest/src/main/java/com/baeldung/books/repositories/SubjectRepository.java index 76e34b079953..187b01f22253 100644 --- a/spring-data-rest/src/main/java/com/baeldung/repositories/SubjectRepository.java +++ b/spring-data-rest/src/main/java/com/baeldung/books/repositories/SubjectRepository.java @@ -1,11 +1,12 @@ -package com.baeldung.repositories; +package com.baeldung.books.repositories; import org.springframework.data.domain.Page; import org.springframework.data.domain.Pageable; import org.springframework.data.repository.PagingAndSortingRepository; import org.springframework.data.repository.query.Param; import org.springframework.data.rest.core.annotation.RestResource; -import com.baeldung.models.Subject; + +import com.baeldung.books.models.Subject; public interface SubjectRepository extends PagingAndSortingRepository { diff --git a/spring-data-rest/src/main/java/com/baeldung/repositories/UserRepository.java b/spring-data-rest/src/main/java/com/baeldung/books/repositories/UserRepository.java similarity index 91% rename from spring-data-rest/src/main/java/com/baeldung/repositories/UserRepository.java rename to spring-data-rest/src/main/java/com/baeldung/books/repositories/UserRepository.java index a3fed1c31844..f0823338bcc0 100644 --- a/spring-data-rest/src/main/java/com/baeldung/repositories/UserRepository.java +++ b/spring-data-rest/src/main/java/com/baeldung/books/repositories/UserRepository.java @@ -1,11 +1,12 @@ -package com.baeldung.repositories; +package com.baeldung.books.repositories; import org.springframework.data.repository.CrudRepository; import org.springframework.data.repository.query.Param; import org.springframework.data.rest.core.annotation.RepositoryRestResource; import org.springframework.data.rest.core.annotation.RestResource; import org.springframework.web.bind.annotation.CrossOrigin; -import com.baeldung.models.WebsiteUser; + +import com.baeldung.books.models.WebsiteUser; @CrossOrigin @RepositoryRestResource(collectionResourceRel = "users", path = "users") diff --git a/spring-data-rest/src/main/java/com/baeldung/validators/WebsiteUserValidator.java b/spring-data-rest/src/main/java/com/baeldung/books/validators/WebsiteUserValidator.java similarity index 87% rename from spring-data-rest/src/main/java/com/baeldung/validators/WebsiteUserValidator.java rename to spring-data-rest/src/main/java/com/baeldung/books/validators/WebsiteUserValidator.java index 0380332708fd..ad7511c2bad9 100644 --- a/spring-data-rest/src/main/java/com/baeldung/validators/WebsiteUserValidator.java +++ b/spring-data-rest/src/main/java/com/baeldung/books/validators/WebsiteUserValidator.java @@ -1,10 +1,10 @@ -package com.baeldung.validators; +package com.baeldung.books.validators; import org.springframework.stereotype.Component; import org.springframework.validation.Errors; import org.springframework.validation.Validator; -import com.baeldung.models.WebsiteUser; +import com.baeldung.books.models.WebsiteUser; @Component("beforeCreateWebsiteUserValidator") public class WebsiteUserValidator implements Validator { diff --git a/spring-data-rest/src/test/java/com/baeldung/events/AuthorEventHandlerUnitTest.java b/spring-data-rest/src/test/java/com/baeldung/books/events/AuthorEventHandlerUnitTest.java similarity index 86% rename from spring-data-rest/src/test/java/com/baeldung/events/AuthorEventHandlerUnitTest.java rename to spring-data-rest/src/test/java/com/baeldung/books/events/AuthorEventHandlerUnitTest.java index c01d5882a0ed..719c4d7c8605 100644 --- a/spring-data-rest/src/test/java/com/baeldung/events/AuthorEventHandlerUnitTest.java +++ b/spring-data-rest/src/test/java/com/baeldung/books/events/AuthorEventHandlerUnitTest.java @@ -1,6 +1,8 @@ -package com.baeldung.events; +package com.baeldung.books.events; + +import com.baeldung.books.events.AuthorEventHandler; +import com.baeldung.books.models.Author; -import com.baeldung.models.Author; import org.junit.Test; import org.mockito.Mockito; import org.springframework.data.rest.core.annotation.RepositoryEventHandler; diff --git a/spring-data-rest/src/test/java/com/baeldung/events/BookEventHandlerUnitTest.java b/spring-data-rest/src/test/java/com/baeldung/books/events/BookEventHandlerUnitTest.java similarity index 81% rename from spring-data-rest/src/test/java/com/baeldung/events/BookEventHandlerUnitTest.java rename to spring-data-rest/src/test/java/com/baeldung/books/events/BookEventHandlerUnitTest.java index d6b8b3b25e20..4b9d77afa2b0 100644 --- a/spring-data-rest/src/test/java/com/baeldung/events/BookEventHandlerUnitTest.java +++ b/spring-data-rest/src/test/java/com/baeldung/books/events/BookEventHandlerUnitTest.java @@ -1,7 +1,9 @@ -package com.baeldung.events; +package com.baeldung.books.events; + +import com.baeldung.books.events.BookEventHandler; +import com.baeldung.books.models.Author; +import com.baeldung.books.models.Book; -import com.baeldung.models.Author; -import com.baeldung.models.Book; import org.junit.Test; import org.mockito.Mockito; diff --git a/spring-data-rest/src/test/java/com/baeldung/projection/SpringDataProjectionLiveTest.java b/spring-data-rest/src/test/java/com/baeldung/books/projections/SpringDataProjectionLiveTest.java similarity index 91% rename from spring-data-rest/src/test/java/com/baeldung/projection/SpringDataProjectionLiveTest.java rename to spring-data-rest/src/test/java/com/baeldung/books/projections/SpringDataProjectionLiveTest.java index 274ae3bc1dde..98b5831b9665 100644 --- a/spring-data-rest/src/test/java/com/baeldung/projection/SpringDataProjectionLiveTest.java +++ b/spring-data-rest/src/test/java/com/baeldung/books/projections/SpringDataProjectionLiveTest.java @@ -1,4 +1,4 @@ -package com.baeldung.projection; +package com.baeldung.books.projections; import static org.junit.Assert.assertEquals; import static org.junit.Assert.assertFalse; @@ -16,11 +16,11 @@ import org.springframework.boot.test.context.SpringBootTest.WebEnvironment; import org.springframework.test.context.junit4.SpringRunner; -import com.baeldung.SpringDataRestApplication; -import com.baeldung.models.Author; -import com.baeldung.models.Book; -import com.baeldung.repositories.AuthorRepository; -import com.baeldung.repositories.BookRepository; +import com.baeldung.books.SpringDataRestApplication; +import com.baeldung.books.models.Author; +import com.baeldung.books.models.Book; +import com.baeldung.books.repositories.AuthorRepository; +import com.baeldung.books.repositories.BookRepository; @RunWith(SpringRunner.class) @SpringBootTest(classes = SpringDataRestApplication.class, webEnvironment = WebEnvironment.DEFINED_PORT) diff --git a/spring-data-rest/src/test/java/com/baeldung/validator/SpringDataRestValidatorIntegrationTest.java b/spring-data-rest/src/test/java/com/baeldung/books/validator/SpringDataRestValidatorIntegrationTest.java similarity index 97% rename from spring-data-rest/src/test/java/com/baeldung/validator/SpringDataRestValidatorIntegrationTest.java rename to spring-data-rest/src/test/java/com/baeldung/books/validator/SpringDataRestValidatorIntegrationTest.java index 6da76d6a3371..75733475e761 100644 --- a/spring-data-rest/src/test/java/com/baeldung/validator/SpringDataRestValidatorIntegrationTest.java +++ b/spring-data-rest/src/test/java/com/baeldung/books/validator/SpringDataRestValidatorIntegrationTest.java @@ -1,4 +1,4 @@ -package com.baeldung.validator; +package com.baeldung.books.validator; import static org.springframework.test.web.servlet.request.MockMvcRequestBuilders.delete; import static org.springframework.test.web.servlet.request.MockMvcRequestBuilders.get; @@ -19,8 +19,8 @@ import org.springframework.test.web.servlet.MockMvc; import org.springframework.web.context.WebApplicationContext; -import com.baeldung.SpringDataRestApplication; -import com.baeldung.models.WebsiteUser; +import com.baeldung.books.SpringDataRestApplication; +import com.baeldung.books.models.WebsiteUser; import com.fasterxml.jackson.databind.ObjectMapper; @RunWith(SpringJUnit4ClassRunner.class) diff --git a/spring-data-rest/src/test/java/com/baeldung/springdatawebsupport/application/test/UserControllerIntegrationTest.java b/spring-data-rest/src/test/java/com/baeldung/springdatawebsupport/application/test/UserControllerIntegrationTest.java index e1aff7e09d1a..d7ef36178315 100644 --- a/spring-data-rest/src/test/java/com/baeldung/springdatawebsupport/application/test/UserControllerIntegrationTest.java +++ b/spring-data-rest/src/test/java/com/baeldung/springdatawebsupport/application/test/UserControllerIntegrationTest.java @@ -42,7 +42,7 @@ public void whenGetRequestToUsersEndPoint_thenCorrectResponse() throws Exception @Test public void whenGetRequestToUserEndPointWithNameRequestParameter_thenCorrectResponse() throws Exception { - mockMvc.perform(MockMvcRequestBuilders.get("/user").param("name", "John").contentType(MediaType.APPLICATION_JSON_UTF8)).andExpect(MockMvcResultMatchers.status().isOk()) + mockMvc.perform(MockMvcRequestBuilders.get("/users").param("name", "John").contentType(MediaType.APPLICATION_JSON_UTF8)).andExpect(MockMvcResultMatchers.status().isOk()) .andExpect(MockMvcResultMatchers.jsonPath("$['content'][0].['name']").value("John")); } diff --git a/spring-data-rest/src/test/java/org/baeldung/SpringContextIntegrationTest.java b/spring-data-rest/src/test/java/org/baeldung/SpringContextIntegrationTest.java index 0380e3dc2ffc..c2682855b8c4 100644 --- a/spring-data-rest/src/test/java/org/baeldung/SpringContextIntegrationTest.java +++ b/spring-data-rest/src/test/java/org/baeldung/SpringContextIntegrationTest.java @@ -5,7 +5,7 @@ import org.springframework.boot.test.context.SpringBootTest; import org.springframework.test.context.junit4.SpringRunner; -import com.baeldung.SpringDataRestApplication; +import com.baeldung.books.SpringDataRestApplication; @RunWith(SpringRunner.class) @SpringBootTest(classes = SpringDataRestApplication.class) From 1f7a6f65d3dcf521b5278bcee6e683c46fd2f125 Mon Sep 17 00:00:00 2001 From: Kevin Gilmore Date: Sun, 30 Jun 2019 16:45:12 -0500 Subject: [PATCH 23/24] BAEL-2898 BAEL-3057 BAEL-3020 add links back to articles --- algorithms-miscellaneous-3/README.md | 1 + core-groovy-2/README.md | 3 ++- libraries-2/README.md | 2 +- 3 files changed, 4 insertions(+), 2 deletions(-) diff --git a/algorithms-miscellaneous-3/README.md b/algorithms-miscellaneous-3/README.md index 4dd4b66ff286..7a83a97c5b9a 100644 --- a/algorithms-miscellaneous-3/README.md +++ b/algorithms-miscellaneous-3/README.md @@ -4,3 +4,4 @@ - [Implementing Simple State Machines with Java Enums](https://www.baeldung.com/java-enum-simple-state-machine) - [Converting Between Roman and Arabic Numerals in Java](http://www.baeldung.com/java-convert-roman-arabic) - [Practical Java Examples of the Big O Notation](http://www.baeldung.com/java-algorithm-complexity) +- [Checking If a List Is Sorted in Java](https://www.baeldung.com/java-check-if-list-sorted) diff --git a/core-groovy-2/README.md b/core-groovy-2/README.md index 1d35669cd744..d6fc6fc2f726 100644 --- a/core-groovy-2/README.md +++ b/core-groovy-2/README.md @@ -5,4 +5,5 @@ - [String Matching in Groovy](http://www.baeldung.com/) - [Template Engines in Groovy](https://www.baeldung.com/groovy-template-engines) - [Groovy def Keyword](https://www.baeldung.com/groovy-def-keyword) -- [Pattern Matching in Strings in Groovy](https://www.baeldung.com/groovy-pattern-matching) \ No newline at end of file +- [Pattern Matching in Strings in Groovy](https://www.baeldung.com/groovy-pattern-matching) +- [Working with XML in Groovy](https://www.baeldung.com/groovy-xml) \ No newline at end of file diff --git a/libraries-2/README.md b/libraries-2/README.md index 8243b9f82ce2..cdeed10b3fb1 100644 --- a/libraries-2/README.md +++ b/libraries-2/README.md @@ -4,4 +4,4 @@ - [A Guide to jBPM with Java](https://www.baeldung.com/jbpm-java) - [Guide to Classgraph Library](https://www.baeldung.com/classgraph) - [Create a Java Command Line Program with Picocli](https://www.baeldung.com/java-picocli-create-command-line-program) - +- [Guide to Java Parallel Collectors Library](https://www.baeldung.com/java-parallel-collectors) From 64cf6156d8c762e1483b0d258fccc2eb77387997 Mon Sep 17 00:00:00 2001 From: Kevin Gilmore Date: Fri, 23 Aug 2019 21:03:13 -0500 Subject: [PATCH 24/24] BAEL-3126 BAEL-2463 README --- algorithms-miscellaneous-3/README.md | 1 + jackson-2/README.md | 1 + 2 files changed, 2 insertions(+) diff --git a/algorithms-miscellaneous-3/README.md b/algorithms-miscellaneous-3/README.md index 6a38df484a84..ce0fde041582 100644 --- a/algorithms-miscellaneous-3/README.md +++ b/algorithms-miscellaneous-3/README.md @@ -7,3 +7,4 @@ - [Checking If a List Is Sorted in Java](https://www.baeldung.com/java-check-if-list-sorted) - [Checking if a Java Graph has a Cycle](https://www.baeldung.com/java-graph-has-a-cycle) - [A Guide to the Folding Technique in Java](https://www.baeldung.com/folding-hashing-technique) +- [Creating a Triangle with for Loops in Java](https://www.baeldung.com/java-print-triangle) diff --git a/jackson-2/README.md b/jackson-2/README.md index bb2a58483f68..920eaa91e86f 100644 --- a/jackson-2/README.md +++ b/jackson-2/README.md @@ -11,3 +11,4 @@ The "REST With Spring" Classes: http://bit.ly/restwithspring - [Working with Tree Model Nodes in Jackson](https://www.baeldung.com/jackson-json-node-tree-model) - [Converting JSON to CSV in Java](https://www.baeldung.com/java-converting-json-to-csv) - [Compare Two JSON Objects with Jackson](https://www.baeldung.com/jackson-compare-two-json-objects) +- [Calling Default Serializer from Custom Serializer in Jackson](https://www.baeldung.com/jackson-call-default-serializer-from-custom-serializer)