Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMykola Nikishov2018-11-03 18:28:40 -0400
committerAlexander Kurtakov2018-11-06 01:10:51 -0500
commit01e47a783fe110929107d78302c5b51b8d3fb9dd (patch)
tree2bd6e7bd6c0851adefb02803d8c2db209824b9d9
parent15a87510cc5744d65e0cc31b59cea479125f8429 (diff)
downloadrt.equinox.p2-01e47a783fe110929107d78302c5b51b8d3fb9dd.tar.gz
rt.equinox.p2-01e47a783fe110929107d78302c5b51b8d3fb9dd.tar.xz
rt.equinox.p2-01e47a783fe110929107d78302c5b51b8d3fb9dd.zip
Make MessageDigestProcessingStep's methods finalY20181107-2200I20181107-1800I20181107-0200I20181106-1800
Methods write(int) and close() of this internal non-API class are not meant to be modified by subclasses. Change-Id: I9253d0f5f4ec3b8fe14f5466e78146b40b3d212a Signed-off-by: Mykola Nikishov <mn@mn.com.ua>
-rw-r--r--bundles/org.eclipse.equinox.p2.artifact.repository/src/org/eclipse/equinox/internal/p2/artifact/processors/checksum/MessageDigestProcessingStep.java6
1 files changed, 2 insertions, 4 deletions
diff --git a/bundles/org.eclipse.equinox.p2.artifact.repository/src/org/eclipse/equinox/internal/p2/artifact/processors/checksum/MessageDigestProcessingStep.java b/bundles/org.eclipse.equinox.p2.artifact.repository/src/org/eclipse/equinox/internal/p2/artifact/processors/checksum/MessageDigestProcessingStep.java
index abf5a264e..ba25d4ff3 100644
--- a/bundles/org.eclipse.equinox.p2.artifact.repository/src/org/eclipse/equinox/internal/p2/artifact/processors/checksum/MessageDigestProcessingStep.java
+++ b/bundles/org.eclipse.equinox.p2.artifact.repository/src/org/eclipse/equinox/internal/p2/artifact/processors/checksum/MessageDigestProcessingStep.java
@@ -29,8 +29,7 @@ public abstract class MessageDigestProcessingStep extends ProcessingStep {
private ByteBuffer buffer = ByteBuffer.allocate(BUFFER_SIZE);
@Override
- // TODO template method, should be final but MD5Verifier prevents this
- public void write(int b) throws IOException {
+ final public void write(int b) throws IOException {
getDestination().write(b);
boolean isBufferFull = buffer.remaining() == 0;
@@ -52,8 +51,7 @@ public abstract class MessageDigestProcessingStep extends ProcessingStep {
}
@Override
- // TODO should be final but MD5Verifier prevents this
- public void close() throws IOException {
+ final public void close() throws IOException {
processBufferredBytes();
String digestString = digest();
onClose(digestString);

Back to the top