Remove redundant 'final' modifiers
The 'final' modifier is redundant on private members, and on members of 'final' classes. Change-Id: Ib89f00f3c839cc58be26bc58a2acae8d095bcbc7
This commit is contained in:
@@ -39,48 +39,48 @@ public final class Plugin extends JavaScriptObject {
|
||||
}
|
||||
|
||||
/** Installed name of the plugin. */
|
||||
public final String getName() {
|
||||
public String getName() {
|
||||
return getPluginName();
|
||||
}
|
||||
|
||||
/** Installed name of the plugin. */
|
||||
public final native String getPluginName()
|
||||
public native String getPluginName()
|
||||
/*-{ return this.getPluginName() }-*/;
|
||||
|
||||
/** Navigate the UI to the screen identified by the token. */
|
||||
public final native void go(String token)
|
||||
public native void go(String token)
|
||||
/*-{ return this.go(token) }-*/;
|
||||
|
||||
/** Refresh the current UI. */
|
||||
public final native void refresh()
|
||||
public native void refresh()
|
||||
/*-{ return this.refresh() }-*/;
|
||||
|
||||
/** Refresh Gerrit's menu bar. */
|
||||
public final native void refreshMenuBar()
|
||||
public native void refreshMenuBar()
|
||||
/*-{ return this.refreshMenuBar() }-*/;
|
||||
|
||||
/** @return the preferences of the currently signed in user, the default preferences if not signed in */
|
||||
public final native GeneralPreferences getUserPreferences()
|
||||
public native GeneralPreferences getUserPreferences()
|
||||
/*-{ return this.getUserPreferences() }-*/;
|
||||
|
||||
/** Refresh the user preferences of the current user. */
|
||||
public final native void refreshUserPreferences()
|
||||
public native void refreshUserPreferences()
|
||||
/*-{ return this.refreshUserPreferences() }-*/;
|
||||
|
||||
/** @return the server info */
|
||||
public final native ServerInfo getServerInfo()
|
||||
public native ServerInfo getServerInfo()
|
||||
/*-{ return this.getServerInfo() }-*/;
|
||||
|
||||
/** @return the current user */
|
||||
public final native AccountInfo getCurrentUser()
|
||||
public native AccountInfo getCurrentUser()
|
||||
/*-{ return this.getCurrentUser() }-*/;
|
||||
|
||||
/** Check if user is signed in. */
|
||||
public final native boolean isSignedIn()
|
||||
public native boolean isSignedIn()
|
||||
/*-{ return this.isSignedIn() }-*/;
|
||||
|
||||
/** Show message in Gerrit's ErrorDialog. */
|
||||
public final native void showError(String message)
|
||||
public native void showError(String message)
|
||||
/*-{ return this.showError(message) }-*/;
|
||||
|
||||
/**
|
||||
@@ -90,7 +90,7 @@ public final class Plugin extends JavaScriptObject {
|
||||
* regular expression matching use {@code screenRegex()} .
|
||||
* @param entry callback function invoked to create the screen widgets.
|
||||
*/
|
||||
public final void screen(String token, Screen.EntryPoint entry) {
|
||||
public void screen(String token, Screen.EntryPoint entry) {
|
||||
screen(token, wrap(entry));
|
||||
}
|
||||
|
||||
@@ -105,7 +105,7 @@ public final class Plugin extends JavaScriptObject {
|
||||
* {@code Screen} object passed into the {@code Screen.EntryPoint}.
|
||||
* @param entry callback function invoked to create the screen widgets.
|
||||
*/
|
||||
public final void screenRegex(String regex, Screen.EntryPoint entry) {
|
||||
public void screenRegex(String regex, Screen.EntryPoint entry) {
|
||||
screenRegex(regex, wrap(entry));
|
||||
}
|
||||
|
||||
@@ -118,7 +118,7 @@ public final class Plugin extends JavaScriptObject {
|
||||
* @param token literal anchor token appearing after the plugin name.
|
||||
* @param entry callback function invoked to create the settings screen widgets.
|
||||
*/
|
||||
public final void settingsScreen(String token, String menu, Screen.EntryPoint entry) {
|
||||
public void settingsScreen(String token, String menu, Screen.EntryPoint entry) {
|
||||
settingsScreen(token, menu, wrap(entry));
|
||||
}
|
||||
|
||||
@@ -132,7 +132,7 @@ public final class Plugin extends JavaScriptObject {
|
||||
* registered.
|
||||
* @param entry callback function invoked to create the panel widgets.
|
||||
*/
|
||||
public final void panel(GerritUiExtensionPoint extensionPoint, Panel.EntryPoint entry) {
|
||||
public void panel(GerritUiExtensionPoint extensionPoint, Panel.EntryPoint entry) {
|
||||
panel(extensionPoint.name(), wrap(entry));
|
||||
}
|
||||
|
||||
|
@@ -60,20 +60,20 @@ public class Panel extends SimplePanel {
|
||||
}
|
||||
|
||||
static final class Context extends JavaScriptObject {
|
||||
final native Element body() /*-{ return this.body }-*/;
|
||||
native Element body() /*-{ return this.body }-*/;
|
||||
|
||||
final native String get(String k) /*-{ return this.p[k]; }-*/;
|
||||
final native int getInt(String k, int d) /*-{
|
||||
native String get(String k) /*-{ return this.p[k]; }-*/;
|
||||
native int getInt(String k, int d) /*-{
|
||||
return this.p.hasOwnProperty(k) ? this.p[k] : d
|
||||
}-*/;
|
||||
final native int getBoolean(String k, boolean d) /*-{
|
||||
native int getBoolean(String k, boolean d) /*-{
|
||||
return this.p.hasOwnProperty(k) ? this.p[k] : d
|
||||
}-*/;
|
||||
final native JavaScriptObject getObject(String k)
|
||||
native JavaScriptObject getObject(String k)
|
||||
/*-{ return this.p[k]; }-*/;
|
||||
|
||||
|
||||
final native void detach(Panel p) /*-{
|
||||
native void detach(Panel p) /*-{
|
||||
this.onUnload($entry(function(){
|
||||
p.@com.google.gwt.user.client.ui.Widget::onDetach()();
|
||||
}));
|
||||
|
@@ -62,12 +62,12 @@ public final class Screen extends SimplePanel {
|
||||
}
|
||||
|
||||
static final class Context extends JavaScriptObject {
|
||||
final native Element body() /*-{ return this.body }-*/;
|
||||
final native JsArrayString token_match() /*-{ return this.token_match }-*/;
|
||||
final native void show() /*-{ this.show() }-*/;
|
||||
final native void setTitle(String t) /*-{ this.setTitle(t) }-*/;
|
||||
final native void setWindowTitle(String t) /*-{ this.setWindowTitle(t) }-*/;
|
||||
final native void detach(Screen s) /*-{
|
||||
native Element body() /*-{ return this.body }-*/;
|
||||
native JsArrayString token_match() /*-{ return this.token_match }-*/;
|
||||
native void show() /*-{ this.show() }-*/;
|
||||
native void setTitle(String t) /*-{ this.setTitle(t) }-*/;
|
||||
native void setWindowTitle(String t) /*-{ this.setWindowTitle(t) }-*/;
|
||||
native void detach(Screen s) /*-{
|
||||
this.onUnload($entry(function(){
|
||||
s.@com.google.gwt.user.client.ui.Widget::onDetach()();
|
||||
}));
|
||||
@@ -87,7 +87,7 @@ public final class Screen extends SimplePanel {
|
||||
}
|
||||
|
||||
/** @return the token suffix after {@code "/#/x/plugin-name/"}. */
|
||||
public final String getToken() {
|
||||
public String getToken() {
|
||||
return getToken(0);
|
||||
}
|
||||
|
||||
@@ -96,12 +96,12 @@ public final class Screen extends SimplePanel {
|
||||
* group 0 is the entire token, see {@link #getToken()}.
|
||||
* @return the token from the regex match group.
|
||||
*/
|
||||
public final String getToken(int group) {
|
||||
public String getToken(int group) {
|
||||
return ctx.token_match().get(group);
|
||||
}
|
||||
|
||||
/** @return total number of token groups. */
|
||||
public final int getTokenGroups() {
|
||||
public int getTokenGroups() {
|
||||
return ctx.token_match().length();
|
||||
}
|
||||
|
||||
@@ -110,7 +110,7 @@ public final class Screen extends SimplePanel {
|
||||
*
|
||||
* @param titleText text to display above the widget.
|
||||
*/
|
||||
public final void setPageTitle(String titleText) {
|
||||
public void setPageTitle(String titleText) {
|
||||
ctx.setTitle(titleText);
|
||||
}
|
||||
|
||||
@@ -119,7 +119,7 @@ public final class Screen extends SimplePanel {
|
||||
*
|
||||
* @param titleText text to display in the window title bar.
|
||||
*/
|
||||
public final void setWindowTitle(String titleText) {
|
||||
public void setWindowTitle(String titleText) {
|
||||
ctx.setWindowTitle(titleText);
|
||||
}
|
||||
|
||||
@@ -128,13 +128,13 @@ public final class Screen extends SimplePanel {
|
||||
*
|
||||
* @param w child containing the content.
|
||||
*/
|
||||
public final void show(Widget w) {
|
||||
public void show(Widget w) {
|
||||
setWidget(w);
|
||||
ctx.show();
|
||||
}
|
||||
|
||||
/** Show this screen in the web interface. */
|
||||
public final void show() {
|
||||
public void show() {
|
||||
ctx.show();
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user