Package tilda.db

Class SequencePoll

  • All Implemented Interfaces:
    java.lang.Runnable

    public class SequencePoll
    extends DBPoll
    Allows managing a templorary database-level sequence with
    Author:
    Laurent Hasson
    • Nested Class Summary

      Nested Classes 
      Modifier and Type Class Description
      static interface  SequencePoll.Handler  
    • Field Summary

      • Fields inherited from class tilda.utils.concurrent.DBPoll

        _C, LOG
    • Constructor Summary

      Constructors 
      Constructor Description
      SequencePoll​(java.lang.String PoolName, long PauseMillis, java.lang.String SequenceName, SequencePoll.Handler H)  
    • Constructor Detail

      • SequencePoll

        public SequencePoll​(java.lang.String PoolName,
                            long PauseMillis,
                            java.lang.String SequenceName,
                            SequencePoll.Handler H)
    • Method Detail

      • getSequenceName

        public java.lang.String getSequenceName()
      • init

        public void init()
                  throws java.lang.Exception
        Description copied from class: DBPoll
        Initializes the connection. Must be called before the class is used either directly by calling the run() method, or through a Thread.
        Overrides:
        init in class DBPoll
        Throws:
        java.lang.Exception - if the connection couldn't be instanciated.
      • close

        protected void close()
                      throws java.lang.Exception
        Description copied from class: DBPoll
        Called when the thread is closing
        Specified by:
        close in class DBPoll
        Throws:
        java.lang.Exception
      • doRun

        protected boolean doRun​(Connection C,
                                int Count)
                         throws java.lang.Exception
        Specified by:
        doRun in class DBPoll
        Returns:
        Throws:
        java.lang.Exception