Home
last modified time | relevance | path

Searched refs:conn (Results 1 – 25 of 92) sorted by relevance

1234

/frameworks/base/services/tests/servicestests/src/com/android/server/am/
DPersistentConnectionTest.java111 final MyConnection conn = new MyConnection("tag", context, handler, userId, cn, in testAll() local
116 assertFalse(conn.isBound()); in testAll()
117 assertFalse(conn.isConnected()); in testAll()
118 assertFalse(conn.isRebindScheduled()); in testAll()
119 assertEquals(5000, conn.getNextBackoffMsForTest()); in testAll()
120 assertNull(conn.getServiceBinder()); in testAll()
127 conn.bind(); in testAll()
129 assertTrue(conn.isBound()); in testAll()
130 assertTrue(conn.shouldBeBoundForTest()); in testAll()
131 assertFalse(conn.isConnected()); in testAll()
[all …]
/frameworks/base/core/tests/coretests/src/android/app/activity/
DServiceTest.java233 TestConnection conn = new TestConnection(true, false); in bindExpectResult() local
239 getContext().bindService(service, conn, 0); in bindExpectResult()
253 getContext().unbindService(conn); in bindExpectResult()
266 getContext().unbindService(conn); in bindExpectResult()
268 conn = new TestConnection(true, true); in bindExpectResult()
272 conn.setMonitor(true); in bindExpectResult()
274 getContext().bindService(service, conn, 0); in bindExpectResult()
283 getContext().unbindService(conn); in bindExpectResult()
291 conn.setMonitor(false); in bindExpectResult()
296 getContext().unbindService(conn); in bindExpectResult()
[all …]
/frameworks/base/tests/testables/src/android/testing/
DTestableContext.java230 public boolean bindService(Intent service, ServiceConnection conn, int flags) { in bindService() argument
231 if (mService != null) mService.getLeakInfo(conn).addAllocation(new Throwable()); in bindService()
232 if (checkMocks(service.getComponent(), conn)) return true; in bindService()
233 return super.bindService(service, conn, flags); in bindService()
240 public boolean bindServiceAsUser(Intent service, ServiceConnection conn, int flags, in bindServiceAsUser() argument
242 if (mService != null) mService.getLeakInfo(conn).addAllocation(new Throwable()); in bindServiceAsUser()
243 if (checkMocks(service.getComponent(), conn)) return true; in bindServiceAsUser()
244 return super.bindServiceAsUser(service, conn, flags, handler, user); in bindServiceAsUser()
251 public boolean bindServiceAsUser(Intent service, ServiceConnection conn, int flags, in bindServiceAsUser() argument
253 if (mService != null) mService.getLeakInfo(conn).addAllocation(new Throwable()); in bindServiceAsUser()
[all …]
/frameworks/opt/telephony/src/java/com/android/internal/telephony/imsphone/
DImsPhoneCallTracker.java172 ImsPhoneConnection conn = new ImsPhoneConnection(mPhone, imsCall,
185 conn.setActiveCallDisconnectedOnAnswer(answeringWillDisconnect);
188 conn.setAllowAddCallDuringVideoCall(mAllowAddCallDuringVideoCall);
189 addConnection(conn);
191 setVideoCallProvider(conn, imsCall);
197 mPhone.notifyUnknownConnection(conn);
201 conn.update(imsCall, ImsPhoneCall.State.WAITING);
204 mPhone.notifyNewRingingConnection(conn);
1057 private void dialInternal(ImsPhoneConnection conn, int clirMode, int videoState, in dialInternal() argument
1060 if (conn == null) { in dialInternal()
[all …]
DImsPhoneCall.java133 for (Connection conn : mConnections) { in toString()
134 sb.append(conn); in toString()
153 public void attach(Connection conn) { in attach() argument
155 Rlog.v(LOG_TAG, "attach : " + mCallContext + " conn = " + conn); in attach()
158 mConnections.add(conn); in attach()
163 public void attach(Connection conn, State state) { in attach() argument
168 this.attach(conn); in attach()
172 public void attachFake(Connection conn, State state) { in attachFake() argument
173 attach(conn, state); in attachFake()
179 public boolean connectionDisconnected(ImsPhoneConnection conn) { in connectionDisconnected() argument
[all …]
/frameworks/opt/telephony/src/java/com/android/internal/telephony/
DGsmCdmaCall.java69 public void attach(Connection conn, DriverCall dc) { in attach() argument
70 mConnections.add(conn); in attach()
75 public void attachFake(Connection conn, State state) { in attachFake() argument
76 mConnections.add(conn); in attachFake()
84 public boolean connectionDisconnected(GsmCdmaConnection conn) { in connectionDisconnected() argument
106 public void detach(GsmCdmaConnection conn) { in detach() argument
107 mConnections.remove(conn); in detach()
114 /*package*/ boolean update (GsmCdmaConnection conn, DriverCall dc) { in update() argument
DGsmCdmaCallTracker.java259 GsmCdmaConnection conn = (GsmCdmaConnection)connCopy.get(i); in fakeHoldForegroundBeforeDial() local
261 conn.fakeHoldBeforeDial(); in fakeHoldForegroundBeforeDial()
776 GsmCdmaConnection conn = mConnections[i]; in handlePollCalls() local
791 if (conn != null || dc != null) { in handlePollCalls()
796 conn+", dc=" + dc); in handlePollCalls()
798 if (conn == null && dc != null) { in handlePollCalls()
880 } else if (conn != null && dc == null) { in handlePollCalls()
884 mDroppedDuringPoll.add(conn); in handlePollCalls()
915 } else if (conn != null && dc != null && !conn.compareTo(dc) && isPhoneTypeGsm()) { in handlePollCalls()
919 mDroppedDuringPoll.add(conn); in handlePollCalls()
[all …]
/frameworks/base/media/jni/
Dandroid_media_MediaHTTPConnection.cpp85 JNIEnv *env, jobject thiz, const sp<JMediaHTTPConnection> &conn) { in setObject() argument
89 if (conn != NULL) { in setObject()
90 conn->incStrong(thiz); in setObject()
95 env->SetLongField(thiz, gFields.context, (jlong)conn.get()); in setObject()
117 sp<JMediaHTTPConnection> conn = new JMediaHTTPConnection(env, thiz); in android_media_MediaHTTPConnection_native_setup() local
119 setObject(env, thiz, conn); in android_media_MediaHTTPConnection_native_setup()
129 sp<JMediaHTTPConnection> conn = getObject(env, thiz); in android_media_MediaHTTPConnection_native_getIMemory() local
131 return javaObjectForIBinder(env, IInterface::asBinder(conn->getIMemory())); in android_media_MediaHTTPConnection_native_getIMemory()
136 sp<JMediaHTTPConnection> conn = getObject(env, thiz); in android_media_MediaHTTPConnection_native_readAt() local
141 jbyteArray byteArrayObj = conn->getByteArrayObj(); in android_media_MediaHTTPConnection_native_readAt()
[all …]
/frameworks/base/tests/UsbHostExternalManagmentTest/UsbHostExternalManagmentTestApp/src/com/android/hardware/usb/externalmanagementtest/
DAoapInterface.java95 public static int getProtocol(UsbDeviceConnection conn) { in getProtocol() argument
97 int len = conn.controlTransfer( in getProtocol()
106 public static void sendString(UsbDeviceConnection conn, int index, String string) { in sendString() argument
108 int len = conn.controlTransfer( in sendString()
119 public static void sendAoapStart(UsbDeviceConnection conn) { in sendAoapStart() argument
120 int len = conn.controlTransfer( in sendAoapStart()
/frameworks/base/tests/AccessoryDisplay/sink/src/com/android/accessorydisplay/sink/
DSinkActivity.java176 UsbDeviceConnection conn = mUsbManager.openDevice(device); in connect() local
177 if (conn == null) { in connect()
183 if (!conn.claimInterface(iface, true)) { in connect()
192 int protocolVersion = getProtocol(conn); in connect()
226 mAccessoryConnection = conn; in connect()
228 mTransport = new UsbAccessoryBulkTransport(mLogger, conn, bulkIn, bulkOut); in connect()
241 int protocolVersion = getProtocol(conn); in connect()
249 sendString(conn, UsbAccessoryConstants.ACCESSORY_STRING_MANUFACTURER, MANUFACTURER); in connect()
250 sendString(conn, UsbAccessoryConstants.ACCESSORY_STRING_MODEL, MODEL); in connect()
251 sendString(conn, UsbAccessoryConstants.ACCESSORY_STRING_DESCRIPTION, DESCRIPTION); in connect()
[all …]
/frameworks/base/tests/BandwidthTests/src/com/android/tests/bandwidthenforcement/
DBandwidthEnforcementTestService.java95 final HttpURLConnection conn = (HttpURLConnection) new URL("http://www.google.com/") in testUrlConnection() local
98 conn.connect(); in testUrlConnection()
100 new InputStreamReader(conn.getInputStream())); in testUrlConnection()
105 conn.disconnect(); in testUrlConnection()
119 final HttpURLConnection conn = (HttpURLConnection) new URL("http://ipv6.google.com/") in testUrlConnectionv6() local
122 conn.connect(); in testUrlConnectionv6()
124 new InputStreamReader(conn.getInputStream())); in testUrlConnectionv6()
129 conn.disconnect(); in testUrlConnectionv6()
/frameworks/base/tests/FrameworkPerf/src/com/android/frameworkperf/
DFrameworkPerfActivity.java251 void dispatchCurOp(TestConnection conn) { in dispatchCurOp() argument
252 if (mCurConnection != conn) { in dispatchCurOp()
253 Log.w(TAG, "Dispatching on invalid connection: " + conn); in dispatchCurOp()
285 conn.mService.send(msg); in dispatchCurOp()
327 final TestConnection conn = mCurConnection; in disconnect() local
328 if (conn != null) { in disconnect()
332 Log.i(TAG, "Unbinding " + conn, here); in disconnect()
335 unbindService(conn); in disconnect()
338 if (conn.mLinked) { in disconnect()
341 conn.mService.send(msg); in disconnect()
[all …]
/frameworks/base/services/backup/java/com/android/server/backup/
DTransportManager.java159 TransportConnection conn = mValidTransports.get(component); in getTransportBinder() local
160 if (conn == null) { in getTransportBinder()
164 return conn.getBinder(); in getTransportBinder()
174 for (TransportConnection conn : mValidTransports.values()) { in getTransportName()
175 if (conn.getBinder() == binder) { in getTransportName()
176 return conn.getName(); in getTransportName()
213 TransportConnection conn = mValidTransports.get(transportComponent); in ensureTransportReady() local
214 if (conn == null) { in ensureTransportReady()
219 conn.bindIfUnbound(); in ensureTransportReady()
220 conn.addListener(listener); in ensureTransportReady()
[all …]
/frameworks/base/core/java/android/view/inputmethod/
DInputBinding.java58 public InputBinding(InputConnection conn, IBinder connToken, in InputBinding() argument
60 mConnection = conn; in InputBinding()
73 public InputBinding(InputConnection conn, InputBinding binding) { in InputBinding() argument
74 mConnection = conn; in InputBinding()
/frameworks/av/media/libstagefright/
DDataSource.cpp170 sp<IMediaHTTPConnection> conn = httpService->makeHTTPConnection(); in CreateFromURI() local
171 if (conn == NULL) { in CreateFromURI()
175 httpSource = new MediaHTTP(conn); in CreateFromURI()
226 sp<IMediaHTTPConnection> conn = httpService->makeHTTPConnection(); in CreateMediaHTTP() local
227 if (conn == NULL) { in CreateMediaHTTP()
230 return new MediaHTTP(conn); in CreateMediaHTTP()
/frameworks/base/services/devicepolicy/java/com/android/server/devicepolicy/
DDeviceAdminServiceController.java171 final DevicePolicyServiceConnection conn = in startServiceForOwner() local
174 mConnections.put(userId, conn); in startServiceForOwner()
175 conn.bind(); in startServiceForOwner()
197 final DevicePolicyServiceConnection conn = mConnections.get(userId); in disconnectServiceOnUserLocked() local
198 if (conn != null) { in disconnectServiceOnUserLocked()
201 conn.unbind(); in disconnectServiceOnUserLocked()
/frameworks/base/samples/training/network-usage/src/com/example/android/networkusage/
DNetworkActivity.java267 HttpURLConnection conn = (HttpURLConnection) url.openConnection(); in downloadUrl() local
268 conn.setReadTimeout(10000 /* milliseconds */); in downloadUrl()
269 conn.setConnectTimeout(15000 /* milliseconds */); in downloadUrl()
270 conn.setRequestMethod("GET"); in downloadUrl()
271 conn.setDoInput(true); in downloadUrl()
273 conn.connect(); in downloadUrl()
274 InputStream stream = conn.getInputStream(); in downloadUrl()
/frameworks/base/services/core/java/com/android/server/am/
DConnectionRecord.java31 final IServiceConnection conn; // The client connection. field in ConnectionRecord
43 pw.println(prefix + "conn=" + conn.asBinder() in dump()
52 conn = _conn; in ConnectionRecord()
118 sb.append(Integer.toHexString(System.identityHashCode(conn.asBinder()))); in toString()
DContentProviderRecord.java78 public ContentProviderHolder newHolder(ContentProviderConnection conn) { in newHolder() argument
82 holder.connection = conn; in newHolder()
196 ContentProviderConnection conn = connections.get(i); in dump() local
197 pw.print(prefix); pw.print(" -> "); pw.println(conn.toClientString()); in dump()
198 if (conn.provider != this) { in dump()
200 pw.println(conn.provider); in dump()
/frameworks/base/tests/ActivityTests/src/com/google/android/test/activity/
DActivityTestMain.java207 ServiceConnection conn = new ServiceConnection() { in onCreateOptionsMenu()
217 if (bindService(intent, conn, Context.BIND_AUTO_CREATE)) { in onCreateOptionsMenu()
218 mConnections.add(conn); in onCreateOptionsMenu()
236 ServiceConnection conn = new ServiceConnection() { in onCreateOptionsMenu()
251 Log.i(TAG, "Binding new service: " + conn); in onCreateOptionsMenu()
252 if (bindService(intent, conn, Context.BIND_AUTO_CREATE)) { in onCreateOptionsMenu()
253 mIsolatedConnection = conn; in onCreateOptionsMenu()
309 ServiceConnection conn = new ServiceConnection() { in onCreateOptionsMenu()
319 if (bindServiceAsUser(intent, conn, Context.BIND_AUTO_CREATE, UserHandle.SYSTEM)) { in onCreateOptionsMenu()
320 mConnections.add(conn); in onCreateOptionsMenu()
[all …]
/frameworks/opt/telephony/src/java/com/android/internal/telephony/sip/
DSipPhone.java638 SipConnection conn = (SipConnection) c; in merge() local
639 add(conn); in merge()
640 if (conn.getState() == Call.State.HOLDING) { in merge()
641 conn.unhold(audioGroup); in merge()
647 private void add(SipConnection conn) { in add() argument
649 SipCall call = conn.getCall(); in add()
651 if (call != null) call.mConnections.remove(conn); in add()
653 mConnections.add(conn); in add()
654 conn.changeOwner(this); in add()
704 void onConnectionStateChanged(SipConnection conn) { in onConnectionStateChanged() argument
[all …]
/frameworks/base/core/java/org/apache/http/conn/scheme/
DSocketFactory.java32 package org.apache.http.conn.scheme;
39 import org.apache.http.conn.ConnectTimeoutException;
/frameworks/base/tests/CoreTests/android/core/
DTestHttpClient.java98 final HttpClientConnection conn) throws HttpException, IOException { in execute() argument
101 this.context.setAttribute(ExecutionContext.HTTP_CONNECTION, conn); in execute()
105 HttpResponse response = this.httpexecutor.execute(request, conn, this.context); in execute()
/frameworks/av/media/libstagefright/http/
DMediaHTTP.cpp32 MediaHTTP::MediaHTTP(const sp<IMediaHTTPConnection> &conn) in MediaHTTP() argument
33 : mInitCheck((conn != NULL) ? OK : NO_INIT), in MediaHTTP()
34 mHTTPConnection(conn), in MediaHTTP()
/frameworks/base/core/tests/coretests/src/android/net/http/
DAbstractProxyTest.java35 import org.apache.http.conn.params.ConnRoutePNames;
36 import org.apache.http.conn.params.ConnRouteParams;
37 import org.apache.http.conn.scheme.Scheme;
38 import org.apache.http.conn.ssl.AllowAllHostnameVerifier;
39 import org.apache.http.conn.ssl.SSLSocketFactory;

1234