xmlgraphics-fop-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From acumis...@apache.org
Subject svn commit: r601433 - /xmlgraphics/fop/trunk/src/java/org/apache/fop/render/afp/fonts/CharacterSet.java
Date Wed, 05 Dec 2007 17:30:05 GMT
Author: acumiskey
Date: Wed Dec  5 09:30:04 2007
New Revision: 601433

URL: http://svn.apache.org/viewvc?rev=601433&view=rev
Log:
Checkstyle fixes

Modified:
    xmlgraphics/fop/trunk/src/java/org/apache/fop/render/afp/fonts/CharacterSet.java

Modified: xmlgraphics/fop/trunk/src/java/org/apache/fop/render/afp/fonts/CharacterSet.java
URL: http://svn.apache.org/viewvc/xmlgraphics/fop/trunk/src/java/org/apache/fop/render/afp/fonts/CharacterSet.java?rev=601433&r1=601432&r2=601433&view=diff
==============================================================================
--- xmlgraphics/fop/trunk/src/java/org/apache/fop/render/afp/fonts/CharacterSet.java (original)
+++ xmlgraphics/fop/trunk/src/java/org/apache/fop/render/afp/fonts/CharacterSet.java Wed Dec
 5 09:30:04 2007
@@ -21,6 +21,7 @@
 
 import java.io.UnsupportedEncodingException;
 import java.util.HashMap;
+import java.util.Map;
 
 import org.apache.commons.logging.Log;
 import org.apache.commons.logging.LogFactory;
@@ -54,42 +55,42 @@
     /**
      * The code page to which the character set relates
      */
-    protected String _codePage;
+    protected String codePage;
 
     /**
      * The encoding used for the code page
      */
-    protected String _encoding;
+    protected String encoding;
 
     /**
      * The character set relating to the font
      */
-    protected String _name;
+    protected String name;
 
     /**
      * The name of the character set as EBCIDIC bytes
      */
-    private byte[] _nameBytes;
+    private byte[] nameBytes;
 
     /**
      * The path to the installed fonts
      */
-    protected String _path;
+    protected String path;
 
     /**
      * Indicator as to whether to metrics have been loaded
      */
-    private boolean _isMetricsLoaded = false;
+    private boolean isMetricsLoaded = false;
 
     /**
      * The current orientation (currently only 0 is suppoted by FOP)
      */
-    private String _currentOrientation = "0";
+    private String currentOrientation = "0";
 
     /**
      * The collection of objects for each orientation
      */
-    private HashMap _characterSetOrientations;
+    private Map characterSetOrientations = null;
 
     /**
      * Constructor for the CharacterSetMetric object, the character set is used
@@ -112,28 +113,28 @@
         }
 
         if (name.length() < 8) {
-            _name = StringUtils.rpad(name, ' ', 8);
+            this.name = StringUtils.rpad(name, ' ', 8);
         } else {
-            _name = name;
+            this.name = name;
         }
 
         try {
 
-            _nameBytes = name.getBytes(AFPConstants.EBCIDIC_ENCODING);
+            this.nameBytes = name.getBytes(AFPConstants.EBCIDIC_ENCODING);
 
         } catch (UnsupportedEncodingException usee) {
 
-            _nameBytes = name.getBytes();
+            this.nameBytes = name.getBytes();
             log.warn(
                 "Constructor:: UnsupportedEncodingException translating the name "
                 + name);
 
         }
 
-        _codePage = codePage;
-        _encoding = encoding;
-        _path = path;
-        _characterSetOrientations = new HashMap(4);
+        this.codePage = codePage;
+        this.encoding = encoding;
+        this.path = path;
+        this.characterSetOrientations = new HashMap(4);
 
     }
 
@@ -143,7 +144,7 @@
      */
     public void addCharacterSetOrientation(CharacterSetOrientation cso) {
 
-        _characterSetOrientations.put(
+        characterSetOrientations.put(
             String.valueOf(cso.getOrientation()),
             cso);
 
@@ -210,7 +211,7 @@
      * @return the path where the font resources are installed
      */
     public String getPath() {
-        return _path;
+        return path;
     }
 
     /**
@@ -248,11 +249,11 @@
      */
     private void load() {
 
-        if (!_isMetricsLoaded) {
+        if (!isMetricsLoaded) {
 
             AFPFontReader afpFontReader = new AFPFontReader();
             afpFontReader.loadCharacterSetMetric(this);
-            _isMetricsLoaded = true;
+            isMetricsLoaded = true;
 
         }
 
@@ -263,7 +264,7 @@
      * @return String
      */
     public String getName() {
-        return _name;
+        return name;
     }
 
     /**
@@ -271,7 +272,7 @@
      * @return byte[]
      */
     public byte[] getNameBytes() {
-        return _nameBytes;
+        return nameBytes;
     }
 
     /**
@@ -279,7 +280,7 @@
      * @return String
      */
     public String getCodePage() {
-        return _codePage;
+        return codePage;
     }
 
     /**
@@ -287,7 +288,7 @@
      * @return String
      */
     public String getEncoding() {
-        return _encoding;
+        return encoding;
     }
 
     /**
@@ -303,9 +304,8 @@
      */
     private CharacterSetOrientation getCharacterSetOrientation() {
 
-        CharacterSetOrientation c =
-            (CharacterSetOrientation) _characterSetOrientations.get(
-            _currentOrientation);
+        CharacterSetOrientation c
+            = (CharacterSetOrientation) characterSetOrientations.get(currentOrientation);
         return c;
 
     }



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


Mime
View raw message