SubmitRuleOptions: Remove separate defaults() static method

Nobody was calling builder(), and nobody should be using a builder that
isn't initialized with the default values. Only have a single builder
method exposed by this class, and call it builder().

Change-Id: I4bfe96942ebfa9a21c1618fe9e1eee23cff2979d
This commit is contained in:
Dave Borowitz
2017-11-14 08:46:41 -05:00
parent c934fba643
commit f51aa8c1a4
4 changed files with 9 additions and 10 deletions

View File

@@ -26,11 +26,10 @@ import com.google.gerrit.common.Nullable;
@AutoValue
public abstract class SubmitRuleOptions {
public static Builder builder() {
return new AutoValue_SubmitRuleOptions.Builder();
}
public static Builder defaults() {
return builder().allowClosed(false).skipFilters(false).rule(null);
return new AutoValue_SubmitRuleOptions.Builder()
.allowClosed(false)
.skipFilters(false)
.rule(null);
}
public abstract boolean allowClosed();