From 083df07ee19dcc0ef2ae060f054dbc57dcded223 Mon Sep 17 00:00:00 2001 From: Roland Haeder Date: Thu, 12 May 2016 21:09:44 +0200 Subject: [PATCH] sorted new member --- .../jusercore/model/user/UserUtils.java | 28 +++++++++---------- 1 file changed, 14 insertions(+), 14 deletions(-) diff --git a/src/org/mxchange/jusercore/model/user/UserUtils.java b/src/org/mxchange/jusercore/model/user/UserUtils.java index 81749b3..bd2c898 100644 --- a/src/org/mxchange/jusercore/model/user/UserUtils.java +++ b/src/org/mxchange/jusercore/model/user/UserUtils.java @@ -124,10 +124,23 @@ public class UserUtils implements Serializable { return encryptedPassword; } + /** + * Generates a pseudo-random user name + *

+ * @return User name + */ + public static String generateRandomUserName () { + // User name's format is normally "user" + random number (10 digits) + String userName = String.format("user%d", RANDOM_NUMBER_GENERATOR.nextInt(10000000)); //NOI18N + + // Return it + return userName; + } + /** * Checks if password from container matches the updatedUser's password *

- * @param container Container holding user instance and unencrypted password + * @param container Container holding user instance and unencrypted password * @param updatedUser Updated user instance from database *

* @return Whether the password matches @@ -188,19 +201,6 @@ public class UserUtils implements Serializable { return encryptedPassword.equals(container.getUser().getUserEncryptedPassword()); } - /** - * Generates a pseudo-random user name - *

- * @return User name - */ - public static String generateRandomUserName () { - // User name's format is normally "user" + random number (10 digits) - String userName = String.format("user%d", RANDOM_NUMBER_GENERATOR.nextInt(10000000)); //NOI18N - - // Return it - return userName; - } - /** * No instance from this class */ -- 2.39.5