Lines Matching refs:State
36 std::ostream& operator<<(std::ostream& os, State state) { in operator <<()
38 case State::kTraceFailed: in operator <<()
41 case State::kConnectionError: in operator <<()
44 case State::kSessionNotFound: in operator <<()
47 case State::kIdle: in operator <<()
50 case State::kConnecting: in operator <<()
53 case State::kConfigured: in operator <<()
56 case State::kTracing: in operator <<()
59 case State::kTraceEnded: in operator <<()
161 using State = ::perfetto::consumer::State; typedef
164 State state; // Never invalid.
199 using State = ::perfetto::consumer::State; typedef in iorap::perfetto::StateChangedSubject
219 State last_state{State::kIdle};
225 void DcheckBadStateTransition(State state, bool fail_unless = false) const { in DcheckBadStateTransition()
229 void DcheckValidStateTransition(State state) { in DcheckValidStateTransition()
231 DCHECK_GE(state, State::kTraceFailed); in DcheckValidStateTransition()
232 DCHECK_LE(state, State::kTraceEnded); in DcheckValidStateTransition()
235 DCHECK_NE(state, State::kIdle); in DcheckValidStateTransition()
237 DCHECK_NE(state, State::kSessionNotFound); in DcheckValidStateTransition()
242 case State::kTraceFailed: // Final and unrecoverable. in DcheckValidStateTransition()
244 if (state == State::kConnectionError) { in DcheckValidStateTransition()
251 case State::kConnectionError: // Final and unrecoverable. in DcheckValidStateTransition()
254 case State::kSessionNotFound: in DcheckValidStateTransition()
257 case State::kIdle: in DcheckValidStateTransition()
260 case State::kConnecting: in DcheckValidStateTransition()
262 case State::kConfigured: in DcheckValidStateTransition()
266 case State::kTracing: in DcheckValidStateTransition()
270 case State::kConnectionError: in DcheckValidStateTransition()
278 case State::kConfigured: in DcheckValidStateTransition()
280 if (state != State::kTracing // OK: this is documented. in DcheckValidStateTransition()
281 && state != State::kTraceFailed) { // Undocumented selinux failure. in DcheckValidStateTransition()
287 if (state != State::kTraceEnded) { // b/122607276 #1 in DcheckValidStateTransition()
292 case State::kTracing: in DcheckValidStateTransition()
294 case State::kTraceEnded: in DcheckValidStateTransition()
296 case State::kTraceFailed: in DcheckValidStateTransition()
302 case State::kTraceEnded: in DcheckValidStateTransition()
313 case State::kTraceFailed: in IsTerminalState()
314 case State::kConnectionError: in IsTerminalState()
315 case State::kTraceEnded: in IsTerminalState()
324 bool OnStateChanged(Handle handle, State state) { in OnStateChanged()
338 case State::kTraceFailed: in OnStateChanged()
341 case State::kConnectionError: in OnStateChanged()
346 case State::kConnecting: in OnStateChanged()
347 case State::kConfigured: in OnStateChanged()
348 case State::kTracing: in OnStateChanged()
352 case State::kTraceEnded: // XX: do we even need to emit the 'TraceEnded' state? in OnStateChanged()
362 if (last_state == State::kConfigured && state == State::kConnectionError) { in OnStateChanged()
381 last_state = State::kSessionNotFound; in OnCreateFailed()
395 static void CallbackOnStateChanged(Handle handle, State state, void* callback_arg) { in CallbackOnStateChanged()
432 void EmitNext(State state) { in EmitNext()
681 using State = ::perfetto::consumer::State; in CreatePerfettoStream() typedef
727 && state_change.state == State::kConfigured) { in CreatePerfettoStream()
731 state_change.state == State::kTraceEnded) { in CreatePerfettoStream()
808 using State = ::perfetto::consumer::State; in CollectPerfettoTraceBufferImmediately() typedef
810 case State::kConnecting: in CollectPerfettoTraceBufferImmediately()
814 case State::kConfigured: in CollectPerfettoTraceBufferImmediately()
817 case State::kTracing: in CollectPerfettoTraceBufferImmediately()
821 case State::kTraceEnded: { in CollectPerfettoTraceBufferImmediately()