Aurimas Liutikas | bcfbe3a | 2023-10-30 15:25:21 -0700 | [diff] [blame] | 1 | /* |
| 2 | * This file is auto-generated. DO NOT MODIFY. |
| 3 | */ |
| 4 | package android.media; |
| 5 | /** {@hide} */ |
| 6 | public class VolumeShaperState implements android.os.Parcelable |
| 7 | { |
| 8 | /** Linear volume in the range MIN_LINEAR_VOLUME to MAX_LINEAR_VOLUME. */ |
| 9 | public float volume = 0.000000f; |
| 10 | /** Position on curve expressed from MIN_CURVE_TIME to MAX_CURVE_TIME. */ |
| 11 | public float xOffset = 0.000000f; |
| 12 | public static final android.os.Parcelable.Creator<VolumeShaperState> CREATOR = new android.os.Parcelable.Creator<VolumeShaperState>() { |
| 13 | @Override |
| 14 | public VolumeShaperState createFromParcel(android.os.Parcel _aidl_source) { |
| 15 | VolumeShaperState _aidl_out = new VolumeShaperState(); |
| 16 | _aidl_out.readFromParcel(_aidl_source); |
| 17 | return _aidl_out; |
| 18 | } |
| 19 | @Override |
| 20 | public VolumeShaperState[] newArray(int _aidl_size) { |
| 21 | return new VolumeShaperState[_aidl_size]; |
| 22 | } |
| 23 | }; |
| 24 | @Override public final void writeToParcel(android.os.Parcel _aidl_parcel, int _aidl_flag) |
| 25 | { |
| 26 | int _aidl_start_pos = _aidl_parcel.dataPosition(); |
| 27 | _aidl_parcel.writeInt(0); |
| 28 | _aidl_parcel.writeFloat(volume); |
| 29 | _aidl_parcel.writeFloat(xOffset); |
| 30 | int _aidl_end_pos = _aidl_parcel.dataPosition(); |
| 31 | _aidl_parcel.setDataPosition(_aidl_start_pos); |
| 32 | _aidl_parcel.writeInt(_aidl_end_pos - _aidl_start_pos); |
| 33 | _aidl_parcel.setDataPosition(_aidl_end_pos); |
| 34 | } |
| 35 | public final void readFromParcel(android.os.Parcel _aidl_parcel) |
| 36 | { |
| 37 | int _aidl_start_pos = _aidl_parcel.dataPosition(); |
| 38 | int _aidl_parcelable_size = _aidl_parcel.readInt(); |
| 39 | try { |
| 40 | if (_aidl_parcelable_size < 4) throw new android.os.BadParcelableException("Parcelable too small");; |
| 41 | if (_aidl_parcel.dataPosition() - _aidl_start_pos >= _aidl_parcelable_size) return; |
| 42 | volume = _aidl_parcel.readFloat(); |
| 43 | if (_aidl_parcel.dataPosition() - _aidl_start_pos >= _aidl_parcelable_size) return; |
| 44 | xOffset = _aidl_parcel.readFloat(); |
| 45 | } finally { |
| 46 | if (_aidl_start_pos > (Integer.MAX_VALUE - _aidl_parcelable_size)) { |
| 47 | throw new android.os.BadParcelableException("Overflow in the size of parcelable"); |
| 48 | } |
| 49 | _aidl_parcel.setDataPosition(_aidl_start_pos + _aidl_parcelable_size); |
| 50 | } |
| 51 | } |
| 52 | @Override |
| 53 | public int describeContents() { |
| 54 | int _mask = 0; |
| 55 | return _mask; |
| 56 | } |
| 57 | } |