Home
last modified time | relevance | path

Searched refs:State (Results 1 – 25 of 410) sorted by relevance

12345678910>>...17

/frameworks/base/startop/iorap/src/com/google/android/startop/iorap/
DEventSequenceValidator.java101 private State state = State.INIT;
106 if (state == State.UNKNOWN) { in onIntentStarted()
112 if (state != State.INIT && in onIntentStarted()
113 state != State.INTENT_FAILED && in onIntentStarted()
114 state != State.ACTIVITY_CANCELLED && in onIntentStarted()
115 state != State.ACTIVITY_FINISHED && in onIntentStarted()
116 state != State.REPORT_FULLY_DRAWN) { in onIntentStarted()
118 String.format("Cannot transition from %s to %s", state, State.INTENT_STARTED)); in onIntentStarted()
124 Log.i(TAG, String.format("Transition from %s to %s", state, State.INTENT_STARTED)); in onIntentStarted()
125 state = State.INTENT_STARTED; in onIntentStarted()
[all …]
/frameworks/base/core/tests/bandwidthtests/src/com/android/bandwidthtest/
DNetworkState.java19 import android.net.NetworkInfo.State;
36 private List<State> mStateDepository;
37 private State mTransitionTarget;
42 mStateDepository = new ArrayList<State>(); in NetworkState()
44 mTransitionTarget = State.UNKNOWN; in NetworkState()
47 public NetworkState(State currentState) { in NetworkState()
48 mStateDepository = new ArrayList<State>(); in NetworkState()
51 mTransitionTarget = State.UNKNOWN; in NetworkState()
60 mTransitionTarget = State.UNKNOWN; in resetNetworkState()
69 public void setStateTransitionCriteria(State initState, StateTransitionDirection transitionDir, in setStateTransitionCriteria()
[all …]
/frameworks/base/packages/SystemUI/src/com/android/systemui/doze/
DDozeMachine.java62 public enum State { enum in DozeMachine
148 private final ArrayList<State> mQueuedRequests = new ArrayList<>();
149 private State mState = State.UNINITIALIZED;
193 public void requestState(State requestedState) { in requestState()
194 Preconditions.checkArgument(requestedState != State.DOZE_REQUEST_PULSE); in requestState()
204 requestState(State.DOZE_REQUEST_PULSE, pulseReason); in requestPulse()
214 private void requestState(State requestedState, int pulseReason) { in requestState()
241 public State getState() { in getState()
258 Preconditions.checkState(mState == State.DOZE_REQUEST_PULSE in getPulseReason()
259 || mState == State.DOZE_PULSING in getPulseReason()
[all …]
DDozeDockHandler.java24 import com.android.systemui.doze.DozeMachine.State;
60 public void transitionTo(DozeMachine.State oldState, DozeMachine.State newState) { in transitionTo()
97 DozeMachine.State nextState; in onEvent()
100 nextState = State.DOZE_AOD_DOCKED; in onEvent()
103 nextState = mConfig.alwaysOnEnabled(UserHandle.USER_CURRENT) ? State.DOZE_AOD in onEvent()
104 : State.DOZE; in onEvent()
107 nextState = State.DOZE; in onEvent()
116 DozeMachine.State state = mMachine.getState(); in isPulsing()
117 return state == State.DOZE_REQUEST_PULSE || state == State.DOZE_PULSING in isPulsing()
118 || state == State.DOZE_PULSING_BRIGHT; in isPulsing()
DDozeTriggers.java41 import com.android.systemui.doze.DozeMachine.State;
307 final State state = mMachine.getState(); in onSensor()
308 if (state == State.DOZE_AOD || state == State.DOZE) { in onSensor()
355 final DozeMachine.State state = mMachine.getState();
356 final boolean paused = (state == DozeMachine.State.DOZE_AOD_PAUSED);
357 final boolean pausing = (state == DozeMachine.State.DOZE_AOD_PAUSING);
358 final boolean aod = (state == DozeMachine.State.DOZE_AOD);
360 if (state == DozeMachine.State.DOZE_PULSING
361 || state == DozeMachine.State.DOZE_PULSING_BRIGHT) {
373 mMachine.requestState(DozeMachine.State.DOZE_AOD);
[all …]
/frameworks/base/packages/SystemUI/tests/src/com/android/systemui/doze/
DDozeWallpaperStateTest.java64 mDozeWallpaperState.transitionTo(DozeMachine.State.UNINITIALIZED, in testDreamNotification()
65 DozeMachine.State.DOZE_AOD); in testDreamNotification()
67 mDozeWallpaperState.transitionTo(DozeMachine.State.DOZE_AOD, DozeMachine.State.FINISH); in testDreamNotification()
72 mDozeWallpaperState.transitionTo(DozeMachine.State.FINISH, DozeMachine.State.DOZE_AOD); in testDreamNotification()
83 mDozeWallpaperState.transitionTo(DozeMachine.State.UNINITIALIZED, in testAnimates_whenSupported()
84 DozeMachine.State.DOZE_AOD); in testAnimates_whenSupported()
88 mDozeWallpaperState.transitionTo(DozeMachine.State.DOZE_AOD, DozeMachine.State.FINISH); in testAnimates_whenSupported()
100 mDozeWallpaperState.transitionTo(DozeMachine.State.UNINITIALIZED, in testDoesNotAnimate_whenNotSupported()
101 DozeMachine.State.DOZE_AOD); in testDoesNotAnimate_whenNotSupported()
104 mDozeWallpaperState.transitionTo(DozeMachine.State.DOZE_AOD, DozeMachine.State.FINISH); in testDoesNotAnimate_whenNotSupported()
[all …]
DDozeDockHandlerTest.java38 import com.android.systemui.doze.DozeMachine.State;
63 when(mMachine.getState()).thenReturn(State.DOZE_AOD); in setUp()
65 mDockHandler.transitionTo(DozeMachine.State.UNINITIALIZED, DozeMachine.State.INITIALIZED); in setUp()
75 mDockHandler.transitionTo(DozeMachine.State.INITIALIZED, DozeMachine.State.FINISH); in transitionToFinish_unregistersDockEventListener()
84 verify(mMachine).requestState(eq(State.DOZE_AOD_DOCKED)); in onEvent_docked_requestsDockedAodState()
91 verify(mMachine, never()).requestState(eq(State.DOZE_AOD)); in onEvent_noneWhileEnabledAod_ignoresIfAlreadyNone()
100 verify(mMachine).requestState(eq(State.DOZE_AOD)); in onEvent_noneWhileEnabledAod_requestsAodState()
111 verify(mMachine).requestState(eq(State.DOZE)); in onEvent_noneWhileDisabledAod_requestsDozeState()
118 verify(mMachine).requestState(eq(State.DOZE)); in onEvent_hide_requestsDozeState()
123 when(mMachine.getState()).thenReturn(State.DOZE_PULSING); in onEvent_dockedWhilePulsing_wontRequestStateChange()
[all …]
DDozeTriggersTest.java19 import static com.android.systemui.doze.DozeMachine.State.DOZE_AOD;
124 when(mMachine.getState()).thenReturn(DozeMachine.State.DOZE); in testOnNotification_stillWorksAfterOneFailedProxCheck()
128 mTriggers.transitionTo(DozeMachine.State.UNINITIALIZED, DozeMachine.State.INITIALIZED); in testOnNotification_stillWorksAfterOneFailedProxCheck()
129 mTriggers.transitionTo(DozeMachine.State.INITIALIZED, DozeMachine.State.DOZE); in testOnNotification_stillWorksAfterOneFailedProxCheck()
149 when(mMachine.getState()).thenReturn(DozeMachine.State.DOZE); in testTransitionTo_disablesAndEnablesTouchSensors()
151 mTriggers.transitionTo(DozeMachine.State.INITIALIZED, DozeMachine.State.DOZE); in testTransitionTo_disablesAndEnablesTouchSensors()
157 mTriggers.transitionTo(DozeMachine.State.DOZE, in testTransitionTo_disablesAndEnablesTouchSensors()
158 DozeMachine.State.DOZE_REQUEST_PULSE); in testTransitionTo_disablesAndEnablesTouchSensors()
159 mTriggers.transitionTo(DozeMachine.State.DOZE_REQUEST_PULSE, in testTransitionTo_disablesAndEnablesTouchSensors()
160 DozeMachine.State.DOZE_PULSING); in testTransitionTo_disablesAndEnablesTouchSensors()
[all …]
/frameworks/opt/telephony/tests/telephonytests/src/com/android/internal/telephony/
DSimulatedGsmCallState.java33 enum State { enum in CallInfo
41 State(int value) {mValue = value;} in State() method in CallInfo.State
48 State mState;
53 CallInfo (boolean isMT, State state, boolean isMpty, String number) { in CallInfo()
68 return new CallInfo (false, State.DIALING, false, number); in createOutgoingCall()
73 return new CallInfo (true, State.INCOMING, false, number); in createIncomingCall()
112 return mState == State.ACTIVE || mState == State.HOLDING; in isActiveOrHeld()
117 return mState == State.DIALING || mState == State.ALERTING; in isConnecting()
122 return mState == State.INCOMING || mState == State.WAITING; in isRinging()
192 && (call.mState == CallInfo.State.INCOMING in triggerRing()
[all …]
DGsmCdmaCallTrackerTest.java102 assertEquals(PhoneConstants.State.IDLE, mCTUT.getState()); in testMOCallDial()
103 assertEquals(GsmCdmaCall.State.IDLE, mCTUT.mForegroundCall.getState()); in testMOCallDial()
104 assertEquals(GsmCdmaCall.State.IDLE, mCTUT.mBackgroundCall.getState()); in testMOCallDial()
114 assertEquals(PhoneConstants.State.OFFHOOK, mCTUT.getState()); in testMOCallDial()
115 assertEquals(GsmCdmaCall.State.DIALING, mCTUT.mForegroundCall.getState()); in testMOCallDial()
132 assertEquals(GsmCdmaCall.State.ACTIVE, mCTUT.mForegroundCall.getState()); in testMOCallPickUp()
133 assertEquals(GsmCdmaCall.State.IDLE, mCTUT.mBackgroundCall.getState()); in testMOCallPickUp()
144 assertEquals(GsmCdmaCall.State.DIALING, mCTUT.mForegroundCall.getState()); in testMOCallHangup()
145 assertEquals(PhoneConstants.State.OFFHOOK, mCTUT.getState()); in testMOCallHangup()
155 assertEquals(GsmCdmaCall.State.IDLE, mCTUT.mForegroundCall.getState()); in testMOCallHangup()
[all …]
DGsmCdmaCallTest.java53 assertEquals(Call.State.IDLE, mCallUnderTest.getState()); in testAttachDetach()
56 mDriverCall.state = DriverCall.State.ACTIVE; in testAttachDetach()
61 assertEquals(Call.State.ACTIVE, mCallUnderTest.getState()); in testAttachDetach()
68 assertEquals(Call.State.IDLE, mCallUnderTest.getState()); in testAttachDetach()
75 assertEquals(Call.State.IDLE, mCallUnderTest.getState()); in testMultiparty()
81 mDriverCall.state = DriverCall.State.ACTIVE; in testMultiparty()
108 mDriverCall.state = DriverCall.State.ACTIVE; in testConnectionDisconnected()
114 assertEquals(Call.State.ACTIVE, mCallUnderTest.getState()); in testConnectionDisconnected()
117 doReturn(Call.State.DISCONNECTED).when(mConnection1).getState(); in testConnectionDisconnected()
119 assertEquals(Call.State.ACTIVE, mCallUnderTest.getState()); in testConnectionDisconnected()
[all …]
/frameworks/opt/telephony/tests/telephonytests/src/com/android/internal/telephony/imsphone/
DImsPhoneCallTest.java78 assertEquals(Call.State.IDLE, mImsCallUT.getState()); in testAttachDetach()
81 mImsCallUT.attach(mConnection1, Call.State.ACTIVE); in testAttachDetach()
85 assertEquals(Call.State.ACTIVE, mImsCallUT.getState()); in testAttachDetach()
92 assertEquals(Call.State.IDLE, mImsCallUT.getState()); in testAttachDetach()
99 mImsCallUT.attach(mConnection1, Call.State.ACTIVE); in testConnectionDisconnected()
100 mImsCallUT.attach(mConnection2, Call.State.ACTIVE); in testConnectionDisconnected()
103 assertEquals(Call.State.ACTIVE, mImsCallUT.getState()); in testConnectionDisconnected()
105 doReturn(Call.State.DISCONNECTED).when(mConnection1).getState(); in testConnectionDisconnected()
107 assertEquals(Call.State.ACTIVE, mImsCallUT.getState()); in testConnectionDisconnected()
108 doReturn(Call.State.DISCONNECTED).when(mConnection2).getState(); in testConnectionDisconnected()
[all …]
/frameworks/base/services/backup/backuplib/java/com/android/server/backup/transport/
DTransportClient.java104 @State
105 private int mState = State.IDLE;
212 case State.UNUSABLE: in connectAsync()
216 case State.IDLE: in connectAsync()
228 setStateLocked(State.BOUND_AND_CONNECTING, null); in connectAsync()
237 case State.BOUND_AND_CONNECTING: in connectAsync()
244 case State.CONNECTED: in connectAsync()
264 case State.UNUSABLE: in unbind()
265 case State.IDLE: in unbind()
267 case State.BOUND_AND_CONNECTING: in unbind()
[all …]
/frameworks/base/core/java/android/uwb/
DRangingSession.java56 private enum State { enum in RangingSession
79 private State mState = State.INIT;
230 mState = State.INIT; in RangingSession()
241 return mState == State.IDLE || mState == State.ACTIVE; in isOpen()
257 if (mState != State.IDLE) { in start()
282 if (mState != State.ACTIVE && mState != State.IDLE) { in reconfigure()
314 if (mState != State.ACTIVE) { in stop()
346 if (mState == State.CLOSED) { in close()
363 if (mState == State.CLOSED) { in onRangingOpened()
368 mState = State.IDLE; in onRangingOpened()
[all …]
/frameworks/opt/telephony/tests/telephonytests/src/com/android/internal/telephony/gsm/
DGSMPhoneTest.java.broken144 assertEquals(PhoneConstants.State.IDLE, mGSMPhone.getState());
149 assertEquals(Call.State.IDLE, mGSMPhone.getRingingCall().getState());
150 assertEquals(Call.State.IDLE, mGSMPhone.getForegroundCall().getState());
151 assertEquals(Call.State.IDLE, mGSMPhone.getBackgroundCall().getState());
163 assertEquals(PhoneConstants.State.OFFHOOK, mGSMPhone.getState());
168 assertEquals(PhoneConstants.State.OFFHOOK, mGSMPhone.getState());
169 assertEquals(Call.State.DIALING, mGSMPhone.getForegroundCall().getState());
180 assertEquals(Call.State.IDLE, mGSMPhone.getRingingCall().getState());
181 assertEquals(Call.State.DIALING,
183 assertEquals(Call.State.IDLE, mGSMPhone.getBackgroundCall().getState());
[all …]
/frameworks/base/core/java/com/android/internal/transition/
DEpicenterTranslateClipReveal.java150 final State startStateX = new State(startClip.left, startClip.right, startX); in onAppear()
151 final State endStateX = new State(endClip.left, endClip.right, endX); in onAppear()
152 final State startStateY = new State(startClip.top, startClip.bottom, startY); in onAppear()
153 final State endStateY = new State(endClip.top, endClip.bottom, endY); in onAppear()
182 final State startStateX = new State(startClip.left, startClip.right, startX); in onDisappear()
183 final State endStateX = new State(endClip.left, endClip.right, endX); in onDisappear()
184 final State startStateY = new State(startClip.top, startClip.bottom, startY); in onDisappear()
185 final State endStateY = new State(endClip.top, endClip.bottom, endY); in onDisappear()
210 private static Animator createRectAnimator(final View view, State startX, State startY, in createRectAnimator()
211 float startZ, State endX, State endY, float endZ, TransitionValues endValues, in createRectAnimator()
[all …]
/frameworks/base/services/core/java/com/android/server/location/provider/
DAbstractLocationProvider.java54 void onStateChanged(State oldState, State newState); in onStateChanged()
66 public static final class State { class in AbstractLocationProvider
72 public static final State EMPTY_STATE = new State(false, null, null,
96 private State(boolean allowed, ProviderProperties properties, CallerIdentity identity, in State() method in AbstractLocationProvider.State
107 public State withAllowed(boolean allowed) { in withAllowed()
111 return new State(allowed, properties, identity, extraAttributionTags); in withAllowed()
118 public State withProperties(@Nullable ProviderProperties properties) { in withProperties()
122 return new State(allowed, properties, identity, extraAttributionTags); in withProperties()
129 public State withIdentity(@Nullable CallerIdentity identity) { in withIdentity()
133 return new State(allowed, properties, identity, extraAttributionTags); in withIdentity()
[all …]
/frameworks/native/libs/ui/
DFenceTime.cpp38 State::VALID : State::INVALID), in FenceTime()
40 mSignalTime(mState == State::INVALID ? in FenceTime()
46 State::VALID : State::INVALID), in FenceTime()
48 mSignalTime(mState == State::INVALID ? in FenceTime()
53 : mState(Fence::isValidTimestamp(signalTime) ? State::VALID : State::INVALID), in FenceTime()
63 if (CC_UNLIKELY(src.state != Snapshot::State::SIGNAL_TIME)) { in applyTrustedSnapshot()
71 if (src.state == Snapshot::State::EMPTY) { in applyTrustedSnapshot()
97 return mState != State::INVALID; in isValid()
157 if (CC_UNLIKELY(mState == State::FORCED_VALID_FOR_TEST)) { in getSignalTime()
200 State::FORCED_VALID_FOR_TEST : State::INVALID), in FenceTime()
[all …]
/frameworks/base/core/java/android/os/
DSystemService.java33 private static HashMap<String, State> sStates = Maps.newHashMap();
38 public enum State { enum in SystemService
44 State(String state) { in State() method in SystemService.State
82 public static State getState(String service) { in getState()
84 final State state = sStates.get(rawState); in getState()
88 return State.STOPPED; in getState()
96 return State.STOPPED.equals(getState(service)); in isStopped()
103 return State.RUNNING.equals(getState(service)); in isRunning()
109 public static void waitForState(String service, State state, long timeoutMillis) in waitForState()
114 final State currentState = getState(service); in waitForState()
[all …]
/frameworks/av/media/libmediatranscoding/transcoder/benchmark/
DMediaTranscoderBenchmark.cpp106 static void TranscodeMediaFile(benchmark::State& state, const std::string& srcFileName, in TranscodeMediaFile()
250 static void TranscodeMediaFile(benchmark::State& state, const std::string& srcFileName, in TranscodeMediaFile()
276 static void BM_TranscodeAvc2AvcAudioVideo2AudioVideo(benchmark::State& state) { in BM_TranscodeAvc2AvcAudioVideo2AudioVideo()
282 static void BM_TranscodeAvc2AvcVideo2Video(benchmark::State& state) { in BM_TranscodeAvc2AvcVideo2Video()
288 static void BM_TranscodeAvc2AvcAV2AVMaxOperatingRate(benchmark::State& state) { in BM_TranscodeAvc2AvcAV2AVMaxOperatingRate()
294 static void BM_TranscodeAvc2AvcV2VMaxOperatingRate(benchmark::State& state) { in BM_TranscodeAvc2AvcV2VMaxOperatingRate()
300 static void BM_TranscodeAvc2AvcAV2AV720P(benchmark::State& state) { in BM_TranscodeAvc2AvcAV2AV720P()
306 static void BM_TranscodeAvc2AvcAV2AV720PMaxOperatingRate(benchmark::State& state) { in BM_TranscodeAvc2AvcAV2AV720PMaxOperatingRate()
313 static void BM_TranscodeHevc2AvcAudioVideo2AudioVideo(benchmark::State& state) { in BM_TranscodeHevc2AvcAudioVideo2AudioVideo()
319 static void BM_TranscodeHevc2AvcVideo2Video(benchmark::State& state) { in BM_TranscodeHevc2AvcVideo2Video()
[all …]
/frameworks/base/core/proto/android/service/
Dnotification.proto55 enum State { enum
60 optional State state = 2;
166 enum State { enum
174 optional State state = 6 [ (android.privacy).dest = DEST_AUTOMATIC ];
228 enum State { enum
235 optional State reminders = 1;
236 optional State events = 2;
237 optional State messages = 3;
238 optional State calls = 4;
239 optional State repeat_callers = 5;
[all …]
/frameworks/opt/telephony/src/java/com/android/internal/telephony/sip/
DSipPhone.java134 if (sipAudioCall.getState() != SipSession.State.INCOMING_CALL) { in takeIncomingCall()
157 if ((mRingingCall.getState() == Call.State.INCOMING) || in acceptCall()
158 (mRingingCall.getState() == Call.State.WAITING)) { in acceptCall()
212 if (mForegroundCall.getState() == SipCall.State.ACTIVE) { in dialInternal()
215 if (mForegroundCall.getState() != SipCall.State.IDLE) { in dialInternal()
256 if ((mForegroundCall.getState() != SipCall.State.ACTIVE) in conference()
257 || (mForegroundCall.getState() != SipCall.State.ACTIVE)) { in conference()
420 private static Call.State getCallStateFrom(SipAudioCall sipAudioCall) { in getCallStateFrom()
421 if (sipAudioCall.isOnHold()) return Call.State.HOLDING; in getCallStateFrom()
424 case SipSession.State.READY_TO_CALL: return Call.State.IDLE; in getCallStateFrom()
[all …]
/frameworks/base/services/core/java/com/android/server/storage/
DDeviceStorageMonitorService.java93 private volatile int mForceLevel = State.LEVEL_UNKNOWN;
96 private final ArrayMap<UUID, State> mStates = new ArrayMap<>();
102 private static class State { class in DeviceStorageMonitorService
137 case State.LEVEL_UNKNOWN: return "UNKNOWN"; in levelToString()
138 case State.LEVEL_NORMAL: return "NORMAL"; in levelToString()
139 case State.LEVEL_LOW: return "LOW"; in levelToString()
140 case State.LEVEL_FULL: return "FULL"; in levelToString()
158 private State findOrCreateState(UUID uuid) { in findOrCreateState()
159 State state = mStates.get(uuid); in findOrCreateState()
161 state = new State(); in findOrCreateState()
[all …]
/frameworks/base/telephony/java/com/android/internal/telephony/
DOperatorInfo.java29 public enum State { enum in OperatorInfo
46 private State mState = State.UNKNOWN;
69 public State
82 State state) { in OperatorInfo()
94 State state, in OperatorInfo()
121 this(operatorAlphaLong, operatorAlphaShort, operatorNumeric, State.UNKNOWN); in OperatorInfo()
128 private static State rilStateToState(String s) { in rilStateToState()
130 return State.UNKNOWN; in rilStateToState()
132 return State.AVAILABLE; in rilStateToState()
134 return State.CURRENT; in rilStateToState()
[all …]
/frameworks/opt/telephony/src/java/com/android/internal/telephony/
DCall.java40 public enum State { enum in Call
66 public static State
67 stateFromDCState (DriverCall.State dcState) { in stateFromDCState()
69 case ACTIVE: return State.ACTIVE; in stateFromDCState()
70 case HOLDING: return State.HOLDING; in stateFromDCState()
71 case DIALING: return State.DIALING; in stateFromDCState()
72 case ALERTING: return State.ALERTING; in stateFromDCState()
73 case INCOMING: return State.INCOMING; in stateFromDCState()
74 case WAITING: return State.WAITING; in stateFromDCState()
86 public State mState = State.IDLE;
[all …]

12345678910>>...17