added main method for an easy way to generate static keys

This commit is contained in:
Sebastian Sdorra
2014-01-25 11:50:18 +01:00
parent ebd280f9ca
commit 5951b32f8e

View File

@@ -30,6 +30,7 @@
*/
package sonia.scm.security;
//~--- non-JDK imports --------------------------------------------------------
@@ -68,6 +69,17 @@ public class DefaultKeyGenerator implements KeyGenerator
//~--- methods --------------------------------------------------------------
/**
* Method description
*
*
* @param args
*/
public static void main(String[] args)
{
System.out.println(new DefaultKeyGenerator().createKey());
}
/**
* Method description
*
@@ -107,8 +119,8 @@ public class DefaultKeyGenerator implements KeyGenerator
//~--- fields ---------------------------------------------------------------
/** Field description */
private AtomicLong sessionKey = new AtomicLong();
private final AtomicLong sessionKey = new AtomicLong();
/** Field description */
private Random random = new Random();
private final Random random = new Random();
}