Small SQL persistence fixes to model classes (#863)

* Small SQL persistence fixes to model classes

- Add a createVKey() method to Registry (Registry vkeys are composite)
- Add/fix toSqlEntities() methods in premium and reserved list classes.

* Remove fixes addressed by #866
This commit is contained in:
Michael Muller 2020-11-10 11:12:09 -05:00 committed by GitHub
parent c1745e4b01
commit c022aa8dc5
2 changed files with 5 additions and 1 deletions

View file

@ -285,6 +285,10 @@ public class Registry extends ImmutableObject implements Buildable, DatastoreAnd
return VKey.create(Registry.class, tld, Key.create(getCrossTldKey(), Registry.class, tld));
}
public static VKey<Registry> createVKey(Key<Registry> key) {
return createVKey(key.getName());
}
/**
* The name of the pricing engine that this TLD uses.
*

View file

@ -352,7 +352,7 @@ public final class PremiumList extends BaseDomainLabelList<Money, PremiumList.Pr
@Override
public ImmutableList<SqlEntity> toSqlEntities() {
return null;
return ImmutableList.of();
}
/** A builder for constructing {@link PremiumListEntry} objects, since they are immutable. */