com.enterprisemath.utils.UniqueCodeGenerator Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of em-utils Show documentation
Show all versions of em-utils Show documentation
Collection of utility classes for large scale projects focusing on robust and testable code.
package com.enterprisemath.utils;
import java.util.Set;
/**
* Provides functionality to unique code generation.
*
* @author radek.hecl
*
*/
public interface UniqueCodeGenerator {
/**
* Generates code with high probability this will be the globally unique one.
*
* @param prefix prefix of generated code
* @return generated code
*/
public String generateUniqueCode(String prefix);
/**
* Generates multiple codes with high probability these will be the globally unique ones.
*
* @param prefix prefix of all generated codes
* @param number number of codes to generate, must be greater than 0
* @return generated codes
*/
public Set generateUniqueCodes(String prefix, int number);
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy