From 9dcf718733374d0720f487012bf0d76b8813b4d5 Mon Sep 17 00:00:00 2001 From: hns Date: Tue, 14 May 2002 16:40:28 +0000 Subject: [PATCH] Changed remove() method to remove node itself if no arguments are supplied. Added getNodeProperty() method which will only return properties of the node but not the underlying prototype, thus avoiding to return functions declared for the prototype. This is used for the HopObjects get() function. Added getDefaultValue() to return a string representation for HopObjects. Previously, concatenating HopObjects to Strings threw an error. --- src/helma/scripting/fesi/ESNode.java | 111 +++++++++++---------------- 1 file changed, 43 insertions(+), 68 deletions(-) diff --git a/src/helma/scripting/fesi/ESNode.java b/src/helma/scripting/fesi/ESNode.java index caf8d1b5..85cef0a7 100644 --- a/src/helma/scripting/fesi/ESNode.java +++ b/src/helma/scripting/fesi/ESNode.java @@ -158,14 +158,20 @@ public class ESNode extends ObjectPrototype { /** - * Remove one or more subnodes. + * Remove node itself or one or more subnodes. */ public boolean remove (ESValue args[]) { checkNode (); - for (int i=0; i