pbwest 2002/12/02 23:25:20
Modified: src/org/apache/fop/fo Tag: FOP_0-20-0_Alt-Design FoRoot.java
Log:
sparsePropsMap changed from HashMap to int[].
Revision Changes Path
No revision
No revision
1.1.2.20 +9 -7 xml-fop/src/org/apache/fop/fo/Attic/FoRoot.java
Index: FoRoot.java
===================================================================
RCS file: /home/cvs/xml-fop/src/org/apache/fop/fo/Attic/FoRoot.java,v
retrieving revision 1.1.2.19
retrieving revision 1.1.2.20
diff -u -r1.1.2.19 -r1.1.2.20
--- FoRoot.java 1 Dec 2002 14:56:26 -0000 1.1.2.19
+++ FoRoot.java 3 Dec 2002 07:25:20 -0000 1.1.2.20
@@ -27,6 +27,7 @@
import org.xml.sax.Attributes;
+import java.util.Arrays;
import java.util.HashMap;
import java.util.NoSuchElementException;
@@ -49,7 +50,7 @@
position in the <i>sparsePropsSet</i> array. See
{@link org.apache.fop.fo.FONode#sparsePropsSet FONode.sparsePropsSet}.
*/
- private static final HashMap sparsePropsMap;
+ private static final int[] sparsePropsMap;
/** An <tt>int</tt> array of of the applicable property indices, in
property index order. */
@@ -63,11 +64,12 @@
// applicableProps is a HashMap containing the indicies of the
// sparsePropsSet array, indexed by the FO index of the FO slot
// in sparsePropsSet.
- sparsePropsMap = new HashMap(1);
+ sparsePropsMap = new int[PropNames.LAST_PROPERTY_INDEX + 1];
+ Arrays.fill(sparsePropsMap, -1);
numProps = 1;
sparseIndices = new int[] { PropNames.MEDIA_USAGE };
- sparsePropsMap.put
- (Ints.consts.get(PropNames.MEDIA_USAGE), Ints.consts.get(0));
+ sparsePropsMap
+ [PropNames.MEDIA_USAGE] = 0;
}
/**
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]