Skip to content

Commit e6678f4

Browse files
committed
Make DataSize constants final
1 parent 30e1257 commit e6678f4

1 file changed

Lines changed: 5 additions & 5 deletions

File tree

  • spring-core/src/main/java/org/springframework/util/unit

spring-core/src/main/java/org/springframework/util/unit/DataSize.java

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright 2002-2018 the original author or authors.
2+
* Copyright 2002-2019 the original author or authors.
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.
@@ -41,22 +41,22 @@ public final class DataSize implements Comparable<DataSize> {
4141
/**
4242
* Bytes per Kilobyte.
4343
*/
44-
private static long BYTES_PER_KB = 1024;
44+
private static final long BYTES_PER_KB = 1024;
4545

4646
/**
4747
* Bytes per Megabyte.
4848
*/
49-
private static long BYTES_PER_MB = BYTES_PER_KB * 1024;
49+
private static final long BYTES_PER_MB = BYTES_PER_KB * 1024;
5050

5151
/**
5252
* Bytes per Gigabyte.
5353
*/
54-
private static long BYTES_PER_GB = BYTES_PER_MB * 1024;
54+
private static final long BYTES_PER_GB = BYTES_PER_MB * 1024;
5555

5656
/**
5757
* Bytes per Terabyte.
5858
*/
59-
private static long BYTES_PER_TB = BYTES_PER_GB * 1024;
59+
private static final long BYTES_PER_TB = BYTES_PER_GB * 1024;
6060

6161

6262
private final long bytes;

0 commit comments

Comments
 (0)