You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@hc.apache.org by gg...@apache.org on 2018/08/13 23:59:42 UTC
httpcomponents-core git commit: Pull up setter method to the class
where the ivar is actually defined.
Repository: httpcomponents-core
Updated Branches:
refs/heads/4.4.x a6536f2c3 -> 6f1cb1226
Pull up setter method to the class where the ivar is actually defined.
Project: http://git-wip-us.apache.org/repos/asf/httpcomponents-core/repo
Commit: http://git-wip-us.apache.org/repos/asf/httpcomponents-core/commit/6f1cb122
Tree: http://git-wip-us.apache.org/repos/asf/httpcomponents-core/tree/6f1cb122
Diff: http://git-wip-us.apache.org/repos/asf/httpcomponents-core/diff/6f1cb122
Branch: refs/heads/4.4.x
Commit: 6f1cb1226b1aedb49d0d48b29f8a74c007595a1d
Parents: a6536f2
Author: Gary Gregory <ga...@gmail.com>
Authored: Mon Aug 13 17:59:38 2018 -0600
Committer: Gary Gregory <ga...@gmail.com>
Committed: Mon Aug 13 17:59:38 2018 -0600
----------------------------------------------------------------------
.../http/impl/nio/codecs/AbstractContentDecoder.java | 14 ++++++++++++++
.../apache/http/impl/nio/codecs/IdentityDecoder.java | 11 -----------
2 files changed, 14 insertions(+), 11 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/httpcomponents-core/blob/6f1cb122/httpcore-nio/src/main/java/org/apache/http/impl/nio/codecs/AbstractContentDecoder.java
----------------------------------------------------------------------
diff --git a/httpcore-nio/src/main/java/org/apache/http/impl/nio/codecs/AbstractContentDecoder.java b/httpcore-nio/src/main/java/org/apache/http/impl/nio/codecs/AbstractContentDecoder.java
index 3d65ace..0fcbd2c 100644
--- a/httpcore-nio/src/main/java/org/apache/http/impl/nio/codecs/AbstractContentDecoder.java
+++ b/httpcore-nio/src/main/java/org/apache/http/impl/nio/codecs/AbstractContentDecoder.java
@@ -77,6 +77,20 @@ public abstract class AbstractContentDecoder implements ContentDecoder {
}
/**
+ * Sets the completed status of this decoder. Normally this is not necessary
+ * (the decoder will automatically complete when the underlying channel
+ * returns EOF). It is useful to mark the decoder as completed if you have
+ * some other means to know all the necessary data has been read and want to
+ * reuse the underlying connection for more messages.
+ *
+ * @param completed the completed status of this decoder.
+ * @since 4.4.11
+ */
+ public void setCompleted(final boolean completed) {
+ this.completed = completed;
+ }
+
+ /**
* Reads from the channel to the destination.
*
* @param dst destination.
http://git-wip-us.apache.org/repos/asf/httpcomponents-core/blob/6f1cb122/httpcore-nio/src/main/java/org/apache/http/impl/nio/codecs/IdentityDecoder.java
----------------------------------------------------------------------
diff --git a/httpcore-nio/src/main/java/org/apache/http/impl/nio/codecs/IdentityDecoder.java b/httpcore-nio/src/main/java/org/apache/http/impl/nio/codecs/IdentityDecoder.java
index fe9311b..fddd480 100644
--- a/httpcore-nio/src/main/java/org/apache/http/impl/nio/codecs/IdentityDecoder.java
+++ b/httpcore-nio/src/main/java/org/apache/http/impl/nio/codecs/IdentityDecoder.java
@@ -59,17 +59,6 @@ public class IdentityDecoder extends AbstractContentDecoder
super(channel, buffer, metrics);
}
- /**
- * Sets the completed status of this decoder. Normally this is not necessary
- * (the decoder will automatically complete when the underlying channel
- * returns EOF). It is useful to mark the decoder as completed if you have
- * some other means to know all the necessary data has been read and want to
- * reuse the underlying connection for more messages.
- */
- public void setCompleted(final boolean completed) {
- this.completed = completed;
- }
-
@Override
public int read(final ByteBuffer dst) throws IOException {
Args.notNull(dst, "Byte buffer");