Example usage for java.lang.reflect Method hashCode

List of usage examples for java.lang.reflect Method hashCode

Introduction

In this page you can find the example usage for java.lang.reflect Method hashCode.

Prototype

public int hashCode() 

Source Link

Document

Returns a hashcode for this Method .

Usage

From source file:Main.java

public static void printMethods(Class cl) {
    Method[] methods = cl.getDeclaredMethods();

    for (int i = 0; i < methods.length; i++) {
        Method m = methods[i];
        System.out.println(m.hashCode());

    }//w  ww .jav  a2  s . com
}

From source file:org.gachette.spi.graphprovider.collection.CollectionGraphProvider.java

private int calculateEvaluatorKey(Object object, Method method, Object[] parameters) {
    int hash = 1;
    hash = hash * 17 + object.hashCode();
    hash = hash * 31 + method.hashCode();
    if (parameters != null) {
        hash = hash * 13 + Arrays.hashCode(parameters);
    }/*from  w w  w .j a  v a 2  s  .c o m*/
    return hash;
}