Class Registrar

All Implemented Interfaces:
Buildable, Jsonifiable, UnsafeSerializable, Serializable, Cloneable

@Entity public class Registrar extends UpdateAutoTimestampEntity implements Buildable, Jsonifiable
Information about a registrar.
See Also:
  • Field Details

    • PHONE_PASSCODE_PATTERN

      public static final com.google.re2j.Pattern PHONE_PASSCODE_PATTERN
      Regex for telephone support passcode (5 digit string).
  • Constructor Details

    • Registrar

      public Registrar()
  • Method Details

    • getRegistrarId

      public String getRegistrarId()
    • getCreationTime

      public org.joda.time.DateTime getCreationTime()
    • getIanaIdentifier

      @Nullable public Long getIanaIdentifier()
    • getPoNumber

      public Optional<String> getPoNumber()
    • getBillingAccountMap

      public com.google.common.collect.ImmutableSortedMap<org.joda.money.CurrencyUnit,String> getBillingAccountMap()
    • getLastUpdateTime

      public org.joda.time.DateTime getLastUpdateTime()
    • getLastCertificateUpdateTime

      public org.joda.time.DateTime getLastCertificateUpdateTime()
    • getLastExpiringCertNotificationSentDate

      public org.joda.time.DateTime getLastExpiringCertNotificationSentDate()
    • getLastExpiringFailoverCertNotificationSentDate

      public org.joda.time.DateTime getLastExpiringFailoverCertNotificationSentDate()
    • getRegistrarName

      public String getRegistrarName()
    • getType

      public Registrar.Type getType()
    • getState

      public Registrar.State getState()
    • getAllowedTlds

      public com.google.common.collect.ImmutableSortedSet<String> getAllowedTlds()
    • isLive

      public boolean isLive()
      Returns true if the registrar is live.

      A live registrar is one that can have live domains/contacts/hosts in the registry, meaning that it is either currently active or used to be active (i.e. suspended).

    • isLiveAndPubliclyVisible

      public boolean isLiveAndPubliclyVisible()
      Returns true if registrar should be visible in WHOIS results.
    • getClientCertificate

      public Optional<String> getClientCertificate()
      Returns the client certificate string if it has been set, or empty otherwise.
    • getClientCertificateHash

      public Optional<String> getClientCertificateHash()
      Returns the client certificate hash if it has been set, or empty otherwise.
    • getFailoverClientCertificate

      public Optional<String> getFailoverClientCertificate()
      Returns the failover client certificate string if it has been set, or empty otherwise.
    • getFailoverClientCertificateHash

      public Optional<String> getFailoverClientCertificateHash()
      Returns the failover client certificate hash if it has been set, or empty otherwise.
    • getIpAddressAllowList

      public com.google.common.collect.ImmutableList<CidrAddressBlock> getIpAddressAllowList()
    • getLocalizedAddress

      public RegistrarAddress getLocalizedAddress()
    • getInternationalizedAddress

      public RegistrarAddress getInternationalizedAddress()
    • getPhoneNumber

      public String getPhoneNumber()
    • getFaxNumber

      public String getFaxNumber()
    • getEmailAddress

      public String getEmailAddress()
    • getWhoisServer

      public String getWhoisServer()
    • getRdapBaseUrls

      public com.google.common.collect.ImmutableSet<String> getRdapBaseUrls()
    • getBlockPremiumNames

      public boolean getBlockPremiumNames()
    • getContactsRequireSyncing

      public boolean getContactsRequireSyncing()
    • isRegistryLockAllowed

      public boolean isRegistryLockAllowed()
    • getUrl

      public String getUrl()
    • getIcannReferralEmail

      public String getIcannReferralEmail()
    • getDriveFolderId

      public String getDriveFolderId()
    • getContacts

      public com.google.common.collect.ImmutableSortedSet<RegistrarPoc> getContacts()
      Returns a list of all RegistrarPoc objects for this registrar sorted by their email address.
    • getContactsOfType

      public com.google.common.collect.ImmutableSortedSet<RegistrarPoc> getContactsOfType(RegistrarPoc.Type type)
      Returns a list of RegistrarPoc objects of a given type for this registrar sorted by their email address.
    • getWhoisAbuseContact

      public Optional<RegistrarPoc> getWhoisAbuseContact()
      Returns the RegistrarPoc that is the WHOIS abuse contact for this registrar, or empty if one does not exist.
    • toJsonMap

      public Map<String,Object> toJsonMap()
      Description copied from interface: Jsonifiable
      Returns a JSON representation of this object.

      The returned value must not return sensitive fields, so that it may be safe to return to the client via an API response.

      Specified by:
      toJsonMap in interface Jsonifiable
    • verifyPassword

      public boolean verifyPassword(String password)
    • getPhonePasscode

      public String getPhonePasscode()
    • asBuilder

      public Registrar.Builder asBuilder()
      Specified by:
      asBuilder in interface Buildable
    • createVKey

      public VKey<Registrar> createVKey()
      Creates a VKey for this instance.
      Overrides:
      createVKey in class ImmutableObject
    • createVKey

      public static VKey<Registrar> createVKey(String registrarId)
      Creates a VKey for the given registrarId.
    • checkValidEmail

      public static String checkValidEmail(String email)
      Verifies that the email address in question is not null and has a valid format.
    • loadAll

      public static Iterable<Registrar> loadAll()
      Loads all registrar entities directly from the database.
    • loadAllCached

      public static Iterable<Registrar> loadAllCached()
      Loads all registrar entities using an in-memory cache.
    • loadAllKeysCached

      public static com.google.common.collect.ImmutableSet<VKey<Registrar>> loadAllKeysCached()
      Loads all registrar keys using an in-memory cache.
    • loadByRegistrarId

      public static Optional<Registrar> loadByRegistrarId(String registrarId)
      Loads and returns a registrar entity by its id directly from the database.
    • loadByRegistrarIdCached

      public static Optional<Registrar> loadByRegistrarIdCached(String registrarId)
      Loads and returns a registrar entity by its id using an in-memory cache.

      Returns empty if the registrar isn't found.

    • loadRequiredRegistrarCached

      public static Registrar loadRequiredRegistrarCached(String registrarId)
      Loads and returns a registrar entity by its id using an in-memory cache.

      Throws if the registrar isn't found.