public GenericEJBInterceptor() {
try
{
// Get the methods from Object
Class[] empty = {};
Class type = Object.class;
TO_STRING = type.getMethod("toString", empty);
HASH_CODE = type.getMethod("hashCode", empty);
EQUALS = type.getMethod("equals", new Class[] { type });
// Get the methods from EJBObject
type = EJBObject.class;
GET_PRIMARY_KEY = type.getMethod("getPrimaryKey", empty);
GET_HANDLE = type.getMethod("getHandle", empty);
GET_EJB_HOME = type.getMethod("getEJBHome", empty);
IS_IDENTICAL = type.getMethod("isIdentical", new Class[] { type });
}
catch (Exception e)
{
e.printStackTrace();
throw new ExceptionInInitializerError(e);
}
// For externalization to work
}