Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit 9aee12a

Browse files
author
evitwilly
committed
added count sort algorithm, edited some comments in different files, added Kotlin variant for Command pattern
1 parent 3725759 commit 9aee12a

File tree

18 files changed

+106
-3
lines changed

18 files changed

+106
-3
lines changed
0 Bytes
Binary file not shown.
0 Bytes
Binary file not shown.

‎.gradle/7.1/fileHashes/fileHashes.bin

700 Bytes
Binary file not shown.

‎.gradle/7.1/fileHashes/fileHashes.lock

0 Bytes
Binary file not shown.
0 Bytes
Binary file not shown.

‎src/main/kotlin/design_patterns/Builder.kt

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,8 @@ package design_patterns
1010

1111

1212
/**
13-
* first variant
13+
*
14+
* The first variant
1415
*
1516
*/
1617

@@ -62,7 +63,8 @@ class Pony1 {
6263

6364
/**
6465
*
65-
* the second variant
66+
* The second variant
67+
*
6668
*/
6769

6870
class Pony2 {
@@ -106,6 +108,7 @@ class Pony2 {
106108
/**
107109
*
108110
* Kotlin variant with default arguments
111+
*
109112
*/
110113

111114
class Pony3(

‎src/main/kotlin/design_patterns/Command.kt

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,8 @@ package design_patterns
44
* pattern: Command
55
*
66
* description: it's a behavioral pattern that allows you to wrap requests or simple operations in separate objects.
7+
*
8+
* P.S. Kotlin variant of this pattern is shown in tests
79
*/
810

911
interface ArithmeticCommand {

‎src/main/kotlin/design_patterns/Decorator.kt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@ package design_patterns
77
*
88
* description: classes implement a common interface and to extend the functionality of the previous object,
99
* the old object is passed through the constructor
10+
*
1011
*/
1112

1213
interface MyPrinter {

‎src/main/kotlin/design_patterns/Dependency Injection.kt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@ package design_patterns
66
* using: used when we have classes that depend on others
77
*
88
* description: all dependencies (classes that ours depends on) are passed through the constructor
9+
*
910
*/
1011

1112
class NewsApiService {

‎src/main/kotlin/design_patterns/Facade.kt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@ package design_patterns
66
* using: used to simplify access to an object with a complex implementation
77
*
88
* description: a complex object contains several dependencies within itself, which it combines with each other
9+
*
910
*/
1011

1112

0 commit comments

Comments
(0)

AltStyle によって変換されたページ (->オリジナル) /