commons-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From rwins...@apache.org
Subject svn commit: r489067 - in /jakarta/commons/proper/net/branches/JDK_1_5_BRANCH/src: main/java/org/apache/commons/net/ntp/TimeInfo.java main/java/org/apache/commons/net/telnet/TelnetOption.java site/site.xml
Date Wed, 20 Dec 2006 12:24:44 GMT
Author: rwinston
Date: Wed Dec 20 04:24:43 2006
New Revision: 489067

URL: http://svn.apache.org/viewvc?view=rev&rev=489067
Log:
Some more FindBugs improvements

Modified:
    jakarta/commons/proper/net/branches/JDK_1_5_BRANCH/src/main/java/org/apache/commons/net/ntp/TimeInfo.java
    jakarta/commons/proper/net/branches/JDK_1_5_BRANCH/src/main/java/org/apache/commons/net/telnet/TelnetOption.java
    jakarta/commons/proper/net/branches/JDK_1_5_BRANCH/src/site/site.xml

Modified: jakarta/commons/proper/net/branches/JDK_1_5_BRANCH/src/main/java/org/apache/commons/net/ntp/TimeInfo.java
URL: http://svn.apache.org/viewvc/jakarta/commons/proper/net/branches/JDK_1_5_BRANCH/src/main/java/org/apache/commons/net/ntp/TimeInfo.java?view=diff&rev=489067&r1=489066&r2=489067
==============================================================================
--- jakarta/commons/proper/net/branches/JDK_1_5_BRANCH/src/main/java/org/apache/commons/net/ntp/TimeInfo.java
(original)
+++ jakarta/commons/proper/net/branches/JDK_1_5_BRANCH/src/main/java/org/apache/commons/net/ntp/TimeInfo.java
Wed Dec 20 04:24:43 2006
@@ -29,7 +29,7 @@
 public class TimeInfo {
 
     private NtpV3Packet _message;
-    private List _comments;
+    private List<String> _comments;
     private Long _delay;
     private Long _offset;
 
@@ -117,7 +117,7 @@
     public void addComment(String comment)
     {
         if (_comments == null) {
-            _comments = new ArrayList();
+            _comments = new ArrayList<String>();
         }
         _comments.add(comment);
     }
@@ -133,7 +133,7 @@
         }
         _detailsComputed = true;
         if (_comments == null) {
-            _comments = new ArrayList();
+            _comments = new ArrayList<String>();
         }
 
         TimeStamp origNtpTime = _message.getOriginateTimeStamp();
@@ -169,7 +169,7 @@
             // might be via a broadcast NTP packet...
             if (xmitNtpTime.ntpValue() != 0)
             {
-                _offset = new Long(xmitTime - _returnTime);
+                _offset = Long.valueOf(xmitTime - _returnTime);
                 _comments.add("Error: zero orig time -- cannot compute delay");
             } else
                 _comments.add("Error: zero orig time -- cannot compute delay/offset");
@@ -183,7 +183,7 @@
             {
                 // without receive or xmit time cannot figure out processing time
                 // so delay is simply the network travel time
-                _delay = new Long(_returnTime - origTime);
+                _delay = Long.valueOf(_returnTime - origTime);
             }
             // TODO: is offset still valid if rcvNtpTime=0 || xmitNtpTime=0 ???
             // Could always hash origNtpTime (sendTime) but if host doesn't set it
@@ -192,11 +192,11 @@
             if (rcvNtpTime.ntpValue() != 0)
             {
                 // xmitTime is 0 just use rcv time
-                _offset = new Long(rcvTime - origTime);
+                _offset = Long.valueOf(rcvTime - origTime);
             } else if (xmitNtpTime.ntpValue() != 0)
             {
                 // rcvTime is 0 just use xmitTime time
-                _offset = new Long(xmitTime - _returnTime);
+                _offset = Long.valueOf(xmitTime - _returnTime);
             }
         } else
         {
@@ -231,11 +231,11 @@
                          _comments.add("Warning: processing time > total network time");
                  }
              }
-             _delay = new Long(delayValue);
+             _delay = Long.valueOf(delayValue);
             if (origTime > _returnTime) // assert destTime >= origTime
                 _comments.add("Error: OrigTime > DestRcvTime");
 
-            _offset = new Long(((rcvTime - origTime) + (xmitTime - _returnTime)) / 2);
+            _offset = Long.valueOf(((rcvTime - origTime) + (xmitTime - _returnTime)) / 2);
         }
     }
 

Modified: jakarta/commons/proper/net/branches/JDK_1_5_BRANCH/src/main/java/org/apache/commons/net/telnet/TelnetOption.java
URL: http://svn.apache.org/viewvc/jakarta/commons/proper/net/branches/JDK_1_5_BRANCH/src/main/java/org/apache/commons/net/telnet/TelnetOption.java?view=diff&rev=489067&r1=489066&r2=489067
==============================================================================
--- jakarta/commons/proper/net/branches/JDK_1_5_BRANCH/src/main/java/org/apache/commons/net/telnet/TelnetOption.java
(original)
+++ jakarta/commons/proper/net/branches/JDK_1_5_BRANCH/src/main/java/org/apache/commons/net/telnet/TelnetOption.java
Wed Dec 20 04:24:43 2006
@@ -32,87 +32,87 @@
     /*** The maximum value an option code can have.  This value is 255. ***/
     public static final int MAX_OPTION_VALUE = 255;
 
-    public static int BINARY = 0;
+    public static final int BINARY = 0;
 
-    public static int ECHO = 1;
+    public static final int ECHO = 1;
 
-    public static int PREPARE_TO_RECONNECT = 2;
+    public static final int PREPARE_TO_RECONNECT = 2;
 
-    public static int SUPPRESS_GO_AHEAD = 3;
+    public static final int SUPPRESS_GO_AHEAD = 3;
 
-    public static int APPROXIMATE_MESSAGE_SIZE = 4;
+    public static final int APPROXIMATE_MESSAGE_SIZE = 4;
 
-    public static int STATUS = 5;
+    public static final int STATUS = 5;
 
-    public static int TIMING_MARK = 6;
+    public static final int TIMING_MARK = 6;
 
-    public static int REMOTE_CONTROLLED_TRANSMISSION = 7;
+    public static final int REMOTE_CONTROLLED_TRANSMISSION = 7;
 
-    public static int NEGOTIATE_OUTPUT_LINE_WIDTH = 8;
+    public static final int NEGOTIATE_OUTPUT_LINE_WIDTH = 8;
 
-    public static int NEGOTIATE_OUTPUT_PAGE_SIZE = 9;
+    public static final int NEGOTIATE_OUTPUT_PAGE_SIZE = 9;
 
-    public static int NEGOTIATE_CARRIAGE_RETURN = 10;
+    public static final int NEGOTIATE_CARRIAGE_RETURN = 10;
 
-    public static int NEGOTIATE_HORIZONTAL_TAB_STOP = 11;
+    public static final int NEGOTIATE_HORIZONTAL_TAB_STOP = 11;
 
-    public static int NEGOTIATE_HORIZONTAL_TAB = 12;
+    public static final int NEGOTIATE_HORIZONTAL_TAB = 12;
 
-    public static int NEGOTIATE_FORMFEED = 13;
+    public static final int NEGOTIATE_FORMFEED = 13;
 
-    public static int NEGOTIATE_VERTICAL_TAB_STOP = 14;
+    public static final int NEGOTIATE_VERTICAL_TAB_STOP = 14;
 
-    public static int NEGOTIATE_VERTICAL_TAB = 15;
+    public static final int NEGOTIATE_VERTICAL_TAB = 15;
 
-    public static int NEGOTIATE_LINEFEED = 16;
+    public static final int NEGOTIATE_LINEFEED = 16;
 
-    public static int EXTENDED_ASCII = 17;
+    public static final int EXTENDED_ASCII = 17;
 
-    public static int FORCE_LOGOUT = 18;
+    public static final int FORCE_LOGOUT = 18;
 
-    public static int BYTE_MACRO = 19;
+    public static final int BYTE_MACRO = 19;
 
-    public static int DATA_ENTRY_TERMINAL = 20;
+    public static final int DATA_ENTRY_TERMINAL = 20;
 
-    public static int SUPDUP = 21;
+    public static final int SUPDUP = 21;
 
-    public static int SUPDUP_OUTPUT = 22;
+    public static final int SUPDUP_OUTPUT = 22;
 
-    public static int SEND_LOCATION = 23;
+    public static final int SEND_LOCATION = 23;
 
-    public static int TERMINAL_TYPE = 24;
+    public static final int TERMINAL_TYPE = 24;
 
-    public static int END_OF_RECORD = 25;
+    public static final int END_OF_RECORD = 25;
 
     public static int TACACS_USER_IDENTIFICATION = 26;
 
-    public static int OUTPUT_MARKING = 27;
+    public static final int OUTPUT_MARKING = 27;
 
-    public static int TERMINAL_LOCATION_NUMBER = 28;
+    public static final int TERMINAL_LOCATION_NUMBER = 28;
 
-    public static int REGIME_3270 = 29;
+    public static final int REGIME_3270 = 29;
 
-    public static int X3_PAD = 30;
+    public static final int X3_PAD = 30;
 
-    public static int WINDOW_SIZE = 31;
+    public static final int WINDOW_SIZE = 31;
 
-    public static int TERMINAL_SPEED = 32;
+    public static final int TERMINAL_SPEED = 32;
 
-    public static int REMOTE_FLOW_CONTROL = 33;
+    public static final int REMOTE_FLOW_CONTROL = 33;
 
-    public static int LINEMODE = 34;
+    public static final int LINEMODE = 34;
 
-    public static int X_DISPLAY_LOCATION = 35;
+    public static final int X_DISPLAY_LOCATION = 35;
 
-    public static int OLD_ENVIRONMENT_VARIABLES = 36;
+    public static final int OLD_ENVIRONMENT_VARIABLES = 36;
 
-    public static int AUTHENTICATION = 37;
+    public static final int AUTHENTICATION = 37;
 
-    public static int ENCRYPTION = 38;
+    public static final int ENCRYPTION = 38;
 
-    public static int NEW_ENVIRONMENT_VARIABLES = 39;
+    public static final int NEW_ENVIRONMENT_VARIABLES = 39;
 
-    public static int EXTENDED_OPTIONS_LIST = 255;
+    public static final int EXTENDED_OPTIONS_LIST = 255;
 
     private static int __FIRST_OPTION = BINARY;
     private static int __LAST_OPTION = EXTENDED_OPTIONS_LIST;

Modified: jakarta/commons/proper/net/branches/JDK_1_5_BRANCH/src/site/site.xml
URL: http://svn.apache.org/viewvc/jakarta/commons/proper/net/branches/JDK_1_5_BRANCH/src/site/site.xml?view=diff&rev=489067&r1=489066&r2=489067
==============================================================================
--- jakarta/commons/proper/net/branches/JDK_1_5_BRANCH/src/site/site.xml (original)
+++ jakarta/commons/proper/net/branches/JDK_1_5_BRANCH/src/site/site.xml Wed Dec 20 04:24:43
2006
@@ -24,7 +24,6 @@
       <item name="Release Notes"         href="/changes-report.html"/>
     </menu>
     <menu name="Development">
-      <item name="To-Do List" href="/tasks.html"/>
       <item name="Coding Specifications" href="/code-standards.html"/>
     </menu>
     



---------------------------------------------------------------------
To unsubscribe, e-mail: commons-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: commons-dev-help@jakarta.apache.org


Mime
View raw message