package androidx.core.util; import android.annotation.SuppressLint; import android.util.Range; import androidx.annotation.RequiresApi; import kotlin.ranges.ClosedRange; @SuppressLint({"ClassVerificationFailure"}) /* loaded from: classes.dex */ public final class RangeKt { @RequiresApi(21) public static final > Range rangeTo(T t, T t2) { return new Range<>(t, t2); } @RequiresApi(21) public static final > Range plus(Range range, T t) { return range.extend((Range) t); } @RequiresApi(21) public static final > Range plus(Range range, Range range2) { return range.extend(range2); } @RequiresApi(21) public static final > Range and(Range range, Range range2) { return range.intersect(range2); } @RequiresApi(21) public static final > ClosedRange toClosedRange(final Range range) { return new ClosedRange() { // from class: androidx.core.util.RangeKt$toClosedRange$1 /* JADX WARN: Incorrect types in method signature: (TT;)Z */ public boolean contains(Comparable comparable) { return ClosedRange.DefaultImpls.contains(this, comparable); } public boolean isEmpty() { return ClosedRange.DefaultImpls.isEmpty(this); } /* JADX WARN: Incorrect return type in method signature: ()TT; */ @Override // kotlin.ranges.ClosedRange public Comparable getEndInclusive() { return range.getUpper(); } /* JADX WARN: Incorrect return type in method signature: ()TT; */ @Override // kotlin.ranges.ClosedRange public Comparable getStart() { return range.getLower(); } }; } @RequiresApi(21) public static final > Range toRange(ClosedRange closedRange) { return new Range<>(closedRange.getStart(), closedRange.getEndInclusive()); } }