question: public static MaildirMessageName createUniqueName ( MaildirFolder parentFolder , long size ) { String timestamp = String . valueOf ( System . currentTimeMillis ( ) ) ; timestamp = timestamp . substring ( 0 , timestamp . length ( ) - 3 ) ; StringBuilder uniquePart = new StringBuilder ( ) ; uniquePart . append ( Integer . toHexString ( random . nextInt ( ) ) ) ; uniquePart . append ( timestamp . substring ( timestamp . length ( ) - 3 ) ) ; uniquePart . append ( processName ) ; uniquePart . append ( getNextDeliveryNumber ( ) ) ; String sizeString = ",S=" + String . valueOf ( size ) ; String fullName = timestamp + "." + uniquePart . toString ( ) + "." + currentHostname + sizeString ; MaildirMessageName uniqueName = new MaildirMessageName ( parentFolder , fullName ) ; uniqueName . timestamp = timestamp ; uniqueName . uniqueString = uniquePart . toString ( ) ; uniqueName . hostname = currentHostname ; uniqueName . sizeString = sizeString ; uniqueName . isSplit = true ; uniqueName . size = size ; return uniqueName ; }
target:  Create a name for a message according to <a href="http://cr.yp.to/proto/maildir.html" /><br/> The following elements are used: <br><br/> "A unique name has three pieces, separated by dots. On the left is the result of time() or the second counter from gettimeofday(). On the right is the result of gethostname(). (To deal with invalid host names, replace / with \057 and : with \072.) In the middle is a delivery identifier, discussed below. <br/><br/> Modern delivery identifiers are created by concatenating enough of the following strings to guarantee uniqueness: <br/><br/> [...]<br/> * Rn, where n is (in hexadecimal) the output of the operating system's unix_cryptorandomnumber() system call, or an equivalent source such as /dev/urandom. Unfortunately, some operating systems don't include cryptographic random number generators.<br/> [...]<br/> * Mn, where n is (in decimal) the microsecond counter from the same gettimeofday() used for the left part of the unique name.<br/> * Pn, where n is (in decimal) the process ID.<br/> * Qn, where n is (in decimal) the number of deliveries made by this process.<br/> <br/> [...]"