Class AdvertisingID


  • public final class AdvertisingID
    extends java.lang.Object
    Object that encapsulate advertising ID
    • Constructor Summary

      Constructors 
      Constructor Description
      AdvertisingID()  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      java.lang.String get()
      Get the advertising ID
      boolean isLimited()
      Is the use of the advertising ID limited
      boolean isNotNull()
      Is the advertising ID not null
      boolean isReady()
      Tell if the process to retrieve advertising ID is already complete
      • Methods inherited from class java.lang.Object

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

      • AdvertisingID

        public AdvertisingID()
    • Method Detail

      • isReady

        public boolean isReady()
        Tell if the process to retrieve advertising ID is already complete
        Returns:
        true if the process is completed
      • get

        @Nullable
        public java.lang.String get()
                             throws java.lang.IllegalStateException
        Get the advertising ID
        Returns:
        The advertising ID if available, null otherwise
        Throws:
        java.lang.IllegalStateException - if the advertising id is not available yet (check isReady())
      • isLimited

        public boolean isLimited()
                          throws java.lang.IllegalStateException
        Is the use of the advertising ID limited
        Returns:
        true if the advertising ID limited
        Throws:
        java.lang.IllegalStateException - if the advertising id is not available yet (check isReady())
      • isNotNull

        public boolean isNotNull()
        Is the advertising ID not null
        Returns:
        true if its not