Class GeneratorImpl

  • All Implemented Interfaces:
    Generator

    public class GeneratorImpl
    extends java.lang.Object
    implements Generator
    Represents a store sequence.
    Since:
    0.4.1
    Author:
    Abe White
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void allocate​(int additional)
      Hint to the sequence to allocate additional values up-front for efficiency.
      java.lang.Object current()
      The current sequence value, or null if the sequence does not support current values.
      boolean equals​(java.lang.Object other)  
      Seq getDelegate()
      Delegate.
      java.lang.String getName()
      The sequence name.
      int hashCode()  
      java.lang.Object next()
      The next sequence value.
      • Methods inherited from class java.lang.Object

        clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • GeneratorImpl

        public GeneratorImpl​(Seq seq,
                             java.lang.String name,
                             StoreContext ctx,
                             ClassMetaData meta)
        Constructor; supply delegate.
    • Method Detail

      • getName

        public java.lang.String getName()
        Description copied from interface: Generator
        The sequence name.
        Specified by:
        getName in interface Generator
      • next

        public java.lang.Object next()
        Description copied from interface: Generator
        The next sequence value.
        Specified by:
        next in interface Generator
      • current

        public java.lang.Object current()
        Description copied from interface: Generator
        The current sequence value, or null if the sequence does not support current values.
        Specified by:
        current in interface Generator
      • allocate

        public void allocate​(int additional)
        Description copied from interface: Generator
        Hint to the sequence to allocate additional values up-front for efficiency.
        Specified by:
        allocate in interface Generator
      • hashCode

        public int hashCode()
        Overrides:
        hashCode in class java.lang.Object
      • equals

        public boolean equals​(java.lang.Object other)
        Overrides:
        equals in class java.lang.Object