Package google.registry.model.tld.label
Class BaseDomainLabelList<T extends Comparable<?>,R extends DomainLabelEntry<T,?>>
java.lang.Object
google.registry.model.ImmutableObject
google.registry.model.tld.label.BaseDomainLabelList<T,R>
- Type Parameters:
T
- The type of the root value being listed, e.g.ReservationType
.R
- The type of domain label entry being listed, e.g.ReservedList.ReservedListEntry
(note, must subclassDomainLabelEntry
.
- Direct Known Subclasses:
PremiumList
,ReservedList
@MappedSuperclass
public abstract class BaseDomainLabelList<T extends Comparable<?>,R extends DomainLabelEntry<T,?>>
extends ImmutableObject
implements Buildable
Base class for
ReservedList
and PremiumList
objects.-
Nested Class Summary
Modifier and TypeClassDescriptionstatic class
BaseDomainLabelList.Builder<T extends BaseDomainLabelList<?,
?>, B extends BaseDomainLabelList.Builder<T, ?>> Base builder for derived classes ofBaseDomainLabelList
.Nested classes/interfaces inherited from class google.registry.model.ImmutableObject
ImmutableObject.DoNotHydrate, ImmutableObject.IgnoredInDiffableMap, ImmutableObject.Insignificant
Nested classes/interfaces inherited from interface google.registry.model.Buildable
Buildable.GenericBuilder<S,
B extends Buildable.GenericBuilder<?, ?>>, Buildable.Overlayable<T> -
Field Summary
Fields inherited from class google.registry.model.ImmutableObject
hashCode
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionorg.joda.time.DateTime
Returns the creation time of this revision of the reserved list.getName()
Returns the name of the reserved list.final com.google.common.collect.ImmutableSet
<String> Gets the names of the tlds that reference this list.long
Returns the ID of this revision, or throws if null.Turns the list CSV data into a map of labels to parsed data of type R.protected abstract boolean
refersToList
(Tld tld, String name) splitOnComment
(String line) Helper function to extract the comment from an input line.Methods inherited from class google.registry.model.ImmutableObject
clone, cloneEmptyToNull, createVKey, equals, getSignificantFields, hashCode, toDiffableFieldMap, toHydratedString, toString, toStringHelper
-
Constructor Details
-
BaseDomainLabelList
public BaseDomainLabelList()
-
-
Method Details
-
getRevisionId
public long getRevisionId()Returns the ID of this revision, or throws if null. -
getName
Returns the name of the reserved list. -
getCreationTimestamp
public org.joda.time.DateTime getCreationTimestamp()Returns the creation time of this revision of the reserved list. -
parse
Turns the list CSV data into a map of labels to parsed data of type R.- Parameters:
lines
- the CSV file, line by line
-
splitOnComment
Helper function to extract the comment from an input line. Returns a list containing the line (sans comment) and the comment (in that order). If the line was blank or empty, then this method returns an empty list. -
getReferencingTlds
Gets the names of the tlds that reference this list. -
refersToList
-