title: what is the use of param in Hibernate <generator> tag?
body: <p>I am new to Hibernate and in my current project hibernate config file,I found some codes like below:</p>
  
  <pre><code>&lt;id name="id" column="ANNOBATCHJOBLOGID"&gt;
      &lt;generator class="sg.gov.frontier.core.techinfra.persistence.dao.SequenceGeneratorYYYYMMDD"&gt;
          &lt;param name="sequence"&gt;ANNO_BATCH_JOB_LOG_SEQ&lt;/param&gt;
      &lt;/generator&gt;
  &lt;/id&gt;
  </code></pre>
  
  <p>just feel confused about the the param tag ,can someone tell me what is the use of it? and also the "ANNO_BATCH_JOB_LOG_SEQ" .Thanks a lot</p>
  
  <p>the SequenceGeneratorYYYYMMDD class is here :</p>
  
  <pre><code>public class SequenceGeneratorYYYYMMDD extends SequenceGenerator {
      protected Logger logger = Logger.getLogger(SequenceGeneratorYYYYMMDD.class);
      public String sequenceName;
      public String parameters;
  
      public static final long SEQUENCE_MIN_NUMBER = 1;
      public static final long SEQUENCE_MAX_NUMBER = 999999;
      public static final long SEQUENCE_INCREMENT_NUMBER = 1;
      public static final long SEQUENCE_START_NUMBER = 1;
  
      public SequenceGeneratorYYYYMMDD() {
          super();
      }
  
      public long getNextSequenceForSequenceName(String strSequenceName)
              throws DataAccessObjectException {
          final SequenceDao sequenceDao = new SequenceDao();
  
          Long sequence = sequenceDao.getNextKey(strSequenceName);
  
          return sequence;
      }
  
      public void configure(Type type, Properties params, Dialect dialect)
              throws MappingException {
          this.sequenceName = getString(SEQUENCE, params, "hibernate_sequence");
          this.parameters = params.getProperty(PARAMETERS);
          String schemaName = params.getProperty(SCHEMA);
          String catalogName = params.getProperty(CATALOG);
  
          if (sequenceName.indexOf('.') &lt; 0) {
              sequenceName = Table.qualify(catalogName, schemaName, sequenceName);
          }
  
      }
  
      public String getString(String property, Properties properties,
              String defaultValue) {
          String propValue = properties.getProperty(property);
          return propValue == null ? defaultValue : propValue;
      }
  
      public Serializable generate(SessionImplementor session, Object obj)
              throws HibernateException {
  
          String result = DateUtil.convertDateToDateString(new DateTime(),
                  "yyMMddHH");
  
          try {
              result = result
                      + StringUtil
                              .leftPad(
                                      String.valueOf(getNextSequenceForSequenceName(sequenceName)),
                                      '0', 8);
          } catch (DataAccessObjectException e) {
              throw new HibernateException(e.getMessage(), e.getCause());
          }
  
          logger.debug("Generated sequence no. " + result);
          return new Long(result);
  
      }
  }
  </code></pre>
  
  <p>how can i know which method i need to pass the param? though seems is getNextSequenceForSequenceName() method.</p>