You are viewing a plain text version of this content. The canonical link for it is here.
Posted to fop-commits@xmlgraphics.apache.org by pb...@apache.org on 2002/10/03 15:13:51 UTC

cvs commit: xml-fop/src/org/apache/fop/fo FObjectNames.java

pbwest      2002/10/03 06:13:51

  Modified:    src/org/apache/fop/fo Tag: FOP_0-20-0_Alt-Design
                        FObjectNames.java
  Log:
  Added getFOName().
  
  Revision  Changes    Path
  No                   revision
  
  
  No                   revision
  
  
  1.1.2.4   +19 -2     xml-fop/src/org/apache/fop/fo/Attic/FObjectNames.java
  
  Index: FObjectNames.java
  ===================================================================
  RCS file: /home/cvs/xml-fop/src/org/apache/fop/fo/Attic/FObjectNames.java,v
  retrieving revision 1.1.2.3
  retrieving revision 1.1.2.4
  diff -u -r1.1.2.3 -r1.1.2.4
  --- FObjectNames.java	3 Sep 2002 03:30:51 -0000	1.1.2.3
  +++ FObjectNames.java	3 Oct 2002 13:13:51 -0000	1.1.2.4
  @@ -10,6 +10,8 @@
   
   package org.apache.fop.fo;
   
  +import org.apache.fop.apps.FOPException;
  +
   /**
    * Data class containing the Flow Object names and associated integer
    * constants.
  @@ -153,4 +155,19 @@
                                   ,{ "title", "fo.sequences"    }  //55
                                 ,{ "wrapper", "fo.sequences"    }  //56
       };
  +
  +    /**
  +     * @param foType <tt>int</tt> index of the FO type.
  +     * @return <tt>String</tt> name of the FO.
  +     * @exception FOPException if the FO index is invalid.
  +     */
  +    public static String getFOName(int foType)
  +                throws FOPException
  +    {
  +        if (foType < 0 || foType > LAST_FO)
  +                throw new FOPException
  +                        ("getFOName: type is invalid: " + foType);
  +        return foLocalNames[foType][0];
  +    }
  +
   }
  
  
  

---------------------------------------------------------------------
To unsubscribe, e-mail: fop-cvs-unsubscribe@xml.apache.org
For additional commands, e-mail: fop-cvs-help@xml.apache.org