google-nomulus/javatests/google/registry
nickfelt 1e7fc4d64d Remove Builder type param on RequestComponentBuilder/RequestHandler
It turns out this type parameter was never necessary.  A builder only needs the reflexive second type parameter when you want to have a builder inheritance hierarchy where the descendant builders have methods that the ancestor builder doesn't.  In that case, the type param enables the ancestor builder's setter methods to automatically return the correct derived type, so that if you start with a derived builder, you can call a setter method inherited from an ancestor and then continue the chain with setters from the derived builder (e.g. new ContactResource.Builder().setCreationTime(now).setContactId(), which otherwise would have returned an EppResource.Builder from setCreationTime(), at which point the call to setContactId() would not compile).

Even then, it's not strictly necessary to use the type parameter, since you could instead just have each derived type override every inherited method to specify itself as the return type.  But that would be a lot of extra boilerplate and brittleness.

Anyway, in this case, there is a builder hierarchy, but RequestComponentBuilder specifies all the methods that we're ever going to want on our builders, so there's never any need to be able to call specific derived builder methods.  We only even need the individual builder classes so that Dagger can generate them separately for each component.

-------------
Created by MOE: https://github.com/google/moe
MOE_MIGRATED_REVID=148269178
2017-02-27 11:12:07 -05:00
..
backup Add @VirtualEntity checking to Ofy's deleteWithoutBackup() 2017-02-08 17:31:07 -05:00
batch Refer to Datastore everywhere correctly by its capitalized form 2017-02-17 12:12:12 -05:00
bigquery Update copyright year on all license headers 2017-02-02 16:27:22 -05:00
builddefs Update copyright year on all license headers 2017-02-02 16:27:22 -05:00
config Remove unnecessary line to load configs 2017-02-27 11:07:40 -05:00
cron Update copyright year on all license headers 2017-02-02 16:27:22 -05:00
dns Refer to Datastore everywhere correctly by its capitalized form 2017-02-17 12:12:12 -05:00
export Add Cloud KMS based secret storage 2017-02-17 12:22:12 -05:00
flows Improve handling of lastSubordinateChange and beef up tests 2017-02-17 12:23:36 -05:00
groups Update copyright year on all license headers 2017-02-02 16:27:22 -05:00
keyring/kms Add Cloud KMS based secret storage 2017-02-17 12:22:12 -05:00
mapreduce/inputs Update copyright year on all license headers 2017-02-02 16:27:22 -05:00
model Add Cloud KMS based secret storage 2017-02-17 12:22:12 -05:00
module Update copyright year on all license headers 2017-02-02 16:27:22 -05:00
monitoring Re-add some accidentally removed license headers 2017-02-06 16:45:23 -05:00
pricing Update copyright year on all license headers 2017-02-02 16:27:22 -05:00
rdap Update copyright year on all license headers 2017-02-02 16:27:22 -05:00
rde Fix a comment nit (can't @link to a generic type) 2017-02-17 12:20:45 -05:00
request Remove Builder type param on RequestComponentBuilder/RequestHandler 2017-02-27 11:12:07 -05:00
security Daggerize XsrfTokenManager 2017-02-22 11:43:10 -05:00
server Refer to Datastore everywhere correctly by its capitalized form 2017-02-17 12:12:12 -05:00
storage/drive Update copyright year on all license headers 2017-02-02 16:27:22 -05:00
testing Daggerize XsrfTokenManager 2017-02-22 11:43:10 -05:00
tldconfig/idn Update copyright year on all license headers 2017-02-02 16:27:22 -05:00
tmch Update copyright year on all license headers 2017-02-02 16:27:22 -05:00
tools Make ListObjectsAction return 200 when sending JSON error 2017-02-27 11:10:37 -05:00
ui Daggerize XsrfTokenManager 2017-02-22 11:43:10 -05:00
util Update copyright year on all license headers 2017-02-02 16:27:22 -05:00
whois Tighten up restrictions on domain/host naming on EPP resources 2017-02-07 13:29:03 -05:00
xjc Add mapper to import domains from RDE deposits 2017-02-06 16:46:46 -05:00
xml Update copyright year on all license headers 2017-02-02 16:27:22 -05:00