/libcore/dalvik/src/main/java/dalvik/system/ |
H A D | SocketTagger.java | 24 * Callbacks for socket assignment and reassignment. 37 * thread. The socket is either newly connected or reused from a connection 47 * <p><strong>Note:</strong> this method will not be invoked when the socket 52 public final void tag(Socket socket) throws SocketException { argument 53 if (!socket.isClosed()) { 54 tag(socket.getFileDescriptor$()); 58 public final void untag(Socket socket) throws SocketException { argument 59 if (!socket.isClosed()) { 60 untag(socket.getFileDescriptor$()); 65 * Sets this process' socket tagge [all...] |
/libcore/luni/src/main/java/java/nio/channels/ |
H A D | ServerSocketChannel.java | 29 * stream-oriented listening socket. Binding and manipulation of socket options 31 * by calling {@code socket()}. ServerSocketChannels can not be constructed for 32 * an already existing server-socket, nor can a {@link java.net.SocketImpl} be assigned. 34 * A server-socket channel is open but not bound when created by the {@code 51 * Creates an open and unbound server-socket channel. 65 * Gets the valid operations of this channel. Server-socket channels support 78 * Return the server-socket assigned this channel, which does not declare 81 * @return the server-socket assigned to this channel. 83 public abstract ServerSocket socket(); method in class:ServerSocketChannel [all...] |
H A D | DatagramChannel.java | 32 * abstraction of a datagram socket. The {@code socket} method of this class can 34 * socket. 86 * Returns the related datagram socket of this channel, which does not 92 public abstract DatagramSocket socket(); method in class:DatagramChannel 95 * Returns whether this channel's socket is connected or not. 97 * @return <code>true</code> if this channel's socket is connected; 103 * Connects the socket of this channel to a remote address, which is the 134 * Disconnects the socket of this channel, which has been connected before 139 * socket i [all...] |
H A D | SocketChannel.java | 30 * abstraction of stream connecting socket. 32 * The {@link #socket()} method returns a {@link Socket} instance which 33 * allows a wider range of socket operations than {@code SocketChannel} itself. 35 * <p>A socket channel is open but not connected when created by {@link #open}. 43 * trying to connect; {@link #isConnected} tests whether the socket connect 50 * on the socket returned by {@link #socket} 79 * Creates an open and unconnected socket channel. 93 * Creates a socket channel and connects it to a socket addres 142 public abstract Socket socket(); method in class:SocketChannel [all...] |
/libcore/harmony-tests/src/test/java/org/apache/harmony/tests/java/nio/channels/ |
H A D | MockServerSocketChannel.java | 33 public ServerSocket socket() { method in class:MockServerSocketChannel
|
H A D | UnixSelectorTest.java | 32 ServerSocket socket = null; field in class:UnixSelectorTest.Server 39 this.socket = serverChannel.socket(); 40 socket.bind(null); 80 boolean isConnected = socketChannel.connect(server.socket.getLocalSocketAddress());
|
H A D | MockSocketChannel.java | 34 public Socket socket() { method in class:MockSocketChannel
|
H A D | MockDatagramChannel.java | 34 public DatagramSocket socket() { method in class:MockDatagramChannel
|
H A D | ServerSocketChannelTest.java | 117 assertNull(ssc.socket().getLocalSocketAddress()); 119 ssc.socket().bind(null); 121 InetSocketAddress localAddress = (InetSocketAddress) ssc.socket().getLocalSocketAddress(); 131 portHog.socket().bind(null); 136 ssc.socket().bind(portHog.socket().getLocalSocketAddress()); 150 ssc.socket().bind(null); 161 portPickingChannel.socket().bind(null); 163 InetSocketAddress address = (InetSocketAddress) portPickingChannel.socket().getLocalSocketAddress(); 171 ssc.socket() 592 Socket socket; field in class:ServerSocketChannelTest.WriteSocketThread 596 WriteSocketThread(Socket socket, byte[] buffer) argument [all...] |
/libcore/luni/src/main/java/java/util/logging/ |
H A D | SocketHandler.java | 26 * A handler that writes log messages to a socket connection. 63 // the socket connection 64 private Socket socket; field in class:SocketHandler 103 // Initialize the socket connection and prepare the output stream 125 this.socket = new Socket(host, p); 131 super.internalSetOutputStream(new BufferedOutputStream(this.socket.getOutputStream())); 141 if (this.socket != null) { 142 this.socket.close(); 143 this.socket = null; 146 getErrorManager().error("Exception occurred when closing the socket handle [all...] |
/libcore/luni/src/main/java/javax/net/ssl/ |
H A D | X509KeyManager.java | 39 * @param socket 40 * the socket for the connection, or {@code null} if 41 * the alias selected does not depend on a specific socket. 46 Socket socket); 57 * @param socket 58 * the socket for the connection, or {@code null} if 59 * the alias selected does not depend on a specific socket. 64 Socket socket); 45 chooseClientAlias(String[] keyType, Principal[] issuers, Socket socket) argument 63 chooseServerAlias(String keyType, Principal[] issuers, Socket socket) argument
|
/libcore/luni/src/test/java/libcore/java/net/ |
H A D | OldAndroidDatagramTest.java | 42 DatagramSocket socket; field in class:OldAndroidDatagramTest.Reflector 59 socket.receive(packet); 74 socket.send(packet); 81 socket.close(); 91 socket = new DatagramSocket(port, address); 121 DatagramSocket socket = null; 131 socket = new DatagramSocket(2345, InetAddress.getLocalHost()); 141 socket.send(packet); 150 socket.receive(packet); 161 if (socket ! [all...] |
/libcore/luni/src/test/java/libcore/javax/net/ssl/ |
H A D | PSKKeyManagerProxy.java | 47 protected SecretKey getKey(String identityHint, String identity, Socket socket) { argument 57 protected String chooseServerKeyIdentityHint(Socket socket) { argument 67 protected String chooseClientKeyIdentity(String identityHint, Socket socket) { argument
|
/libcore/support/src/test/java/libcore/javax/net/ssl/ |
H A D | ForwardingX509ExtendedKeyManager.java | 38 public String chooseClientAlias(String[] keyType, Principal[] issuers, Socket socket) { argument 39 return delegate.chooseClientAlias(keyType, issuers, socket); 43 public String chooseServerAlias(String keyType, Principal[] issuers, Socket socket) { argument 44 return delegate.chooseServerAlias(keyType, issuers, socket);
|
H A D | TestKeyManager.java | 63 public String chooseClientAlias(String[] keyTypes, Principal[] issuers, Socket socket) { argument 71 dumpSocket(socket); 73 return dumpAlias(keyManager.chooseClientAlias(keyTypes, issuers, socket)); 88 public String chooseServerAlias(String keyType, Principal[] issuers, Socket socket) { argument 94 dumpSocket(socket); 96 return dumpAlias(keyManager.chooseServerAlias(keyType, issuers, socket)); 99 private void dumpSocket(Socket socket) { argument 100 out.print(" | socket: "); 101 out.print(String.valueOf(socket));
|
/libcore/support/src/test/java/org/apache/harmony/xnet/tests/support/ |
H A D | SSLSocketFactoryImpl.java | 17 public Socket createSocket(Socket socket, String s, int i, boolean flag) argument 19 if (socket == null) { 20 throw new IOException("incorrect socket"); 30 socket = new Socket(s, i); 32 socket = new Socket(s, i); 33 socket.close(); 35 return socket;
|
H A D | X509KeyManagerImpl.java | 140 public String chooseClientAlias(String[] as, Principal[] aprincipal, Socket socket) { argument 147 if (socket == null) { 184 public String chooseServerAlias(String as, Principal[] aprincipal, Socket socket) { argument 190 if (as.equals(server) && socket != null) {
|
/libcore/support/src/test/java/tests/util/ |
H A D | DelegatingSSLSocketFactory.java | 40 * Invoked after obtaining a socket from the delegate and before returning it to the caller. 44 protected void configureSocket(@SuppressWarnings("unused") SSLSocket socket) {} argument 58 SSLSocket socket = (SSLSocket) mDelegate.createSocket(); 59 configureSocket(socket); 60 return socket; 66 SSLSocket socket = (SSLSocket) mDelegate.createSocket(s, host, port, autoClose); 67 configureSocket(socket); 68 return socket; 73 SSLSocket socket = (SSLSocket) mDelegate.createSocket(host, port); 74 configureSocket(socket); [all...] |
/libcore/harmony-tests/src/test/java/org/apache/harmony/tests/javax/net/ssl/ |
H A D | X509ExtendedKeyManagerTest.java | 133 Socket socket) { 142 Socket socket) { 132 chooseClientAlias(String[] keyType, Principal[] issuers, Socket socket) argument 141 chooseServerAlias(String keyType, Principal[] issuers, Socket socket) argument
|
H A D | HandshakeCompletedEventTest.java | 75 SSLSocket socket = (SSLSocket) SSLSocketFactory.getDefault().createSocket(); 76 HandshakeCompletedEvent event = new HandshakeCompletedEvent(socket, session); 90 SSLSocket socket = (SSLSocket) SSLSocketFactory.getDefault().createSocket(); 91 HandshakeCompletedEvent event = new HandshakeCompletedEvent(socket, session); 101 SSLSocket socket = (SSLSocket) SSLSocketFactory.getDefault().createSocket(); 102 HandshakeCompletedEvent event = new HandshakeCompletedEvent(socket, session); 112 SSLSocket socket = (SSLSocket) SSLSocketFactory.getDefault().createSocket(); 113 HandshakeCompletedEvent event = new HandshakeCompletedEvent(socket, session); 124 SSLSocket socket = (SSLSocket) SSLSocketFactory.getDefault().createSocket(); 125 HandshakeCompletedEvent event = new HandshakeCompletedEvent(socket, sessio 202 private SSLSocket socket; field in class:HandshakeCompletedEventTest [all...] |
/libcore/luni/src/main/java/java/nio/ |
H A D | ServerSocketChannelImpl.java | 45 private final ServerSocketAdapter socket; field in class:ServerSocketChannelImpl 51 this.socket = new ServerSocketAdapter(this); 54 @Override public ServerSocket socket() { method in class:ServerSocketChannelImpl 55 return socket; 63 if (!socket.isBound()) { 67 // Create an empty socket channel. This will be populated by ServerSocketAdapter.implAccept. 73 socket.implAccept(result); 78 // Otherwise, this is a non-blocking socket and there's nothing ready, so we'll 102 IoUtils.setBlocking(socket.getFD$(), blocking); 107 if (!socket [all...] |
H A D | DatagramChannelImpl.java | 58 private DatagramSocket socket; field in class:DatagramChannelImpl 72 // whether the socket is bound 83 fd = IoBridge.socket(false); 97 * Getting the internal DatagramSocket If we have not the socket, we create 101 synchronized public DatagramSocket socket() { method in class:DatagramChannelImpl 102 if (socket == null) { 103 socket = new DatagramSocketAdapter(new PlainDatagramSocketImpl(fd, localPort), this); 105 return socket; 114 * if the associated socket (if present) needs to be updated 128 if (updateSocketState && socket ! [all...] |
/libcore/luni/src/main/java/libcore/io/ |
H A D | IoUtils.java | 75 * Closes 'socket', ignoring any exceptions. Does nothing if 'socket' is null. 77 public static void closeQuietly(Socket socket) { argument 78 if (socket != null) { 80 socket.close();
|
H A D | IoBridge.java | 105 * Connects socket 'fd' to 'inetAddress' on 'port', with no timeout. The lack of a timeout 117 * Connects socket 'fd' to 'inetAddress' on 'port', with a the given 'timeoutMs'. 142 // 1. set the socket to non-blocking, 146 // 4. set the socket back to blocking. 148 // 1. set the socket to non-blocking. 155 IoUtils.setBlocking(fd, true); // 4. set the socket back to blocking. 172 IoUtils.setBlocking(fd, true); // 4. set the socket back to blocking. 247 * java.net has its own socket options similar to the underlying Unix ones. We paper over the 301 throw new SocketException("Unknown socket option: " + option); 314 * java.net has its own socket option 601 public static FileDescriptor socket(boolean stream) throws SocketException { method in class:IoBridge [all...] |
/libcore/luni/src/test/java/libcore/java/nio/channels/ |
H A D | OldSocketChannelTest.java | 169 Socket gotSocket = this.channel1.socket(); 282 ssc.socket().bind(null, 0); 301 sc.connect(ssc.socket().getLocalSocketAddress()); 317 sc.connect(ssc.socket().getLocalSocketAddress()); 355 public Socket socket() { method in class:OldSocketChannelTest.MockSocketChannel
|