Bladeren bron

largest-series-product: make classes and methods package private #1052 (#1067)

* make classes and methods package private #1052

* method accessor changes
Saatvik Arya 8 jaren geleden
bovenliggende
commit
822636c7a1

+ 3
- 3
exercises/largest-series-product/.meta/src/reference/java/LargestSeriesProductCalculator.java Bestand weergeven

@@ -1,13 +1,13 @@
1
-public final class LargestSeriesProductCalculator {
1
+final class LargestSeriesProductCalculator {
2 2
 
3 3
     private final String stringToSearch;
4 4
 
5
-    public LargestSeriesProductCalculator(final String stringToSearch) throws IllegalArgumentException {
5
+    LargestSeriesProductCalculator(final String stringToSearch) throws IllegalArgumentException {
6 6
         this.stringToSearch = stringToSearch;
7 7
         validateStringToSearch();
8 8
     }
9 9
 
10
-    public long calculateLargestProductForSeriesLength(final int seriesLength) throws IllegalArgumentException {
10
+    long calculateLargestProductForSeriesLength(final int seriesLength) throws IllegalArgumentException {
11 11
         if (seriesLength < 0) {
12 12
             throw new IllegalArgumentException("Series length must be non-negative.");
13 13
         } else if (seriesLength == 0) {