classpath-patches
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[cp-patches] FYI: API doc fixes in java.text.* package


From: David Gilbert
Subject: [cp-patches] FYI: API doc fixes in java.text.* package
Date: Wed, 20 Jul 2005 09:11:02 +0000
User-agent: Mozilla Thunderbird 1.0.2 (X11/20050426)

I committed this patch to clean up some minor API doc problems:

2005-07-20  David Gilbert  <address@hidden>

        * java/text/AttributedCharacterIterator.java: fixed minor API doc
        problems and 80 column wrapping;
        * java/text/BreakIterator.java
        (getCharacterInstance(Locale)): matched argument name to API docs,
        (getLineInstance(Locale)): likewise,
        (getSentenceInstance(Locale)): likewise,
        (getWordInstance(Locale)): likewise,
        and fixed minor API doc problems all over;
        * java/text/CharacterIterator.java: fixed minor API doc problems.

Regards,

Dave Gilbert

Index: java/text/AttributedCharacterIterator.java
===================================================================
RCS file: 
/cvsroot/classpath/classpath/java/text/AttributedCharacterIterator.java,v
retrieving revision 1.11
diff -u -r1.11 AttributedCharacterIterator.java
--- java/text/AttributedCharacterIterator.java  2 Jul 2005 20:32:41 -0000       
1.11
+++ java/text/AttributedCharacterIterator.java  20 Jul 2005 08:04:46 -0000
@@ -74,7 +74,8 @@
      * This is the attribute for the reading form of text.  This is used
      * for storing pronunciation along with the written text for languages
      * which need it.  The value of attributes of this key type are
-     * instances of <code>Annotation</code> which wrappers a 
<code>String</code>.
+     * instances of <code>Annotation</code> which wrappers a 
+     * <code>String</code>.
      */
     public static final Attribute READING = new Attribute ("READING");
 
@@ -114,14 +115,16 @@
     }
 
     /**
-     * This method resolves an instance of 
<code>AttributedCharacterIterator.Attribute</code>
+     * This method resolves an instance of 
+     * <code>AttributedCharacterIterator.Attribute</code>
      * that is being deserialized to one of the three pre-defined attribute
      * constants.  It does this by comparing the names of the attributes.  The
      * constant that the deserialized object resolves to is returned.
      *
      * @return The resolved contant value
      *
-     * @exception InvalidObjectException If the object being deserialized 
cannot be resolved.
+     * @exception InvalidObjectException If the object being deserialized 
+     *            cannot be resolved.
      */
     protected Object readResolve() throws InvalidObjectException
     {
@@ -134,7 +137,8 @@
       if (this.equals (INPUT_METHOD_SEGMENT))
         return INPUT_METHOD_SEGMENT;
 
-      throw new InvalidObjectException ("Can't resolve Attribute: " + 
getName());
+      throw new InvalidObjectException ("Can't resolve Attribute: " 
+              + getName());
     }
     
     /**
@@ -142,13 +146,16 @@
      * The two objects will be considered equal if and only if:
      * <ul>
      * <li>The specified object is not <code>null</code>.
-     * <li>The specified object is an instance of 
<code>AttributedCharacterIterator.Attribute</code>.
+     * <li>The specified object is an instance of 
+     * <code>AttributedCharacterIterator.Attribute</code>.
      * <li>The specified object has the same attribute name as this object.
      * </ul>
      *
-     * @param The <code>Object</code> to test for equality against this object.
+     * @param obj  the <code>Object</code> to test for equality against this 
+     *             object.
      *
-     * @return <code>true</code> if the specified object is equal to this one, 
<code>false</code> otherwise.
+     * @return <code>true</code> if the specified object is equal to this one, 
+     *         <code>false</code> otherwise.
      */
     public final boolean equals (Object obj)
     {
Index: java/text/BreakIterator.java
===================================================================
RCS file: /cvsroot/classpath/classpath/java/text/BreakIterator.java,v
retrieving revision 1.11
diff -u -r1.11 BreakIterator.java
--- java/text/BreakIterator.java        2 Jul 2005 20:32:41 -0000       1.11
+++ java/text/BreakIterator.java        20 Jul 2005 08:04:47 -0000
@@ -114,9 +114,9 @@
    * This methdod returns the offset of the text element boundary following
    * the specified offset.
    *
-   * @param offset The text index from which to find the next text boundary.
+   * @param pos The text index from which to find the next text boundary.
    *
-   * @param The next text boundary following the specified index.
+   * @return The next text boundary following the specified index.
    */
   public abstract int following (int pos);
 
@@ -186,9 +186,9 @@
    *
    * @return A <code>BreakIterator</code> instance for the default locale.
    */
-  public static BreakIterator getCharacterInstance (Locale loc)
+  public static BreakIterator getCharacterInstance (Locale locale)
   {
-    BreakIterator r = getInstance ("CharacterIterator", loc);
+    BreakIterator r = getInstance ("CharacterIterator", locale);
     if (r == null)
       r = new gnu.java.text.CharacterBreakIterator ();
     return r;
@@ -214,9 +214,9 @@
    *
    * @return A <code>BreakIterator</code> instance for the default locale.
    */
-  public static BreakIterator getLineInstance (Locale loc)
+  public static BreakIterator getLineInstance (Locale locale)
   {
-    BreakIterator r = getInstance ("LineIterator", loc);
+    BreakIterator r = getInstance ("LineIterator", locale);
     if (r == null)
       r = new gnu.java.text.LineBreakIterator ();
     return r;
@@ -242,9 +242,9 @@
    *
    * @return A <code>BreakIterator</code> instance for the default locale.
    */
-  public static BreakIterator getSentenceInstance (Locale loc)
+  public static BreakIterator getSentenceInstance (Locale locale)
   {
-    BreakIterator r = getInstance ("SentenceIterator", loc);
+    BreakIterator r = getInstance ("SentenceIterator", locale);
     if (r == null)
       r = new gnu.java.text.SentenceBreakIterator ();
     return r;
@@ -254,7 +254,7 @@
    * This method returns the text this object is iterating over as a
    * <code>CharacterIterator</code>.
    *
-   * @param The text being iterated over.
+   * @return The text being iterated over.
    */
   public abstract CharacterIterator getText ();
 
@@ -278,9 +278,9 @@
    *
    * @return A <code>BreakIterator</code> instance for the default locale.
    */
-  public static BreakIterator getWordInstance (Locale loc)
+  public static BreakIterator getWordInstance (Locale locale)
   {
-    BreakIterator r = getInstance ("WordIterator", loc);
+    BreakIterator r = getInstance ("WordIterator", locale);
     if (r == null)
       r = new gnu.java.text.WordBreakIterator ();
     return r;
@@ -290,7 +290,7 @@
    * This method tests whether or not the specified position is a text
    * element boundary.
    *
-   * @param offset The text position to test.
+   * @param pos The text position to test.
    *
    * @return <code>true</code> if the position is a boundary,
    * <code>false</code> otherwise. 
@@ -332,8 +332,7 @@
    * This methdod returns the offset of the text element boundary preceding
    * the specified offset.
    *
-   * @param offset The text index from which to find the preceding
-   *               text boundary. 
+   * @param pos The text index from which to find the preceding text boundary. 
    *
    * @returns The next text boundary preceding the specified index.
    */
@@ -357,7 +356,7 @@
   /**
    * This method sets the text string to iterate over.
    *
-   * @param str The <code>String</code> to iterate over.
+   * @param newText The <code>String</code> to iterate over.
    */
   public void setText (String newText)
   {
@@ -368,7 +367,7 @@
    * This method sets the text to iterate over from the specified
    * <code>CharacterIterator</code>.
    * 
-   * @param ci The desired <code>CharacterIterator</code>.
+   * @param newText The desired <code>CharacterIterator</code>.
    */
   public abstract void setText (CharacterIterator newText);
 }
Index: java/text/CharacterIterator.java
===================================================================
RCS file: /cvsroot/classpath/classpath/java/text/CharacterIterator.java,v
retrieving revision 1.7
diff -u -r1.7 CharacterIterator.java
--- java/text/CharacterIterator.java    2 Jul 2005 20:32:41 -0000       1.7
+++ java/text/CharacterIterator.java    20 Jul 2005 08:04:47 -0000
@@ -1,5 +1,5 @@
 /* CharacterIterator.java -- Iterate over a character range
-   Copyright (C) 1998, 2001 Free Software Foundation, Inc.
+   Copyright (C) 1998, 2001, 2005 Free Software Foundation, Inc.
 
 This file is part of GNU Classpath.
 
@@ -64,8 +64,8 @@
 
   /**
    * This method increments the current index and then returns the character
-   * at the new index value.  If the index is already at <code>getEndIndex() - 
1</code>,
-   * it will not be incremented.
+   * at the new index value.  If the index is already at 
+   * <code>getEndIndex() - 1</code>, it will not be incremented.
    *
    * @return The character at the position of the incremented index value,
    * or <code>DONE</code> if the index has reached getEndIndex() - 1
@@ -78,7 +78,8 @@
    * index, it will not be decremented.
    *
    * @return The character at the position of the decremented index value,
-   * or <code>DONE</code> if index was already equal to the beginning index 
value.
+   *         or address@hidden #DONE} if index was already equal to the 
beginning index
+   *         value.
    */
   char previous();
 
@@ -86,7 +87,8 @@
    * This method sets the index value to the beginning of the range and returns
    * the character there.
    *
-   * @return The character at the beginning of the range, or <code>DONE</code> 
if the range is empty.
+   * @return The character at the beginning of the range, or address@hidden 
#DONE} if 
+   *         the range is empty.
    */
   char first();
 
@@ -95,7 +97,8 @@
    * returns the character there.  If the range is empty, then the index value
    * will be set equal to the beginning index.
    *
-   * @return The character at the end of the range, or <code>DONE</code> if 
the range is empty.
+   * @return The character at the end of the range, or address@hidden #DONE} 
if the 
+   *         range is empty.
    */
   char last();  
 
@@ -112,7 +115,8 @@
    *
    * @param index The new index value.
    *
-   * @return The character at the new index value or <code>DONE</code> if the 
index value is equal to <code>getEndIndex</code>.
+   * @return The character at the new index value or address@hidden #DONE} if 
the index
+   *         value is equal to address@hidden #getEndIndex()}.
    */
   char setIndex (int index) throws IllegalArgumentException;
 

reply via email to

[Prev in Thread] Current Thread [Next in Thread]