[FOray-commit] SF.net SVN: foray: [9706] trunk/foray
Modular XSL-FO Implementation for Java.
Status: Alpha
Brought to you by:
victormote
|
From: <vic...@us...> - 2007-06-06 21:40:18
|
Revision: 9706
http://svn.sourceforge.net/foray/?rev=9706&view=rev
Author: victormote
Date: 2007-06-06 14:34:43 -0700 (Wed, 06 Jun 2007)
Log Message:
-----------
Conform to axsl changes requiring AreaNode to return an AreaNode for getChildAt(...).
Modified Paths:
--------------
trunk/foray/foray-areatree/src/java/org/foray/area/AreaNode.java
trunk/foray/foray-common/src/java/org/foray/common/AbstractOrderedTreeNode.java
trunk/foray/foray-fotree/src/java/org/foray/fotree/FONode.java
Modified: trunk/foray/foray-areatree/src/java/org/foray/area/AreaNode.java
===================================================================
--- trunk/foray/foray-areatree/src/java/org/foray/area/AreaNode.java 2007-06-06 21:00:10 UTC (rev 9705)
+++ trunk/foray/foray-areatree/src/java/org/foray/area/AreaNode.java 2007-06-06 21:34:43 UTC (rev 9706)
@@ -84,6 +84,19 @@
/**
* {@inheritDoc}
*/
+ public AreaNode getChildAt(final int childIndex) {
+ if (childIndex < 0) {
+ return null;
+ }
+ if (childIndex >= getChildren().size()) {
+ return null;
+ }
+ return getChildren().get(childIndex);
+ }
+
+ /**
+ * {@inheritDoc}
+ */
public List<? extends AreaNode> getSiblings() {
if (this.getParent() == null) {
return null;
Modified: trunk/foray/foray-common/src/java/org/foray/common/AbstractOrderedTreeNode.java
===================================================================
--- trunk/foray/foray-common/src/java/org/foray/common/AbstractOrderedTreeNode.java 2007-06-06 21:00:10 UTC (rev 9705)
+++ trunk/foray/foray-common/src/java/org/foray/common/AbstractOrderedTreeNode.java 2007-06-06 21:34:43 UTC (rev 9706)
@@ -84,19 +84,6 @@
/**
* {@inheritDoc}
*/
- public AbstractOrderedTreeNode getChildAt(final int childIndex) {
- if (childIndex < 0) {
- return null;
- }
- if (childIndex >= getChildren().size()) {
- return null;
- }
- return getChildren().get(childIndex);
- }
-
- /**
- * {@inheritDoc}
- */
public int getChildCount() {
if (getChildren() == null) {
return 0;
Modified: trunk/foray/foray-fotree/src/java/org/foray/fotree/FONode.java
===================================================================
--- trunk/foray/foray-fotree/src/java/org/foray/fotree/FONode.java 2007-06-06 21:00:10 UTC (rev 9705)
+++ trunk/foray/foray-fotree/src/java/org/foray/fotree/FONode.java 2007-06-06 21:34:43 UTC (rev 9706)
@@ -154,7 +154,13 @@
* {@inheritDoc}
*/
public FONode getChildAt(final int childIndex) {
- return (FONode) super.getChildAt(childIndex);
+ if (childIndex < 0) {
+ return null;
+ }
+ if (childIndex >= getChildren().size()) {
+ return null;
+ }
+ return getChildren().get(childIndex);
}
/**
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|