From 5f61416305c47c4db0b94c0cf500e9a9d11d4cdb Mon Sep 17 00:00:00 2001 From: Kenny Root Date: Wed, 17 Feb 2010 12:00:37 -0800 Subject: Add hashCode() to BluetoothService$RemoteService RemoteService is used as a key in a HashMap, so it should have a hashCode() Change-Id: I69b72991474f4d5ec11c0620a6e66eb0c44d04b6 --- core/java/android/server/BluetoothService.java | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'core/java/android/server') diff --git a/core/java/android/server/BluetoothService.java b/core/java/android/server/BluetoothService.java index dfb775f..aa20ac4 100644 --- a/core/java/android/server/BluetoothService.java +++ b/core/java/android/server/BluetoothService.java @@ -136,6 +136,14 @@ public class BluetoothService extends IBluetooth.Stub { } return false; } + + @Override + public int hashCode() { + int hash = 1; + hash = hash * 31 + (address == null ? 0 : address.hashCode()); + hash = hash * 31 + (uuid == null ? 0 : uuid.hashCode()); + return hash; + } } static { -- cgit v1.1