@Test public void testHashCode() { UserNotAuthorizedException exception = new UserNotAuthorizedException(OCFErrorCode.NO_MORE_ELEMENTS.getMessageDefinition("IteratorName", "entityGUID", "entityType"), reportingClassName, reportingActionDescription, userId); UserNotAuthorizedException exception2 = new UserNotAuthorizedException(OCFErrorCode.NO_MORE_ELEMENTS.getMessageDefinition("IteratorName", "entityGUID", "entityType"), reportingClassName, reportingActionDescription, reportedCaughtException, userId); UserNotAuthorizedException exception3 = new UserNotAuthorizedException(OCFErrorCode.NO_MORE_ELEMENTS.getMessageDefinition("IteratorName", "entityGUID", "entityType"), reportingClassName, reportingActionDescription, reportedCaughtException, userId); assertTrue(exception.hashCode() == exception.hashCode()); assertFalse(exception.hashCode() == exception2.hashCode()); assertTrue(exception.equals(exception)); assertFalse(exception.equals(reportedCaughtException)); assertFalse(exception.equals(exception2)); assertTrue(exception2.equals(exception3)); assertTrue(exception.toString().contains("UserNotAuthorizedException")); assertTrue(exception.toString().equals(exception.toString())); assertFalse(exception.toString().equals(exception2.toString())); assertTrue(exception.getUserId().equals(exception2.getUserId())); }
@Override public int hashCode() { return Objects.hash(super.hashCode(), getUserId()); }
UserNotAuthorizedException extends OCFCheckedExceptionBase { @Override public int hashCode() { return Objects.hash(super.hashCode(), getUserId()); } }
UserNotAuthorizedException extends OCFCheckedExceptionBase { @Override public int hashCode() { return Objects.hash(super.hashCode(), getUserId()); } UserNotAuthorizedException(ExceptionMessageDefinition messageDefinition,
                                      String                     className,
                                      String                     actionDescription,
                                      String                     userId);  UserNotAuthorizedException(ExceptionMessageDefinition messageDefinition,
                                      String                     className,
                                      String                     actionDescription,
                                      String                     userId,
                                      Map<String, Object>        relatedProperties);  UserNotAuthorizedException(ExceptionMessageDefinition messageDefinition,
                                      String                     className,
                                      String                     actionDescription,
                                      Throwable                  caughtError,
                                      String                     userId);  UserNotAuthorizedException(ExceptionMessageDefinition messageDefinition,
                                      String                     className,
                                      String                     actionDescription,
                                      Throwable                  caughtError,
                                      String                     userId,
                                      Map<String, Object>        relatedProperties);  UserNotAuthorizedException(int                 httpCode,
                                      String              className,
                                      String              actionDescription,
                                      String              errorMessage,
                                      String              errorMessageId,
                                      String[]            errorMessageParameters,
                                      String              systemAction,
                                      String              userAction,
                                      String              caughtErrorClassName,
                                      String              userId,
                                      Map<String, Object> relatedProperties); @Deprecated  UserNotAuthorizedException(int    httpCode,
                                      String className,
                                      String actionDescription,
                                      String errorMessage,
                                      String systemAction,
                                      String userAction,
                                      String userId); @Deprecated  UserNotAuthorizedException(int                 httpCode,
                                      String              className,
                                      String              actionDescription,
                                      String              errorMessage,
                                      String              systemAction,
                                      String              userAction,
                                      String              userId,
                                      Map<String, Object> relatedProperties); @Deprecated  UserNotAuthorizedException(int       httpCode,
                                      String    className,
                                      String    actionDescription,
                                      String    errorMessage,
                                      String    systemAction,
                                      String    userAction,
                                      Throwable caughtError,
                                      String    userId); @Deprecated  UserNotAuthorizedException(int                 httpCode,
                                      String              className,
                                      String              actionDescription,
                                      String              errorMessage,
                                      String              systemAction,
                                      String              userAction,
                                      Throwable           caughtError,
                                      String              userId,
                                      Map<String, Object> relatedProperties);  UserNotAuthorizedException(UserNotAuthorizedException template);  UserNotAuthorizedException(OCFCheckedExceptionBase template,
                                      String                  userId); }
UserNotAuthorizedException extends OCFCheckedExceptionBase { @Override public int hashCode() { return Objects.hash(super.hashCode(), getUserId()); } UserNotAuthorizedException(ExceptionMessageDefinition messageDefinition,
                                      String                     className,
                                      String                     actionDescription,
                                      String                     userId);  UserNotAuthorizedException(ExceptionMessageDefinition messageDefinition,
                                      String                     className,
                                      String                     actionDescription,
                                      String                     userId,
                                      Map<String, Object>        relatedProperties);  UserNotAuthorizedException(ExceptionMessageDefinition messageDefinition,
                                      String                     className,
                                      String                     actionDescription,
                                      Throwable                  caughtError,
                                      String                     userId);  UserNotAuthorizedException(ExceptionMessageDefinition messageDefinition,
                                      String                     className,
                                      String                     actionDescription,
                                      Throwable                  caughtError,
                                      String                     userId,
                                      Map<String, Object>        relatedProperties);  UserNotAuthorizedException(int                 httpCode,
                                      String              className,
                                      String              actionDescription,
                                      String              errorMessage,
                                      String              errorMessageId,
                                      String[]            errorMessageParameters,
                                      String              systemAction,
                                      String              userAction,
                                      String              caughtErrorClassName,
                                      String              userId,
                                      Map<String, Object> relatedProperties); @Deprecated  UserNotAuthorizedException(int    httpCode,
                                      String className,
                                      String actionDescription,
                                      String errorMessage,
                                      String systemAction,
                                      String userAction,
                                      String userId); @Deprecated  UserNotAuthorizedException(int                 httpCode,
                                      String              className,
                                      String              actionDescription,
                                      String              errorMessage,
                                      String              systemAction,
                                      String              userAction,
                                      String              userId,
                                      Map<String, Object> relatedProperties); @Deprecated  UserNotAuthorizedException(int       httpCode,
                                      String    className,
                                      String    actionDescription,
                                      String    errorMessage,
                                      String    systemAction,
                                      String    userAction,
                                      Throwable caughtError,
                                      String    userId); @Deprecated  UserNotAuthorizedException(int                 httpCode,
                                      String              className,
                                      String              actionDescription,
                                      String              errorMessage,
                                      String              systemAction,
                                      String              userAction,
                                      Throwable           caughtError,
                                      String              userId,
                                      Map<String, Object> relatedProperties);  UserNotAuthorizedException(UserNotAuthorizedException template);  UserNotAuthorizedException(OCFCheckedExceptionBase template,
                                      String                  userId); String getUserId(); @Override String toString(); @Override boolean equals(Object objectToCompare); @Override int hashCode(); }
UserNotAuthorizedException extends OCFCheckedExceptionBase { @Override public int hashCode() { return Objects.hash(super.hashCode(), getUserId()); } UserNotAuthorizedException(ExceptionMessageDefinition messageDefinition,
                                      String                     className,
                                      String                     actionDescription,
                                      String                     userId);  UserNotAuthorizedException(ExceptionMessageDefinition messageDefinition,
                                      String                     className,
                                      String                     actionDescription,
                                      String                     userId,
                                      Map<String, Object>        relatedProperties);  UserNotAuthorizedException(ExceptionMessageDefinition messageDefinition,
                                      String                     className,
                                      String                     actionDescription,
                                      Throwable                  caughtError,
                                      String                     userId);  UserNotAuthorizedException(ExceptionMessageDefinition messageDefinition,
                                      String                     className,
                                      String                     actionDescription,
                                      Throwable                  caughtError,
                                      String                     userId,
                                      Map<String, Object>        relatedProperties);  UserNotAuthorizedException(int                 httpCode,
                                      String              className,
                                      String              actionDescription,
                                      String              errorMessage,
                                      String              errorMessageId,
                                      String[]            errorMessageParameters,
                                      String              systemAction,
                                      String              userAction,
                                      String              caughtErrorClassName,
                                      String              userId,
                                      Map<String, Object> relatedProperties); @Deprecated  UserNotAuthorizedException(int    httpCode,
                                      String className,
                                      String actionDescription,
                                      String errorMessage,
                                      String systemAction,
                                      String userAction,
                                      String userId); @Deprecated  UserNotAuthorizedException(int                 httpCode,
                                      String              className,
                                      String              actionDescription,
                                      String              errorMessage,
                                      String              systemAction,
                                      String              userAction,
                                      String              userId,
                                      Map<String, Object> relatedProperties); @Deprecated  UserNotAuthorizedException(int       httpCode,
                                      String    className,
                                      String    actionDescription,
                                      String    errorMessage,
                                      String    systemAction,
                                      String    userAction,
                                      Throwable caughtError,
                                      String    userId); @Deprecated  UserNotAuthorizedException(int                 httpCode,
                                      String              className,
                                      String              actionDescription,
                                      String              errorMessage,
                                      String              systemAction,
                                      String              userAction,
                                      Throwable           caughtError,
                                      String              userId,
                                      Map<String, Object> relatedProperties);  UserNotAuthorizedException(UserNotAuthorizedException template);  UserNotAuthorizedException(OCFCheckedExceptionBase template,
                                      String                  userId); String getUserId(); @Override String toString(); @Override boolean equals(Object objectToCompare); @Override int hashCode();  }