Sub OkHttpTimeout
Dim connTimeOut As Long = 5000
Dim readTimeOut As Long = 2000
Dim callTimeOut As Long = 2000
Dim jo As JavaObject = HttpUtils2Service.hc
Dim builder As JavaObject = jo.RunMethod("sharedInit", Array("hc"))
Dim TimeUnit As JavaObject
TimeUnit.InitializeStatic("java.util.concurrent.TimeUnit")
Dim Milliseconds As JavaObject = TimeUnit.GetField("MILLISECONDS")
builder.RunMethod("connectTimeout", Array(connTimeOut, Milliseconds))
builder.RunMethod("readTimeout", Array(readTimeOut, Milliseconds))
builder.RunMethod("callTimeout", Array(callTimeOut, Milliseconds))
jo.SetField("client", builder.RunMethod("build", Null))
End Sub