Ignore:
Timestamp:
2014-02-27T01:41:49+01:00 (10 years ago)
Author:
Don-vip
Message:

fix some Sonar issues (JLS order)

Location:
trunk/src/org/openstreetmap/josm/tools
Files:
8 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/org/openstreetmap/josm/tools/AudioUtil.java

    r6830 r6889  
    2828     * @return the calibrated length of recording in seconds.
    2929     */
    30     static public double getCalibratedDuration(File wavFile) {
     30    public static double getCalibratedDuration(File wavFile) {
    3131        try {
    3232            AudioInputStream audioInputStream = AudioSystem.getAudioInputStream(
  • trunk/src/org/openstreetmap/josm/tools/Diff.java

    r6830 r6889  
    491491
    492492    /** Standard ScriptBuilders. */
    493     public final static ScriptBuilder
     493    public static final ScriptBuilder
    494494    forwardScript = new ForwardScript(),
    495495    reverseScript = new ReverseScript();
  • trunk/src/org/openstreetmap/josm/tools/ImageProvider.java

    r6814 r6889  
    854854
    855855    /** 90 degrees in radians units */
    856     final static double DEGREE_90 = 90.0 * Math.PI / 180.0;
     856    static final double DEGREE_90 = 90.0 * Math.PI / 180.0;
    857857
    858858    /**
  • trunk/src/org/openstreetmap/josm/tools/LanguageInfo.java

    r6380 r6889  
    3535     * @since 5915
    3636     */
    37     static public String getWikiLanguagePrefix(LocaleType type) {
     37    public static String getWikiLanguagePrefix(LocaleType type) {
    3838        if(type == LocaleType.ENGLISH)
    3939          return "";
     
    6060     * @see #getWikiLanguagePrefix(LocaleType)
    6161     */
    62     static public String getWikiLanguagePrefix() {
     62    public static String getWikiLanguagePrefix() {
    6363        return getWikiLanguagePrefix(LocaleType.DEFAULT);
    6464    }
     
    7070     * @see #getJOSMLocaleCode(Locale)
    7171     */
    72     static public String getJOSMLocaleCode() {
     72    public static String getJOSMLocaleCode() {
    7373        return getJOSMLocaleCode(Locale.getDefault());
    7474    }
     
    8484     * @return the JOSM code for the given locale
    8585     */
    86     static public String getJOSMLocaleCode(Locale locale) {
     86    public static String getJOSMLocaleCode(Locale locale) {
    8787        if (locale == null) return "en";
    8888        String full = locale.toString();
     
    106106     * @return the resulting locale
    107107     */
    108     static public Locale getLocale(String localeName) {
     108    public static Locale getLocale(String localeName) {
    109109        if (localeName.equals("he")) {
    110110            localeName = "iw_IL";
     
    123123    }
    124124
    125     static public String getLanguageCodeXML() {
     125    public static String getLanguageCodeXML() {
    126126        return getJOSMLocaleCode()+".";
    127127    }
    128128   
    129     static public String getLanguageCodeManifest() {
     129    public static String getLanguageCodeManifest() {
    130130        return getJOSMLocaleCode()+"_";
    131131    }
  • trunk/src/org/openstreetmap/josm/tools/OsmUrlToBounds.java

    r6830 r6889  
    250250     * @return matching zoom level for area
    251251     */
    252     static public int getZoom(Bounds b) {
     252    public static int getZoom(Bounds b) {
    253253        // convert to mercator (for calculation of zoom only)
    254254        double latMin = Math.log(Math.tan(Math.PI/4.0+b.getMinLat()/180.0*Math.PI/2.0))*180.0/Math.PI;
  • trunk/src/org/openstreetmap/josm/tools/Shortcut.java

    r6380 r6889  
    432432     * @return the platform specific key stroke for the  'Copy' command
    433433     */
    434     static public KeyStroke getCopyKeyStroke() {
     434    public static KeyStroke getCopyKeyStroke() {
    435435        Shortcut sc = shortcuts.get("system:copy");
    436436        if (sc == null) return null;
     
    445445     * @return the platform specific key stroke for the 'Paste' command
    446446     */
    447     static public KeyStroke getPasteKeyStroke() {
     447    public static KeyStroke getPasteKeyStroke() {
    448448        Shortcut sc = shortcuts.get("system:paste");
    449449        if (sc == null) return null;
     
    458458     * @return the platform specific key stroke for the 'Cut' command
    459459     */
    460     static public KeyStroke getCutKeyStroke() {
     460    public static KeyStroke getCutKeyStroke() {
    461461        Shortcut sc = shortcuts.get("system:cut");
    462462        if (sc == null) return null;
  • trunk/src/org/openstreetmap/josm/tools/Utils.java

    r6883 r6889  
    412412    }
    413413
    414     private final static double EPSILON = 1e-11;
     414    private static final double EPSILON = 1e-11;
    415415
    416416    /**
  • trunk/src/org/openstreetmap/josm/tools/WindowGeometry.java

    r6828 r6889  
    3131     * @return the geometry object
    3232     */
    33     static public WindowGeometry centerOnScreen(Dimension extent) {
     33    public static WindowGeometry centerOnScreen(Dimension extent) {
    3434        return centerOnScreen(extent, "gui.geometry");
    3535    }
     
    4444     * @return the geometry object
    4545     */
    46     static public WindowGeometry centerOnScreen(Dimension extent, String preferenceKey) {
     46    public static WindowGeometry centerOnScreen(Dimension extent, String preferenceKey) {
    4747        Rectangle size = preferenceKey != null ? getScreenInfo(preferenceKey)
    4848            : getFullScreenInfo();
     
    6262     * @return the geometry object
    6363     */
    64     static public WindowGeometry centerInWindow(Component reference, Dimension extent) {
     64    public static WindowGeometry centerInWindow(Component reference, Dimension extent) {
    6565        Window parentWindow = null;
    6666        while(reference != null && ! (reference instanceof Window) ) {
     
    8282     * Exception thrown by the WindowGeometry class if something goes wrong
    8383     */
    84     static public class WindowGeometryException extends Exception {
     84    public static class WindowGeometryException extends Exception {
    8585        public WindowGeometryException(String message, Throwable cause) {
    8686            super(message, cause);
     
    178178    }
    179179
    180     static public WindowGeometry mainWindow(String preferenceKey, String arg, boolean maximize) {
     180    public static WindowGeometry mainWindow(String preferenceKey, String arg, boolean maximize) {
    181181        Rectangle screenDimension = getScreenInfo("gui.geometry");
    182182        if (arg != null) {
Note: See TracChangeset for help on using the changeset viewer.