Java Hash String hash(String string)

Here you can find the source of hash(String string)

Description

Hashes the specified string.

License

Open Source License

Parameter

Parameter Description
string The string.

Return

The hash.

Declaration

public static int hash(String string) 

Method Source Code

//package com.java2s;
//License from project: Open Source License 

public class Main {
    /**//from w  w w.  j av  a  2  s  .c  om
     * Hashes the specified string.
     *
     * @param string The string.
     * @return The hash.
     */
    public static int hash(String string) {
        return string.hashCode();
    }
}

Related

  1. hash(String s)
  2. hash(String s, int start, int end)
  3. hash(String src)
  4. hash(String str, int max)
  5. hash(String str, int offset)
  6. hash(String string, int length)
  7. hash(String strPlain)
  8. hash32(String data)
  9. hashAlgToId(String hashAlg)