com.instantbank.component.lettersjobmdb.ejb
Class LettersJobMessageEJB.SequencedFileName

java.lang.Object
  |
  +--com.instantbank.component.lettersjobmdb.ejb.LettersJobMessageEJB.SequencedFileName
Enclosing class:
LettersJobMessageEJB

class LettersJobMessageEJB.SequencedFileName
extends java.lang.Object

Auxiliary class that generates names of files with a sequencing criterium.

Author:
InstantBank (Rodrigo Lopez)

Field Summary
private  char[] buffer
          Temporay buffer for efficient name building.
private  java.text.DecimalFormat df
          Formatter for the sequence number.
private  int seqIndex
          Index inside the buffer where the sequencing figure is placed.
private  int seqnum
          Sequence number
 
Constructor Summary
LettersJobMessageEJB.SequencedFileName(java.lang.String jobName, java.util.Date date, int seqNum)
          SequencedFileName constructor.
 
Method Summary
 java.lang.String nextName()
          Produces the next name.
 
Methods inherited from class java.lang.Object
, clone, equals, finalize, getClass, hashCode, notify, notifyAll, registerNatives, toString, wait, wait, wait
 

Field Detail

seqnum

private int seqnum
Sequence number

buffer

private char[] buffer
Temporay buffer for efficient name building.

seqIndex

private int seqIndex
Index inside the buffer where the sequencing figure is placed.

df

private java.text.DecimalFormat df
Formatter for the sequence number.
Constructor Detail

LettersJobMessageEJB.SequencedFileName

public LettersJobMessageEJB.SequencedFileName(java.lang.String jobName,
                                              java.util.Date date,
                                              int seqNum)
SequencedFileName constructor.
Parameters:
jobName - String seed for names.
date - Date seed for names.
seqNum - Starting value for the sequence number.
Method Detail

nextName

public java.lang.String nextName()
Produces the next name. The sequencing number is incremented each time this service is invoked.
Returns:
Description of the Return Value