Annotate libjingle_peerconnection_java with @Nullable.

Bug: webrtc:8881
Change-Id: Ida2ef6c003567d19529c21629c916ed40e8de3a6
Reviewed-on: https://webrtc-review.googlesource.com/63380
Commit-Queue: Sami Kalliomäki <sakal@webrtc.org>
Reviewed-by: Paulina Hensman <phensman@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#22563}
This commit is contained in:
Sami Kalliomäki
2018-03-22 13:32:44 +01:00
committed by Commit Bot
parent 12d6a49e97
commit e7592d8d5f
47 changed files with 277 additions and 170 deletions

View File

@ -19,6 +19,7 @@ import android.media.MediaCodecInfo;
import android.media.MediaCodecInfo.CodecCapabilities;
import android.media.MediaCodecList;
import android.os.Build;
import javax.annotation.Nullable;
/** Factory for Android hardware VideoDecoders. */
@SuppressWarnings("deprecation") // API level 16 requires use of deprecated methods.
@ -47,6 +48,7 @@ public class HardwareVideoDecoderFactory implements VideoDecoderFactory {
this.fallbackToSoftware = fallbackToSoftware;
}
@Nullable
@Override
public VideoDecoder createDecoder(String codecType) {
VideoCodecType type = VideoCodecType.valueOf(codecType);
@ -70,7 +72,7 @@ public class HardwareVideoDecoderFactory implements VideoDecoderFactory {
sharedContext);
}
private MediaCodecInfo findCodecForType(VideoCodecType type) {
private @Nullable MediaCodecInfo findCodecForType(VideoCodecType type) {
// HW decoding is not supported on builds before KITKAT.
if (Build.VERSION.SDK_INT < Build.VERSION_CODES.KITKAT) {
return null;