22
22
* OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
23
23
* THE SOFTWARE.
24
24
*/
25
- /*
26
- * This project is licensed under the MIT license. Module model-view-viewmodel is using ZK framework licensed under LGPL (see lgpl-3.0.txt).
27
- *
28
- * The MIT License
29
- * Copyright © 2014-2022 Ilkka Seppälä
30
- *
31
- * Permission is hereby granted, free of charge, to any person obtaining a copy
32
- * of this software and associated documentation files (the "Software"), to deal
33
- * in the Software without restriction, including without limitation the rights
34
- * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
35
- * copies of the Software, and to permit persons to whom the Software is
36
- * furnished to do so, subject to the following conditions:
37
- *
38
- * The above copyright notice and this permission notice shall be included in
39
- * all copies or substantial portions of the Software.
40
- *
41
- * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
42
- * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
43
- * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
44
- * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
45
- * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
46
- * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
47
- * THE SOFTWARE.
48
- */
49
25
package com .iluwatar .currying ;
50
26
51
27
import java .time .LocalDate ;
52
28
53
29
/**
54
30
* This is a Javadoc comment to pass the style check.
55
31
*/
56
-
57
32
public class App {
58
33
/**
59
34
* This is a Javadoc comment to pass the style check.
@@ -69,13 +44,9 @@ public static void main(String[] args) {
69
44
Book .AddTitle kingHorrorBooksFunc = horrorBookFunc .withAuthor ("Stephen King" );
70
45
Book .AddTitle rowlingFantasyBooksFunc = fantasyBookFunc .withAuthor ("J.K. Rowling" );
71
46
72
- // Creates horror books by Stephen King
47
+ // Creates books by Stephen King (horror and fantasy genres)
73
48
Book shining = kingHorrorBooksFunc .withTitle ("The Shining" )
74
49
.withPublicationDate (LocalDate .of (1977 , 1 , 28 ));
75
- Book it = kingHorrorBooksFunc .withTitle ("It" )
76
- .withPublicationDate (LocalDate .of (1986 , 9 , 15 ));
77
-
78
- // Creates fantasy books by Stephen King
79
50
Book darkTower = kingFantasyBooksFunc .withTitle ("The Dark Tower: Gunslinger" )
80
51
.withPublicationDate (LocalDate .of (1982 , 6 , 10 ));
81
52
@@ -91,10 +62,14 @@ public static void main(String[] args) {
91
62
.withTitle ("Foundation" )
92
63
.withPublicationDate (LocalDate .of (1942 , 5 , 1 ));
93
64
65
+ System .out .println ("Stephen King Books:" );
94
66
System .out .println (shining );
95
- System .out .println (it );
96
67
System .out .println (darkTower );
68
+
69
+ System .out .println ("J.K. Rowling Books:" );
97
70
System .out .println (chamberOfSecrets );
71
+
72
+ System .out .println ("Sci-fi Books:" );
98
73
System .out .println (dune );
99
74
System .out .println (foundation );
100
75
}
0 commit comments