Remove redundant 'static' modifiers

enums, interfaces, and field members in interfaces are by default
static, so don't need to be explicitly declared so.

Change-Id: I29270c28be30965767519ad0105a7d93a24e0ab4
This commit is contained in:
David Pursehouse
2016-04-11 20:24:44 +09:00
parent 67881a213a
commit ad0e4bfe7d
81 changed files with 93 additions and 93 deletions

View File

@@ -44,7 +44,7 @@ public class Description {
}
}
public static enum FieldOrdering {
public enum FieldOrdering {
/** Default ordering places fields at end of the parent metric name. */
AT_END,

View File

@@ -54,7 +54,7 @@ public class PrologEnvironment extends BufferingPrologControl {
private static final Logger log =
LoggerFactory.getLogger(PrologEnvironment.class);
public static interface Factory {
public interface Factory {
/**
* Construct a new Prolog interpreter.
*

View File

@@ -39,7 +39,7 @@ import java.util.Map;
/** Access control management for server-wide capabilities. */
public class CapabilityControl {
public static interface Factory {
public interface Factory {
CapabilityControl create(CurrentUser user);
}

View File

@@ -66,7 +66,7 @@ public class CreateAccount implements RestModifyView<TopLevelResource, Input> {
public List<String> groups;
}
public static interface Factory {
public interface Factory {
CreateAccount create(String username);
}

View File

@@ -42,7 +42,7 @@ import org.slf4j.LoggerFactory;
public class CreateEmail implements RestModifyView<AccountResource, EmailInput> {
private static final Logger log = LoggerFactory.getLogger(CreateEmail.class);
public static interface Factory {
public interface Factory {
CreateEmail create(String email);
}

View File

@@ -77,7 +77,7 @@ import java.util.Set;
import java.util.concurrent.ExecutorService;
public class ChangeInserter extends BatchUpdate.InsertChangeOp {
public static interface Factory {
public interface Factory {
ChangeInserter create(Change.Id cid, RevCommit rc, String refName);
}

View File

@@ -68,7 +68,7 @@ public class PatchSetInserter extends BatchUpdate.Op {
private static final Logger log =
LoggerFactory.getLogger(PatchSetInserter.class);
public static interface Factory {
public interface Factory {
PatchSetInserter create(RefControl refControl, PatchSet.Id psId,
RevCommit commit);
}

View File

@@ -28,7 +28,7 @@ public class ReviewerResource implements RestResource {
public static final TypeLiteral<RestView<ReviewerResource>> REVIEWER_KIND =
new TypeLiteral<RestView<ReviewerResource>>() {};
public static interface Factory {
public interface Factory {
ReviewerResource create(ChangeResource change, Account.Id id);
}

View File

@@ -41,7 +41,7 @@ import java.util.TreeMap;
public class ListCaches implements RestReadView<ConfigResource> {
private final DynamicMap<Cache<?, ?>> cacheMap;
public static enum OutputFormat {
public enum OutputFormat {
LIST, TEXT_LIST
}

View File

@@ -52,7 +52,7 @@ public class PostCaches implements RestModifyView<ConfigResource, Input> {
}
}
public static enum Operation {
public enum Operation {
FLUSH_ALL, FLUSH
}

View File

@@ -82,7 +82,7 @@ import java.util.TimeZone;
@Singleton
public class ChangeEditModifier {
private static enum TreeOperation {
private enum TreeOperation {
CHANGE_ENTRY,
DELETE_ENTRY,
RENAME_ENTRY,

View File

@@ -100,7 +100,7 @@ public class BatchUpdate implements AutoCloseable {
}
/** Order of execution of the various phases. */
public static enum Order {
public enum Order {
/**
* Update the repository and execute all ref updates before touching the
* database.

View File

@@ -103,7 +103,7 @@ public class GroupCollector {
return rsrc.getPatchSet().getGroups();
}
private static interface Lookup {
private interface Lookup {
List<String> lookup(PatchSet.Id psId)
throws OrmException, NoSuchChangeException;
}

View File

@@ -106,7 +106,7 @@ public class MergeUtil {
: MergeStrategy.RESOLVE;
}
public static interface Factory {
public interface Factory {
MergeUtil create(ProjectState project);
MergeUtil create(ProjectState project, boolean useContentMerge);
}

View File

@@ -24,7 +24,7 @@ import java.util.EnumSet;
import java.util.Set;
public class NotifyConfig implements Comparable<NotifyConfig> {
public static enum Header {
public enum Header {
TO, CC, BCC
}

View File

@@ -262,7 +262,7 @@ public class WorkQueue {
* <li>{@link #DONE}: finished executing, if not periodic.</li>
* </ol>
*/
public static enum State {
public enum State {
// Ordered like this so ordinal matches the order we would
// prefer to see tasks sorted in: done before running,
// running before ready, ready before sleeping.

View File

@@ -66,7 +66,7 @@ public class CommitValidators {
private static final Logger log = LoggerFactory
.getLogger(CommitValidators.class);
public static enum Policy {
public enum Policy {
/** Use {@link #validateForGerritCommits}. */
GERRIT,

View File

@@ -56,7 +56,7 @@ import java.util.Locale;
@RequiresCapability(GlobalCapability.CREATE_GROUP)
public class CreateGroup implements RestModifyView<TopLevelResource, GroupInput> {
public static interface Factory {
public interface Factory {
CreateGroup create(@Assisted String name);
}

View File

@@ -24,7 +24,7 @@ import com.google.inject.assistedinject.Assisted;
/** Send notice about a change being abandoned by its owner. */
public class AbandonedSender extends ReplyToChangeSender {
public static interface Factory extends
public interface Factory extends
ReplyToChangeSender.Factory<AbandonedSender> {
@Override
AbandonedSender create(Project.NameKey project, Change.Id change);

View File

@@ -23,7 +23,7 @@ import com.google.inject.assistedinject.Assisted;
/** Asks a user to review a change. */
public class AddReviewerSender extends NewChangeSender {
public static interface Factory {
public interface Factory {
AddReviewerSender create(Project.NameKey project, Change.Id id);
}

View File

@@ -52,7 +52,7 @@ public class CommentSender extends ReplyToChangeSender {
private static final Logger log = LoggerFactory
.getLogger(CommentSender.class);
public static interface Factory {
public interface Factory {
CommentSender create(Project.NameKey project, Change.Id id);
}

View File

@@ -33,7 +33,7 @@ public class CreateChangeSender extends NewChangeSender {
private static final Logger log =
LoggerFactory.getLogger(CreateChangeSender.class);
public static interface Factory {
public interface Factory {
CreateChangeSender create(Project.NameKey project, Change.Id id);
}

View File

@@ -24,7 +24,7 @@ import com.google.inject.assistedinject.Assisted;
/** Send notice about a vote that was removed from a change. */
public class DeleteVoteSender extends ReplyToChangeSender {
public static interface Factory extends
public interface Factory extends
ReplyToChangeSender.Factory<DeleteVoteSender> {
@Override
DeleteVoteSender create(Project.NameKey project, Change.Id change);

View File

@@ -23,7 +23,7 @@ import com.google.inject.assistedinject.Assisted;
/** Send notice about a change failing to merged. */
public class MergeFailSender extends ReplyToChangeSender {
public static interface Factory {
public interface Factory {
MergeFailSender create(Project.NameKey project, Change.Id id);
}

View File

@@ -31,7 +31,7 @@ import com.google.inject.assistedinject.Assisted;
/** Send notice about a change successfully merged. */
public class MergedSender extends ReplyToChangeSender {
public static interface Factory {
public interface Factory {
MergedSender create(Project.NameKey project, Change.Id id);
}

View File

@@ -31,7 +31,7 @@ import java.util.Set;
/** Send notice of new patch sets for reviewers. */
public class ReplacePatchSetSender extends ReplyToChangeSender {
public static interface Factory {
public interface Factory {
ReplacePatchSetSender create(Project.NameKey project, Change.Id id);
}

View File

@@ -22,7 +22,7 @@ import com.google.gwtorm.server.OrmException;
/** Alert a user to a reply to a change, usually commentary made during review. */
public abstract class ReplyToChangeSender extends ChangeEmail {
public static interface Factory<T extends ReplyToChangeSender> {
public interface Factory<T extends ReplyToChangeSender> {
T create(Project.NameKey project, Change.Id id);
}

View File

@@ -24,7 +24,7 @@ import com.google.inject.assistedinject.Assisted;
/** Send notice about a change being restored by its owner. */
public class RestoredSender extends ReplyToChangeSender {
public static interface Factory extends
public interface Factory extends
ReplyToChangeSender.Factory<RestoredSender> {
@Override
RestoredSender create(Project.NameKey project, Change.Id id);

View File

@@ -24,7 +24,7 @@ import com.google.inject.assistedinject.Assisted;
/** Send notice about a change being reverted. */
public class RevertedSender extends ReplyToChangeSender {
public static interface Factory {
public interface Factory {
RevertedSender create(Project.NameKey project, Change.Id id);
}

View File

@@ -57,7 +57,7 @@ public class SmtpEmailSender implements EmailSender {
}
}
public static enum Encryption {
public enum Encryption {
NONE, SSL, TLS
}

View File

@@ -37,7 +37,7 @@ import java.util.List;
public class IntraLineDiff implements Serializable {
static final long serialVersionUID = IntraLineDiffKey.serialVersionUID;
public static enum Status implements CodedEnum {
public enum Status implements CodedEnum {
EDIT_LIST('e'), DISABLED('D'), TIMEOUT('T'), ERROR('E');
private final char code;

View File

@@ -40,7 +40,7 @@ import java.util.regex.Pattern;
class IntraLineLoader implements Callable<IntraLineDiff> {
static final Logger log = LoggerFactory.getLogger(IntraLineLoader.class);
static interface Factory {
interface Factory {
IntraLineLoader create(IntraLineDiffKey key, IntraLineDiffArgs args);
}

View File

@@ -18,7 +18,7 @@ package com.google.gerrit.server.plugins;
public interface HttpModuleGenerator extends ModuleGenerator {
void export(String javascript);
static class NOP extends ModuleGenerator.NOP
class NOP extends ModuleGenerator.NOP
implements HttpModuleGenerator {
@Override
public void export(String javascript) {

View File

@@ -27,7 +27,7 @@ public interface ModuleGenerator {
Module create() throws InvalidPluginException;
static class NOP implements ModuleGenerator {
class NOP implements ModuleGenerator {
@Override
public void setPluginName(String name) {

View File

@@ -32,7 +32,7 @@ import java.util.jar.Attributes;
import java.util.jar.Manifest;
public abstract class Plugin {
public static enum ApiType {
public enum ApiType {
EXTENSION, PLUGIN, JS
}

View File

@@ -64,7 +64,7 @@ public class CreateBranch implements RestModifyView<ProjectResource, Input> {
public String revision;
}
public static interface Factory {
public interface Factory {
CreateBranch create(String ref);
}

View File

@@ -80,7 +80,7 @@ import java.util.List;
@RequiresCapability(GlobalCapability.CREATE_PROJECT)
public class CreateProject implements RestModifyView<TopLevelResource, ProjectInput> {
public static interface Factory {
public interface Factory {
CreateProject create(String name);
}

View File

@@ -76,7 +76,7 @@ import java.util.TreeSet;
public class ListProjects implements RestReadView<TopLevelResource> {
private static final Logger log = LoggerFactory.getLogger(ListProjects.class);
public static enum FilterType {
public enum FilterType {
CODE {
@Override
boolean matches(Repository git) throws IOException {

View File

@@ -69,7 +69,7 @@ public class OutputStreamQuery {
private static final DateTimeFormatter dtf =
DateTimeFormat.forPattern("yyyy-MM-dd HH:mm:ss zzz");
public static enum OutputFormat {
public enum OutputFormat {
TEXT, JSON
}

View File

@@ -91,7 +91,7 @@ public class DataSourceProvider implements Provider<DataSource>,
}
}
public static enum Context {
public enum Context {
SINGLE_USER, MULTI_USER
}

View File

@@ -135,7 +135,7 @@ public class ToolsCatalog {
/** A file served out of the tools root directory. */
public static class Entry {
public static enum Type {
public enum Type {
DIR, FILE
}

View File

@@ -19,7 +19,7 @@ import java.util.SortedSet;
public class TreeFormatter {
public static interface TreeNode {
public interface TreeNode {
String getDisplayName();
boolean isVisible();
SortedSet<? extends TreeNode> getChildren();