Class EppResource.Builder<T extends EppResource,B extends EppResource.Builder<T,B>>

Direct Known Subclasses:
ContactBase.Builder, DomainBase.Builder, HostBase.Builder
Enclosing class:
EppResource

public abstract static class EppResource.Builder<T extends EppResource,B extends EppResource.Builder<T,B>> extends Buildable.GenericBuilder<T,B>
Abstract builder for EppResource types.
  • Constructor Details

  • Method Details

    • setCreationTime

      public B setCreationTime(org.joda.time.DateTime creationTime)
      Set the time this resource was created.

      Note: This can only be used if the creation time hasn't already been set, which it is in normal EPP flows.

    • setCreationTimeForTest

      public B setCreationTimeForTest(org.joda.time.DateTime creationTime)
      Set the time this resource was created. Should only be used in tests.
    • setDeletionTime

      public B setDeletionTime(org.joda.time.DateTime deletionTime)
      Set the time after which this resource should be considered deleted.
    • setPersistedCurrentSponsorRegistrarId

      public B setPersistedCurrentSponsorRegistrarId(String currentSponsorRegistrarId)
      Set the current sponsoring registrar.
    • setCreationRegistrarId

      public B setCreationRegistrarId(String creationRegistrarId)
      Set the registrar that created this resource.
    • setLastEppUpdateTime

      public B setLastEppUpdateTime(org.joda.time.DateTime lastEppUpdateTime)
      Set the time when a <update> was performed on this resource.
    • setLastEppUpdateRegistrarId

      public B setLastEppUpdateRegistrarId(String lastEppUpdateRegistrarId)
      Set the registrar who last performed a <update> on this resource.
    • setStatusValues

      public B setStatusValues(com.google.common.collect.ImmutableSet<StatusValue> statusValues)
      Set this resource's status values.
    • addStatusValue

      public B addStatusValue(StatusValue statusValue)
      Add to this resource's status values.
    • removeStatusValue

      public B removeStatusValue(StatusValue statusValue)
      Remove from this resource's status values.
    • addStatusValues

      public B addStatusValues(com.google.common.collect.ImmutableSet<StatusValue> statusValues)
      Add to this resource's status values.
    • removeStatusValues

      public B removeStatusValues(com.google.common.collect.ImmutableSet<StatusValue> statusValues)
      Remove from this resource's status values.
    • setRepoId

      public B setRepoId(String repoId)
      Set this resource's repoId.
    • setUpdateTimestamp

      public B setUpdateTimestamp(UpdateAutoTimestamp updateTimestamp)
      Set the update timestamp.

      This is provided at EppResource since UpdateAutoTimestampEntity doesn't have a Builder.

    • build

      public T build()
      Build the resource, nullifying empty strings and sets and setting defaults.
      Overrides:
      build in class Buildable.Builder<T extends EppResource>