diff options
author | Treehugger Robot <treehugger-gerrit@google.com> | 2017-08-24 21:25:49 +0000 |
---|---|---|
committer | Gerrit Code Review <noreply-gerritcodereview@google.com> | 2017-08-24 21:25:49 +0000 |
commit | 94bbd4256d7261aa1d8ddf660e7856cde5afa49f (patch) | |
tree | 8299c300f3b4dbc2a5360c3319ac41bf1b389e55 /framework/java/android/bluetooth/BluetoothHealthAppConfiguration.java | |
parent | 931010f176faa894f06051c57290f7723dfbcd49 (diff) | |
parent | 9e045d26d0128826b40520f523307d8d16473779 (diff) |
Merge changes from topic "bt-fix-checkstyle-errors"
* changes:
Fix checkstyle errors (2/2)
Fix checkstyle errors (1/2)
Diffstat (limited to 'framework/java/android/bluetooth/BluetoothHealthAppConfiguration.java')
-rw-r--r-- | framework/java/android/bluetooth/BluetoothHealthAppConfiguration.java | 59 |
1 files changed, 27 insertions, 32 deletions
diff --git a/framework/java/android/bluetooth/BluetoothHealthAppConfiguration.java b/framework/java/android/bluetooth/BluetoothHealthAppConfiguration.java index 1717a1e36e..7c9db6f721 100644 --- a/framework/java/android/bluetooth/BluetoothHealthAppConfiguration.java +++ b/framework/java/android/bluetooth/BluetoothHealthAppConfiguration.java @@ -25,7 +25,6 @@ import android.os.Parcelable; * the {@link BluetoothHealth} class. This class represents an application configuration * that the Bluetooth Health third party application will register to communicate with the * remote Bluetooth health device. - * */ public final class BluetoothHealthAppConfiguration implements Parcelable { private final String mName; @@ -52,12 +51,11 @@ public final class BluetoothHealthAppConfiguration implements Parcelable { * * @param name Friendly name associated with the application configuration * @param dataType Data Type of the remote Bluetooth Health device - * @param role {@link BluetoothHealth#SOURCE_ROLE} or - * {@link BluetoothHealth#SINK_ROLE} + * @param role {@link BluetoothHealth#SOURCE_ROLE} or {@link BluetoothHealth#SINK_ROLE} * @hide */ BluetoothHealthAppConfiguration(String name, int dataType, int role, int - channelType) { + channelType) { mName = name; mDataType = dataType; mRole = role; @@ -71,10 +69,8 @@ public final class BluetoothHealthAppConfiguration implements Parcelable { if (mName == null) return false; - return mName.equals(config.getName()) && - mDataType == config.getDataType() && - mRole == config.getRole() && - mChannelType == config.getChannelType(); + return mName.equals(config.getName()) && mDataType == config.getDataType() + && mRole == config.getRole() && mChannelType == config.getChannelType(); } return false; } @@ -91,11 +87,11 @@ public final class BluetoothHealthAppConfiguration implements Parcelable { @Override public String toString() { - return "BluetoothHealthAppConfiguration [mName = " + mName + - ",mDataType = " + mDataType + ", mRole = " + mRole + ",mChannelType = " + - mChannelType + "]"; + return "BluetoothHealthAppConfiguration [mName = " + mName + ",mDataType = " + mDataType + + ", mRole = " + mRole + ",mChannelType = " + mChannelType + "]"; } + @Override public int describeContents() { return 0; } @@ -121,8 +117,7 @@ public final class BluetoothHealthAppConfiguration implements Parcelable { /** * Return the role associated with this application configuration. * - * @return One of {@link BluetoothHealth#SOURCE_ROLE} or - * {@link BluetoothHealth#SINK_ROLE} + * @return One of {@link BluetoothHealth#SOURCE_ROLE} or {@link BluetoothHealth#SINK_ROLE} */ public int getRole() { return mRole; @@ -131,9 +126,8 @@ public final class BluetoothHealthAppConfiguration implements Parcelable { /** * Return the channel type associated with this application configuration. * - * @return One of {@link BluetoothHealth#CHANNEL_TYPE_RELIABLE} or - * {@link BluetoothHealth#CHANNEL_TYPE_STREAMING} or - * {@link BluetoothHealth#CHANNEL_TYPE_ANY}. + * @return One of {@link BluetoothHealth#CHANNEL_TYPE_RELIABLE} or {@link + * BluetoothHealth#CHANNEL_TYPE_STREAMING} or {@link BluetoothHealth#CHANNEL_TYPE_ANY}. * @hide */ public int getChannelType() { @@ -141,23 +135,24 @@ public final class BluetoothHealthAppConfiguration implements Parcelable { } public static final Parcelable.Creator<BluetoothHealthAppConfiguration> CREATOR = - new Parcelable.Creator<BluetoothHealthAppConfiguration>() { - @Override - public BluetoothHealthAppConfiguration createFromParcel(Parcel in) { - String name = in.readString(); - int type = in.readInt(); - int role = in.readInt(); - int channelType = in.readInt(); - return new BluetoothHealthAppConfiguration(name, type, role, - channelType); - } - - @Override - public BluetoothHealthAppConfiguration[] newArray(int size) { - return new BluetoothHealthAppConfiguration[size]; - } - }; + new Parcelable.Creator<BluetoothHealthAppConfiguration>() { + @Override + public BluetoothHealthAppConfiguration createFromParcel(Parcel in) { + String name = in.readString(); + int type = in.readInt(); + int role = in.readInt(); + int channelType = in.readInt(); + return new BluetoothHealthAppConfiguration(name, type, role, + channelType); + } + + @Override + public BluetoothHealthAppConfiguration[] newArray(int size) { + return new BluetoothHealthAppConfiguration[size]; + } + }; + @Override public void writeToParcel(Parcel out, int flags) { out.writeString(mName); out.writeInt(mDataType); |