public final class okhttp3.internal.http.CallServerInterceptor implements okhttp3.Interceptor
minor version: 0
major version: 59
flags: flags: (0x0031) ACC_PUBLIC, ACC_FINAL, ACC_SUPER
this_class: okhttp3.internal.http.CallServerInterceptor
super_class: java.lang.Object
{
private final boolean forWebSocket;
descriptor: Z
flags: (0x0012) ACC_PRIVATE, ACC_FINAL
public void <init>(boolean);
descriptor: (Z)V
flags: (0x0001) ACC_PUBLIC
Code:
stack=2, locals=2, args_size=2
start local 0 // okhttp3.internal.http.CallServerInterceptor this
start local 1 // boolean forWebSocket
0: .line 36
aload 0 /* this */
invokespecial java.lang.Object.<init>:()V
1: .line 37
aload 0 /* this */
iload 1 /* forWebSocket */
putfield okhttp3.internal.http.CallServerInterceptor.forWebSocket:Z
2: .line 38
return
end local 1 // boolean forWebSocket
end local 0 // okhttp3.internal.http.CallServerInterceptor this
LocalVariableTable:
Start End Slot Name Signature
0 3 0 this Lokhttp3/internal/http/CallServerInterceptor;
0 3 1 forWebSocket Z
MethodParameters:
Name Flags
forWebSocket
public okhttp3.Response intercept(okhttp3.Interceptor$Chain);
descriptor: (Lokhttp3/Interceptor$Chain;)Lokhttp3/Response;
flags: (0x0001) ACC_PUBLIC
Code:
stack=6, locals=14, args_size=2
start local 0 // okhttp3.internal.http.CallServerInterceptor this
start local 1 // okhttp3.Interceptor$Chain chain
0: .line 41
aload 1 /* chain */
checkcast okhttp3.internal.http.RealInterceptorChain
astore 2 /* realChain */
start local 2 // okhttp3.internal.http.RealInterceptorChain realChain
1: .line 42
aload 2 /* realChain */
invokevirtual okhttp3.internal.http.RealInterceptorChain.httpStream:()Lokhttp3/internal/http/HttpCodec;
astore 3 /* httpCodec */
start local 3 // okhttp3.internal.http.HttpCodec httpCodec
2: .line 43
aload 2 /* realChain */
invokevirtual okhttp3.internal.http.RealInterceptorChain.streamAllocation:()Lokhttp3/internal/connection/StreamAllocation;
astore 4 /* streamAllocation */
start local 4 // okhttp3.internal.connection.StreamAllocation streamAllocation
3: .line 44
aload 2 /* realChain */
invokevirtual okhttp3.internal.http.RealInterceptorChain.connection:()Lokhttp3/Connection;
checkcast okhttp3.internal.connection.RealConnection
astore 5 /* connection */
start local 5 // okhttp3.internal.connection.RealConnection connection
4: .line 45
aload 2 /* realChain */
invokevirtual okhttp3.internal.http.RealInterceptorChain.request:()Lokhttp3/Request;
astore 6 /* request */
start local 6 // okhttp3.Request request
5: .line 47
invokestatic java.lang.System.currentTimeMillis:()J
lstore 7 /* sentRequestMillis */
start local 7 // long sentRequestMillis
6: .line 49
aload 2 /* realChain */
invokevirtual okhttp3.internal.http.RealInterceptorChain.eventListener:()Lokhttp3/EventListener;
aload 2 /* realChain */
invokevirtual okhttp3.internal.http.RealInterceptorChain.call:()Lokhttp3/Call;
invokevirtual okhttp3.EventListener.requestHeadersStart:(Lokhttp3/Call;)V
7: .line 50
aload 3 /* httpCodec */
aload 6 /* request */
invokeinterface okhttp3.internal.http.HttpCodec.writeRequestHeaders:(Lokhttp3/Request;)V
8: .line 51
aload 2 /* realChain */
invokevirtual okhttp3.internal.http.RealInterceptorChain.eventListener:()Lokhttp3/EventListener;
aload 2 /* realChain */
invokevirtual okhttp3.internal.http.RealInterceptorChain.call:()Lokhttp3/Call;
aload 6 /* request */
invokevirtual okhttp3.EventListener.requestHeadersEnd:(Lokhttp3/Call;Lokhttp3/Request;)V
9: .line 53
aconst_null
astore 9 /* responseBuilder */
start local 9 // okhttp3.Response$Builder responseBuilder
10: .line 54
aload 6 /* request */
invokevirtual okhttp3.Request.method:()Ljava/lang/String;
invokestatic okhttp3.internal.http.HttpMethod.permitsRequestBody:(Ljava/lang/String;)Z
ifeq 28
aload 6 /* request */
invokevirtual okhttp3.Request.body:()Lokhttp3/RequestBody;
ifnull 28
11: .line 58
ldc "100-continue"
aload 6 /* request */
ldc "Expect"
invokevirtual okhttp3.Request.header:(Ljava/lang/String;)Ljava/lang/String;
invokevirtual java.lang.String.equalsIgnoreCase:(Ljava/lang/String;)Z
ifeq 15
12: .line 59
aload 3 /* httpCodec */
invokeinterface okhttp3.internal.http.HttpCodec.flushRequest:()V
13: .line 60
aload 2 /* realChain */
invokevirtual okhttp3.internal.http.RealInterceptorChain.eventListener:()Lokhttp3/EventListener;
aload 2 /* realChain */
invokevirtual okhttp3.internal.http.RealInterceptorChain.call:()Lokhttp3/Call;
invokevirtual okhttp3.EventListener.responseHeadersStart:(Lokhttp3/Call;)V
14: .line 61
aload 3 /* httpCodec */
iconst_1
invokeinterface okhttp3.internal.http.HttpCodec.readResponseHeaders:(Z)Lokhttp3/Response$Builder;
astore 9 /* responseBuilder */
15: .line 64
StackMap locals: okhttp3.internal.http.CallServerInterceptor okhttp3.Interceptor$Chain okhttp3.internal.http.RealInterceptorChain okhttp3.internal.http.HttpCodec okhttp3.internal.connection.StreamAllocation okhttp3.internal.connection.RealConnection okhttp3.Request long okhttp3.Response$Builder
StackMap stack:
aload 9 /* responseBuilder */
ifnonnull 26
16: .line 66
aload 2 /* realChain */
invokevirtual okhttp3.internal.http.RealInterceptorChain.eventListener:()Lokhttp3/EventListener;
aload 2 /* realChain */
invokevirtual okhttp3.internal.http.RealInterceptorChain.call:()Lokhttp3/Call;
invokevirtual okhttp3.EventListener.requestBodyStart:(Lokhttp3/Call;)V
17: .line 67
aload 6 /* request */
invokevirtual okhttp3.Request.body:()Lokhttp3/RequestBody;
invokevirtual okhttp3.RequestBody.contentLength:()J
lstore 10 /* contentLength */
start local 10 // long contentLength
18: .line 69
new okhttp3.internal.http.CallServerInterceptor$CountingSink
dup
aload 3 /* httpCodec */
aload 6 /* request */
lload 10 /* contentLength */
invokeinterface okhttp3.internal.http.HttpCodec.createRequestBody:(Lokhttp3/Request;J)Lokio/Sink;
invokespecial okhttp3.internal.http.CallServerInterceptor$CountingSink.<init>:(Lokio/Sink;)V
19: .line 68
astore 12 /* requestBodyOut */
start local 12 // okhttp3.internal.http.CallServerInterceptor$CountingSink requestBodyOut
20: .line 70
aload 12 /* requestBodyOut */
invokestatic okio.Okio.buffer:(Lokio/Sink;)Lokio/BufferedSink;
astore 13 /* bufferedRequestBody */
start local 13 // okio.BufferedSink bufferedRequestBody
21: .line 72
aload 6 /* request */
invokevirtual okhttp3.Request.body:()Lokhttp3/RequestBody;
aload 13 /* bufferedRequestBody */
invokevirtual okhttp3.RequestBody.writeTo:(Lokio/BufferedSink;)V
22: .line 73
aload 13 /* bufferedRequestBody */
invokeinterface okio.BufferedSink.close:()V
23: .line 74
aload 2 /* realChain */
invokevirtual okhttp3.internal.http.RealInterceptorChain.eventListener:()Lokhttp3/EventListener;
24: .line 75
aload 2 /* realChain */
invokevirtual okhttp3.internal.http.RealInterceptorChain.call:()Lokhttp3/Call;
aload 12 /* requestBodyOut */
getfield okhttp3.internal.http.CallServerInterceptor$CountingSink.successfulCount:J
invokevirtual okhttp3.EventListener.requestBodyEnd:(Lokhttp3/Call;J)V
end local 13 // okio.BufferedSink bufferedRequestBody
end local 12 // okhttp3.internal.http.CallServerInterceptor$CountingSink requestBodyOut
end local 10 // long contentLength
25: .line 76
goto 28
StackMap locals:
StackMap stack:
26: aload 5 /* connection */
invokevirtual okhttp3.internal.connection.RealConnection.isMultiplexed:()Z
ifne 28
27: .line 80
aload 4 /* streamAllocation */
invokevirtual okhttp3.internal.connection.StreamAllocation.noNewStreams:()V
28: .line 84
StackMap locals:
StackMap stack:
aload 3 /* httpCodec */
invokeinterface okhttp3.internal.http.HttpCodec.finishRequest:()V
29: .line 86
aload 9 /* responseBuilder */
ifnonnull 32
30: .line 87
aload 2 /* realChain */
invokevirtual okhttp3.internal.http.RealInterceptorChain.eventListener:()Lokhttp3/EventListener;
aload 2 /* realChain */
invokevirtual okhttp3.internal.http.RealInterceptorChain.call:()Lokhttp3/Call;
invokevirtual okhttp3.EventListener.responseHeadersStart:(Lokhttp3/Call;)V
31: .line 88
aload 3 /* httpCodec */
iconst_0
invokeinterface okhttp3.internal.http.HttpCodec.readResponseHeaders:(Z)Lokhttp3/Response$Builder;
astore 9 /* responseBuilder */
32: .line 91
StackMap locals:
StackMap stack:
aload 9 /* responseBuilder */
33: .line 92
aload 6 /* request */
invokevirtual okhttp3.Response$Builder.request:(Lokhttp3/Request;)Lokhttp3/Response$Builder;
34: .line 93
aload 4 /* streamAllocation */
invokevirtual okhttp3.internal.connection.StreamAllocation.connection:()Lokhttp3/internal/connection/RealConnection;
invokevirtual okhttp3.internal.connection.RealConnection.handshake:()Lokhttp3/Handshake;
invokevirtual okhttp3.Response$Builder.handshake:(Lokhttp3/Handshake;)Lokhttp3/Response$Builder;
35: .line 94
lload 7 /* sentRequestMillis */
invokevirtual okhttp3.Response$Builder.sentRequestAtMillis:(J)Lokhttp3/Response$Builder;
36: .line 95
invokestatic java.lang.System.currentTimeMillis:()J
invokevirtual okhttp3.Response$Builder.receivedResponseAtMillis:(J)Lokhttp3/Response$Builder;
37: .line 96
invokevirtual okhttp3.Response$Builder.build:()Lokhttp3/Response;
38: .line 91
astore 10 /* response */
start local 10 // okhttp3.Response response
39: .line 98
aload 10 /* response */
invokevirtual okhttp3.Response.code:()I
istore 11 /* code */
start local 11 // int code
40: .line 99
iload 11 /* code */
bipush 100
if_icmpne 50
41: .line 102
aload 3 /* httpCodec */
iconst_0
invokeinterface okhttp3.internal.http.HttpCodec.readResponseHeaders:(Z)Lokhttp3/Response$Builder;
astore 9 /* responseBuilder */
42: .line 104
aload 9 /* responseBuilder */
43: .line 105
aload 6 /* request */
invokevirtual okhttp3.Response$Builder.request:(Lokhttp3/Request;)Lokhttp3/Response$Builder;
44: .line 106
aload 4 /* streamAllocation */
invokevirtual okhttp3.internal.connection.StreamAllocation.connection:()Lokhttp3/internal/connection/RealConnection;
invokevirtual okhttp3.internal.connection.RealConnection.handshake:()Lokhttp3/Handshake;
invokevirtual okhttp3.Response$Builder.handshake:(Lokhttp3/Handshake;)Lokhttp3/Response$Builder;
45: .line 107
lload 7 /* sentRequestMillis */
invokevirtual okhttp3.Response$Builder.sentRequestAtMillis:(J)Lokhttp3/Response$Builder;
46: .line 108
invokestatic java.lang.System.currentTimeMillis:()J
invokevirtual okhttp3.Response$Builder.receivedResponseAtMillis:(J)Lokhttp3/Response$Builder;
47: .line 109
invokevirtual okhttp3.Response$Builder.build:()Lokhttp3/Response;
48: .line 104
astore 10 /* response */
49: .line 111
aload 10 /* response */
invokevirtual okhttp3.Response.code:()I
istore 11 /* code */
50: .line 114
StackMap locals: okhttp3.Response int
StackMap stack:
aload 2 /* realChain */
invokevirtual okhttp3.internal.http.RealInterceptorChain.eventListener:()Lokhttp3/EventListener;
51: .line 115
aload 2 /* realChain */
invokevirtual okhttp3.internal.http.RealInterceptorChain.call:()Lokhttp3/Call;
aload 10 /* response */
invokevirtual okhttp3.EventListener.responseHeadersEnd:(Lokhttp3/Call;Lokhttp3/Response;)V
52: .line 117
aload 0 /* this */
getfield okhttp3.internal.http.CallServerInterceptor.forWebSocket:Z
ifeq 58
iload 11 /* code */
bipush 101
if_icmpne 58
53: .line 119
aload 10 /* response */
invokevirtual okhttp3.Response.newBuilder:()Lokhttp3/Response$Builder;
54: .line 120
getstatic okhttp3.internal.Util.EMPTY_RESPONSE:Lokhttp3/ResponseBody;
invokevirtual okhttp3.Response$Builder.body:(Lokhttp3/ResponseBody;)Lokhttp3/Response$Builder;
55: .line 121
invokevirtual okhttp3.Response$Builder.build:()Lokhttp3/Response;
56: .line 119
astore 10 /* response */
57: .line 122
goto 62
58: .line 123
StackMap locals:
StackMap stack:
aload 10 /* response */
invokevirtual okhttp3.Response.newBuilder:()Lokhttp3/Response$Builder;
59: .line 124
aload 3 /* httpCodec */
aload 10 /* response */
invokeinterface okhttp3.internal.http.HttpCodec.openResponseBody:(Lokhttp3/Response;)Lokhttp3/ResponseBody;
invokevirtual okhttp3.Response$Builder.body:(Lokhttp3/ResponseBody;)Lokhttp3/Response$Builder;
60: .line 125
invokevirtual okhttp3.Response$Builder.build:()Lokhttp3/Response;
61: .line 123
astore 10 /* response */
62: .line 128
StackMap locals:
StackMap stack:
ldc "close"
aload 10 /* response */
invokevirtual okhttp3.Response.request:()Lokhttp3/Request;
ldc "Connection"
invokevirtual okhttp3.Request.header:(Ljava/lang/String;)Ljava/lang/String;
invokevirtual java.lang.String.equalsIgnoreCase:(Ljava/lang/String;)Z
ifne 64
63: .line 129
ldc "close"
aload 10 /* response */
ldc "Connection"
invokevirtual okhttp3.Response.header:(Ljava/lang/String;)Ljava/lang/String;
invokevirtual java.lang.String.equalsIgnoreCase:(Ljava/lang/String;)Z
ifeq 65
64: .line 130
StackMap locals:
StackMap stack:
aload 4 /* streamAllocation */
invokevirtual okhttp3.internal.connection.StreamAllocation.noNewStreams:()V
65: .line 133
StackMap locals:
StackMap stack:
iload 11 /* code */
sipush 204
if_icmpeq 66
iload 11 /* code */
sipush 205
if_icmpne 70
StackMap locals:
StackMap stack:
66: aload 10 /* response */
invokevirtual okhttp3.Response.body:()Lokhttp3/ResponseBody;
invokevirtual okhttp3.ResponseBody.contentLength:()J
lconst_0
lcmp
ifle 70
67: .line 134
new java.net.ProtocolException
dup
68: .line 135
new java.lang.StringBuilder
dup
ldc "HTTP "
invokespecial java.lang.StringBuilder.<init>:(Ljava/lang/String;)V
iload 11 /* code */
invokevirtual java.lang.StringBuilder.append:(I)Ljava/lang/StringBuilder;
ldc " had non-zero Content-Length: "
invokevirtual java.lang.StringBuilder.append:(Ljava/lang/String;)Ljava/lang/StringBuilder;
aload 10 /* response */
invokevirtual okhttp3.Response.body:()Lokhttp3/ResponseBody;
invokevirtual okhttp3.ResponseBody.contentLength:()J
invokevirtual java.lang.StringBuilder.append:(J)Ljava/lang/StringBuilder;
invokevirtual java.lang.StringBuilder.toString:()Ljava/lang/String;
69: .line 134
invokespecial java.net.ProtocolException.<init>:(Ljava/lang/String;)V
athrow
70: .line 138
StackMap locals:
StackMap stack:
aload 10 /* response */
areturn
end local 11 // int code
end local 10 // okhttp3.Response response
end local 9 // okhttp3.Response$Builder responseBuilder
end local 7 // long sentRequestMillis
end local 6 // okhttp3.Request request
end local 5 // okhttp3.internal.connection.RealConnection connection
end local 4 // okhttp3.internal.connection.StreamAllocation streamAllocation
end local 3 // okhttp3.internal.http.HttpCodec httpCodec
end local 2 // okhttp3.internal.http.RealInterceptorChain realChain
end local 1 // okhttp3.Interceptor$Chain chain
end local 0 // okhttp3.internal.http.CallServerInterceptor this
LocalVariableTable:
Start End Slot Name Signature
0 71 0 this Lokhttp3/internal/http/CallServerInterceptor;
0 71 1 chain Lokhttp3/Interceptor$Chain;
1 71 2 realChain Lokhttp3/internal/http/RealInterceptorChain;
2 71 3 httpCodec Lokhttp3/internal/http/HttpCodec;
3 71 4 streamAllocation Lokhttp3/internal/connection/StreamAllocation;
4 71 5 connection Lokhttp3/internal/connection/RealConnection;
5 71 6 request Lokhttp3/Request;
6 71 7 sentRequestMillis J
10 71 9 responseBuilder Lokhttp3/Response$Builder;
18 25 10 contentLength J
20 25 12 requestBodyOut Lokhttp3/internal/http/CallServerInterceptor$CountingSink;
21 25 13 bufferedRequestBody Lokio/BufferedSink;
39 71 10 response Lokhttp3/Response;
40 71 11 code I
Exceptions:
throws java.io.IOException
MethodParameters:
Name Flags
chain
}
SourceFile: "CallServerInterceptor.java"
NestMembers:
okhttp3.internal.http.CallServerInterceptor$CountingSink
InnerClasses:
public abstract Chain = okhttp3.Interceptor$Chain of okhttp3.Interceptor
public Builder = okhttp3.Response$Builder of okhttp3.Response
final CountingSink = okhttp3.internal.http.CallServerInterceptor$CountingSink of okhttp3.internal.http.CallServerInterceptor