equal
deleted
inserted
replaced
1 /* |
1 /* |
2 * Copyright (c) 1994, 2011, Oracle and/or its affiliates. All rights reserved. |
2 * Copyright (c) 1994, 2013, Oracle and/or its affiliates. All rights reserved. |
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. |
3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. |
4 * |
4 * |
5 * This code is free software; you can redistribute it and/or modify it |
5 * This code is free software; you can redistribute it and/or modify it |
6 * under the terms of the GNU General Public License version 2 only, as |
6 * under the terms of the GNU General Public License version 2 only, as |
7 * published by the Free Software Foundation. Oracle designates this |
7 * published by the Free Software Foundation. Oracle designates this |
203 |
203 |
204 /** |
204 /** |
205 * Returns a hash code for a {@code boolean} value; compatible with |
205 * Returns a hash code for a {@code boolean} value; compatible with |
206 * {@code Boolean.hashCode()}. |
206 * {@code Boolean.hashCode()}. |
207 * |
207 * |
|
208 * @param value the value to hash |
|
209 * @return a hash code value for a {@code boolean} value. |
208 * @since 1.8 |
210 * @since 1.8 |
209 * |
|
210 * @return a hash code value for a {@code boolean} value. |
|
211 */ |
211 */ |
212 public static int hashCode(boolean value) { |
212 public static int hashCode(boolean value) { |
213 return value ? 1231 : 1237; |
213 return value ? 1231 : 1237; |
214 } |
214 } |
215 |
215 |