webrtc_m130/sdk/android/src/java/org/webrtc/RtcException.java
Byoungchan Lee b244727265 [Android] Add RtcError class and use it in RtpTransceiver.setCodecPreferences
This CL modifies RtpTransceiver.setCodecPreferences to return RtcError
instead of void, making it easier to handle errors when setting
codec preferences. To achieve this, new RtcException and RtcError
classes are introduced to represent errors in WebRTC,
mimicking api/rtc_error.h in C++.

Bug: webrtc:42225493
Change-Id: I0f4c6e56f8f2af3353915a41084f6b7b46d793d4
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/352900
Reviewed-by: Zoé Lepaul <xalep@webrtc.org>
Commit-Queue: Zoé Lepaul <xalep@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#42476}
2024-06-13 13:57:21 +00:00

23 lines
709 B
Java

/*
* Copyright (c) 2024 The WebRTC project authors. All Rights Reserved.
*
* Use of this source code is governed by a BSD-style license
* that can be found in the LICENSE file in the root of the source
* tree. An additional intellectual property rights grant can be found
* in the file PATENTS. All contributing project authors may
* be found in the AUTHORS file in the root of the source tree.
*/
package org.webrtc;
/**
* RtcException represents exceptions that are specific to the WebRTC library. Refer to the file
* api/rtc_error.h for more information.
*/
public class RtcException extends RuntimeException {
public RtcException(String message) {
super(message);
}
}