/foundation/multimedia/media_foundation/engine/scene/recorder/internal/ |
H A D | state.h | 43 enum class Intent { class 76 virtual std::tuple<ErrorCode, Action> Enter(Intent intent); 78 std::tuple<ErrorCode, Action> Execute(Intent intent, const Plugin::Any& param); 99 std::tuple<ErrorCode, Action> DispatchIntent(Intent intent, const Plugin::Any& param); 104 const std::map<Intent, std::string> intentDesc_ = { 105 {Intent::SET_OBS, "SET_OBS"}, 106 {Intent::SET_VIDEO_SOURCE, "SET_VIDEO_SOURCE"}, 107 {Intent::SET_AUDIO_SOURCE, "SET_AUDIO_SOURCE"}, 108 {Intent::SET_OUTPUT_FORMAT, "SET_OUTPUT_FORMAT"}, 109 {Intent [all...] |
H A D | state_machine.h | 61 ErrorCode SendEvent(Intent intent, const Plugin::Any& param = {}); 63 ErrorCode SendEvent(Intent intent, const Plugin::Any& param = {}) const; 65 ErrorCode SendEventAsync(Intent intent, const Plugin::Any& param = {}); 67 ErrorCode SendEventAsync(Intent intent, const Plugin::Any& param = {}) const; 72 Action ProcessIntent(Intent intent, const Plugin::Any& param); 82 void OnIntentExecuted(Intent intent, Action action, ErrorCode result); 85 mutable OSAL::Synchronizer<Intent, ErrorCode> intentSync_; 87 mutable Intent lastIntent {Intent::INTENT_BUTT};
|
H A D | state_machine.cpp | 64 ErrorCode StateMachine::SendEvent(Intent intent, const Plugin::Any& param) const in SendEvent() 69 ErrorCode StateMachine::SendEvent(Intent intent, const Plugin::Any& param) in SendEvent() 82 ErrorCode StateMachine::SendEventAsync(Intent intent, const Plugin::Any& param) const in SendEventAsync() 87 ErrorCode StateMachine::SendEventAsync(Intent intent, const Plugin::Any& param) in SendEventAsync() 96 Action StateMachine::ProcessIntent(Intent intent, const Plugin::Any& param) in ProcessIntent() 217 void StateMachine::OnIntentExecuted(Intent intent, Action action, ErrorCode result) in OnIntentExecuted() 225 if (intent == Intent::NOTIFY_READY && action == Action::TRANS_TO_RECORDING) { in OnIntentExecuted() 226 intentSync_.Notify(Intent::START, result); in OnIntentExecuted()
|
H A D | recording_state.h | 35 std::tuple<ErrorCode, Action> Enter(Intent intent) override 39 if (intent == Intent::RESUME) {
|
H A D | state.cpp | 28 std::tuple<ErrorCode, Action> State::Enter(Intent intent) in Enter() 40 std::tuple<ErrorCode, Action> State::Execute(Intent intent, const Plugin::Any& param) in Execute() 136 std::tuple<ErrorCode, Action> State::DispatchIntent(Intent intent, const Plugin::Any& param) in DispatchIntent()
|
H A D | pause_state.h | 34 std::tuple<ErrorCode, Action> Enter(Intent) override
|
/foundation/multimedia/media_foundation/engine/scene/player/internal/ |
H A D | state.cpp | 39 const char* State::GetIntentName(Intent intent) in GetIntentName() 41 static const std::map<Intent, const char*> intentDesc = { in GetIntentName() 42 {Intent::SET_SOURCE, "SET_SOURCE"}, in GetIntentName() 43 {Intent::PREPARE, "PREPARE"}, in GetIntentName() 44 {Intent::SEEK, "SEEK"}, in GetIntentName() 45 {Intent::PLAY, "PLAY"}, in GetIntentName() 46 {Intent::PAUSE, "PAUSE"}, in GetIntentName() 47 {Intent::RESUME, "RESUME"}, in GetIntentName() 48 {Intent::STOP, "STOP"}, in GetIntentName() 49 {Intent in GetIntentName() [all...] |
H A D | state_machine.h | 55 ErrorCode SendEvent(Intent intent, const Plugin::Any& param = {}); 57 ErrorCode SendEvent(Intent intent, const Plugin::Any& param = {}) const; 59 ErrorCode SendEventAsync(Intent intent, const Plugin::Any& param = {}); 61 ErrorCode SendEventAsync(Intent intent, const Plugin::Any& param = {}) const; 63 void Notify(Intent intent, ErrorCode code); 68 Action ProcessIntent(Intent intent, const Plugin::Any& param); 78 void OnIntentExecuted(Intent intent, Action action, ErrorCode result); 81 mutable OSAL::Synchronizer<Intent, ErrorCode> intentSync_; 83 mutable Intent lastIntent {Intent [all...] |
H A D | state.h | 42 enum class Intent { class 75 virtual std::tuple<ErrorCode, Action> Enter(Intent intent); 77 std::tuple<ErrorCode, Action> Execute(Intent intent, const Plugin::Any& param); 94 static const char* GetIntentName(Intent intent); 98 std::tuple<ErrorCode, Action> DispatchIntent(Intent intent, const Plugin::Any& param);
|
H A D | state_machine.cpp | 73 ErrorCode StateMachine::SendEvent(Intent intent, const Plugin::Any& param) const in SendEvent() 78 ErrorCode StateMachine::SendEvent(Intent intent, const Plugin::Any& param) in SendEvent() 91 ErrorCode StateMachine::SendEventAsync(Intent intent, const Plugin::Any& param) const in SendEventAsync() 96 ErrorCode StateMachine::SendEventAsync(Intent intent, const Plugin::Any& param) in SendEventAsync() 106 Action StateMachine::ProcessIntent(Intent intent, const Plugin::Any& param) in ProcessIntent() 236 void StateMachine::OnIntentExecuted(Intent intent, Action action, ErrorCode result) in OnIntentExecuted() 247 if (intent == Intent::NOTIFY_READY && action == Action::TRANS_TO_PLAYING) { in OnIntentExecuted() 248 intentSync_.Notify(Intent::PLAY, result); in OnIntentExecuted() 254 void StateMachine::Notify(Intent intent, ErrorCode code) in Notify()
|
H A D | playing_state.h | 35 std::tuple<ErrorCode, Action> Enter(Intent intent) override 39 if (intent == Intent::RESUME) {
|
H A D | stopped_state.h | 27 std::tuple<ErrorCode, Action> Enter(Intent) override
|
H A D | idle_state.h | 40 std::tuple<ErrorCode, Action> Enter(Intent) override
|
H A D | preparing_state.h | 35 std::tuple<ErrorCode, Action> Enter(Intent) override
|
H A D | ready_state.h | 35 std::tuple<ErrorCode, Action> Enter(Intent intent) override
|
H A D | eos_state.h | 47 std::tuple<ErrorCode, Action> Enter(Intent intent) override
|
H A D | pause_state.h | 35 std::tuple<ErrorCode, Action> Enter(Intent) override
|
/foundation/multimedia/media_foundation/test/unittest/ |
H A D | TestStateMachine.cpp | 55 stateMachine_->SendEventAsync(Intent::STOP); 96 EXPECT_EQ(ErrorCode::ERROR_INVALID_PARAMETER_TYPE, stateMachine.SendEvent(Intent::SET_SOURCE)); in TEST_F() 104 EXPECT_EQ(ErrorCode::SUCCESS, stateMachine.SendEvent(Intent::SET_SOURCE, source)); in TEST_F() 111 EXPECT_EQ(ErrorCode::SUCCESS, stateMachine.SendEvent(Intent::PREPARE)); in TEST_F() 118 EXPECT_EQ(ErrorCode::SUCCESS, stateMachine.SendEvent(Intent::NOTIFY_ERROR)); in TEST_F() 126 EXPECT_EQ(ErrorCode::SUCCESS, stateMachine.SendEvent(Intent::SET_SOURCE, source)); in TEST_F() 128 EXPECT_EQ(ErrorCode::SUCCESS, stateMachine.SendEvent(Intent::PREPARE)); in TEST_F() 130 EXPECT_EQ(ErrorCode::SUCCESS, stateMachine.SendEvent(Intent::NOTIFY_READY)); in TEST_F() 137 EXPECT_EQ(ErrorCode::SUCCESS, stateMachine.SendEvent(Intent::PLAY)); in TEST_F() 144 EXPECT_EQ(ErrorCode::SUCCESS, stateMachine.SendEvent(Intent in TEST_F() [all...] |
/foundation/multimedia/media_foundation/engine/scene/recorder/standard/ |
H A D | hirecorder_impl.cpp | 54 fsm_.SendEvent(Intent::RESET); in ~HiRecorderImpl() 147 auto ret = fsm_.SendEvent(Intent::SET_OUTPUT_FORMAT, outputFormatType_); 171 auto ret = fsm_.SendEvent(Intent::CONFIGURE, hstRecParam); in Configure() 183 auto ret = fsm_.SendEvent(Intent::PREPARE); in Prepare() 212 ret = fsm_.SendEvent(Intent::RESUME); in Start() 214 ret = fsm_.SendEvent(Intent::START); in Start() 225 auto ret = TransErrorCode(fsm_.SendEvent(Intent::PAUSE)); in Pause() 235 auto ret = TransErrorCode(fsm_.SendEvent(Intent::RESUME)); in Resume() 247 auto ret = TransErrorCode(fsm_.SendEvent(Intent::STOP, isDrainAll)); in Stop() 267 auto ret = TransErrorCode(fsm_.SendEvent(Intent in Reset() [all...] |
/foundation/multimedia/media_foundation/engine/scene/player/lite/ |
H A D | hiplayer_impl.cpp | 94 fsm_.SendEventAsync(Intent::STOP); in ~HiPlayerImpl() 138 ret = CppExt::to_underlying(fsm_.SendEvent(Intent::SET_SOURCE, mediaSource)); in SetSource() 151 auto ret = fsm_.SendEvent(Intent::PREPARE); in Prepare() 185 ret = fsm_.SendEvent(Intent::RESUME); in Play() 187 ret = fsm_.SendEvent(Intent::PLAY); in Play() 202 auto ret = CppExt::to_underlying(fsm_.SendEvent(Intent::PAUSE)); in Pause() 211 auto ret = CppExt::to_underlying(fsm_.SendEvent(Intent::STOP)); in Stop() 219 return fsm_.SendEventAsync(Intent::STOP); in StopAsync() 240 return CppExt::to_underlying(fsm_.SendEvent(Intent::SEEK, SeekInfo{hstTime, smode})); in Rewind() 288 fsm_.SendEventAsync(Intent in OnEvent() [all...] |
/foundation/bundlemanager/bundle_framework/services/bundlemgr/src/ |
H A D | bundle_profile.cpp | 298 struct Intent { struct 317 std::vector<Intent> intents; 1400 void from_json(const nlohmann::json &jsonObject, Intent &intents) in from_json() 1484 GetValueIfFindKey<std::vector<Intent>>(jsonObject, in from_json()
|