Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 301abd2e authored by Jayachandran Chinnakkannu's avatar Jayachandran Chinnakkannu Committed by Gerrit Code Review
Browse files

Merge "Fix QOS API review comments"

parents 9575e877 eb1bdda9
Loading
Loading
Loading
Loading
+12 −12
Original line number Diff line number Diff line
@@ -10686,11 +10686,11 @@ package android.telephony.data {
  public final class EpsBearerQosSessionAttributes implements android.os.Parcelable android.net.QosSessionAttributes {
    method public int describeContents();
    method public long getGuaranteedDownlinkBitRate();
    method public long getGuaranteedUplinkBitRate();
    method public long getMaxDownlinkBitRate();
    method public long getMaxUplinkBitRate();
    method public int getQci();
    method public long getGuaranteedDownlinkBitRateKbps();
    method public long getGuaranteedUplinkBitRateKbps();
    method public long getMaxDownlinkBitRateKbps();
    method public long getMaxUplinkBitRateKbps();
    method public int getQosIdentifier();
    method @NonNull public java.util.List<java.net.InetSocketAddress> getRemoteAddresses();
    method public void writeToParcel(@NonNull android.os.Parcel, int);
    field @NonNull public static final android.os.Parcelable.Creator<android.telephony.data.EpsBearerQosSessionAttributes> CREATOR;
@@ -10698,13 +10698,13 @@ package android.telephony.data {
  public final class NrQosSessionAttributes implements android.os.Parcelable android.net.QosSessionAttributes {
    method public int describeContents();
    method public int get5Qi();
    method public long getAveragingWindow();
    method public long getGuaranteedDownlinkBitRate();
    method public long getGuaranteedUplinkBitRate();
    method public long getMaxDownlinkBitRate();
    method public long getMaxUplinkBitRate();
    method public int getQfi();
    method @NonNull public java.time.Duration getBitRateWindowDuration();
    method public long getGuaranteedDownlinkBitRateKbps();
    method public long getGuaranteedUplinkBitRateKbps();
    method public long getMaxDownlinkBitRateKbps();
    method public long getMaxUplinkBitRateKbps();
    method @IntRange(from=1, to=63) public int getQosFlowIdentifier();
    method public int getQosIdentifier();
    method @NonNull public java.util.List<java.net.InetSocketAddress> getRemoteAddresses();
    method public void writeToParcel(@NonNull android.os.Parcel, int);
    field @NonNull public static final android.os.Parcelable.Creator<android.telephony.data.NrQosSessionAttributes> CREATOR;
+5 −5
Original line number Diff line number Diff line
@@ -53,7 +53,7 @@ public final class EpsBearerQosSessionAttributes implements Parcelable, QosSessi
     *
     * @return the qci of the session
     */
    public int getQci() {
    public int getQosIdentifier() {
        return mQci;
    }

@@ -66,7 +66,7 @@ public final class EpsBearerQosSessionAttributes implements Parcelable, QosSessi
     *
     * @return the guaranteed bit rate in kbps
     */
    public long getGuaranteedUplinkBitRate() {
    public long getGuaranteedUplinkBitRateKbps() {
        return mGuaranteedUplinkBitRate;
    }

@@ -79,7 +79,7 @@ public final class EpsBearerQosSessionAttributes implements Parcelable, QosSessi
     *
     * @return the guaranteed bit rate in kbps
     */
    public long getGuaranteedDownlinkBitRate() {
    public long getGuaranteedDownlinkBitRateKbps() {
        return mGuaranteedDownlinkBitRate;
    }

@@ -92,7 +92,7 @@ public final class EpsBearerQosSessionAttributes implements Parcelable, QosSessi
     *
     * @return the max uplink bit rate in kbps
     */
    public long getMaxUplinkBitRate() {
    public long getMaxUplinkBitRateKbps() {
        return mMaxUplinkBitRate;
    }

@@ -105,7 +105,7 @@ public final class EpsBearerQosSessionAttributes implements Parcelable, QosSessi
     *
     * @return the max downlink bit rate in kbps
     */
    public long getMaxDownlinkBitRate() {
    public long getMaxDownlinkBitRateKbps() {
        return mMaxDownlinkBitRate;
    }

+12 −9
Original line number Diff line number Diff line
@@ -16,6 +16,7 @@

package android.telephony.data;

import android.annotation.IntRange;
import android.annotation.NonNull;
import android.annotation.SystemApi;
import android.net.QosSessionAttributes;
@@ -26,6 +27,7 @@ import android.util.Log;
import java.net.InetAddress;
import java.net.InetSocketAddress;
import java.net.UnknownHostException;
import java.time.Duration;
import java.util.ArrayList;
import java.util.Collections;
import java.util.List;
@@ -40,7 +42,7 @@ import java.util.Objects;
public final class NrQosSessionAttributes implements Parcelable, QosSessionAttributes {
    private static final String TAG = NrQosSessionAttributes.class.getSimpleName();
    private final int m5Qi;
    private final int mQfi;
    private final @IntRange(from=1, to=63) int mQfi;
    private final long mMaxUplinkBitRate;
    private final long mMaxDownlinkBitRate;
    private final long mGuaranteedUplinkBitRate;
@@ -55,7 +57,7 @@ public final class NrQosSessionAttributes implements Parcelable, QosSessionAttri
     *
     * @return the 5QI of the QOS flow
     */
    public int get5Qi() {
    public int getQosIdentifier() {
        return m5Qi;
    }

@@ -65,7 +67,7 @@ public final class NrQosSessionAttributes implements Parcelable, QosSessionAttri
     *
     * @return the QOS flow identifier of the session
     */
    public int getQfi() {
    public @IntRange(from=1, to=63) int getQosFlowIdentifier() {
        return mQfi;
    }

@@ -78,7 +80,7 @@ public final class NrQosSessionAttributes implements Parcelable, QosSessionAttri
     *
     * @return the guaranteed bit rate in kbps
     */
    public long getGuaranteedUplinkBitRate() {
    public long getGuaranteedUplinkBitRateKbps() {
        return mGuaranteedUplinkBitRate;
    }

@@ -91,7 +93,7 @@ public final class NrQosSessionAttributes implements Parcelable, QosSessionAttri
     *
     * @return the guaranteed bit rate in kbps
     */
    public long getGuaranteedDownlinkBitRate() {
    public long getGuaranteedDownlinkBitRateKbps() {
        return mGuaranteedDownlinkBitRate;
    }

@@ -104,7 +106,7 @@ public final class NrQosSessionAttributes implements Parcelable, QosSessionAttri
     *
     * @return the max uplink bit rate in kbps
     */
    public long getMaxUplinkBitRate() {
    public long getMaxUplinkBitRateKbps() {
        return mMaxUplinkBitRate;
    }

@@ -117,7 +119,7 @@ public final class NrQosSessionAttributes implements Parcelable, QosSessionAttri
     *
     * @return the max downlink bit rate in kbps
     */
    public long getMaxDownlinkBitRate() {
    public long getMaxDownlinkBitRateKbps() {
        return mMaxDownlinkBitRate;
    }

@@ -129,8 +131,9 @@ public final class NrQosSessionAttributes implements Parcelable, QosSessionAttri
     *
     * @return the averaging window duration in milliseconds
     */
    public long getAveragingWindow() {
        return mAveragingWindow;
    @NonNull
    public Duration getBitRateWindowDuration() {
        return Duration.ofMillis(mAveragingWindow);
    }

    /**