Home
last modified time | relevance | path

Searched refs:socket (Results 1 – 25 of 66) sorted by relevance

123

/frameworks/opt/net/voip/src/jni/rtp/
DRtpStream.cpp48 int socket = ::socket(ss.ss_family, SOCK_DGRAM, 0); in create() local
50 if (socket == -1 || bind(socket, (sockaddr *)&ss, sizeof(ss)) != 0 || in create()
51 getsockname(socket, (sockaddr *)&ss, &len) != 0) { in create()
53 ::close(socket); in create()
61 env->SetIntField(thiz, gSocket, socket); in create()
64 ::close(socket); in create()
66 socket = ::socket(ss.ss_family, SOCK_DGRAM, 0); in create()
67 if (socket != -1) { in create()
77 if (bind(socket, (sockaddr *)&ss, sizeof(ss)) == 0) { in create()
78 env->SetIntField(thiz, gSocket, socket); in create()
[all …]
DAudioGroup.cpp101 bool set(int mode, int socket, sockaddr_storage *remote,
167 bool AudioStream::set(int mode, int socket, sockaddr_storage *remote, in set() argument
203 mSocket = socket; in set()
944 jint socket, jstring jRemoteAddress, jint remotePort, in add() argument
966 socket = dup(socket); in add()
967 if (socket == -1) { in add()
991 if (!stream->set(mode, socket, &remote, codec, sampleRate, sampleCount, in add()
997 socket = -1; in add()
1027 close(socket); in add()
/frameworks/support/v4/java/android/support/v4/net/
DTrafficStatsCompat.java36 void tagSocket(Socket socket) throws SocketException; in tagSocket() argument
37 void untagSocket(Socket socket) throws SocketException; in untagSocket() argument
76 public void tagSocket(Socket socket) { in tagSocket() argument
80 public void untagSocket(Socket socket) { in untagSocket() argument
111 public void tagSocket(Socket socket) throws SocketException { in tagSocket() argument
112 TrafficStatsCompatIcs.tagSocket(socket); in tagSocket()
116 public void untagSocket(Socket socket) throws SocketException { in untagSocket() argument
117 TrafficStatsCompatIcs.untagSocket(socket); in untagSocket()
193 public static void tagSocket(Socket socket) throws SocketException { in tagSocket() argument
194 IMPL.tagSocket(socket); in tagSocket()
[all …]
/frameworks/base/core/java/android/net/
DNetwork.java140 Socket socket = createSocket(); in connectToHost() local
141 if (localAddress != null) socket.bind(localAddress); in connectToHost()
142 socket.connect(new InetSocketAddress(hostAddresses[i], port)); in connectToHost()
143 return socket; in connectToHost()
159 Socket socket = createSocket(); in createSocket() local
160 socket.bind(new InetSocketAddress(localAddress, localPort)); in createSocket()
161 socket.connect(new InetSocketAddress(address, port)); in createSocket()
162 return socket; in createSocket()
167 Socket socket = createSocket(); in createSocket() local
168 socket.connect(new InetSocketAddress(host, port)); in createSocket()
[all …]
DSSLCertificateSocketFactory.java189 public static void verifyHostname(Socket socket, String hostname) throws IOException { in verifyHostname() argument
190 if (!(socket instanceof SSLSocket)) { in verifyHostname()
197 SSLSocket ssl = (SSLSocket) socket; in verifyHostname()
337 public byte[] getNpnSelectedProtocol(Socket socket) { in getNpnSelectedProtocol() argument
338 return castToOpenSSLSocket(socket).getNpnSelectedProtocol(); in getNpnSelectedProtocol()
351 public byte[] getAlpnSelectedProtocol(Socket socket) { in getAlpnSelectedProtocol() argument
352 return castToOpenSSLSocket(socket).getAlpnSelectedProtocol(); in getAlpnSelectedProtocol()
388 public void setUseSessionTickets(Socket socket, boolean useSessionTickets) { in setUseSessionTickets() argument
389 castToOpenSSLSocket(socket).setUseSessionTickets(useSessionTickets); in setUseSessionTickets()
400 public void setHostname(Socket socket, String hostName) { in setHostname() argument
[all …]
DSntpClient.java73 DatagramSocket socket = null; in requestTime() local
75 socket = new DatagramSocket(); in requestTime()
76 socket.setSoTimeout(timeout); in requestTime()
91 socket.send(request); in requestTime()
95 socket.receive(response); in requestTime()
125 if (socket != null) { in requestTime()
126 socket.close(); in requestTime()
DDnsPinger.java100 DatagramSocket socket; field in DnsPinger.ActivePing
148 newActivePing.socket = new DatagramSocket(); in handleMessage()
150 newActivePing.socket.setSoTimeout(SOCKET_TIMEOUT_MS); in handleMessage()
154 newActivePing.socket.setNetworkInterface(NetworkInterface.getByName( in handleMessage()
174 newActivePing.socket.send(packet); in handleMessage()
192 curPing.socket.receive(replyPacket); in handleMessage()
217 curPing.socket.close(); in handleMessage()
222 curPing.socket.close(); in handleMessage()
233 activePing.socket.close(); in handleMessage()
DPskKeyManager.java137 public String chooseServerKeyIdentityHint(Socket socket) { in chooseServerKeyIdentityHint() argument
168 public String chooseClientKeyIdentity(String identityHint, Socket socket) { in chooseClientKeyIdentity() argument
203 public SecretKey getKey(String identityHint, String identity, Socket socket) { in getKey() argument
DVpnService.java209 public boolean protect(int socket) { in protect() argument
210 return NetworkUtils.protectFromVpn(socket); in protect()
219 public boolean protect(Socket socket) { in protect() argument
220 return protect(socket.getFileDescriptor$().getInt$()); in protect()
230 public boolean protect(DatagramSocket socket) { in protect() argument
231 return protect(socket.getFileDescriptor$().getInt$()); in protect()
DTrafficStats.java198 public static void tagSocket(Socket socket) throws SocketException { in tagSocket() argument
199 SocketTagger.get().tag(socket); in tagSocket()
205 public static void untagSocket(Socket socket) throws SocketException { in untagSocket() argument
206 SocketTagger.get().untag(socket); in untagSocket()
/frameworks/support/v4/ics/android/support/v4/net/
DTrafficStatsCompatIcs.java48 public static void tagSocket(Socket socket) throws SocketException { in tagSocket() argument
49 TrafficStats.tagSocket(socket); in tagSocket()
52 public static void untagSocket(Socket socket) throws SocketException { in untagSocket() argument
53 TrafficStats.untagSocket(socket); in untagSocket()
/frameworks/base/core/java/android/bluetooth/
DBluetoothAdapter.java1513 BluetoothServerSocket socket = new BluetoothServerSocket( in listenUsingRfcommOn() local
1515 int errno = socket.mSocket.bindListen(); in listenUsingRfcommOn()
1517 socket.setChannel(socket.mSocket.getPort()); in listenUsingRfcommOn()
1525 return socket; in listenUsingRfcommOn()
1629 BluetoothServerSocket socket; in createNewRfcommSocketAndRecord() local
1630 socket = new BluetoothServerSocket(BluetoothSocket.TYPE_RFCOMM, auth, in createNewRfcommSocketAndRecord()
1632 socket.setServiceName(name); in createNewRfcommSocketAndRecord()
1633 int errno = socket.mSocket.bindListen(); in createNewRfcommSocketAndRecord()
1640 return socket; in createNewRfcommSocketAndRecord()
1652 BluetoothServerSocket socket = new BluetoothServerSocket( in listenUsingInsecureRfcommOn() local
[all …]
/frameworks/base/core/java/android/app/backup/
DBackupTransport.java400 public int performFullBackup(PackageInfo targetPackage, ParcelFileDescriptor socket) { in performFullBackup() argument
501 public int getNextFullRestoreDataChunk(ParcelFileDescriptor socket) { in getNextFullRestoreDataChunk() argument
622 …public int performFullBackup(PackageInfo targetPackage, ParcelFileDescriptor socket) throws Remote… in performFullBackup() argument
623 return BackupTransport.this.performFullBackup(targetPackage, socket); in performFullBackup()
642 public int getNextFullRestoreDataChunk(ParcelFileDescriptor socket) { in getNextFullRestoreDataChunk() argument
643 return BackupTransport.this.getNextFullRestoreDataChunk(socket); in getNextFullRestoreDataChunk()
/frameworks/base/packages/services/Proxy/src/com/android/proxyhandler/
DProxyServer.java240 private void sendLine(Socket socket, String line) throws IOException { in sendLine() argument
241 OutputStream os = socket.getOutputStream(); in sendLine()
254 private void skipToRequestBody(Socket socket) throws IOException { in skipToRequestBody() argument
255 while (getLine(socket.getInputStream()).length() != 0); in skipToRequestBody()
337 Socket socket = serverSocket.accept(); in run() local
339 if (socket.getInetAddress().isLoopbackAddress()) { in run()
340 ProxyConnection parser = new ProxyConnection(socket); in run()
344 socket.close(); in run()
/frameworks/base/tests/BandwidthTests/src/com/android/tests/bandwidthenforcement/
DBandwidthEnforcementTestService.java155 final DatagramSocket socket = new DatagramSocket(); in testDns() local
157 socket.setSoTimeout(10000); in testDns()
162 socket.send(queryPacket); in testDns()
166 socket.receive(replyPacket); in testDns()
170 socket.close(); in testDns()
/frameworks/base/services/core/java/com/android/server/
DNativeDaemonConnector.java80 NativeDaemonConnector(INativeDaemonConnectorCallbacks callbacks, String socket, in NativeDaemonConnector() argument
82 this(callbacks, socket, responseQueueSize, logTag, maxLogSize, wl, in NativeDaemonConnector()
86 NativeDaemonConnector(INativeDaemonConnectorCallbacks callbacks, String socket, in NativeDaemonConnector() argument
90 mSocket = socket; in NativeDaemonConnector()
154 LocalSocket socket = null; in listenToSocket() local
157 socket = new LocalSocket(); in listenToSocket()
160 socket.connect(address); in listenToSocket()
162 InputStream inputStream = socket.getInputStream(); in listenToSocket()
164 mOutputStream = socket.getOutputStream(); in listenToSocket()
254 if (socket != null) { in listenToSocket()
[all …]
/frameworks/native/opengl/libs/GLES_trace/src/
Dgltrace_transport.cpp35 int serverSocket = socket(AF_LOCAL, SOCK_STREAM, 0); in acceptClientConnection()
94 TCPStream::TCPStream(int socket) { in TCPStream() argument
95 mSocket = socket; in TCPStream()
/frameworks/base/core/java/com/android/internal/backup/
DIBackupTransport.aidl240 int performFullBackup(in PackageInfo targetPackage, in ParcelFileDescriptor socket); in performFullBackup() argument
276 int getNextFullRestoreDataChunk(in ParcelFileDescriptor socket); in getNextFullRestoreDataChunk() argument
/frameworks/opt/bluetooth/src/android/bluetooth/client/map/
DBluetoothMapRfcommTransport.java32 public BluetoothMapRfcommTransport(BluetoothSocket socket) { in BluetoothMapRfcommTransport() argument
34 mSocket = socket; in BluetoothMapRfcommTransport()
DBluetoothMasClient.java462 private BluetoothSocket socket = null; field in BluetoothMasClient.SocketConnectThread
471 socket = mDevice.createRfcommSocket(mMas.getRfcommCannelNumber()); in run()
472 socket.connect(); in run()
475 transport = new BluetoothMapRfcommTransport(socket); in run()
493 if (socket != null) { in closeSocket()
494 socket.close(); in closeSocket()
/frameworks/base/core/jni/
Dandroid_net_NetUtils.cpp283 static jint android_net_utils_bindSocketToNetwork(JNIEnv *env, jobject thiz, jint socket, in android_net_utils_bindSocketToNetwork() argument
286 return setNetworkForSocket(netId, socket); in android_net_utils_bindSocketToNetwork()
289 static jboolean android_net_utils_protectFromVpn(JNIEnv *env, jobject thiz, jint socket) in android_net_utils_protectFromVpn() argument
291 return (jboolean) !protectFromVpn(socket); in android_net_utils_protectFromVpn()
/frameworks/base/docs/html/guide/topics/connectivity/
Dwifip2p.jd481 …<li>Create a {@link java.net.ServerSocket}. This socket waits for a connection from a client on a …
485 the server socket to connect to the server device.</li>
488socket successfully connects to the server socket, you can send data from the client to the server
491 …<li>The server socket waits for a client connection (with the {@link java.net.ServerSocket#accept(…
499 to create this client-server socket communication and transfer JPEG images from a client
518 * Create a server socket and wait for client connections. This
562 …<p>On the client, connect to the server socket with a client socket and transfer data. This example
570 Socket socket = new Socket();
575 * Create a client socket with the host,
578 socket.bind(null);
[all …]
Dbluetooth.jd102 <dd>Represents the interface for a Bluetooth socket (similar to a TCP
108 <dd>Represents an open server socket that listens for incoming requests
110 Android devices, one device must open a server socket with this class. When a
464 you want your application to host a server socket that will accept incoming
474 device must open a server socket and the other one must initiate the connection
494 server, so that each one has a server socket open and listening for connections.
497 a server socket on demand and the other device can simply initiate the
513 socket is to listen for incoming connection requests and when one is accepted,
534 <p>Here's the basic procedure to set up a server socket and accept a
557 registered with this listening server socket. When successful, {@link
[all …]
/frameworks/base/core/java/android/os/
DProcess.java374 final LocalSocket socket; field in Process.ZygoteState
381 private ZygoteState(LocalSocket socket, DataInputStream inputStream, in ZygoteState() argument
383 this.socket = socket; in ZygoteState()
424 socket.close(); in close()
/frameworks/base/core/java/org/apache/http/conn/scheme/
DLayeredSocketFactory.java71 Socket socket, in createSocket() argument

123