Home | History | Annotate | Download | only in transport

Lines Matching refs:transport

17 package com.android.server.backup.transport;
19 import static com.android.server.backup.transport.TransportUtils.formatMessage;
45 import com.android.server.backup.transport.TransportUtils.Priority;
63 * responsible for only one connection to the transport service, not more.
68 * IBackupTransport} instance. It's meant to be passed around as a token to a connected transport.
155 * Attempts to connect to the transport (if needed).
158 * bound. You go from nothing to bound, then to bound and connected. To have a usable transport
160 * usable transport binder regardless of the state of the object, it may already be connected,
170 * call. However, the {@param IBackupTransport} parameter, the transport binder, is not
173 * The reasons for a null transport binder are:
186 * For unusable transport binders check {@link DeadObjectException}.
239 log(Priority.DEBUG, caller, "Async connect: reusing transport");
247 * Removes the transport binding.
285 * Attempts to connect to the transport (if needed) and returns it.
301 * @return A {@link IBackupTransport} transport binder instance or null. If it's non-null it can
312 IBackupTransport transport = mTransport;
313 if (transport != null) {
314 log(Priority.DEBUG, caller, "Sync connect: reusing transport");
315 return transport;
336 transport = transportFuture.get();
340 return transport;
343 log(Priority.ERROR, caller, error + " while waiting for transport: " + e.getMessage());
349 * Tries to connect to the transport, if it fails throws {@link TransportNotAvailableException}.
355 * @return A {@link IBackupTransport} transport binder instance.
361 IBackupTransport transport = connect(caller);
362 if (transport == null) {
363 log(Priority.ERROR, caller, "Transport connection failed");
366 return transport;
370 transport, returns the transport,
375 * @return A {@link IBackupTransport} transport binder instance.
380 IBackupTransport transport = mTransport;
381 if (transport == null) {
382 log(Priority.ERROR, caller, "Transport not connected");
385 return transport;
421 IBackupTransport transport = IBackupTransport.Stub.asInterface(binder);
426 log(Priority.DEBUG, "Transport connected");
427 setStateLocked(State.CONNECTED, transport);
428 notifyListenersAndClearLocked(transport);
488 @Nullable IBackupTransport transport,
490 String transportString = (transport != null) ? "IBackupTransport" : "null";
491 log(Priority.INFO, "Notifying [" + caller + "] transport = " + transportString);
492 mListenerHandler.post(() -> listener.onTransportConnectionResult(transport, this));
496 private void notifyListenersAndClearLocked(@Nullable IBackupTransport transport) {
500 notifyListener(listener, transport, caller);
506 private void setStateLocked(@State int state, @Nullable IBackupTransport transport) {
510 mTransport = transport;
514 String transport = mTransportComponent.flattenToShortString();
519 EventLog.writeEvent(EventLogTags.BACKUP_TRANSPORT_LIFECYCLE, transport, value);
523 EventLog.writeEvent(EventLogTags.BACKUP_TRANSPORT_CONNECTION, transport, value);
553 mTransport == null, "Transport expected to be null when state = UNUSABLE");
556 checkState(mTransport == null, "Transport expected to be null when state = IDLE");
561 "Transport expected to be null when state = BOUND_AND_CONNECTING");
567 "Transport expected to be non-null when state = CONNECTED");