Address Tuner Filter Delay API review feedback
Bug: 213174673 Test: atest android.media.tv.tuner.cts.TunerTest Change-Id: I601967d7c57f1026a518185ed35d4c25d56bebeb
This commit is contained in:
@@ -6716,8 +6716,8 @@ package android.media.tv.tuner.filter {
|
||||
method @Nullable public String acquireSharedFilterToken();
|
||||
method public void close();
|
||||
method public int configure(@NonNull android.media.tv.tuner.filter.FilterConfiguration);
|
||||
method public int delayCallbackUntilBufferFilled(int);
|
||||
method public int delayCallbackUntilTimeMillis(long);
|
||||
method public int delayCallbackUntilBytesAccumulated(int);
|
||||
method public int delayCallbackUntilMillisElapsed(long);
|
||||
method public int flush();
|
||||
method public void freeSharedFilterToken(@NonNull String);
|
||||
method @Deprecated public int getId();
|
||||
|
||||
@@ -612,8 +612,12 @@ public class Filter implements AutoCloseable {
|
||||
* be a no-op. Use {@link TunerVersionChecker#getTunerVersion()} to get the version information.
|
||||
*
|
||||
* @param delayInMs specifies the duration of the delay in milliseconds.
|
||||
* @return one of the following results: {@link Tuner#RESULT_SUCCESS},
|
||||
* {@link Tuner#RESULT_UNAVAILABLE}, {@link Tuner#RESULT_NOT_INITIALIZED},
|
||||
* {@link Tuner#RESULT_INVALID_STATE}, {@link Tuner#RESULT_INVALID_ARGUMENT},
|
||||
* {@link Tuner#RESULT_OUT_OF_MEMORY}, or {@link Tuner#RESULT_UNKNOWN_ERROR}.
|
||||
*/
|
||||
public int delayCallbackUntilTimeMillis(long delayInMs) {
|
||||
public int delayCallbackUntilMillisElapsed(long delayInMs) {
|
||||
if (!TunerVersionChecker.checkHigherOrEqualVersionTo(
|
||||
TunerVersionChecker.TUNER_VERSION_2_0, "setTimeDelayHint")) {
|
||||
return Tuner.RESULT_UNAVAILABLE;
|
||||
@@ -638,8 +642,12 @@ public class Filter implements AutoCloseable {
|
||||
* be a no-op. Use {@link TunerVersionChecker#getTunerVersion()} to get the version information.
|
||||
*
|
||||
* @param delayInBytes specifies the duration of the delay in bytes.
|
||||
* @return one of the following results: {@link Tuner#RESULT_SUCCESS},
|
||||
* {@link Tuner#RESULT_UNAVAILABLE}, {@link Tuner#RESULT_NOT_INITIALIZED},
|
||||
* {@link Tuner#RESULT_INVALID_STATE}, {@link Tuner#RESULT_INVALID_ARGUMENT},
|
||||
* {@link Tuner#RESULT_OUT_OF_MEMORY}, or {@link Tuner#RESULT_UNKNOWN_ERROR}.
|
||||
*/
|
||||
public int delayCallbackUntilBufferFilled(int delayInBytes) {
|
||||
public int delayCallbackUntilBytesAccumulated(int delayInBytes) {
|
||||
if (!TunerVersionChecker.checkHigherOrEqualVersionTo(
|
||||
TunerVersionChecker.TUNER_VERSION_2_0, "setTimeDelayHint")) {
|
||||
return Tuner.RESULT_UNAVAILABLE;
|
||||
|
||||
Reference in New Issue
Block a user