From 6b80543360fc0a89cdf43184eced0b19eeda3b32 Mon Sep 17 00:00:00 2001 From: catalin-burcea Date: Sun, 6 Oct 2019 15:57:30 +0300 Subject: [PATCH] Move articles out of core-java-lang part 2 --- .../core-java-lang-oop-2/README.md | 1 - .../core-java-lang-operators/README.md | 1 + .../CompoundOperatorsUnitTest.java | 0 .../diamond => diamondoperator}/Car.java | 2 +- .../DiamondOperatorUnitTest.java | 2 +- .../diamond => diamondoperator}/Diesel.java | 2 +- .../diamond => diamondoperator}/Engine.java | 2 +- .../diamond => diamondoperator}/Vehicle.java | 2 +- .../{test => }/InstanceOfUnitTest.java | 2 +- .../core-java-lang-syntax-2/README.md | 6 +++++ .../ConditionalBranches.java | 2 +- .../core}/controlstructures/Loops.java | 2 +- .../core}/nativekeyword/DateTimeUtils.java | 2 +- .../core}/nativekeyword/NativeMainApp.java | 4 +--- .../com/baeldung/core}/packages/TodoApp.java | 6 ++--- .../com/baeldung/core}/packages/TodoList.java | 6 ++--- .../core}/packages/domain/TodoItem.java | 2 +- .../Employee.java | 2 +- .../ExampleClass.java | 2 +- .../PublicOuterClass.java | 2 +- .../core}/scope/BracketScopeExample.java | 2 +- .../core}/scope/ClassScopeExample.java | 2 +- .../core}/scope/LoopScopeExample.java | 2 +- .../core}/scope/MethodScopeExample.java | 2 +- .../core}/scope/NestedScopesExample.java | 2 +- .../doublebrace/DoubleBraceUnitTest.java | 2 +- .../DateTimeUtilsManualTest.java | 6 ++--- .../core}/packages/PackagesUnitTest.java | 9 ++++---- .../core-java-lang-syntax/README.md | 22 +++++++------------ ...WhenUsingLoops.java => LoopsUnitTest.java} | 2 +- core-java-modules/core-java-lang/README.md | 10 --------- .../java/com/baeldung/system/ChatWindow.java | 0 .../com/baeldung/system/DateTimeService.java | 0 .../baeldung/system/EnvironmentVariables.java | 0 .../com/baeldung/system/SystemErrDemo.java | 0 .../com/baeldung/system/SystemExitDemo.java | 0 .../com/baeldung/system/SystemOutDemo.java | 0 .../com/baeldung/system/UserCredentials.java | 0 .../system/DateTimeServiceUnitTest.java | 0 .../system/EnvironmentVariablesUnitTest.java | 0 .../system/SystemArrayCopyUnitTest.java | 0 .../baeldung/system/SystemNanoUnitTest.java | 0 .../system/SystemPropertiesUnitTest.java | 0 43 files changed, 49 insertions(+), 62 deletions(-) rename core-java-modules/{core-java-lang => core-java-lang-operators}/src/test/java/com/baeldung/compoundoperators/CompoundOperatorsUnitTest.java (100%) rename core-java-modules/core-java-lang-operators/src/test/java/com/baeldung/{java/diamond => diamondoperator}/Car.java (62%) rename core-java-modules/core-java-lang-operators/src/test/java/com/baeldung/{java/diamond => diamondoperator}/DiamondOperatorUnitTest.java (87%) rename core-java-modules/core-java-lang-operators/src/test/java/com/baeldung/{java/diamond => diamondoperator}/Diesel.java (76%) rename core-java-modules/core-java-lang-operators/src/test/java/com/baeldung/{java/diamond => diamondoperator}/Engine.java (54%) rename core-java-modules/core-java-lang-operators/src/test/java/com/baeldung/{java/diamond => diamondoperator}/Vehicle.java (56%) rename core-java-modules/core-java-lang-operators/src/test/java/com/baeldung/keyword/{test => }/InstanceOfUnitTest.java (97%) rename core-java-modules/{core-java-lang/src/main/java/com/baeldung => core-java-lang-syntax-2/src/main/java/com/baeldung/core}/controlstructures/ConditionalBranches.java (97%) rename core-java-modules/{core-java-lang/src/main/java/com/baeldung => core-java-lang-syntax-2/src/main/java/com/baeldung/core}/controlstructures/Loops.java (99%) rename core-java-modules/{core-java-lang/src/main/java/com/baeldung => core-java-lang-syntax-2/src/main/java/com/baeldung/core}/nativekeyword/DateTimeUtils.java (78%) rename core-java-modules/{core-java-lang/src/main/java/com/baeldung => core-java-lang-syntax-2/src/main/java/com/baeldung/core}/nativekeyword/NativeMainApp.java (74%) rename core-java-modules/{core-java-lang/src/main/java/com/baeldung => core-java-lang-syntax-2/src/main/java/com/baeldung/core}/packages/TodoApp.java (86%) rename core-java-modules/{core-java-lang/src/main/java/com/baeldung => core-java-lang-syntax-2/src/main/java/com/baeldung/core}/packages/TodoList.java (84%) rename core-java-modules/{core-java-lang/src/main/java/com/baeldung => core-java-lang-syntax-2/src/main/java/com/baeldung/core}/packages/domain/TodoItem.java (94%) rename core-java-modules/core-java-lang-syntax-2/src/main/java/com/baeldung/core/{modifiers => privatemodifier}/Employee.java (96%) rename core-java-modules/core-java-lang-syntax-2/src/main/java/com/baeldung/core/{modifiers => privatemodifier}/ExampleClass.java (84%) rename core-java-modules/core-java-lang-syntax-2/src/main/java/com/baeldung/core/{modifiers => privatemodifier}/PublicOuterClass.java (90%) rename core-java-modules/{core-java-lang/src/main/java/com/baeldung => core-java-lang-syntax-2/src/main/java/com/baeldung/core}/scope/BracketScopeExample.java (89%) rename core-java-modules/{core-java-lang/src/main/java/com/baeldung => core-java-lang-syntax-2/src/main/java/com/baeldung/core}/scope/ClassScopeExample.java (86%) rename core-java-modules/{core-java-lang/src/main/java/com/baeldung => core-java-lang-syntax-2/src/main/java/com/baeldung/core}/scope/LoopScopeExample.java (92%) rename core-java-modules/{core-java-lang/src/main/java/com/baeldung => core-java-lang-syntax-2/src/main/java/com/baeldung/core}/scope/MethodScopeExample.java (87%) rename core-java-modules/{core-java-lang/src/main/java/com/baeldung => core-java-lang-syntax-2/src/main/java/com/baeldung/core}/scope/NestedScopesExample.java (86%) rename core-java-modules/{core-java-lang-operators/src/test/java/com/baeldung/java => core-java-lang-syntax-2/src/test/java/com/baeldung/core}/doublebrace/DoubleBraceUnitTest.java (96%) rename core-java-modules/{core-java-lang/src/test/java/com/baeldung => core-java-lang-syntax-2/src/test/java/com/baeldung/core}/nativekeyword/DateTimeUtilsManualTest.java (95%) rename core-java-modules/{core-java-lang/src/test/java/com/baeldung => core-java-lang-syntax-2/src/test/java/com/baeldung/core}/packages/PackagesUnitTest.java (85%) rename core-java-modules/core-java-lang-syntax/src/test/java/com/baeldung/loops/{WhenUsingLoops.java => LoopsUnitTest.java} (98%) rename core-java-modules/{core-java-lang-syntax => core-java-lang}/src/main/java/com/baeldung/system/ChatWindow.java (100%) rename core-java-modules/{core-java-lang-syntax => core-java-lang}/src/main/java/com/baeldung/system/DateTimeService.java (100%) rename core-java-modules/{core-java-lang-syntax => core-java-lang}/src/main/java/com/baeldung/system/EnvironmentVariables.java (100%) rename core-java-modules/{core-java-lang-syntax => core-java-lang}/src/main/java/com/baeldung/system/SystemErrDemo.java (100%) rename core-java-modules/{core-java-lang-syntax => core-java-lang}/src/main/java/com/baeldung/system/SystemExitDemo.java (100%) rename core-java-modules/{core-java-lang-syntax => core-java-lang}/src/main/java/com/baeldung/system/SystemOutDemo.java (100%) rename core-java-modules/{core-java-lang-syntax => core-java-lang}/src/main/java/com/baeldung/system/UserCredentials.java (100%) rename core-java-modules/{core-java-lang-syntax => core-java-lang}/src/test/java/com/baeldung/system/DateTimeServiceUnitTest.java (100%) rename core-java-modules/{core-java-lang-syntax => core-java-lang}/src/test/java/com/baeldung/system/EnvironmentVariablesUnitTest.java (100%) rename core-java-modules/{core-java-lang-syntax => core-java-lang}/src/test/java/com/baeldung/system/SystemArrayCopyUnitTest.java (100%) rename core-java-modules/{core-java-lang-syntax => core-java-lang}/src/test/java/com/baeldung/system/SystemNanoUnitTest.java (100%) rename core-java-modules/{core-java-lang-syntax => core-java-lang}/src/test/java/com/baeldung/system/SystemPropertiesUnitTest.java (100%) diff --git a/core-java-modules/core-java-lang-oop-2/README.md b/core-java-modules/core-java-lang-oop-2/README.md index dca7b14d68..e2c30bbb40 100644 --- a/core-java-modules/core-java-lang-oop-2/README.md +++ b/core-java-modules/core-java-lang-oop-2/README.md @@ -7,7 +7,6 @@ This module contains articles about Object-oriented programming (OOP) in Java - [Cannot Reference “X” Before Supertype Constructor Has Been Called](https://www.baeldung.com/java-cannot-reference-x-before-supertype-constructor-error) - [Anonymous Classes in Java](https://www.baeldung.com/java-anonymous-classes) - [Raw Types in Java](https://www.baeldung.com/raw-types-java) -- [Java ‘private’ Access Modifier](https://www.baeldung.com/java-private-keyword) - [Marker Interfaces in Java](https://www.baeldung.com/java-marker-interfaces) - [Java equals() and hashCode() Contracts](https://www.baeldung.com/java-equals-hashcode-contracts) - [Immutable Objects in Java](https://www.baeldung.com/java-immutable-object) diff --git a/core-java-modules/core-java-lang-operators/README.md b/core-java-modules/core-java-lang-operators/README.md index 280c630882..f9fa49ee0d 100644 --- a/core-java-modules/core-java-lang-operators/README.md +++ b/core-java-modules/core-java-lang-operators/README.md @@ -4,3 +4,4 @@ - [The Modulo Operator in Java](https://www.baeldung.com/modulo-java) - [Java instanceof Operator](https://www.baeldung.com/java-instanceof) - [A Guide to Increment and Decrement Unary Operators in Java](https://www.baeldung.com/java-unary-operators) +- [Java Compound Operators](https://www.baeldung.com/java-compound-operators) diff --git a/core-java-modules/core-java-lang/src/test/java/com/baeldung/compoundoperators/CompoundOperatorsUnitTest.java b/core-java-modules/core-java-lang-operators/src/test/java/com/baeldung/compoundoperators/CompoundOperatorsUnitTest.java similarity index 100% rename from core-java-modules/core-java-lang/src/test/java/com/baeldung/compoundoperators/CompoundOperatorsUnitTest.java rename to core-java-modules/core-java-lang-operators/src/test/java/com/baeldung/compoundoperators/CompoundOperatorsUnitTest.java diff --git a/core-java-modules/core-java-lang-operators/src/test/java/com/baeldung/java/diamond/Car.java b/core-java-modules/core-java-lang-operators/src/test/java/com/baeldung/diamondoperator/Car.java similarity index 62% rename from core-java-modules/core-java-lang-operators/src/test/java/com/baeldung/java/diamond/Car.java rename to core-java-modules/core-java-lang-operators/src/test/java/com/baeldung/diamondoperator/Car.java index a680c4e670..7fa52a5eb1 100644 --- a/core-java-modules/core-java-lang-operators/src/test/java/com/baeldung/java/diamond/Car.java +++ b/core-java-modules/core-java-lang-operators/src/test/java/com/baeldung/diamondoperator/Car.java @@ -1,4 +1,4 @@ -package com.baeldung.java.diamond; +package com.baeldung.diamondoperator; public class Car implements Vehicle { diff --git a/core-java-modules/core-java-lang-operators/src/test/java/com/baeldung/java/diamond/DiamondOperatorUnitTest.java b/core-java-modules/core-java-lang-operators/src/test/java/com/baeldung/diamondoperator/DiamondOperatorUnitTest.java similarity index 87% rename from core-java-modules/core-java-lang-operators/src/test/java/com/baeldung/java/diamond/DiamondOperatorUnitTest.java rename to core-java-modules/core-java-lang-operators/src/test/java/com/baeldung/diamondoperator/DiamondOperatorUnitTest.java index ee5f639926..b50119b3c6 100644 --- a/core-java-modules/core-java-lang-operators/src/test/java/com/baeldung/java/diamond/DiamondOperatorUnitTest.java +++ b/core-java-modules/core-java-lang-operators/src/test/java/com/baeldung/diamondoperator/DiamondOperatorUnitTest.java @@ -1,4 +1,4 @@ -package com.baeldung.java.diamond; +package com.baeldung.diamondoperator; import static org.junit.Assert.assertNotNull; diff --git a/core-java-modules/core-java-lang-operators/src/test/java/com/baeldung/java/diamond/Diesel.java b/core-java-modules/core-java-lang-operators/src/test/java/com/baeldung/diamondoperator/Diesel.java similarity index 76% rename from core-java-modules/core-java-lang-operators/src/test/java/com/baeldung/java/diamond/Diesel.java rename to core-java-modules/core-java-lang-operators/src/test/java/com/baeldung/diamondoperator/Diesel.java index 90eb7d9340..0b92d11318 100644 --- a/core-java-modules/core-java-lang-operators/src/test/java/com/baeldung/java/diamond/Diesel.java +++ b/core-java-modules/core-java-lang-operators/src/test/java/com/baeldung/diamondoperator/Diesel.java @@ -1,4 +1,4 @@ -package com.baeldung.java.diamond; +package com.baeldung.diamondoperator; public class Diesel implements Engine { diff --git a/core-java-modules/core-java-lang-operators/src/test/java/com/baeldung/java/diamond/Engine.java b/core-java-modules/core-java-lang-operators/src/test/java/com/baeldung/diamondoperator/Engine.java similarity index 54% rename from core-java-modules/core-java-lang-operators/src/test/java/com/baeldung/java/diamond/Engine.java rename to core-java-modules/core-java-lang-operators/src/test/java/com/baeldung/diamondoperator/Engine.java index 746baf3254..0afd48114a 100644 --- a/core-java-modules/core-java-lang-operators/src/test/java/com/baeldung/java/diamond/Engine.java +++ b/core-java-modules/core-java-lang-operators/src/test/java/com/baeldung/diamondoperator/Engine.java @@ -1,4 +1,4 @@ -package com.baeldung.java.diamond; +package com.baeldung.diamondoperator; public interface Engine { diff --git a/core-java-modules/core-java-lang-operators/src/test/java/com/baeldung/java/diamond/Vehicle.java b/core-java-modules/core-java-lang-operators/src/test/java/com/baeldung/diamondoperator/Vehicle.java similarity index 56% rename from core-java-modules/core-java-lang-operators/src/test/java/com/baeldung/java/diamond/Vehicle.java rename to core-java-modules/core-java-lang-operators/src/test/java/com/baeldung/diamondoperator/Vehicle.java index 8395cdd970..89a5dfefef 100644 --- a/core-java-modules/core-java-lang-operators/src/test/java/com/baeldung/java/diamond/Vehicle.java +++ b/core-java-modules/core-java-lang-operators/src/test/java/com/baeldung/diamondoperator/Vehicle.java @@ -1,4 +1,4 @@ -package com.baeldung.java.diamond; +package com.baeldung.diamondoperator; public interface Vehicle { diff --git a/core-java-modules/core-java-lang-operators/src/test/java/com/baeldung/keyword/test/InstanceOfUnitTest.java b/core-java-modules/core-java-lang-operators/src/test/java/com/baeldung/keyword/InstanceOfUnitTest.java similarity index 97% rename from core-java-modules/core-java-lang-operators/src/test/java/com/baeldung/keyword/test/InstanceOfUnitTest.java rename to core-java-modules/core-java-lang-operators/src/test/java/com/baeldung/keyword/InstanceOfUnitTest.java index 6966fa3944..0e082b69d3 100644 --- a/core-java-modules/core-java-lang-operators/src/test/java/com/baeldung/keyword/test/InstanceOfUnitTest.java +++ b/core-java-modules/core-java-lang-operators/src/test/java/com/baeldung/keyword/InstanceOfUnitTest.java @@ -1,4 +1,4 @@ -package com.baeldung.keyword.test; +package com.baeldung.keyword; import org.junit.Assert; import org.junit.jupiter.api.Test; diff --git a/core-java-modules/core-java-lang-syntax-2/README.md b/core-java-modules/core-java-lang-syntax-2/README.md index d8daadf2aa..a3b11865af 100644 --- a/core-java-modules/core-java-lang-syntax-2/README.md +++ b/core-java-modules/core-java-lang-syntax-2/README.md @@ -5,4 +5,10 @@ This module contains articles about Java syntax ### Relevant Articles: - [Java ‘private’ Access Modifier](https://www.baeldung.com/java-private-keyword) +- [Guide to Java Packages](https://www.baeldung.com/java-packages) +- [If-Else Statement in Java](https://www.baeldung.com/java-if-else) +- [Control Structures in Java](https://www.baeldung.com/java-control-structures) +- [Java Double Brace Initialization](https://www.baeldung.com/java-double-brace-initialization) +- [The Java Native Keyword and Methods](https://www.baeldung.com/java-native) +- [Variable Scope in Java](https://www.baeldung.com/java-variable-scope) - [[<-- Prev]](/core-java-modules/core-java-lang-syntax) diff --git a/core-java-modules/core-java-lang/src/main/java/com/baeldung/controlstructures/ConditionalBranches.java b/core-java-modules/core-java-lang-syntax-2/src/main/java/com/baeldung/core/controlstructures/ConditionalBranches.java similarity index 97% rename from core-java-modules/core-java-lang/src/main/java/com/baeldung/controlstructures/ConditionalBranches.java rename to core-java-modules/core-java-lang-syntax-2/src/main/java/com/baeldung/core/controlstructures/ConditionalBranches.java index bace609699..e15386f048 100644 --- a/core-java-modules/core-java-lang/src/main/java/com/baeldung/controlstructures/ConditionalBranches.java +++ b/core-java-modules/core-java-lang-syntax-2/src/main/java/com/baeldung/core/controlstructures/ConditionalBranches.java @@ -1,4 +1,4 @@ -package com.baeldung.controlstructures; +package com.baeldung.core.controlstructures; public class ConditionalBranches { diff --git a/core-java-modules/core-java-lang/src/main/java/com/baeldung/controlstructures/Loops.java b/core-java-modules/core-java-lang-syntax-2/src/main/java/com/baeldung/core/controlstructures/Loops.java similarity index 99% rename from core-java-modules/core-java-lang/src/main/java/com/baeldung/controlstructures/Loops.java rename to core-java-modules/core-java-lang-syntax-2/src/main/java/com/baeldung/core/controlstructures/Loops.java index bc4515bfc7..9d73127cae 100644 --- a/core-java-modules/core-java-lang/src/main/java/com/baeldung/controlstructures/Loops.java +++ b/core-java-modules/core-java-lang-syntax-2/src/main/java/com/baeldung/core/controlstructures/Loops.java @@ -1,4 +1,4 @@ -package com.baeldung.controlstructures; +package com.baeldung.core.controlstructures; public class Loops { diff --git a/core-java-modules/core-java-lang/src/main/java/com/baeldung/nativekeyword/DateTimeUtils.java b/core-java-modules/core-java-lang-syntax-2/src/main/java/com/baeldung/core/nativekeyword/DateTimeUtils.java similarity index 78% rename from core-java-modules/core-java-lang/src/main/java/com/baeldung/nativekeyword/DateTimeUtils.java rename to core-java-modules/core-java-lang-syntax-2/src/main/java/com/baeldung/core/nativekeyword/DateTimeUtils.java index 0762b0eb8a..1d101719ca 100644 --- a/core-java-modules/core-java-lang/src/main/java/com/baeldung/nativekeyword/DateTimeUtils.java +++ b/core-java-modules/core-java-lang-syntax-2/src/main/java/com/baeldung/core/nativekeyword/DateTimeUtils.java @@ -1,4 +1,4 @@ -package com.baeldung.nativekeyword; +package com.baeldung.core.nativekeyword; public class DateTimeUtils { diff --git a/core-java-modules/core-java-lang/src/main/java/com/baeldung/nativekeyword/NativeMainApp.java b/core-java-modules/core-java-lang-syntax-2/src/main/java/com/baeldung/core/nativekeyword/NativeMainApp.java similarity index 74% rename from core-java-modules/core-java-lang/src/main/java/com/baeldung/nativekeyword/NativeMainApp.java rename to core-java-modules/core-java-lang-syntax-2/src/main/java/com/baeldung/core/nativekeyword/NativeMainApp.java index 76fe548ed3..4bf6b88840 100644 --- a/core-java-modules/core-java-lang/src/main/java/com/baeldung/nativekeyword/NativeMainApp.java +++ b/core-java-modules/core-java-lang-syntax-2/src/main/java/com/baeldung/core/nativekeyword/NativeMainApp.java @@ -1,6 +1,4 @@ -package com.baeldung.nativekeyword; - -import com.baeldung.nativekeyword.DateTimeUtils; +package com.baeldung.core.nativekeyword; public class NativeMainApp { public static void main(String[] args) { diff --git a/core-java-modules/core-java-lang/src/main/java/com/baeldung/packages/TodoApp.java b/core-java-modules/core-java-lang-syntax-2/src/main/java/com/baeldung/core/packages/TodoApp.java similarity index 86% rename from core-java-modules/core-java-lang/src/main/java/com/baeldung/packages/TodoApp.java rename to core-java-modules/core-java-lang-syntax-2/src/main/java/com/baeldung/core/packages/TodoApp.java index 0f4a56f708..d8283f6b0d 100644 --- a/core-java-modules/core-java-lang/src/main/java/com/baeldung/packages/TodoApp.java +++ b/core-java-modules/core-java-lang-syntax-2/src/main/java/com/baeldung/core/packages/TodoApp.java @@ -1,9 +1,9 @@ -package com.baeldung.packages; +package com.baeldung.core.packages; + +import com.baeldung.core.packages.domain.TodoItem; import java.time.LocalDate; -import com.baeldung.packages.domain.TodoItem; - public class TodoApp { public static void main(String[] args) { diff --git a/core-java-modules/core-java-lang/src/main/java/com/baeldung/packages/TodoList.java b/core-java-modules/core-java-lang-syntax-2/src/main/java/com/baeldung/core/packages/TodoList.java similarity index 84% rename from core-java-modules/core-java-lang/src/main/java/com/baeldung/packages/TodoList.java rename to core-java-modules/core-java-lang-syntax-2/src/main/java/com/baeldung/core/packages/TodoList.java index 6ed6cd4ec1..f9f6ac3aca 100644 --- a/core-java-modules/core-java-lang/src/main/java/com/baeldung/packages/TodoList.java +++ b/core-java-modules/core-java-lang-syntax-2/src/main/java/com/baeldung/core/packages/TodoList.java @@ -1,10 +1,10 @@ -package com.baeldung.packages; +package com.baeldung.core.packages; + +import com.baeldung.core.packages.domain.TodoItem; import java.util.ArrayList; import java.util.List; -import com.baeldung.packages.domain.TodoItem; - public class TodoList { private List todoItems; diff --git a/core-java-modules/core-java-lang/src/main/java/com/baeldung/packages/domain/TodoItem.java b/core-java-modules/core-java-lang-syntax-2/src/main/java/com/baeldung/core/packages/domain/TodoItem.java similarity index 94% rename from core-java-modules/core-java-lang/src/main/java/com/baeldung/packages/domain/TodoItem.java rename to core-java-modules/core-java-lang-syntax-2/src/main/java/com/baeldung/core/packages/domain/TodoItem.java index 972e574a7f..195f763974 100644 --- a/core-java-modules/core-java-lang/src/main/java/com/baeldung/packages/domain/TodoItem.java +++ b/core-java-modules/core-java-lang-syntax-2/src/main/java/com/baeldung/core/packages/domain/TodoItem.java @@ -1,4 +1,4 @@ -package com.baeldung.packages.domain; +package com.baeldung.core.packages.domain; import java.time.LocalDate; diff --git a/core-java-modules/core-java-lang-syntax-2/src/main/java/com/baeldung/core/modifiers/Employee.java b/core-java-modules/core-java-lang-syntax-2/src/main/java/com/baeldung/core/privatemodifier/Employee.java similarity index 96% rename from core-java-modules/core-java-lang-syntax-2/src/main/java/com/baeldung/core/modifiers/Employee.java rename to core-java-modules/core-java-lang-syntax-2/src/main/java/com/baeldung/core/privatemodifier/Employee.java index 6ec68d6ebb..4598400e93 100644 --- a/core-java-modules/core-java-lang-syntax-2/src/main/java/com/baeldung/core/modifiers/Employee.java +++ b/core-java-modules/core-java-lang-syntax-2/src/main/java/com/baeldung/core/privatemodifier/Employee.java @@ -1,4 +1,4 @@ -package com.baeldung.core.modifiers; +package com.baeldung.core.privatemodifier; public class Employee { diff --git a/core-java-modules/core-java-lang-syntax-2/src/main/java/com/baeldung/core/modifiers/ExampleClass.java b/core-java-modules/core-java-lang-syntax-2/src/main/java/com/baeldung/core/privatemodifier/ExampleClass.java similarity index 84% rename from core-java-modules/core-java-lang-syntax-2/src/main/java/com/baeldung/core/modifiers/ExampleClass.java rename to core-java-modules/core-java-lang-syntax-2/src/main/java/com/baeldung/core/privatemodifier/ExampleClass.java index 41f0b7a690..8659b4ad9c 100644 --- a/core-java-modules/core-java-lang-syntax-2/src/main/java/com/baeldung/core/modifiers/ExampleClass.java +++ b/core-java-modules/core-java-lang-syntax-2/src/main/java/com/baeldung/core/privatemodifier/ExampleClass.java @@ -1,4 +1,4 @@ -package com.baeldung.core.modifiers; +package com.baeldung.core.privatemodifier; public class ExampleClass { diff --git a/core-java-modules/core-java-lang-syntax-2/src/main/java/com/baeldung/core/modifiers/PublicOuterClass.java b/core-java-modules/core-java-lang-syntax-2/src/main/java/com/baeldung/core/privatemodifier/PublicOuterClass.java similarity index 90% rename from core-java-modules/core-java-lang-syntax-2/src/main/java/com/baeldung/core/modifiers/PublicOuterClass.java rename to core-java-modules/core-java-lang-syntax-2/src/main/java/com/baeldung/core/privatemodifier/PublicOuterClass.java index 329ebf3bb6..8a9e8a8eb3 100644 --- a/core-java-modules/core-java-lang-syntax-2/src/main/java/com/baeldung/core/modifiers/PublicOuterClass.java +++ b/core-java-modules/core-java-lang-syntax-2/src/main/java/com/baeldung/core/privatemodifier/PublicOuterClass.java @@ -1,4 +1,4 @@ -package com.baeldung.core.modifiers; +package com.baeldung.core.privatemodifier; public class PublicOuterClass { diff --git a/core-java-modules/core-java-lang/src/main/java/com/baeldung/scope/BracketScopeExample.java b/core-java-modules/core-java-lang-syntax-2/src/main/java/com/baeldung/core/scope/BracketScopeExample.java similarity index 89% rename from core-java-modules/core-java-lang/src/main/java/com/baeldung/scope/BracketScopeExample.java rename to core-java-modules/core-java-lang-syntax-2/src/main/java/com/baeldung/core/scope/BracketScopeExample.java index 8deec35c16..99feeb060d 100644 --- a/core-java-modules/core-java-lang/src/main/java/com/baeldung/scope/BracketScopeExample.java +++ b/core-java-modules/core-java-lang-syntax-2/src/main/java/com/baeldung/core/scope/BracketScopeExample.java @@ -1,4 +1,4 @@ -package com.baeldung.scope; +package com.baeldung.core.scope; public class BracketScopeExample { diff --git a/core-java-modules/core-java-lang/src/main/java/com/baeldung/scope/ClassScopeExample.java b/core-java-modules/core-java-lang-syntax-2/src/main/java/com/baeldung/core/scope/ClassScopeExample.java similarity index 86% rename from core-java-modules/core-java-lang/src/main/java/com/baeldung/scope/ClassScopeExample.java rename to core-java-modules/core-java-lang-syntax-2/src/main/java/com/baeldung/core/scope/ClassScopeExample.java index c81fcc9550..8bcfee44f2 100644 --- a/core-java-modules/core-java-lang/src/main/java/com/baeldung/scope/ClassScopeExample.java +++ b/core-java-modules/core-java-lang-syntax-2/src/main/java/com/baeldung/core/scope/ClassScopeExample.java @@ -1,4 +1,4 @@ -package com.baeldung.scope; +package com.baeldung.core.scope; public class ClassScopeExample { diff --git a/core-java-modules/core-java-lang/src/main/java/com/baeldung/scope/LoopScopeExample.java b/core-java-modules/core-java-lang-syntax-2/src/main/java/com/baeldung/core/scope/LoopScopeExample.java similarity index 92% rename from core-java-modules/core-java-lang/src/main/java/com/baeldung/scope/LoopScopeExample.java rename to core-java-modules/core-java-lang-syntax-2/src/main/java/com/baeldung/core/scope/LoopScopeExample.java index be41252623..8067085404 100644 --- a/core-java-modules/core-java-lang/src/main/java/com/baeldung/scope/LoopScopeExample.java +++ b/core-java-modules/core-java-lang-syntax-2/src/main/java/com/baeldung/core/scope/LoopScopeExample.java @@ -1,4 +1,4 @@ -package com.baeldung.scope; +package com.baeldung.core.scope; import java.util.Arrays; import java.util.List; diff --git a/core-java-modules/core-java-lang/src/main/java/com/baeldung/scope/MethodScopeExample.java b/core-java-modules/core-java-lang-syntax-2/src/main/java/com/baeldung/core/scope/MethodScopeExample.java similarity index 87% rename from core-java-modules/core-java-lang/src/main/java/com/baeldung/scope/MethodScopeExample.java rename to core-java-modules/core-java-lang-syntax-2/src/main/java/com/baeldung/core/scope/MethodScopeExample.java index 63a6a25271..86b2021c6d 100644 --- a/core-java-modules/core-java-lang/src/main/java/com/baeldung/scope/MethodScopeExample.java +++ b/core-java-modules/core-java-lang-syntax-2/src/main/java/com/baeldung/core/scope/MethodScopeExample.java @@ -1,4 +1,4 @@ -package com.baeldung.scope; +package com.baeldung.core.scope; public class MethodScopeExample { diff --git a/core-java-modules/core-java-lang/src/main/java/com/baeldung/scope/NestedScopesExample.java b/core-java-modules/core-java-lang-syntax-2/src/main/java/com/baeldung/core/scope/NestedScopesExample.java similarity index 86% rename from core-java-modules/core-java-lang/src/main/java/com/baeldung/scope/NestedScopesExample.java rename to core-java-modules/core-java-lang-syntax-2/src/main/java/com/baeldung/core/scope/NestedScopesExample.java index c3c5bec221..51351d237c 100644 --- a/core-java-modules/core-java-lang/src/main/java/com/baeldung/scope/NestedScopesExample.java +++ b/core-java-modules/core-java-lang-syntax-2/src/main/java/com/baeldung/core/scope/NestedScopesExample.java @@ -1,4 +1,4 @@ -package com.baeldung.scope; +package com.baeldung.core.scope; public class NestedScopesExample { diff --git a/core-java-modules/core-java-lang-operators/src/test/java/com/baeldung/java/doublebrace/DoubleBraceUnitTest.java b/core-java-modules/core-java-lang-syntax-2/src/test/java/com/baeldung/core/doublebrace/DoubleBraceUnitTest.java similarity index 96% rename from core-java-modules/core-java-lang-operators/src/test/java/com/baeldung/java/doublebrace/DoubleBraceUnitTest.java rename to core-java-modules/core-java-lang-syntax-2/src/test/java/com/baeldung/core/doublebrace/DoubleBraceUnitTest.java index b03b01d074..fe47dd4c26 100644 --- a/core-java-modules/core-java-lang-operators/src/test/java/com/baeldung/java/doublebrace/DoubleBraceUnitTest.java +++ b/core-java-modules/core-java-lang-syntax-2/src/test/java/com/baeldung/core/doublebrace/DoubleBraceUnitTest.java @@ -1,4 +1,4 @@ -package com.baeldung.java.doublebrace; +package com.baeldung.core.doublebrace; import org.junit.Test; diff --git a/core-java-modules/core-java-lang/src/test/java/com/baeldung/nativekeyword/DateTimeUtilsManualTest.java b/core-java-modules/core-java-lang-syntax-2/src/test/java/com/baeldung/core/nativekeyword/DateTimeUtilsManualTest.java similarity index 95% rename from core-java-modules/core-java-lang/src/test/java/com/baeldung/nativekeyword/DateTimeUtilsManualTest.java rename to core-java-modules/core-java-lang-syntax-2/src/test/java/com/baeldung/core/nativekeyword/DateTimeUtilsManualTest.java index ac27c11c68..1c70acc483 100644 --- a/core-java-modules/core-java-lang/src/test/java/com/baeldung/nativekeyword/DateTimeUtilsManualTest.java +++ b/core-java-modules/core-java-lang-syntax-2/src/test/java/com/baeldung/core/nativekeyword/DateTimeUtilsManualTest.java @@ -1,11 +1,11 @@ -package com.baeldung.nativekeyword; - -import static org.junit.Assert.assertNotNull; +package com.baeldung.core.nativekeyword; import org.junit.BeforeClass; import org.junit.Test; import org.slf4j.Logger; +import static org.junit.Assert.assertNotNull; + public class DateTimeUtilsManualTest { private static final Logger LOG = org.slf4j.LoggerFactory.getLogger(DateTimeUtilsManualTest.class); diff --git a/core-java-modules/core-java-lang/src/test/java/com/baeldung/packages/PackagesUnitTest.java b/core-java-modules/core-java-lang-syntax-2/src/test/java/com/baeldung/core/packages/PackagesUnitTest.java similarity index 85% rename from core-java-modules/core-java-lang/src/test/java/com/baeldung/packages/PackagesUnitTest.java rename to core-java-modules/core-java-lang-syntax-2/src/test/java/com/baeldung/core/packages/PackagesUnitTest.java index 212fb7b3c7..b1237e9948 100644 --- a/core-java-modules/core-java-lang/src/test/java/com/baeldung/packages/PackagesUnitTest.java +++ b/core-java-modules/core-java-lang-syntax-2/src/test/java/com/baeldung/core/packages/PackagesUnitTest.java @@ -1,12 +1,11 @@ -package com.baeldung.packages; +package com.baeldung.core.packages; -import static org.junit.Assert.assertEquals; +import com.baeldung.core.packages.domain.TodoItem; +import org.junit.Test; import java.time.LocalDate; -import org.junit.Test; - -import com.baeldung.packages.domain.TodoItem; +import static org.junit.Assert.assertEquals; public class PackagesUnitTest { diff --git a/core-java-modules/core-java-lang-syntax/README.md b/core-java-modules/core-java-lang-syntax/README.md index 6f3120ec2c..25f5c63dbc 100644 --- a/core-java-modules/core-java-lang-syntax/README.md +++ b/core-java-modules/core-java-lang-syntax/README.md @@ -3,20 +3,14 @@ This module contains articles about Java syntax ### Relevant Articles: -- [The Basics of Java Generics](http://www.baeldung.com/java-generics) -- [Java Primitive Conversions](http://www.baeldung.com/java-primitive-conversions) -- [Java Double Brace Initialization](http://www.baeldung.com/java-double-brace-initialization) -- [Guide to the Diamond Operator in Java](http://www.baeldung.com/java-diamond-operator) -- [The Java continue and break Keywords](http://www.baeldung.com/java-continue-and-break) -- [A Guide to Creating Objects in Java](http://www.baeldung.com/java-initialization) -- [A Guide to Java Loops](http://www.baeldung.com/java-loops) -- [Varargs in Java](http://www.baeldung.com/java-varargs) -- [A Guide to Java Enums](http://www.baeldung.com/a-guide-to-java-enums) -- [Infinite Loops in Java](http://www.baeldung.com/infinite-loops-java) -- [Quick Guide to java.lang.System](http://www.baeldung.com/java-lang-system) +- [The Basics of Java Generics](https://www.baeldung.com/java-generics) +- [Java Primitive Conversions](https://www.baeldung.com/java-primitive-conversions) +- [The Java continue and break Keywords](https://www.baeldung.com/java-continue-and-break) +- [A Guide to Creating Objects in Java](https://www.baeldung.com/java-initialization) +- [A Guide to Java Loops](https://www.baeldung.com/java-loops) +- [Varargs in Java](https://www.baeldung.com/java-varargs) +- [A Guide to Java Enums](https://www.baeldung.com/a-guide-to-java-enums) +- [Infinite Loops in Java](https://www.baeldung.com/infinite-loops-java) - [Java Switch Statement](https://www.baeldung.com/java-switch) -- [The Modulo Operator in Java](https://www.baeldung.com/modulo-java) -- [Ternary Operator In Java](https://www.baeldung.com/java-ternary-operator) -- [Java instanceof Operator](https://www.baeldung.com/java-instanceof) - [Breaking Out of Nested Loops](https://www.baeldung.com/java-breaking-out-nested-loop) - [[More -->]](/core-java-modules/core-java-lang-syntax-2) diff --git a/core-java-modules/core-java-lang-syntax/src/test/java/com/baeldung/loops/WhenUsingLoops.java b/core-java-modules/core-java-lang-syntax/src/test/java/com/baeldung/loops/LoopsUnitTest.java similarity index 98% rename from core-java-modules/core-java-lang-syntax/src/test/java/com/baeldung/loops/WhenUsingLoops.java rename to core-java-modules/core-java-lang-syntax/src/test/java/com/baeldung/loops/LoopsUnitTest.java index f82f9ddaa7..5a8b116a2c 100644 --- a/core-java-modules/core-java-lang-syntax/src/test/java/com/baeldung/loops/WhenUsingLoops.java +++ b/core-java-modules/core-java-lang-syntax/src/test/java/com/baeldung/loops/LoopsUnitTest.java @@ -12,7 +12,7 @@ import org.junit.Assert; import org.junit.BeforeClass; import org.junit.Test; -public class WhenUsingLoops { +public class LoopsUnitTest { private LoopsInJava loops = new LoopsInJava(); private static List list = new ArrayList<>(); diff --git a/core-java-modules/core-java-lang/README.md b/core-java-modules/core-java-lang/README.md index 4b211177d9..3c33409e7e 100644 --- a/core-java-modules/core-java-lang/README.md +++ b/core-java-modules/core-java-lang/README.md @@ -6,29 +6,19 @@ This module contains articles about core features in the Java language - [Generate equals() and hashCode() with Eclipse](https://www.baeldung.com/java-eclipse-equals-and-hashcode) - [Iterating Over Enum Values in Java](https://www.baeldung.com/java-enum-iteration) -- [Java Double Brace Initialization](https://www.baeldung.com/java-double-brace-initialization) -- [Guide to the Diamond Operator in Java](https://www.baeldung.com/java-diamond-operator) - [Comparator and Comparable in Java](https://www.baeldung.com/java-comparator-comparable) -- [The Java continue and break Keywords](https://www.baeldung.com/java-continue-and-break) - [Nested Classes in Java](https://www.baeldung.com/java-nested-classes) - [A Guide to Inner Interfaces in Java](https://www.baeldung.com/java-inner-interfaces) - [Recursion In Java](https://www.baeldung.com/java-recursion) - [A Guide to the finalize Method in Java](https://www.baeldung.com/java-finalize) -- [Infinite Loops in Java](https://www.baeldung.com/infinite-loops-java) - [Quick Guide to java.lang.System](https://www.baeldung.com/java-lang-system) - [Using Java Assertions](https://www.baeldung.com/java-assert) - [Static and Dynamic Binding in Java](https://www.baeldung.com/java-static-dynamic-binding) - [Synthetic Constructs in Java](https://www.baeldung.com/java-synthetic) - [How to Separate Double into Integer and Decimal Parts](https://www.baeldung.com/java-separate-double-into-integer-decimal-parts) - [Retrieving a Class Name in Java](https://www.baeldung.com/java-class-name) -- [Java Compound Operators](https://www.baeldung.com/java-compound-operators) -- [Guide to Java Packages](https://www.baeldung.com/java-packages) -- [The Java Native Keyword and Methods](https://www.baeldung.com/java-native) -- [If-Else Statement in Java](https://www.baeldung.com/java-if-else) -- [Control Structures in Java](https://www.baeldung.com/java-control-structures) - [Java Interfaces](https://www.baeldung.com/java-interfaces) - [Attaching Values to Java Enum](https://www.baeldung.com/java-enum-values) -- [Variable Scope in Java](https://www.baeldung.com/java-variable-scope) - [Java Classes and Objects](https://www.baeldung.com/java-classes-objects) - [A Guide to Java Enums](https://www.baeldung.com/a-guide-to-java-enums) - [[More --> ]](/core-java-modules/core-java-lang-2) \ No newline at end of file diff --git a/core-java-modules/core-java-lang-syntax/src/main/java/com/baeldung/system/ChatWindow.java b/core-java-modules/core-java-lang/src/main/java/com/baeldung/system/ChatWindow.java similarity index 100% rename from core-java-modules/core-java-lang-syntax/src/main/java/com/baeldung/system/ChatWindow.java rename to core-java-modules/core-java-lang/src/main/java/com/baeldung/system/ChatWindow.java diff --git a/core-java-modules/core-java-lang-syntax/src/main/java/com/baeldung/system/DateTimeService.java b/core-java-modules/core-java-lang/src/main/java/com/baeldung/system/DateTimeService.java similarity index 100% rename from core-java-modules/core-java-lang-syntax/src/main/java/com/baeldung/system/DateTimeService.java rename to core-java-modules/core-java-lang/src/main/java/com/baeldung/system/DateTimeService.java diff --git a/core-java-modules/core-java-lang-syntax/src/main/java/com/baeldung/system/EnvironmentVariables.java b/core-java-modules/core-java-lang/src/main/java/com/baeldung/system/EnvironmentVariables.java similarity index 100% rename from core-java-modules/core-java-lang-syntax/src/main/java/com/baeldung/system/EnvironmentVariables.java rename to core-java-modules/core-java-lang/src/main/java/com/baeldung/system/EnvironmentVariables.java diff --git a/core-java-modules/core-java-lang-syntax/src/main/java/com/baeldung/system/SystemErrDemo.java b/core-java-modules/core-java-lang/src/main/java/com/baeldung/system/SystemErrDemo.java similarity index 100% rename from core-java-modules/core-java-lang-syntax/src/main/java/com/baeldung/system/SystemErrDemo.java rename to core-java-modules/core-java-lang/src/main/java/com/baeldung/system/SystemErrDemo.java diff --git a/core-java-modules/core-java-lang-syntax/src/main/java/com/baeldung/system/SystemExitDemo.java b/core-java-modules/core-java-lang/src/main/java/com/baeldung/system/SystemExitDemo.java similarity index 100% rename from core-java-modules/core-java-lang-syntax/src/main/java/com/baeldung/system/SystemExitDemo.java rename to core-java-modules/core-java-lang/src/main/java/com/baeldung/system/SystemExitDemo.java diff --git a/core-java-modules/core-java-lang-syntax/src/main/java/com/baeldung/system/SystemOutDemo.java b/core-java-modules/core-java-lang/src/main/java/com/baeldung/system/SystemOutDemo.java similarity index 100% rename from core-java-modules/core-java-lang-syntax/src/main/java/com/baeldung/system/SystemOutDemo.java rename to core-java-modules/core-java-lang/src/main/java/com/baeldung/system/SystemOutDemo.java diff --git a/core-java-modules/core-java-lang-syntax/src/main/java/com/baeldung/system/UserCredentials.java b/core-java-modules/core-java-lang/src/main/java/com/baeldung/system/UserCredentials.java similarity index 100% rename from core-java-modules/core-java-lang-syntax/src/main/java/com/baeldung/system/UserCredentials.java rename to core-java-modules/core-java-lang/src/main/java/com/baeldung/system/UserCredentials.java diff --git a/core-java-modules/core-java-lang-syntax/src/test/java/com/baeldung/system/DateTimeServiceUnitTest.java b/core-java-modules/core-java-lang/src/test/java/com/baeldung/system/DateTimeServiceUnitTest.java similarity index 100% rename from core-java-modules/core-java-lang-syntax/src/test/java/com/baeldung/system/DateTimeServiceUnitTest.java rename to core-java-modules/core-java-lang/src/test/java/com/baeldung/system/DateTimeServiceUnitTest.java diff --git a/core-java-modules/core-java-lang-syntax/src/test/java/com/baeldung/system/EnvironmentVariablesUnitTest.java b/core-java-modules/core-java-lang/src/test/java/com/baeldung/system/EnvironmentVariablesUnitTest.java similarity index 100% rename from core-java-modules/core-java-lang-syntax/src/test/java/com/baeldung/system/EnvironmentVariablesUnitTest.java rename to core-java-modules/core-java-lang/src/test/java/com/baeldung/system/EnvironmentVariablesUnitTest.java diff --git a/core-java-modules/core-java-lang-syntax/src/test/java/com/baeldung/system/SystemArrayCopyUnitTest.java b/core-java-modules/core-java-lang/src/test/java/com/baeldung/system/SystemArrayCopyUnitTest.java similarity index 100% rename from core-java-modules/core-java-lang-syntax/src/test/java/com/baeldung/system/SystemArrayCopyUnitTest.java rename to core-java-modules/core-java-lang/src/test/java/com/baeldung/system/SystemArrayCopyUnitTest.java diff --git a/core-java-modules/core-java-lang-syntax/src/test/java/com/baeldung/system/SystemNanoUnitTest.java b/core-java-modules/core-java-lang/src/test/java/com/baeldung/system/SystemNanoUnitTest.java similarity index 100% rename from core-java-modules/core-java-lang-syntax/src/test/java/com/baeldung/system/SystemNanoUnitTest.java rename to core-java-modules/core-java-lang/src/test/java/com/baeldung/system/SystemNanoUnitTest.java diff --git a/core-java-modules/core-java-lang-syntax/src/test/java/com/baeldung/system/SystemPropertiesUnitTest.java b/core-java-modules/core-java-lang/src/test/java/com/baeldung/system/SystemPropertiesUnitTest.java similarity index 100% rename from core-java-modules/core-java-lang-syntax/src/test/java/com/baeldung/system/SystemPropertiesUnitTest.java rename to core-java-modules/core-java-lang/src/test/java/com/baeldung/system/SystemPropertiesUnitTest.java