Loading media/libmediatranscoding/aidl/android/media/ITranscodingClientCallback.aidl +24 −0 Original line number Diff line number Diff line Loading @@ -39,6 +39,30 @@ interface ITranscodingClientCallback { ParcelFileDescriptor openFileDescriptor(in @utf8InCpp String fileUri, in @utf8InCpp String mode); /** * Called when the transcoding associated with the jobId finished. * This will only be called if client request to get all the status of the job. * * @param jobId jobId assigned by the MediaTranscodingService upon receiving request. */ oneway void onTranscodingStarted(in int jobId); /** * Called when the transcoding associated with the jobId is paused. * This will only be called if client request to get all the status of the job. * * @param jobId jobId assigned by the MediaTranscodingService upon receiving request. */ oneway void onTranscodingPaused(in int jobId); /** * Called when the transcoding associated with the jobId is resumed. * This will only be called if client request to get all the status of the job. * * @param jobId jobId assigned by the MediaTranscodingService upon receiving request. */ oneway void onTranscodingResumed(in int jobId); /** * Called when the transcoding associated with the jobId finished. * Loading media/libmediatranscoding/aidl/android/media/TranscodingRequestParcel.aidl +8 −2 Original line number Diff line number Diff line Loading @@ -58,8 +58,15 @@ parcelable TranscodingRequestParcel { /** * Whether to receive update on progress and change of awaitNumJobs. * Default to false. */ boolean requestUpdate; boolean requestProgressUpdate = false; /** * Whether to receive update on job's start/stop/pause/resume. * Default to false. */ boolean requestJobEventUpdate = false; /** * Whether this request is for testing. Loading @@ -69,6 +76,5 @@ parcelable TranscodingRequestParcel { /** * Test configuration. This is only valid when isForTesting is set to true. */ TranscodingTestConfig testConfig; } media/libmediatranscoding/include/media/TranscodingRequest.h +2 −1 Original line number Diff line number Diff line Loading @@ -39,7 +39,8 @@ private: destinationFilePath = parcel.destinationFilePath; transcodingType = parcel.transcodingType; priority = parcel.priority; requestUpdate = parcel.requestUpdate; requestProgressUpdate = parcel.requestProgressUpdate; requestJobEventUpdate = parcel.requestJobEventUpdate; isForTesting = parcel.isForTesting; testConfig = parcel.testConfig; } Loading media/libmediatranscoding/tests/TranscodingClientManager_tests.cpp +6 −0 Original line number Diff line number Diff line Loading @@ -64,6 +64,12 @@ struct TestClientCallback : public BnTranscodingClientCallback { return Status::ok(); } Status onTranscodingStarted(int32_t /*in_jobId*/) override { return Status::ok(); } Status onTranscodingPaused(int32_t /*in_jobId*/) override { return Status::ok(); } Status onTranscodingResumed(int32_t /*in_jobId*/) override { return Status::ok(); } Status onTranscodingFinished(int32_t in_jobId, const TranscodingResultParcel& in_result) override { EXPECT_EQ(in_jobId, in_result.jobId); Loading media/libmediatranscoding/tests/TranscodingJobScheduler_tests.cpp +6 −0 Original line number Diff line number Diff line Loading @@ -167,6 +167,12 @@ struct TestClientCallback : public BnTranscodingClientCallback { return Status::ok(); } Status onTranscodingStarted(int32_t /*in_jobId*/) override { return Status::ok(); } Status onTranscodingPaused(int32_t /*in_jobId*/) override { return Status::ok(); } Status onTranscodingResumed(int32_t /*in_jobId*/) override { return Status::ok(); } Status onTranscodingFinished(int32_t in_jobId, const TranscodingResultParcel& in_result) override { EXPECT_EQ(in_jobId, in_result.jobId); Loading Loading
media/libmediatranscoding/aidl/android/media/ITranscodingClientCallback.aidl +24 −0 Original line number Diff line number Diff line Loading @@ -39,6 +39,30 @@ interface ITranscodingClientCallback { ParcelFileDescriptor openFileDescriptor(in @utf8InCpp String fileUri, in @utf8InCpp String mode); /** * Called when the transcoding associated with the jobId finished. * This will only be called if client request to get all the status of the job. * * @param jobId jobId assigned by the MediaTranscodingService upon receiving request. */ oneway void onTranscodingStarted(in int jobId); /** * Called when the transcoding associated with the jobId is paused. * This will only be called if client request to get all the status of the job. * * @param jobId jobId assigned by the MediaTranscodingService upon receiving request. */ oneway void onTranscodingPaused(in int jobId); /** * Called when the transcoding associated with the jobId is resumed. * This will only be called if client request to get all the status of the job. * * @param jobId jobId assigned by the MediaTranscodingService upon receiving request. */ oneway void onTranscodingResumed(in int jobId); /** * Called when the transcoding associated with the jobId finished. * Loading
media/libmediatranscoding/aidl/android/media/TranscodingRequestParcel.aidl +8 −2 Original line number Diff line number Diff line Loading @@ -58,8 +58,15 @@ parcelable TranscodingRequestParcel { /** * Whether to receive update on progress and change of awaitNumJobs. * Default to false. */ boolean requestUpdate; boolean requestProgressUpdate = false; /** * Whether to receive update on job's start/stop/pause/resume. * Default to false. */ boolean requestJobEventUpdate = false; /** * Whether this request is for testing. Loading @@ -69,6 +76,5 @@ parcelable TranscodingRequestParcel { /** * Test configuration. This is only valid when isForTesting is set to true. */ TranscodingTestConfig testConfig; }
media/libmediatranscoding/include/media/TranscodingRequest.h +2 −1 Original line number Diff line number Diff line Loading @@ -39,7 +39,8 @@ private: destinationFilePath = parcel.destinationFilePath; transcodingType = parcel.transcodingType; priority = parcel.priority; requestUpdate = parcel.requestUpdate; requestProgressUpdate = parcel.requestProgressUpdate; requestJobEventUpdate = parcel.requestJobEventUpdate; isForTesting = parcel.isForTesting; testConfig = parcel.testConfig; } Loading
media/libmediatranscoding/tests/TranscodingClientManager_tests.cpp +6 −0 Original line number Diff line number Diff line Loading @@ -64,6 +64,12 @@ struct TestClientCallback : public BnTranscodingClientCallback { return Status::ok(); } Status onTranscodingStarted(int32_t /*in_jobId*/) override { return Status::ok(); } Status onTranscodingPaused(int32_t /*in_jobId*/) override { return Status::ok(); } Status onTranscodingResumed(int32_t /*in_jobId*/) override { return Status::ok(); } Status onTranscodingFinished(int32_t in_jobId, const TranscodingResultParcel& in_result) override { EXPECT_EQ(in_jobId, in_result.jobId); Loading
media/libmediatranscoding/tests/TranscodingJobScheduler_tests.cpp +6 −0 Original line number Diff line number Diff line Loading @@ -167,6 +167,12 @@ struct TestClientCallback : public BnTranscodingClientCallback { return Status::ok(); } Status onTranscodingStarted(int32_t /*in_jobId*/) override { return Status::ok(); } Status onTranscodingPaused(int32_t /*in_jobId*/) override { return Status::ok(); } Status onTranscodingResumed(int32_t /*in_jobId*/) override { return Status::ok(); } Status onTranscodingFinished(int32_t in_jobId, const TranscodingResultParcel& in_result) override { EXPECT_EQ(in_jobId, in_result.jobId); Loading