/libcore/benchmarks/src/benchmarks/regression/ |
D | URLConnectionBenchmark.java | 42 private MockResponse response; field in URLConnectionBenchmark.SingleResponseDispatcher 43 SingleResponseDispatcher(MockResponse response) { in SingleResponseDispatcher() argument 44 this.response = response; in SingleResponseDispatcher() 47 return response; in dispatch() 55 MockResponse response = new MockResponse(); in setUp() local 56 responseHeaders.apply(response); in setUp() 57 transferEncoding.setBody(response, bodySize, chunkSize); in setUp() 60 server.setDispatcher(new SingleResponseDispatcher(response)); in setUp() 95 void setBody(MockResponse response, int bodySize, int chunkSize) throws IOException { in setBody() argument 97 response.setBody(new byte[bodySize]); in setBody() [all …]
|
/libcore/ojluni/src/main/java/sun/security/provider/certpath/ |
D | OCSP.java | 217 byte[] response = null; in check() 247 response = new byte[contentLength > 2048 ? 2048 : contentLength]; in check() 250 int count = in.read(response, total, response.length - total); in check() 255 if (total >= response.length && total < contentLength) { in check() 256 response = Arrays.copyOf(response, total * 2); in check() 259 response = Arrays.copyOf(response, total); in check() 283 ocspResponse = new OCSPResponse(response); in check()
|
D | RevocationChecker.java | 682 OCSPResponse response = null; 700 response = new OCSPResponse(responseBytes); 709 response.verify(Collections.singletonList(certId), issuerCert, 722 response = OCSP.check(Collections.singletonList(certId), 733 (RevocationStatus)response.getSingleResponse(certId); 740 response.getSignerCertificate().getSubjectX500Principal(),
|
/libcore/ojluni/src/test/java/net/Socks/ |
D | SocksIPv6Test.java | 69 private String response = "Hello."; field in SocksIPv6Test 94 server.enqueue(new MockResponse().setResponseCode(200).setBody(response)); in setUp() 156 assertEquals(actual, response); in testSocksOverIPv6() 189 assertEquals(actual, response); in testSocksOverIPv6Hostname()
|
/libcore/luni/src/test/java/org/apache/harmony/luni/tests/internal/net/www/protocol/https/ |
D | HttpsURLConnectionTest.java | 852 MockResponse response = new MockResponse(); in dispatch() local 853 response.setResponseCode(AUTHENTICATION_REQUIRED_CODE); in dispatch() 854 response.addHeader("Proxy-authenticate: Basic realm=\"localhost\""); in dispatch() 855 log("Authentication required. Sending response: " + response); in dispatch() 856 return response; in dispatch() 887 MockResponse response = new MockResponse(); in dispatch() local 888 response.setResponseCode(200); in dispatch() 889 response.setSocketPolicy(SocketPolicy.UPGRADE_TO_SSL_AT_END); in dispatch() 890 return response; in dispatch() 932 MockResponse response = new MockResponse(); in dispatch() local [all …]
|
/libcore/ojluni/src/main/java/sun/net/ftp/impl/ |
D | FtpClient.java | 380 String response = getLastResponseString(); in getTransferSize() local 384 Matcher m = transPat.matcher(response); in getTransferSize() 398 String response = getLastResponseString(); in getTransferName() local 399 int i = response.indexOf("unique file name:"); in getTransferName() 400 int e = response.lastIndexOf(')'); in getTransferName() 403 lastFileName = response.substring(i, e); in getTransferName() 416 String response; in readServerResponse() local 431 response = replyBuf.toString(); in readServerResponse() 434 logger.finest("Server [" + serverAddr + "] --> " + response); in readServerResponse() 437 if (response.length() == 0) { in readServerResponse() [all …]
|
/libcore/luni/src/test/java/libcore/java/net/ |
D | URLConnectionTest.java | 363 MockResponse response = new MockResponse().setChunkedBody("ABCDE\nFGHIJ\nKLMNO\nPQR", 8); in bug2939() local 365 server.enqueue(response); in bug2939() 366 server.enqueue(response); in bug2939() 381 MockResponse response = new MockResponse().setBody("ABCDEFGHIJKLMNOPQR"); in connectionsArePooled() local 383 server.enqueue(response); in connectionsArePooled() 384 server.enqueue(response); in connectionsArePooled() 385 server.enqueue(response); in connectionsArePooled() 397 MockResponse response = new MockResponse().setChunkedBody("ABCDEFGHIJKLMNOPQR", 5); in chunkedConnectionsArePooled() local 399 server.enqueue(response); in chunkedConnectionsArePooled() 400 server.enqueue(response); in chunkedConnectionsArePooled() [all …]
|
/libcore/luni/src/test/java/libcore/android/system/ |
D | OsTest.java | 215 byte[] response = s.toUpperCase(Locale.ROOT).getBytes(StandardCharsets.UTF_8); in checkUnixDomainSocket() 216 Os.write(clientFd, response, 0, response.length); in checkUnixDomainSocket() 236 byte[] response = new byte[request.length]; in checkUnixDomainSocket() 237 assertEquals(response.length, Os.read(clientFd, response, 0, response.length)); in checkUnixDomainSocket() 239 assertEquals(string.toUpperCase(Locale.ROOT), new String(response, StandardCharsets.UTF_8)); in checkUnixDomainSocket() 776 final String response = new String(responseBuf, StandardCharsets.UTF_8); 778 assertEquals(request.toUpperCase(Locale.ROOT), response);
|