Class IdGenerator

java.lang.Object
com.amazonaws.xray.internal.IdGenerator
Direct Known Subclasses:
FastIdGenerator, SecureIdGenerator

public abstract class IdGenerator
extends java.lang.Object
An internal base class for unifying the potential ID generators.

This class is internal-only and its API may receive breaking changes at any time. Do not directly depend on or use this class.

  • Constructor Summary

    Constructors 
    Constructor Description
    IdGenerator()  
  • Method Summary

    Modifier and Type Method Description
    protected abstract long getRandomEntityId()  
    java.lang.String newEntityId()  
    abstract java.lang.String newTraceId()  

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

  • Method Details

    • newTraceId

      public abstract java.lang.String newTraceId()
      Returns:
      a new ID suitable for use in a TraceID
    • newEntityId

      public final java.lang.String newEntityId()
      Returns:
      a new ID suitable for use in any Entity implementation
    • getRandomEntityId

      protected abstract long getRandomEntityId()
      Returns:
      a random long to use as an entity ID