@Immutable public class DisallowIdentityContentLengthStrategy extends java.lang.Object implements ContentLengthStrategy
ContentLengthStrategy implementations that disallows the use of
identity transfer encoding.| 限定符和类型 | 字段和说明 |
|---|---|
static DisallowIdentityContentLengthStrategy |
INSTANCE |
CHUNKED, IDENTITY| 构造器和说明 |
|---|
DisallowIdentityContentLengthStrategy(ContentLengthStrategy contentLengthStrategy) |
| 限定符和类型 | 方法和说明 |
|---|---|
long |
determineLength(HttpMessage message)
Returns length of the given message in bytes.
|
public static final DisallowIdentityContentLengthStrategy INSTANCE
public DisallowIdentityContentLengthStrategy(ContentLengthStrategy contentLengthStrategy)
public long determineLength(HttpMessage message) throws HttpException
ContentLengthStrategyContentLengthStrategy.IDENTITY if the end of the
message will be delimited by the end of connection, or ContentLengthStrategy.CHUNKED
if the message is chunk codeddetermineLength 在接口中 ContentLengthStrategymessage - HTTP messageContentLengthStrategy.IDENTITY, or ContentLengthStrategy.CHUNKEDHttpException - in case of HTTP protocol violation