Skip to content

Commit

Permalink
Better readable javadoc for id generators
Browse files Browse the repository at this point in the history
  • Loading branch information
arteam committed Jan 14, 2022
1 parent 86192fb commit 7d57ca6
Show file tree
Hide file tree
Showing 6 changed files with 10 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,9 @@
/**
* Date: 12/30/14
* Time: 11:19 PM
* <p>Return id from an atomic long counter
* It's the most reliable and straightforward way to generate identifiers</p>
* <p>
* Return id from an atomic long counter.
* It's the most reliable and straightforward way to generate identifiers
*/
public class AtomicLongIdGenerator implements IdGenerator<Long> {

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,8 @@
/**
* Date: 24.08.14
* Time: 18:20
* Return current time as id.
* <p>
* Return the current time as an id.
* Not reliable if you need to guarantee uniqueness of request ids
*/
public class CurrentTimeIdGenerator implements IdGenerator<Long> {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
/**
* Date: 1/12/15
* Time: 11:17 PM
* <p>
* Abstract generator of secure random identifiers
*/
abstract class SecureRandomIdGenerator<T> implements IdGenerator<T> {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,9 @@
/**
* Date: 1/12/15
* Time: 11:38 PM
* <p>
* Generates secure random positive integers under limit
* By default limit is 65536
* By default the limit is 65536
*/
public class SecureRandomIntIdGenerator extends SecureRandomIdGenerator<Integer> {

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
/**
* Date: 1/12/15
* Time: 11:12 PM
* <p>
* Generate secure random positive long identifiers
*/
public class SecureRandomLongIdGenerator extends SecureRandomIdGenerator<Long> {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
/**
* Date: 12/30/14
* Time: 11:45 PM
* <p>
* Generate secure random strings consisting of HEX symbols with length of 40 characters
*/
public class SecureRandomStringIdGenerator extends SecureRandomIdGenerator<String> {
Expand Down

0 comments on commit 7d57ca6

Please sign in to comment.