mirror of
https://github.com/tiennm99/java-design-patterns.git
synced 2026-10-13 06:15:36 +00:00
Adjust checkstyle rules. Make checkstyle fail the build when violations are found. Correct all current checkstyle violations.
This commit is contained in:
1 parent
9fbb085985
commit
cec9a99410
167 files changed
+1242
-969
No files matched your search
@@ -23,6 +23,9 @@ import java.util.Stack;
|
||||
*/
|
||||
public class App {
|
||||
|
||||
/**
|
||||
* Program entry point
|
||||
*/
|
||||
public static void main(String[] args) {
|
||||
Stack<StarMemento> states = new Stack<>();
|
||||
|
||||
|
||||
@@ -11,12 +11,18 @@ public class Star {
|
||||
private int ageYears;
|
||||
private int massTons;
|
||||
|
||||
/**
|
||||
* Constructor
|
||||
*/
|
||||
public Star(StarType startType, int startAge, int startMass) {
|
||||
this.type = startType;
|
||||
this.ageYears = startAge;
|
||||
this.massTons = startMass;
|
||||
}
|
||||
|
||||
/**
|
||||
* Makes time pass for the star
|
||||
*/
|
||||
public void timePasses() {
|
||||
ageYears *= 2;
|
||||
massTons *= 8;
|
||||
|
||||
Reference in new issue
Block a user