k1w1dev
ef42e169b9
fix: Fix sonar issues ( #2925 )
...
* Remove unused member which was also causing a false positive sonar issue.
Fixes sonar issue https://sonarcloud.io/project/issues?open=AY3gHwu5DIZTZkppqVEG&id=iluwatar_java-design-patterns
* Fixes sonar issue https://sonarcloud.io/project/issues?open=AXK0OzDA-CiGJS70dLki&id=iluwatar_java-design-patterns
related to "Refactor the code of the lambda to not have multiple invocations throwing the same checked exception."
Also, updated the code to use Instant and Duration to deal with time instead of int. Added the awaitility
library to perform assertions in test which is more reliable than using Thread.sleep directly to wait for events to happen.
* checkstyle fix
* Add sneaky throws to fix sonar lint issue. This is fine as the newFile method is not being tested but instead the new SimpleFileWriter(...) is.
* The first booking needs to happen outside the assertions. Fixed other warnings
* Use records to pass around related objects instead of using a large number of
individual params, which sonar did not like.
* Checkstyle fixes
* checkstyle fixes
* Remove complexity to keep sonar happy.
* Split into different methods to reduce complexity. Could be broken down even further but currently Sonar is happy.
* Move files to correct package
* Add valid assertions to tests
* rename constants to avoid confusion
* Sonar warning related to cognitive complexity can be suppressed as the methods are quite generic and not functional enough to be separated out.
* Use constants to keep Sonar happy
* Use correct constant naming conventions
* Use correct constant naming conventions
* Use lombok to define noargsconstructor
* Use a single method to do the logging
* Remove unused constructor and redundant method
* Use a reusable method for logging
2024-05-04 08:20:01 +03:00
Ilkka Seppälä
825d45b086
docs: double dispatch explanation + refactor ( #2915 )
2024-04-13 08:30:48 +03:00
Ilkka Seppälä
932836f68b
Update license plugin ( #2020 )
...
* update license plugin
* suppress linelength and emptylineseparator rules
* fix checkstyle error
Co-authored-by: Subhrodip Mohanta <hello@subho.xyz >
2022-09-14 23:22:24 +05:30
va1m
5cf2fe009b
📍 Use lombok, reformat, and optimize the code ( #1560 )
...
* Use lombok, reformat, and optimize the code
* Fix merge conflicts and some sonar issues
Co-authored-by: va1m <va1m@email.com >
2021-03-13 14:19:21 +02:00
Subhrodip Mohanta
7891c2b117
update inception year to 2021 ( #1653 )
2021-02-14 11:57:57 +02:00
Ilkka Seppälä
195a735814
#508 fix SpaceStationMir logging
2020-10-04 14:50:48 +03:00
Toxic Dreamz
31471acb69
Fixed most reported issues by SonarCloud.
2020-08-15 21:47:39 +04:00
Ilkka Seppälä
6a8297598e
#1047 remove module infos
2020-08-01 15:19:09 +03:00
Ilkka Seppälä
417f21ed3d
Code cleanup ( #1461 )
...
* Code cleanup
* Fix flux tests
* Fix checkstyle errors
* Fix compile error
2020-07-30 20:28:47 +03:00
saksham93
16ef70bfdc
Organisation of patterns into modules: ( #1187 )
...
1. Double DIspatch
2. EIP Message Channel
2020-03-07 11:50:51 +00:00
Anurag Agarwal
ea57934db6
Java 11 migrate c-d (remaining) ( #1111 )
...
* Moves converter pattern to Java 11
* Moves cqrs pattern to Java 11
* Moves dao pattern to Java 11
* Moves data-bus pattern to Java 11
* Moves data-locality pattern to Java 11
* Moves data-mapper pattern to Java 11
* Moves data-transfer-object pattern to Java 11
* Moves decorator pattern to Java 11
* Moves delegation pattern to Java 11
* Moves dependency-injection to Java 11
* Moves dirty-flag to Java 11
* Moves double-buffer to Java 11
* Moves double-checked-locking to Java 11
* Moves double-dispatch to Java 11
* Corrects with changes thats breaking test cases
2019-12-14 20:32:45 +02:00
Anurag Agarwal
f2c91eb836
Resolves checkstyle errors for delegation dependency-injection dirty-flag double-buffer double-checked-locking double-dispatch ( #1068 )
...
* Reduces checkstyle errors in delegation
* Reduces checkstyle errors in dependency-injection
* Reduces checkstyle errors in dirty-flag
* Reduces checkstyle errors in double-buffer
* Reduces checkstyle errors in double-checked-locking
* Reduces checkstyle errors in double-dispatch
2019-11-10 19:31:19 +02:00
Leon Mak
6bb3438965
Add java 11 ( #1049 )
2019-10-27 22:08:09 +02:00
Alexander Ivanov
4904d7eea0
#1021 : Fix checkstyle warnings by changing the license header template ( #1027 )
...
* Add custom license header style in order to comply with Google's Checkstyle format
* Update license headers to comply with Google's Checkstyle format
2019-10-22 08:15:35 +03:00
Ilkka Seppälä
9ebbc421dd
Update license headers
2019-10-12 20:05:54 +03:00
Ilkka Seppälä
a113de6a14
Add licenses
2019-07-28 16:24:14 +03:00
kanwarpreet25
c6ecf58687
508 : sonar qube critical issue fixes ( #852 )
...
* 508 : sonar qube critical issue fixes
* 508 : Sunar Qube Fixes
Define a constant instead of duplicating this literal "user_accounts" 4 times.
Define a constant instead of duplicating this literal "userID" 5 times
Define a constant instead of duplicating this literal "additionalInfo" 4 times.
Define a constant instead of duplicating this literal "userName" 4 times.
* 508 : Sunar Qube Fixes
Define a constant instead of duplicating this literal "user_accounts" 4 times.
* 508 : Sonar Qube Fixes
Define a constant instead of duplicating this literal "eEvans" 4 times
Define a constant instead of duplicating this literal "jBloch" 6 times
Define a constant instead of duplicating this literal "mFowler" 3 times
* 508 : Sonar Qube FIxes
Define a constant instead of duplicating this literal "username" 3 times.
* 508: sonar qube issue fixes
Define a constant instead of duplicating this literal "customerDao.getAllCustomers(): " 4 times.
* 508 : sonar qube issue fixes
Define a constant instead of duplicating this literal "App.main(), student : " 4 times.
* 508 : sonar Qube issue fixes
Define a constant instead of duplicating this literal "{} hits {}. {} is damaged!" 3 times.
Define a constant instead of duplicating this literal "{} hits {}." 4 times.
* 508 : Define a constant instead of duplicating this literal "{} hits {}." 4 times.
* 508 : checkstyle fixes
* 508: checkstyle fixes
* 508: checkstyle fixes
* 508: checkstyle fixes
* 508: checkstyle fixes
* 508: checkstyle fixes
* 508: cqrs checkstyle fixes
2019-07-28 15:39:40 +03:00
Artur Mogozov
6694d742a3
Migrate to JUnit5
2017-12-31 16:29:48 +09:00
Mudit Porwal
09585c3874
Removed AvoidStarImport Rule
...
Added JavaDocType Rule
2017-03-22 01:16:02 +08:00
Ilkka Seppälä
faa29f8025
Update license headers
2016-11-27 14:34:20 +02:00
daniel-bryla
e138163c4f
#502 Adjusted tests for logger introduction
2016-11-04 11:47:06 +01:00
daniel-bryla
0438811489
#502 Replaced usages of System.out with logger.
2016-10-23 19:59:03 +02:00
Joseph McCarthy
3d95696078
#358 Added license to all files using plugin
2016-01-27 22:20:42 +00:00
Ilkka Seppala
8b020837ea
Checkstyle corrections
2015-12-29 21:34:27 +02:00
Ilkka Seppala
5f033be54f
Fix PMD violations #327
2015-12-27 21:21:57 +02:00
Ilkka Seppala
cec9a99410
Adjust checkstyle rules. Make checkstyle fail the build when violations are found. Correct all current checkstyle violations.
2015-12-25 23:49:28 +02:00
Jeroen Meulemeester
c837ffe234
Add proper unit tests for double-dispatch pattern
2015-12-11 20:24:56 +01:00
Ankur Kaushal
306b1f3d31
Reformat rest of the design patterns - Issue #224
2015-11-01 21:29:13 -05:00
Ilkka Seppala
f2db01e546
#107 Double Dispatch example JavaDoc
2015-08-18 22:32:13 +03:00
Ilkka Seppala
8524c75ba6
Changed package naming across all examples.
2015-05-31 11:55:18 +03:00
Ilkka Seppala
1cdd338618
Commented the code.
2015-05-09 19:26:35 +03:00
Ilkka Seppala
082f4730ee
Double Dispatch example improvements.
2015-05-09 18:36:37 +03:00
Ilkka Seppala
648ead096c
Unit test for Rectangle
2015-05-08 22:57:14 +03:00
Ilkka Seppala
8c13dd0e10
Completed Double Dispatch example.
2015-05-08 21:49:04 +03:00
Ilkka Seppala
fba664ba49
Added iteration logic.
2015-05-08 21:01:06 +03:00
Ilkka Seppala
41b818771e
Added class hierarchies.
2015-05-08 20:35:47 +03:00
Ilkka Seppala
2029609def
Skeleton for Double Dispatch.
2015-05-08 19:55:58 +03:00