You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@myfaces.apache.org by gr...@apache.org on 2005/05/11 18:14:27 UTC
svn commit: r169651 [2/3] - in /myfaces/trunk:
src/components/org/apache/myfaces/custom/navmenu/
src/components/org/apache/myfaces/custom/navmenu/jscookmenu/
src/components/org/apache/myfaces/custom/panelstack/
src/components/org/apache/myfaces/custom/popup/
src/components/org/apache/myfaces/custom/radio/
src/components/org/apache/myfaces/custom/regexprvalidator/
src/components/org/apache/myfaces/custom/rssticker/
src/components/org/apache/myfaces/custom/savestate/
src/components/org/apache/myfaces/custom/selectOneCountry/
src/components/org/apache/myfaces/custom/sortheader/
src/components/org/apache/myfaces/custom/stylesheet/
src/components/org/apache/myfaces/custom/swapimage/
src/components/org/apache/myfaces/custom/tabbedpane/
src/components/org/apache/myfaces/custom/tree/
src/components/org/apache/myfaces/custom/tree/event/
src/components/org/apache/myfaces/custom/tree/model/
src/components/org/apache/myfaces/custom/tree/renderkit/html/
src/components/org/apache/myfaces/custom/tree/taglib/
src/components/org/apache/myfaces/custom/updateactionlistener/
src/junit/org/apache/myfaces/el/ src/myfaces/org/apache/myfaces/el/
src/xdoclet/org/apache/myfaces/xdoclet/
webapps/src/example/org/apache/myfaces/examples/crosstable/
Modified: myfaces/trunk/src/components/org/apache/myfaces/custom/tree/MutableTreeNode.java
URL: http://svn.apache.org/viewcvs/myfaces/trunk/src/components/org/apache/myfaces/custom/tree/MutableTreeNode.java?rev=169651&r1=169650&r2=169651&view=diff
==============================================================================
--- myfaces/trunk/src/components/org/apache/myfaces/custom/tree/MutableTreeNode.java (original)
+++ myfaces/trunk/src/components/org/apache/myfaces/custom/tree/MutableTreeNode.java Wed May 11 09:14:23 2005
@@ -1,12 +1,12 @@
/*
* Copyright 2004 The Apache Software Foundation.
- *
+ *
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
- *
+ *
* http://www.apache.org/licenses/LICENSE-2.0
- *
+ *
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
@@ -22,16 +22,6 @@
*
* @author <a href="mailto:oliver@rossmueller.com">Oliver Rossmueller</a>
* @version $Revision$ $Date$
- * $Log$
- * Revision 1.3 2004/10/13 11:50:58 matze
- * renamed packages to org.apache
- *
- * Revision 1.2 2004/07/01 21:53:07 mwessendorf
- * ASF switch
- *
- * Revision 1.1 2004/04/22 10:20:23 manolito
- * tree component
- *
*/
public interface MutableTreeNode
extends TreeNode
Modified: myfaces/trunk/src/components/org/apache/myfaces/custom/tree/TreeNode.java
URL: http://svn.apache.org/viewcvs/myfaces/trunk/src/components/org/apache/myfaces/custom/tree/TreeNode.java?rev=169651&r1=169650&r2=169651&view=diff
==============================================================================
--- myfaces/trunk/src/components/org/apache/myfaces/custom/tree/TreeNode.java (original)
+++ myfaces/trunk/src/components/org/apache/myfaces/custom/tree/TreeNode.java Wed May 11 09:14:23 2005
@@ -1,12 +1,12 @@
/*
* Copyright 2004 The Apache Software Foundation.
- *
+ *
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
- *
+ *
* http://www.apache.org/licenses/LICENSE-2.0
- *
+ *
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
@@ -20,18 +20,9 @@
/**
* Defines the requirements for an object that can be used as a tree node for
* {@link HtmlTree}. (inspired by javax.swing.tree.TreeNode).
- *
+ *
* @author <a href="mailto:oliver@rossmueller.com">Oliver Rossmueller </a>
* @version $Revision$ $Date$
- *
- * $Log$
- * Revision 1.6 2005/02/11 00:54:02 svieujot
- * Revert changes commited to the wrong branch.
- *
- * Revision 1.4 2004/11/26 12:14:10 oros
- * MYFACES-8: applied tree table patch by David Le Strat
- *
- * *
*/
public interface TreeNode
{
Modified: myfaces/trunk/src/components/org/apache/myfaces/custom/tree/event/TreeSelectionEvent.java
URL: http://svn.apache.org/viewcvs/myfaces/trunk/src/components/org/apache/myfaces/custom/tree/event/TreeSelectionEvent.java?rev=169651&r1=169650&r2=169651&view=diff
==============================================================================
--- myfaces/trunk/src/components/org/apache/myfaces/custom/tree/event/TreeSelectionEvent.java (original)
+++ myfaces/trunk/src/components/org/apache/myfaces/custom/tree/event/TreeSelectionEvent.java Wed May 11 09:14:23 2005
@@ -1,12 +1,12 @@
/*
* Copyright 2004 The Apache Software Foundation.
- *
+ *
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
- *
+ *
* http://www.apache.org/licenses/LICENSE-2.0
- *
+ *
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
@@ -27,19 +27,6 @@
*
* @author <a href="mailto:oliver@rossmueller.com">Oliver Rossmueller</a>
* @version $Revision$ $Date$
- * $Log$
- * Revision 1.4 2004/10/13 11:50:58 matze
- * renamed packages to org.apache
- *
- * Revision 1.3 2004/07/01 21:53:08 mwessendorf
- * ASF switch
- *
- * Revision 1.2 2004/04/23 19:09:34 o_rossmueller
- * state transition magic
- *
- * Revision 1.1 2004/04/22 21:14:54 o_rossmueller
- * TreeSelectionListener support
- *
*/
public class TreeSelectionEvent extends FacesEvent
{
Modified: myfaces/trunk/src/components/org/apache/myfaces/custom/tree/event/TreeSelectionListener.java
URL: http://svn.apache.org/viewcvs/myfaces/trunk/src/components/org/apache/myfaces/custom/tree/event/TreeSelectionListener.java?rev=169651&r1=169650&r2=169651&view=diff
==============================================================================
--- myfaces/trunk/src/components/org/apache/myfaces/custom/tree/event/TreeSelectionListener.java (original)
+++ myfaces/trunk/src/components/org/apache/myfaces/custom/tree/event/TreeSelectionListener.java Wed May 11 09:14:23 2005
@@ -1,12 +1,12 @@
/*
* Copyright 2004 The Apache Software Foundation.
- *
+ *
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
- *
+ *
* http://www.apache.org/licenses/LICENSE-2.0
- *
+ *
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
@@ -23,16 +23,6 @@
*
* @author <a href="mailto:oliver@rossmueller.com">Oliver Rossmueller</a>
* @version $Revision$ $Date$
- * $Log$
- * Revision 1.3 2004/10/13 11:50:58 matze
- * renamed packages to org.apache
- *
- * Revision 1.2 2004/07/01 21:53:08 mwessendorf
- * ASF switch
- *
- * Revision 1.1 2004/04/22 21:14:54 o_rossmueller
- * TreeSelectionListener support
- *
*/
public interface TreeSelectionListener extends FacesListener
{
Modified: myfaces/trunk/src/components/org/apache/myfaces/custom/tree/model/DefaultTreeModel.java
URL: http://svn.apache.org/viewcvs/myfaces/trunk/src/components/org/apache/myfaces/custom/tree/model/DefaultTreeModel.java?rev=169651&r1=169650&r2=169651&view=diff
==============================================================================
--- myfaces/trunk/src/components/org/apache/myfaces/custom/tree/model/DefaultTreeModel.java (original)
+++ myfaces/trunk/src/components/org/apache/myfaces/custom/tree/model/DefaultTreeModel.java Wed May 11 09:14:23 2005
@@ -1,12 +1,12 @@
/*
* Copyright 2004 The Apache Software Foundation.
- *
+ *
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
- *
+ *
* http://www.apache.org/licenses/LICENSE-2.0
- *
+ *
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
@@ -27,28 +27,6 @@
/**
* @author <a href="mailto:oliver@rossmueller.com">Oliver Rossmueller</a>
* @version $Revision$ $Date$
- * $Log$
- * Revision 1.7 2004/10/13 11:50:58 matze
- * renamed packages to org.apache
- *
- * Revision 1.6 2004/09/01 18:32:57 mwessendorf
- * Organize Imports
- *
- * Revision 1.5 2004/08/15 15:28:04 o_rossmueller
- * new model listener handling to get modified from events which occur outside the scope of a tree request
- *
- * Revision 1.4 2004/07/01 21:53:04 mwessendorf
- * ASF switch
- *
- * Revision 1.3 2004/05/05 00:18:56 o_rossmueller
- * various fixes/modifications in model event handling and tree update
- *
- * Revision 1.2 2004/05/04 00:28:17 o_rossmueller
- * model event handling
- *
- * Revision 1.1 2004/04/22 10:20:24 manolito
- * tree component
- *
*/
public class DefaultTreeModel
implements TreeModel
Modified: myfaces/trunk/src/components/org/apache/myfaces/custom/tree/model/TreeModel.java
URL: http://svn.apache.org/viewcvs/myfaces/trunk/src/components/org/apache/myfaces/custom/tree/model/TreeModel.java?rev=169651&r1=169650&r2=169651&view=diff
==============================================================================
--- myfaces/trunk/src/components/org/apache/myfaces/custom/tree/model/TreeModel.java (original)
+++ myfaces/trunk/src/components/org/apache/myfaces/custom/tree/model/TreeModel.java Wed May 11 09:14:23 2005
@@ -1,12 +1,12 @@
/*
* Copyright 2004 The Apache Software Foundation.
- *
+ *
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
- *
+ *
* http://www.apache.org/licenses/LICENSE-2.0
- *
+ *
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
@@ -21,19 +21,6 @@
/**
* @author <a href="mailto:oliver@rossmueller.com">Oliver Rossmueller</a>
* @version $Revision$ $Date$
- * $Log$
- * Revision 1.4 2004/10/13 11:50:58 matze
- * renamed packages to org.apache
- *
- * Revision 1.3 2004/07/01 21:53:04 mwessendorf
- * ASF switch
- *
- * Revision 1.2 2004/05/05 00:18:56 o_rossmueller
- * various fixes/modifications in model event handling and tree update
- *
- * Revision 1.1 2004/04/22 10:20:24 manolito
- * tree component
- *
*/
public interface TreeModel
{
Modified: myfaces/trunk/src/components/org/apache/myfaces/custom/tree/model/TreeModelEvent.java
URL: http://svn.apache.org/viewcvs/myfaces/trunk/src/components/org/apache/myfaces/custom/tree/model/TreeModelEvent.java?rev=169651&r1=169650&r2=169651&view=diff
==============================================================================
--- myfaces/trunk/src/components/org/apache/myfaces/custom/tree/model/TreeModelEvent.java (original)
+++ myfaces/trunk/src/components/org/apache/myfaces/custom/tree/model/TreeModelEvent.java Wed May 11 09:14:23 2005
@@ -1,12 +1,12 @@
/*
* Copyright 2004 The Apache Software Foundation.
- *
+ *
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
- *
+ *
* http://www.apache.org/licenses/LICENSE-2.0
- *
+ *
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
@@ -19,16 +19,6 @@
/**
* @author <a href="mailto:oliver@rossmueller.com">Oliver Rossmueller</a>
* @version $Revision$ $Date$
- * $Log$
- * Revision 1.3 2004/10/13 11:50:58 matze
- * renamed packages to org.apache
- *
- * Revision 1.2 2004/07/01 21:53:04 mwessendorf
- * ASF switch
- *
- * Revision 1.1 2004/04/22 10:20:24 manolito
- * tree component
- *
*/
public class TreeModelEvent
{
Modified: myfaces/trunk/src/components/org/apache/myfaces/custom/tree/model/TreeModelListener.java
URL: http://svn.apache.org/viewcvs/myfaces/trunk/src/components/org/apache/myfaces/custom/tree/model/TreeModelListener.java?rev=169651&r1=169650&r2=169651&view=diff
==============================================================================
--- myfaces/trunk/src/components/org/apache/myfaces/custom/tree/model/TreeModelListener.java (original)
+++ myfaces/trunk/src/components/org/apache/myfaces/custom/tree/model/TreeModelListener.java Wed May 11 09:14:23 2005
@@ -1,12 +1,12 @@
/*
* Copyright 2004 The Apache Software Foundation.
- *
+ *
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
- *
+ *
* http://www.apache.org/licenses/LICENSE-2.0
- *
+ *
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
@@ -19,19 +19,6 @@
/**
* @author <a href="mailto:oliver@rossmueller.com">Oliver Rossmueller</a>
* @version $Revision$ $Date$
- * $Log$
- * Revision 1.4 2004/10/13 11:50:58 matze
- * renamed packages to org.apache
- *
- * Revision 1.3 2004/07/01 21:53:04 mwessendorf
- * ASF switch
- *
- * Revision 1.2 2004/05/04 00:28:17 o_rossmueller
- * model event handling
- *
- * Revision 1.1 2004/04/22 10:20:24 manolito
- * tree component
- *
*/
public interface TreeModelListener
{
Modified: myfaces/trunk/src/components/org/apache/myfaces/custom/tree/model/TreePath.java
URL: http://svn.apache.org/viewcvs/myfaces/trunk/src/components/org/apache/myfaces/custom/tree/model/TreePath.java?rev=169651&r1=169650&r2=169651&view=diff
==============================================================================
--- myfaces/trunk/src/components/org/apache/myfaces/custom/tree/model/TreePath.java (original)
+++ myfaces/trunk/src/components/org/apache/myfaces/custom/tree/model/TreePath.java Wed May 11 09:14:23 2005
@@ -1,12 +1,12 @@
/*
* Copyright 2004 The Apache Software Foundation.
- *
+ *
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
- *
+ *
* http://www.apache.org/licenses/LICENSE-2.0
- *
+ *
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
@@ -21,16 +21,6 @@
/**
* @author <a href="mailto:oliver@rossmueller.com">Oliver Rossmueller</a>
* @version $Revision$ $Date$
- * $Log$
- * Revision 1.3 2004/10/13 11:50:58 matze
- * renamed packages to org.apache
- *
- * Revision 1.2 2004/07/01 21:53:04 mwessendorf
- * ASF switch
- *
- * Revision 1.1 2004/04/22 10:20:24 manolito
- * tree component
- *
*/
public final class TreePath
extends Object
Modified: myfaces/trunk/src/components/org/apache/myfaces/custom/tree/renderkit/html/HtmlTreeImageCommandLinkRenderer.java
URL: http://svn.apache.org/viewcvs/myfaces/trunk/src/components/org/apache/myfaces/custom/tree/renderkit/html/HtmlTreeImageCommandLinkRenderer.java?rev=169651&r1=169650&r2=169651&view=diff
==============================================================================
--- myfaces/trunk/src/components/org/apache/myfaces/custom/tree/renderkit/html/HtmlTreeImageCommandLinkRenderer.java (original)
+++ myfaces/trunk/src/components/org/apache/myfaces/custom/tree/renderkit/html/HtmlTreeImageCommandLinkRenderer.java Wed May 11 09:14:23 2005
@@ -30,29 +30,6 @@
/**
* @author <a href="mailto:oliver@rossmueller.com">Oliver Rossmueller</a>
* @version $Revision$ $Date$
- * $Log$
- * Revision 1.7 2004/12/22 17:52:54 grantsmith
- * Jira MYFACES-48: Tree Table Component Fixes & Tree Checkbox Support
- *
- * Revision 1.6 2004/10/13 11:50:58 matze
- * renamed packages to org.apache
- *
- * Revision 1.5 2004/07/01 21:53:10 mwessendorf
- * ASF switch
- *
- * Revision 1.4 2004/06/09 20:32:16 o_rossmueller
- * fix: removed duplicate output of value
- *
- * Revision 1.3 2004/06/03 12:57:03 o_rossmueller
- * modified link renderer to use one hidden field for all links according to 1.1 renderkit docs
- * added onclick=clear_XXX to button
- *
- * Revision 1.2 2004/05/27 15:06:39 manolito
- * bugfix: node labels not rendered any more
- *
- * Revision 1.1 2004/04/22 10:20:24 manolito
- * tree component
- *
*/
public class HtmlTreeImageCommandLinkRenderer
extends HtmlLinkRendererBase
Modified: myfaces/trunk/src/components/org/apache/myfaces/custom/tree/renderkit/html/HtmlTreeNodeRenderer.java
URL: http://svn.apache.org/viewcvs/myfaces/trunk/src/components/org/apache/myfaces/custom/tree/renderkit/html/HtmlTreeNodeRenderer.java?rev=169651&r1=169650&r2=169651&view=diff
==============================================================================
--- myfaces/trunk/src/components/org/apache/myfaces/custom/tree/renderkit/html/HtmlTreeNodeRenderer.java (original)
+++ myfaces/trunk/src/components/org/apache/myfaces/custom/tree/renderkit/html/HtmlTreeNodeRenderer.java Wed May 11 09:14:23 2005
@@ -1,12 +1,12 @@
/*
* Copyright 2004 The Apache Software Foundation.
- *
+ *
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
- *
+ *
* http://www.apache.org/licenses/LICENSE-2.0
- *
+ *
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
@@ -25,34 +25,6 @@
/**
* @author <a href="mailto:oliver@rossmueller.com">Oliver Rossmueller</a>
* @version $Revision$ $Date$
- *
- *
- * $Log$
- * Revision 1.8 2004/11/26 12:14:09 oros
- * MYFACES-8: applied tree table patch by David Le Strat
- *
- * Revision 1.7 2004/10/13 11:50:58 matze
- * renamed packages to org.apache
- *
- * Revision 1.6 2004/07/01 21:53:10 mwessendorf
- * ASF switch
- *
- * Revision 1.5 2004/06/09 20:32:16 o_rossmueller
- * fix: removed duplicate output of value
- *
- * Revision 1.4 2004/06/03 12:57:03 o_rossmueller
- * modified link renderer to use one hidden field for all links according to 1.1 renderkit docs
- * added onclick=clear_XXX to button
- *
- * Revision 1.3 2004/05/27 15:06:39 manolito
- * bugfix: node labels not rendered any more
- *
- * Revision 1.2 2004/04/29 18:48:07 o_rossmueller
- * node selection handling
- *
- * Revision 1.1 2004/04/22 10:20:24 manolito
- * tree component
- *
*/
public class HtmlTreeNodeRenderer
extends HtmlLinkRendererBase
Modified: myfaces/trunk/src/components/org/apache/myfaces/custom/tree/renderkit/html/HtmlTreeRenderer.java
URL: http://svn.apache.org/viewcvs/myfaces/trunk/src/components/org/apache/myfaces/custom/tree/renderkit/html/HtmlTreeRenderer.java?rev=169651&r1=169650&r2=169651&view=diff
==============================================================================
--- myfaces/trunk/src/components/org/apache/myfaces/custom/tree/renderkit/html/HtmlTreeRenderer.java (original)
+++ myfaces/trunk/src/components/org/apache/myfaces/custom/tree/renderkit/html/HtmlTreeRenderer.java Wed May 11 09:14:23 2005
@@ -41,30 +41,12 @@
/**
* @author <a href="mailto:oliver@rossmueller.com">Oliver Rossmueller </a>
* @version $Revision$ $Date$
- *
- * $Log$
- * Revision 1.16 2005/02/11 00:54:02 svieujot
- * Revert changes commited to the wrong branch.
- *
- * Revision 1.14 2004/12/24 14:13:16 svieujot
- * Upgrade the tree component to use the Extensions filter.
- *
- * Revision 1.13 2004/12/22 17:52:54 grantsmith
- * Jira MYFACES-48: Tree Table Component Fixes & Tree Checkbox Support
- *
- * Revision 1.12 2004/11/26 12:46:38 oros
- * cleanup: removed unused iconChild attribute
- *
- * Revision 1.11 2004/11/26 12:14:09 oros
- * MYFACES-8: applied tree table patch by David Le Strat
- *
- *
*/
public class HtmlTreeRenderer extends HtmlTableRendererBase
{
private static final Integer ZERO = new Integer(0);
-
+
private static final String DEFAULT_IMAGE_ICON_FOLDER = "images/folder.gif";
public boolean getRendersChildren()
Modified: myfaces/trunk/src/components/org/apache/myfaces/custom/tree/taglib/IconProviderTag.java
URL: http://svn.apache.org/viewcvs/myfaces/trunk/src/components/org/apache/myfaces/custom/tree/taglib/IconProviderTag.java?rev=169651&r1=169650&r2=169651&view=diff
==============================================================================
--- myfaces/trunk/src/components/org/apache/myfaces/custom/tree/taglib/IconProviderTag.java (original)
+++ myfaces/trunk/src/components/org/apache/myfaces/custom/tree/taglib/IconProviderTag.java Wed May 11 09:14:23 2005
@@ -1,12 +1,12 @@
/*
* Copyright 2004 The Apache Software Foundation.
- *
+ *
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
- *
+ *
* http://www.apache.org/licenses/LICENSE-2.0
- *
+ *
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
@@ -31,16 +31,6 @@
/**
* @author <a href="mailto:oliver@rossmueller.com">Oliver Rossmueller</a>
* @version $Revision$ $Date$
- * $Log$
- * Revision 1.3 2004/10/13 11:50:58 matze
- * renamed packages to org.apache
- *
- * Revision 1.2 2004/07/01 21:53:06 mwessendorf
- * ASF switch
- *
- * Revision 1.1 2004/05/04 12:19:14 o_rossmueller
- * added icon provider
- *
*/
public class IconProviderTag
extends TagSupport
Modified: myfaces/trunk/src/components/org/apache/myfaces/custom/tree/taglib/TreeSelectionListenerTag.java
URL: http://svn.apache.org/viewcvs/myfaces/trunk/src/components/org/apache/myfaces/custom/tree/taglib/TreeSelectionListenerTag.java?rev=169651&r1=169650&r2=169651&view=diff
==============================================================================
--- myfaces/trunk/src/components/org/apache/myfaces/custom/tree/taglib/TreeSelectionListenerTag.java (original)
+++ myfaces/trunk/src/components/org/apache/myfaces/custom/tree/taglib/TreeSelectionListenerTag.java Wed May 11 09:14:23 2005
@@ -1,12 +1,12 @@
/*
* Copyright 2004 The Apache Software Foundation.
- *
+ *
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
- *
+ *
* http://www.apache.org/licenses/LICENSE-2.0
- *
+ *
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
@@ -33,16 +33,6 @@
*
* @author <a href="mailto:oliver@rossmueller.com">Oliver Rossmueller</a>
* @version $Revision$ $Date$
- * $Log$
- * Revision 1.3 2004/10/13 11:50:58 matze
- * renamed packages to org.apache
- *
- * Revision 1.2 2004/07/01 21:53:06 mwessendorf
- * ASF switch
- *
- * Revision 1.1 2004/04/22 21:14:55 o_rossmueller
- * TreeSelectionListener support
- *
*/
public class TreeSelectionListenerTag extends TagSupport
{
Modified: myfaces/trunk/src/components/org/apache/myfaces/custom/tree/taglib/TreeTag.java
URL: http://svn.apache.org/viewcvs/myfaces/trunk/src/components/org/apache/myfaces/custom/tree/taglib/TreeTag.java?rev=169651&r1=169650&r2=169651&view=diff
==============================================================================
--- myfaces/trunk/src/components/org/apache/myfaces/custom/tree/taglib/TreeTag.java (original)
+++ myfaces/trunk/src/components/org/apache/myfaces/custom/tree/taglib/TreeTag.java Wed May 11 09:14:23 2005
@@ -1,12 +1,12 @@
/*
* Copyright 2004 The Apache Software Foundation.
- *
+ *
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
- *
+ *
* http://www.apache.org/licenses/LICENSE-2.0
- *
+ *
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
@@ -30,17 +30,9 @@
* <p>
* HtmlTree tag.
* </p>
- *
+ *
* @author <a href="mailto:oliver@rossmueller.com">Oliver Rossmueller </a>
* @version $Revision$ $Date: 2004/10/13 11:50:58
- * $ $Log$
- * $ Revision 1.12 2005/02/18 17:19:30 matzew
- * $ added release() to tag clazzes.
- * $ $ Revision 1.11 2005/02/11 00:54:02
- * svieujot $ Revert changes commited to the wrong branch. $ $ Revision 1.9
- * 2004/11/26 12:46:38 oros $ cleanup: removed unused iconChild attribute $ $
- * Revision 1.8 2004/11/26 12:14:10 oros $ MYFACES-8: applied tree table patch
- * by David Le Strat $
*/
public class TreeTag extends UIComponentTagBase {
Modified: myfaces/trunk/src/components/org/apache/myfaces/custom/updateactionlistener/UpdateActionListener.java
URL: http://svn.apache.org/viewcvs/myfaces/trunk/src/components/org/apache/myfaces/custom/updateactionlistener/UpdateActionListener.java?rev=169651&r1=169650&r2=169651&view=diff
==============================================================================
--- myfaces/trunk/src/components/org/apache/myfaces/custom/updateactionlistener/UpdateActionListener.java (original)
+++ myfaces/trunk/src/components/org/apache/myfaces/custom/updateactionlistener/UpdateActionListener.java Wed May 11 09:14:23 2005
@@ -1,12 +1,12 @@
/*
* Copyright 2004 The Apache Software Foundation.
- *
+ *
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
- *
+ *
* http://www.apache.org/licenses/LICENSE-2.0
- *
+ *
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
@@ -29,19 +29,6 @@
/**
* @author Manfred Geiler (latest modification by $Author$)
* @version $Revision$ $Date$
- * $Log$
- * Revision 1.4 2004/10/13 11:50:59 matze
- * renamed packages to org.apache
- *
- * Revision 1.3 2004/07/01 21:53:11 mwessendorf
- * ASF switch
- *
- * Revision 1.2 2004/05/05 17:36:32 o_rossmueller
- * fix #948629: no converter is needed to convert a String value to Object
- *
- * Revision 1.1 2004/03/31 12:15:28 manolito
- * custom component refactoring
- *
*/
public class UpdateActionListener
implements ActionListener, ValueHolder, StateHolder
Modified: myfaces/trunk/src/components/org/apache/myfaces/custom/updateactionlistener/UpdateActionListenerTag.java
URL: http://svn.apache.org/viewcvs/myfaces/trunk/src/components/org/apache/myfaces/custom/updateactionlistener/UpdateActionListenerTag.java?rev=169651&r1=169650&r2=169651&view=diff
==============================================================================
--- myfaces/trunk/src/components/org/apache/myfaces/custom/updateactionlistener/UpdateActionListenerTag.java (original)
+++ myfaces/trunk/src/components/org/apache/myfaces/custom/updateactionlistener/UpdateActionListenerTag.java Wed May 11 09:14:23 2005
@@ -1,12 +1,12 @@
/*
* Copyright 2004 The Apache Software Foundation.
- *
+ *
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
- *
+ *
* http://www.apache.org/licenses/LICENSE-2.0
- *
+ *
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
@@ -28,16 +28,6 @@
/**
* @author Manfred Geiler (latest modification by $Author$)
* @version $Revision$ $Date$
- * $Log$
- * Revision 1.3 2004/10/13 11:50:59 matze
- * renamed packages to org.apache
- *
- * Revision 1.2 2004/07/01 21:53:11 mwessendorf
- * ASF switch
- *
- * Revision 1.1 2004/03/31 12:15:28 manolito
- * custom component refactoring
- *
*/
public class UpdateActionListenerTag
extends TagSupport
Modified: myfaces/trunk/src/junit/org/apache/myfaces/el/ValueBindingTest.java
URL: http://svn.apache.org/viewcvs/myfaces/trunk/src/junit/org/apache/myfaces/el/ValueBindingTest.java?rev=169651&r1=169650&r2=169651&view=diff
==============================================================================
--- myfaces/trunk/src/junit/org/apache/myfaces/el/ValueBindingTest.java (original)
+++ myfaces/trunk/src/junit/org/apache/myfaces/el/ValueBindingTest.java Wed May 11 09:14:23 2005
@@ -1,12 +1,12 @@
/*
* Copyright 2004 The Apache Software Foundation.
- *
+ *
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
- *
+ *
* http://www.apache.org/licenses/LICENSE-2.0
- *
+ *
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
@@ -25,49 +25,6 @@
* @author Manfred Geiler (latest modification by $Author$)
* @author Anton Koinov
* @version $Revision$ $Date$
- *
- * $Log$
- * Revision 1.30 2004/10/13 11:50:59 matze
- * renamed packages to org.apache
- *
- * Revision 1.29 2004/09/28 19:08:26 dave0000
- * commented some non-working testcases
- *
- * Revision 1.28 2004/09/27 03:12:54 dave0000
- * *** empty log message ***
- *
- * Revision 1.26 2004/09/08 07:43:52 mwessendorf
- * added TestCase
- *
- * Revision 1.25 2004/09/06 16:21:10 mwessendorf
- * added TestCase
- *
- * Revision 1.24 2004/09/02 08:40:18 mwessendorf
- * added TestCase for bug #1018239
- *
- * Revision 1.23 2004/09/01 18:25:19 mwessendorf
- * added TestCase
- *
- * Revision 1.22 2004/07/27 06:46:59 dave0000
- * cleanup/arange testcases, remove duplicates
- *
- * Revision 1.21 2004/07/27 06:28:34 dave0000
- * fix issue with getType of literal expressions (and other improvements)
- *
- * Revision 1.20 2004/07/01 22:00:55 mwessendorf
- * ASF switch
- *
- * Revision 1.19 2004/05/11 04:24:12 dave0000
- * Bug 943166: add value coercion to ManagedBeanConfigurator
- *
- * Revision 1.18 2004/05/10 05:30:15 dave0000
- * Fix issue with setting Managed Bean to a wrong scope
- *
- * Revision 1.17 2004/04/07 03:54:07 dave0000
- * fix testcases to match removed trim() on expression string
- *
- * Revision 1.16 2004/03/30 07:38:11 dave0000
- * implement mixed string-reference expressions
*/
public class ValueBindingTest extends ELBaseTest
{
Modified: myfaces/trunk/src/myfaces/org/apache/myfaces/el/ELParserHelper.java
URL: http://svn.apache.org/viewcvs/myfaces/trunk/src/myfaces/org/apache/myfaces/el/ELParserHelper.java?rev=169651&r1=169650&r2=169651&view=diff
==============================================================================
--- myfaces/trunk/src/myfaces/org/apache/myfaces/el/ELParserHelper.java (original)
+++ myfaces/trunk/src/myfaces/org/apache/myfaces/el/ELParserHelper.java Wed May 11 09:14:23 2005
@@ -1,12 +1,12 @@
/*
* Copyright 2004 The Apache Software Foundation.
- *
+ *
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
- *
+ *
* http://www.apache.org/licenses/LICENSE-2.0
- *
+ *
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
@@ -52,31 +52,9 @@
/**
* Utility class to implement support functionality to "morph" JSP EL into JSF
* EL
- *
+ *
* @author Anton Koinov (latest modification by $Author$)
* @version $Revision$ $Date$
- *
- * $Log$
- * Revision 1.7 2005/04/11 17:39:36 svieujot
- * ELParserHelper : Fix a String IndexOutOfBoundsException & several bugs in toJspELExpression.
- * Add a JUnit Test.
- *
- * Revision 1.6 2004/10/13 11:51:00 matze
- * renamed packages to org.apache
- *
- * Revision 1.5 2004/09/28 19:11:50 dave0000
- * uppercase static final prop
- * remove redundant code
- *
- * Revision 1.4 2004/07/01 22:05:11 mwessendorf
- * ASF switch
- *
- * Revision 1.3 2004/05/10 05:30:13 dave0000
- * Fix issue with setting Managed Bean to a wrong scope
- *
- * Revision 1.2 2004/04/08 23:22:18 dave0000
- * remove assert statements
- *
*/
public class ELParserHelper
{
@@ -123,9 +101,9 @@
/**
* Convert ValueBinding syntax #{ } to JSP EL syntax ${ }
- *
+ *
* @param expressionString <code>ValueBinding</code> reference expression
- *
+ *
* @return JSP EL compatible expression
*/
static String toJspElExpression(String expressionString)
@@ -133,7 +111,7 @@
StringBuffer sb = new StringBuffer(expressionString.length());
int remainsPos = 0;
- for (int posOpenBrace = expressionString.indexOf('{'); posOpenBrace >= 0;
+ for (int posOpenBrace = expressionString.indexOf('{'); posOpenBrace >= 0;
posOpenBrace = expressionString.indexOf('{', remainsPos))
{
if (posOpenBrace > 0)
@@ -151,7 +129,7 @@
{
// // TODO: should use \\ as escape for \ always, not just when before #{
// // allow use of '\' as escape symbol for #{ (for compatibility with Sun's extended implementation)
-// if (isEscaped(expressionString, posOpenBrace - 1))
+// if (isEscaped(expressionString, posOpenBrace - 1))
// {
// escapes: {
// for (int i = sb.length() - 1; i >= 0; i--)
@@ -187,7 +165,7 @@
}
sb.append(expressionString.substring(remainsPos));
-
+
// Create a new String to shrink mem size since we are caching
return new String(sb.toString());
}
@@ -201,12 +179,12 @@
/**
* Return the index of the matching closing brace, skipping over quoted text
- *
+ *
* @param expressionString string to search
* @param indexofOpeningBrace the location of opening brace to match
- *
+ *
* @return the index of the matching closing brace
- *
+ *
* @throws ReferenceSyntaxException if matching brace cannot be found
*/
private static int indexOfMatchingClosingBrace(String expressionString,
@@ -260,7 +238,7 @@
/**
* Returns the index of the matching closing quote, skipping over escaped
* quotes
- *
+ *
* @param expressionString string to scan
* @param indexOfOpeningQuote start from this position in the string
* @return -1 if no match, the index of closing quote otherwise
@@ -269,7 +247,7 @@
int indexOfOpeningQuote)
{
char quote = expressionString.charAt(indexOfOpeningQuote);
- for (int i = expressionString.indexOf(quote, indexOfOpeningQuote + 1);
+ for (int i = expressionString.indexOf(quote, indexOfOpeningQuote + 1);
i >= 0; i = expressionString.indexOf(quote, i + 1))
{
if (!isEscaped(expressionString, i))
@@ -297,7 +275,7 @@
* Replaces all <code>ValueSuffix</code>es with custom implementation
* ValueSuffexes that use JSF <code>PropertyResolver</code> insted of JSP
* EL one.
- *
+ *
* @param expression <code>Expression</code> or
* <code>ExpressionString</code> instance
* @param application <code>Application</code> instance to get
@@ -358,7 +336,7 @@
}
else if (expression instanceof ConditionalExpression)
{
- ConditionalExpression conditionalExpression =
+ ConditionalExpression conditionalExpression =
(ConditionalExpression) expression;
replaceSuffixes(conditionalExpression.getTrueBranch());
replaceSuffixes(conditionalExpression.getFalseBranch());
@@ -434,11 +412,11 @@
/**
* Coerces <code>index</code> to Integer for array types, or returns
* <code>null</code> for non-array types.
- *
+ *
* @param base Object for the base
* @param index Object for the index
* @return Integer a valid Integer index, or null if not an array type
- *
+ *
* @throws ELException if exception occurs trying to coerce to Integer
* @throws EvaluationException if base is array type but cannot convert
* index to Integer
Modified: myfaces/trunk/src/myfaces/org/apache/myfaces/el/MethodBindingImpl.java
URL: http://svn.apache.org/viewcvs/myfaces/trunk/src/myfaces/org/apache/myfaces/el/MethodBindingImpl.java?rev=169651&r1=169650&r2=169651&view=diff
==============================================================================
--- myfaces/trunk/src/myfaces/org/apache/myfaces/el/MethodBindingImpl.java (original)
+++ myfaces/trunk/src/myfaces/org/apache/myfaces/el/MethodBindingImpl.java Wed May 11 09:14:23 2005
@@ -1,12 +1,12 @@
/*
* Copyright 2004 The Apache Software Foundation.
- *
+ *
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
- *
+ *
* http://www.apache.org/licenses/LICENSE-2.0
- *
+ *
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
@@ -35,25 +35,6 @@
/**
* @author Anton Koinov (latest modification by $Author$)
* @version $Revision$ $Date$
- * $Log$
- * Revision 1.17 2004/10/13 11:51:00 matze
- * renamed packages to org.apache
- *
- * Revision 1.16 2004/07/01 22:05:12 mwessendorf
- * ASF switch
- *
- * Revision 1.15 2004/06/23 15:56:16 manolito
- * removed our own version of commons-beanutils MethodUtils
- *
- * Revision 1.14 2004/05/18 17:09:29 manolito
- * resolved the problem with inaccessible methods in private classes that implement a public interface
- *
- * Revision 1.13 2004/05/11 04:24:10 dave0000
- * Bug 943166: add value coercion to ManagedBeanConfigurator
- *
- * Revision 1.12 2004/04/16 15:13:31 manolito
- * validator attribute support and MethodBinding invoke exception handling fixed
- *
*/
public class MethodBindingImpl extends MethodBinding
implements StateHolder
@@ -210,7 +191,7 @@
+ getExpressionString(), e);
}
}
-
+
public String toString()
{
return _valueBinding.toString();
Modified: myfaces/trunk/src/myfaces/org/apache/myfaces/el/PropertyResolverImpl.java
URL: http://svn.apache.org/viewcvs/myfaces/trunk/src/myfaces/org/apache/myfaces/el/PropertyResolverImpl.java?rev=169651&r1=169650&r2=169651&view=diff
==============================================================================
--- myfaces/trunk/src/myfaces/org/apache/myfaces/el/PropertyResolverImpl.java (original)
+++ myfaces/trunk/src/myfaces/org/apache/myfaces/el/PropertyResolverImpl.java Wed May 11 09:14:23 2005
@@ -1,12 +1,12 @@
/*
* Copyright 2004 The Apache Software Foundation.
- *
+ *
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
- *
+ *
* http://www.apache.org/licenses/LICENSE-2.0
- *
+ *
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
@@ -37,46 +37,10 @@
* @author Manfred Geiler (latest modification by $Author$)
* @author Anton Koinov
* @version $Revision$ $Date$
- * $Log$
- * Revision 1.31 2005/01/09 18:15:12 mmarinschek
- * small changes - better error handling, label renderer supports more hooks for sub-classes
- *
- * Revision 1.30 2004/12/03 08:41:45 manolito
- * MYFACES-44 / PropertyResolverImpl has special logic for UIComponents
- *
- * Revision 1.29 2004/10/13 11:51:00 matze
- * renamed packages to org.apache
- *
- * Revision 1.28 2004/09/20 14:35:48 dave0000
- * bug 1030875:
- * getType() should return null if type cannot be determined
- * isReadOnly() should return false if read-only cannot be determined
- *
- * Revision 1.27 2004/07/01 22:05:11 mwessendorf
- * ASF switch
- *
- * Revision 1.26 2004/06/23 15:56:16 manolito
- * removed our own version of commons-beanutils MethodUtils
- *
- * Revision 1.25 2004/05/18 17:09:29 manolito
- * resolved the problem with inaccessible methods in private classes that implement a public interface
- *
- * Revision 1.24 2004/04/26 05:54:59 dave0000
- * Add coercion to ValueBinding (and related changes)
- *
- * Revision 1.23 2004/04/08 13:42:13 royalts
- * removed main method
- *
- * Revision 1.22 2004/04/08 05:16:45 dave0000
- * change to always use JSF PropertyResolver (was using JSP PR sometimes)
- *
- * Revision 1.21 2004/04/06 06:48:23 manolito
- * IndexedPropertyDescriptor issue
- *
*/
public class PropertyResolverImpl extends PropertyResolver
{
- private static final Log log =
+ private static final Log log =
LogFactory.getLog(PropertyResolverImpl.class);
//~ Static fields/initializers ---------------------------------------------
@@ -105,8 +69,8 @@
}
catch (RuntimeException e)
{
- log.error("Exception getting value of property " + property
- + " of bean "
+ log.error("Exception getting value of property " + property
+ + " of bean "
+ base != null ? base.getClass().getName() : "NULL", e);
throw e;
}
@@ -139,13 +103,13 @@
return null;
}
- throw new ReferenceSyntaxException("Must be array or List. Bean: "
+ throw new ReferenceSyntaxException("Must be array or List. Bean: "
+ base.getClass().getName() + ", index " + index);
}
catch (RuntimeException e)
{
- log.error("Exception getting value for index " + index
- + " of bean "
+ log.error("Exception getting value for index " + index
+ + " of bean "
+ base != null ? base.getClass().getName() : "NULL", e);
throw e;
}
@@ -164,8 +128,8 @@
if (property == null ||
property instanceof String && ((String)property).length() == 0)
{
- throw new PropertyNotFoundException("Bean: "
- + base.getClass().getName()
+ throw new PropertyNotFoundException("Bean: "
+ + base.getClass().getName()
+ ", null or empty property name");
}
@@ -181,8 +145,8 @@
}
catch (RuntimeException e)
{
- log.error("Exception setting property " + property
- + " of bean "
+ log.error("Exception setting property " + property
+ + " of bean "
+ base != null ? base.getClass().getName() : "NULL", e);
throw e;
}
@@ -209,8 +173,8 @@
}
if (base instanceof List)
{
- // REVISIT: should we try to grow the list, if growable type
- // (e.g., ArrayList, etc.), and if not large
+ // REVISIT: should we try to grow the list, if growable type
+ // (e.g., ArrayList, etc.), and if not large
// enough?
((List) base).set(index, newValue);
@@ -219,17 +183,17 @@
}
catch (IndexOutOfBoundsException e)
{
- throw new PropertyNotFoundException("Bean: "
+ throw new PropertyNotFoundException("Bean: "
+ base.getClass().getName() + ", index " + index, e);
}
throw new EvaluationException(
- "Bean must be array or List. Bean: "
+ "Bean must be array or List. Bean: "
+ base.getClass().getName() + ", index " + index);
}
catch (RuntimeException e)
{
- log.error("Exception setting value of index " + index + " of bean "
+ log.error("Exception setting value of index " + index + " of bean "
+ base != null ? base.getClass().getName() : "NULL", e);
throw e;
}
@@ -253,10 +217,10 @@
}
// If none of the special bean types, then process as normal Bean
- PropertyDescriptor propertyDescriptor =
+ PropertyDescriptor propertyDescriptor =
getPropertyDescriptor(base, property.toString());
- return propertyDescriptor.getWriteMethod() == null;
+ return propertyDescriptor.getWriteMethod() == null;
}
catch (Exception e)
{
@@ -310,7 +274,7 @@
}
// If none of the special bean types, then process as normal Bean
- PropertyDescriptor propertyDescriptor =
+ PropertyDescriptor propertyDescriptor =
getPropertyDescriptor(base, property.toString());
return propertyDescriptor.getPropertyType();
@@ -339,8 +303,8 @@
if (base instanceof List)
{
- // REVISIT: does it make sense to do this or simply return
- // Object.class? What if the new value is not of
+ // REVISIT: does it make sense to do this or simply return
+ // Object.class? What if the new value is not of
// the old value's class?
Object value = ((List) base).get(index);
@@ -363,7 +327,7 @@
public static void setProperty(Object base, String name, Object newValue)
{
- PropertyDescriptor propertyDescriptor =
+ PropertyDescriptor propertyDescriptor =
getPropertyDescriptor(base, name);
Method m = propertyDescriptor.getWriteMethod();
@@ -388,14 +352,14 @@
}
catch (Throwable t)
{
- throw new EvaluationException("Bean: "
+ throw new EvaluationException("Bean: "
+ base.getClass().getName() + ", property: " + name, t);
}
}
public static Object getProperty(Object base, String name)
{
- PropertyDescriptor propertyDescriptor =
+ PropertyDescriptor propertyDescriptor =
getPropertyDescriptor(base, name);
Method m = propertyDescriptor.getReadMethod();
@@ -420,7 +384,7 @@
}
catch (Throwable t)
{
- throw new EvaluationException("Bean: "
+ throw new EvaluationException("Bean: "
+ base.getClass().getName() + ", property: " + name, t);
}
}
@@ -438,7 +402,7 @@
}
catch (IntrospectionException e)
{
- throw new PropertyNotFoundException("Bean: "
+ throw new PropertyNotFoundException("Bean: "
+ base.getClass().getName() + ", property: " + name, e);
}
@@ -448,9 +412,9 @@
public static PropertyDescriptor getPropertyDescriptor(
BeanInfo beanInfo, String propertyName)
{
- PropertyDescriptor[] propDescriptors =
+ PropertyDescriptor[] propDescriptors =
beanInfo.getPropertyDescriptors();
-
+
if (propDescriptors != null)
{
// TODO: cache this in classLoader safe way
@@ -461,9 +425,9 @@
}
}
- throw new PropertyNotFoundException("Bean: "
- + beanInfo.getBeanDescriptor().getBeanClass().getName()
+ throw new PropertyNotFoundException("Bean: "
+ + beanInfo.getBeanDescriptor().getBeanClass().getName()
+ ", property: " + propertyName);
}
-
+
}
Modified: myfaces/trunk/src/myfaces/org/apache/myfaces/el/ValueBindingImpl.java
URL: http://svn.apache.org/viewcvs/myfaces/trunk/src/myfaces/org/apache/myfaces/el/ValueBindingImpl.java?rev=169651&r1=169650&r2=169651&view=diff
==============================================================================
--- myfaces/trunk/src/myfaces/org/apache/myfaces/el/ValueBindingImpl.java (original)
+++ myfaces/trunk/src/myfaces/org/apache/myfaces/el/ValueBindingImpl.java Wed May 11 09:14:23 2005
@@ -1,12 +1,12 @@
/*
* Copyright 2004 The Apache Software Foundation.
- *
+ *
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
- *
+ *
* http://www.apache.org/licenses/LICENSE-2.0
- *
+ *
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
@@ -53,94 +53,15 @@
* @author Manfred Geiler (latest modification by $Author$)
* @author Anton Koinov
* @version $Revision$ $Date$
- *
- * $Log$
- * Revision 1.54 2004/10/13 11:51:00 matze
- * renamed packages to org.apache
- *
- * Revision 1.53 2004/10/01 12:01:05 dave0000
- * remove unneeded checks
- *
- * Revision 1.52 2004/10/01 11:54:29 dave0000
- * add detailed error messages for "base is null"
- *
- * Revision 1.51 2004/09/28 19:11:49 dave0000
- * uppercase static final prop
- * remove redundant code
- *
- * Revision 1.50 2004/09/28 18:29:48 dave0000
- * fix for bug 1034332: ValueBinding.getExpressionString() not implemented
- *
- * Revision 1.49 2004/09/20 14:35:48 dave0000
- * bug 1030875:
- * getType() should return null if type cannot be determined
- * isReadOnly() should return false if read-only cannot be determined
- *
- * Revision 1.48 2004/07/27 06:28:34 dave0000
- * fix issue with getType of literal expressions (and other improvements)
- *
- * Revision 1.47 2004/07/07 08:34:58 mwessendorf
- * removed unused import-statements
- *
- * Revision 1.46 2004/07/07 00:25:07 o_rossmueller
- * tidy up config/confignew package (moved confignew classes to package config)
- *
- * Revision 1.45 2004/07/06 23:46:01 o_rossmueller
- * tidy up config/confignew package
- *
- * Revision 1.44 2004/07/01 22:05:12 mwessendorf
- * ASF switch
- *
- * Revision 1.43 2004/06/28 22:12:13 o_rossmueller
- * fix #978654: do not coerce null
- *
- * Revision 1.42 2004/06/16 23:02:24 o_rossmueller
- * merged confignew_branch
- *
- * Revision 1.41.2.1 2004/06/16 02:07:23 o_rossmueller
- * get navigation rules from RuntimeConfig
- * refactored all remaining usages of MyFacesFactoryFinder to use RuntimeConfig
- *
- * Revision 1.41 2004/05/31 02:28:37 dave0000
- * Fix for: [955111] RestoreState of outputText with mixed ValueBinding attribute
- *
- * Revision 1.40 2004/05/11 04:24:10 dave0000
- * Bug 943166: add value coercion to ManagedBeanConfigurator
- *
- * Revision 1.39 2004/05/10 05:30:14 dave0000
- * Fix issue with setting Managed Bean to a wrong scope
- *
- * Revision 1.38 2004/04/26 05:54:59 dave0000
- * Add coercion to ValueBinding (and related changes)
- *
- * Revision 1.37 2004/04/08 05:16:45 dave0000
- * change to always use JSF PropertyResolver (was using JSP PR sometimes)
- *
- * Revision 1.36 2004/04/07 09:46:38 tinytoony
- * changed exception handling to show root cause
- *
- * Revision 1.35 2004/04/07 03:21:19 dave0000
- * fix issue with trim()ing of expression strings
- * prepare for PropertyResolver integration
- *
- * Revision 1.34 2004/04/07 01:52:55 dave0000
- * fix set "root" variable - was setting in the wrong scope if new var
- *
- * Revision 1.33 2004/04/07 01:40:13 dave0000
- * fix set "root" variable bug
- *
- * Revision 1.32 2004/03/30 07:40:08 dave0000
- * implement mixed string-reference expressions
- *
*/
public class ValueBindingImpl extends ValueBinding implements StateHolder
{
//~ Static fields/initializers --------------------------------------------
static final Log log = LogFactory.getLog(ValueBindingImpl.class);
-
+
/**
- * To implement function support, subclass and use a static
+ * To implement function support, subclass and use a static
* initialization block to assign your own function mapper
*/
protected static FunctionMapper s_functionMapper = new FunctionMapper()
@@ -148,11 +69,11 @@
public Method resolveFunction(String prefix, String localName)
{
throw new ReferenceSyntaxException(
- "Functions not supported in expressions. Function: "
+ "Functions not supported in expressions. Function: "
+ prefix + ":" + localName);
}
};
-
+
private static final BiLevelCacheMap s_expressionCache =
new BiLevelCacheMap(90)
{
@@ -167,7 +88,7 @@
protected Application _application;
protected String _expressionString;
protected Object _expression;
-
+
/**
* RuntimeConfig is instantiated once per servlet and never changes--we can
* safely cache it
@@ -182,7 +103,7 @@
{
throw new NullPointerException("application");
}
-
+
// Do not trim(), we support mixed string-bindings
if ((expression == null) || (expression.length() == 0))
{
@@ -200,7 +121,7 @@
{
return _expressionString;
}
-
+
public boolean isReadOnly(FacesContext facesContext)
{
try
@@ -211,11 +132,11 @@
return VariableResolverImpl.s_standardImplicitObjects
.containsKey(base_);
}
-
+
Object[] baseAndProperty = (Object[]) base_;
Object base = baseAndProperty[0];
Object property = baseAndProperty[1];
-
+
Integer index = ELParserHelper.toIndex(base, property);
return (index == null)
? _application.getPropertyResolver().isReadOnly(base, property)
@@ -224,7 +145,7 @@
}
catch (NotVariableReferenceException e)
{
- // if it is not a variable reference (e.g., a constant literal),
+ // if it is not a variable reference (e.g., a constant literal),
// we cannot write to it but can read it
return true;
}
@@ -243,7 +164,7 @@
if (base_ instanceof String)
{
String name = (String) base_;
-
+
// Check if it is a ManagedBean
// WARNING: must do this check first to avoid instantiating
// the MB in resolveVariable()
@@ -251,14 +172,14 @@
getRuntimeConfig(facesContext).getManagedBean(name);
if (mbConfig != null)
{
- // Note: if MB Class is not set, will return
+ // Note: if MB Class is not set, will return
// <code>null</code>, which is a valid return value
return mbConfig.getManagedBeanClass();
}
Object val = _application.getVariableResolver()
.resolveVariable(facesContext, name);
-
+
// Note: if there is no ManagedBean or variable with this name
// in any scope,then we will create a new one and thus
// any Object is allowed.
@@ -269,7 +190,7 @@
Object[] baseAndProperty = (Object[]) base_;
Object base = baseAndProperty[0];
Object property = baseAndProperty[1];
-
+
Integer index = ELParserHelper.toIndex(base, property);
return (index == null)
? _application.getPropertyResolver().getType(base, property)
@@ -284,7 +205,7 @@
// Note: we could hadle this case in a more performance efficient manner--
// but this case is so rare, that for months no-one detected
// the error before this code was added.
- try
+ try
{
return getValue(facesContext).getClass();
}
@@ -313,9 +234,9 @@
if (VariableResolverImpl.s_standardImplicitObjects
.containsKey(name))
{
- String errorMessage =
- "Cannot set value of implicit object '"
- + name + "' for expression '" + _expressionString + "'";
+ String errorMessage =
+ "Cannot set value of implicit object '"
+ + name + "' for expression '" + _expressionString + "'";
log.error(errorMessage);
throw new ReferenceSyntaxException(errorMessage);
}
@@ -328,7 +249,7 @@
Object[] baseAndProperty = (Object[]) base_;
Object base = baseAndProperty[0];
Object property = baseAndProperty[1];
- PropertyResolver propertyResolver =
+ PropertyResolver propertyResolver =
_application.getPropertyResolver();
Integer index = ELParserHelper.toIndex(base, property);
@@ -347,7 +268,7 @@
}
}
}
- catch (IndexOutOfBoundsException e)
+ catch (IndexOutOfBoundsException e)
{
// ArrayIndexOutOfBoundsException also here
throw new PropertyNotFoundException(
@@ -357,26 +278,26 @@
{
if (newValue == null)
{
- log.error("Cannot set value for expression '"
+ log.error("Cannot set value for expression '"
+ _expressionString + "' to null.", e);
}
else
{
- log.error("Cannot set value for expression '"
- + _expressionString + "' to a new value of type "
+ log.error("Cannot set value for expression '"
+ + _expressionString + "' to a new value of type "
+ newValue.getClass().getName(), e);
}
throw new EvaluationException(
"Expression: '" + _expressionString + "'", e);
}
}
-
+
private void setValueInScope(
FacesContext facesContext, String name, Object newValue)
throws ELException
{
ExternalContext externalContext = facesContext.getExternalContext();
-
+
// Request context
Map scopeMap = externalContext.getRequestMap();
Object obj = scopeMap.get(name);
@@ -387,7 +308,7 @@
}
// Session context
- scopeMap = externalContext.getSessionMap();
+ scopeMap = externalContext.getSessionMap();
obj = scopeMap.get(name);
if (obj != null)
{
@@ -403,33 +324,33 @@
scopeMap.put(name, coerce(newValue, obj.getClass()));
return;
}
-
+
// Check for ManagedBean
ManagedBean mbConfig =
getRuntimeConfig(facesContext).getManagedBean(name);
if (mbConfig != null)
{
String scopeName = mbConfig.getManagedBeanScope();
-
+
// find the scope handler object
// Note: this does not handle user-extended _scope values
- Scope scope =
+ Scope scope =
(Scope) VariableResolverImpl.s_standardScopes.get(scopeName);
if (scope != null)
{
- scope.put(externalContext, name,
+ scope.put(externalContext, name,
coerce(newValue, mbConfig.getManagedBeanClass()));
return;
}
-
+
log.error("Managed bean '" + name + "' has illegal scope: "
+ scopeName);
- externalContext.getRequestMap().put(name,
+ externalContext.getRequestMap().put(name,
coerce(newValue, mbConfig.getManagedBeanClass()));
return;
}
-
- // unknown target class, put newValue into request scope without coercion
+
+ // unknown target class, put newValue into request scope without coercion
externalContext.getRequestMap().put(name, newValue);
}
@@ -438,7 +359,7 @@
{
try
{
- return _expression instanceof Expression
+ return _expression instanceof Expression
? ((Expression) _expression).evaluate(
new ELVariableResolver(facesContext),
s_functionMapper, ELParserHelper.LOGGER)
@@ -446,7 +367,7 @@
new ELVariableResolver(facesContext),
s_functionMapper, ELParserHelper.LOGGER);
}
- catch (IndexOutOfBoundsException e)
+ catch (IndexOutOfBoundsException e)
{
// ArrayIndexOutOfBoundsException also here
throw new PropertyNotFoundException(
@@ -454,12 +375,12 @@
}
catch (Exception e)
{
- log.error("Cannot get value for expression '" + _expressionString
+ log.error("Cannot get value for expression '" + _expressionString
+ "'", e);
if (e instanceof ELException)
{
- log.error("Root cause for exception : ",
+ log.error("Root cause for exception : ",
((ELException) e).getRootCause());
}
@@ -467,30 +388,30 @@
"Expression: '" + _expressionString + "'", e);
}
}
-
- protected Object resolveToBaseAndProperty(FacesContext facesContext)
- throws ELException, NotVariableReferenceException
+
+ protected Object resolveToBaseAndProperty(FacesContext facesContext)
+ throws ELException, NotVariableReferenceException
{
if (facesContext == null)
{
throw new NullPointerException("facesContext");
}
-
- VariableResolver variableResolver =
+
+ VariableResolver variableResolver =
new ELVariableResolver(facesContext);
Object expression = _expression;
-
+
while (expression instanceof ConditionalExpression)
{
- ConditionalExpression conditionalExpression =
+ ConditionalExpression conditionalExpression =
((ConditionalExpression) expression);
// first, evaluate the condition (and coerce the result to a
// boolean value)
boolean condition =
Coercions.coerceToBoolean(
conditionalExpression.getCondition().evaluate(
- variableResolver, s_functionMapper,
- ELParserHelper.LOGGER),
+ variableResolver, s_functionMapper,
+ ELParserHelper.LOGGER),
ELParserHelper.LOGGER)
.booleanValue();
@@ -503,7 +424,7 @@
{
return ((NamedValue) expression).getName();
}
-
+
if (!(expression instanceof ComplexValue)) {
// all other cases are not variable references
throw new NotVariableReferenceException(
@@ -511,47 +432,47 @@
+ _expression.getClass().getName() + ". Expression: '"
+ _expressionString + "'");
}
-
+
ComplexValue complexValue = (ComplexValue) expression;
-
+
// resolve the prefix
Object base = complexValue.getPrefix()
- .evaluate(variableResolver, s_functionMapper,
+ .evaluate(variableResolver, s_functionMapper,
ELParserHelper.LOGGER);
if (base == null)
{
- throw new PropertyNotFoundException("Base is null: "
+ throw new PropertyNotFoundException("Base is null: "
+ complexValue.getPrefix().getExpressionString());
}
// Resolve and apply the suffixes
List suffixes = complexValue.getSuffixes();
int max = suffixes.size() - 1;
- for (int i = 0; i < max; i++)
+ for (int i = 0; i < max; i++)
{
ValueSuffix suffix = (ValueSuffix) suffixes.get(i);
base = suffix.evaluate(base, variableResolver, s_functionMapper,
ELParserHelper.LOGGER);
if (base == null)
{
- throw new PropertyNotFoundException("Base is null: "
+ throw new PropertyNotFoundException("Base is null: "
+ suffix.getExpressionString());
}
}
-
+
// Resolve the last suffix
ArraySuffix arraySuffix = (ArraySuffix) suffixes.get(max);
Expression arraySuffixIndex = arraySuffix.getIndex();
-
+
Object index;
if (arraySuffixIndex != null)
{
index = arraySuffixIndex.evaluate(
- variableResolver, s_functionMapper,
+ variableResolver, s_functionMapper,
ELParserHelper.LOGGER);
if (index == null)
{
- throw new PropertyNotFoundException("Index is null: "
+ throw new PropertyNotFoundException("Index is null: "
+ arraySuffixIndex.getExpressionString());
}
}
@@ -559,17 +480,17 @@
{
index = ((PropertySuffix) arraySuffix).getName();
}
-
+
return new Object[] {base, index};
}
private Object coerce(Object value, Class clazz) throws ELException
{
return (value == null) ? null
- : (clazz == null) ? value :
+ : (clazz == null) ? value :
Coercions.coerce(value, clazz, ELParserHelper.LOGGER);
}
-
+
protected RuntimeConfig getRuntimeConfig(FacesContext facesContext)
{
if (_runtimeConfig == null)
@@ -578,7 +499,7 @@
}
return _runtimeConfig;
}
-
+
public String toString()
{
return _expressionString;
@@ -589,7 +510,7 @@
private boolean _transient = false;
/**
- * Empty constructor, so that new instances can be created when restoring
+ * Empty constructor, so that new instances can be created when restoring
* state.
*/
public ValueBindingImpl()
@@ -620,17 +541,17 @@
{
_transient = flag;
}
-
+
//~ Internal classes ------------------------------------------------------
public static class ELVariableResolver implements VariableResolver {
private final FacesContext _facesContext;
-
- public ELVariableResolver(FacesContext facesContext)
+
+ public ELVariableResolver(FacesContext facesContext)
{
_facesContext = facesContext;
}
-
+
public Object resolveVariable(String pName)
throws ELException
{
@@ -638,8 +559,8 @@
.resolveVariable(_facesContext, pName);
}
}
-
- public static final class NotVariableReferenceException
+
+ public static final class NotVariableReferenceException
extends ReferenceSyntaxException
{
public NotVariableReferenceException(String message)
Modified: myfaces/trunk/src/myfaces/org/apache/myfaces/el/VariableResolverImpl.java
URL: http://svn.apache.org/viewcvs/myfaces/trunk/src/myfaces/org/apache/myfaces/el/VariableResolverImpl.java?rev=169651&r1=169650&r2=169651&view=diff
==============================================================================
--- myfaces/trunk/src/myfaces/org/apache/myfaces/el/VariableResolverImpl.java (original)
+++ myfaces/trunk/src/myfaces/org/apache/myfaces/el/VariableResolverImpl.java Wed May 11 09:14:23 2005
@@ -1,12 +1,12 @@
/*
* Copyright 2004 The Apache Software Foundation.
- *
+ *
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
- *
+ *
* http://www.apache.org/licenses/LICENSE-2.0
- *
+ *
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
@@ -35,42 +35,6 @@
* @author Manfred Geiler (latest modification by $Author$)
* @author Anton Koinov
* @version $Revision$ $Date$
- * $Log$
- * Revision 1.34 2004/11/08 03:43:20 bdudney
- * Added a div element. x:div to use, inserts a div with class or style attributes
- *
- * Revision 1.33 2004/10/13 11:51:00 matze
- * renamed packages to org.apache
- *
- * Revision 1.32 2004/07/27 06:28:34 dave0000
- * fix issue with getType of literal expressions (and other improvements)
- *
- * Revision 1.31 2004/07/07 08:34:58 mwessendorf
- * removed unused import-statements
- *
- * Revision 1.30 2004/07/07 00:25:07 o_rossmueller
- * tidy up config/confignew package (moved confignew classes to package config)
- *
- * Revision 1.29 2004/07/01 22:05:12 mwessendorf
- * ASF switch
- *
- * Revision 1.28 2004/06/16 23:02:24 o_rossmueller
- * merged confignew_branch
- *
- * Revision 1.27.2.2 2004/06/16 02:07:23 o_rossmueller
- * get navigation rules from RuntimeConfig
- * refactored all remaining usages of MyFacesFactoryFinder to use RuntimeConfig
- *
- * Revision 1.27.2.1 2004/06/13 15:59:07 o_rossmueller
- * started integration of new config mechanism:
- * - factories
- * - components
- * - render kits
- * - managed beans + managed properties (no list/map initialization)
- *
- * Revision 1.27 2004/05/12 07:57:43 manolito
- * Log in javadoc header
- *
*/
public class VariableResolverImpl
extends VariableResolver
@@ -183,7 +147,7 @@
}
});
}
-
+
/**
* Stores all implicit objects defined for this instance of <code>VariableResolver</code>
* <p>
@@ -243,7 +207,7 @@
}
});
}
-
+
/**
* Stores all scopes defined for this instance of <code>VariableResolver</code>
* <p>
@@ -329,7 +293,7 @@
// put in scope
String scopeKey = mbc.getManagedBeanScope();
-
+
// find the scope handler object
Scope scope = (Scope) _scopes.get(scopeKey);
if (scope == null)
Modified: myfaces/trunk/src/xdoclet/org/apache/myfaces/xdoclet/ComponentSubTask.java
URL: http://svn.apache.org/viewcvs/myfaces/trunk/src/xdoclet/org/apache/myfaces/xdoclet/ComponentSubTask.java?rev=169651&r1=169650&r2=169651&view=diff
==============================================================================
--- myfaces/trunk/src/xdoclet/org/apache/myfaces/xdoclet/ComponentSubTask.java (original)
+++ myfaces/trunk/src/xdoclet/org/apache/myfaces/xdoclet/ComponentSubTask.java Wed May 11 09:14:23 2005
@@ -1,12 +1,12 @@
/*
* Copyright 2004 The Apache Software Foundation.
- *
+ *
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
- *
+ *
* http://www.apache.org/licenses/LICENSE-2.0
- *
+ *
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
@@ -24,25 +24,21 @@
* parent="xdoclet.DocletTask"
*
* @author <a href="mailto:Jiri.Zaloudek@ivancice.cz">Jiri Zaloudek</a> (latest modification by $Author$)
- * @version $Revision$ $Date$
- * $Log$
- * Revision 1.1 2004/12/30 09:37:27 matzew
- * added a new RenderKit for WML. Thanks to Jirí aloudek
- *
+ * @version $Revision$ $Date$
*/
-public class ComponentSubTask extends TemplateSubTask {
-
+public class ComponentSubTask extends TemplateSubTask {
+
/** Creates a new instance of ComponentSubTask */
public ComponentSubTask() {
setDestinationFile("{0}.java");
setTemplateURL(getClass().getResource("/org/apache/myfaces/xdoclet/resources/component.xdt"));
}
-
+
public void validateOptions() throws XDocletException {
super.validateOptions();
if (getDestinationFile() == null) {
- throw new XDocletException("Ant Doclet Subtaksk ComponentSubTaks: You have to set attribute 'destinationFile'.");
+ throw new XDocletException("Ant Doclet Subtaksk ComponentSubTaks: You have to set attribute 'destinationFile'.");
}
}
-
+
}
Modified: myfaces/trunk/src/xdoclet/org/apache/myfaces/xdoclet/TagLibSubTask.java
URL: http://svn.apache.org/viewcvs/myfaces/trunk/src/xdoclet/org/apache/myfaces/xdoclet/TagLibSubTask.java?rev=169651&r1=169650&r2=169651&view=diff
==============================================================================
--- myfaces/trunk/src/xdoclet/org/apache/myfaces/xdoclet/TagLibSubTask.java (original)
+++ myfaces/trunk/src/xdoclet/org/apache/myfaces/xdoclet/TagLibSubTask.java Wed May 11 09:14:23 2005
@@ -1,12 +1,12 @@
/*
* Copyright 2004 The Apache Software Foundation.
- *
+ *
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
- *
+ *
* http://www.apache.org/licenses/LICENSE-2.0
- *
+ *
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
@@ -24,25 +24,21 @@
* parent="xdoclet.DocletTask"
*
* @author <a href="mailto:Jiri.Zaloudek@ivancice.cz">Jiri Zaloudek</a> (latest modification by $Author$)
- * @version $Revision$ $Date$
- * $Log$
- * Revision 1.1 2004/12/30 09:37:27 matzew
- * added a new RenderKit for WML. Thanks to Jirí aloudek
- *
+ * @version $Revision$ $Date$
*/
-public class TagLibSubTask extends TemplateSubTask {
-
+public class TagLibSubTask extends TemplateSubTask {
+
/** Creates a new instance of TagSubTask */
public TagLibSubTask() {
setDestinationFile("wap_faces.tld");
setTemplateURL(getClass().getResource("/org/apache/myfaces/xdoclet/resources/tld.xdt"));
}
-
+
public void validateOptions() throws XDocletException {
super.validateOptions();
if (getDestinationFile() == null) {
- throw new XDocletException("Ant Doclet Subtaksk TagSubTaks: You have to set attribute 'destinationFile'.");
+ throw new XDocletException("Ant Doclet Subtaksk TagSubTaks: You have to set attribute 'destinationFile'.");
}
}
-
+
}
Modified: myfaces/trunk/src/xdoclet/org/apache/myfaces/xdoclet/TagSubTask.java
URL: http://svn.apache.org/viewcvs/myfaces/trunk/src/xdoclet/org/apache/myfaces/xdoclet/TagSubTask.java?rev=169651&r1=169650&r2=169651&view=diff
==============================================================================
--- myfaces/trunk/src/xdoclet/org/apache/myfaces/xdoclet/TagSubTask.java (original)
+++ myfaces/trunk/src/xdoclet/org/apache/myfaces/xdoclet/TagSubTask.java Wed May 11 09:14:23 2005
@@ -1,12 +1,12 @@
/*
* Copyright 2004 The Apache Software Foundation.
- *
+ *
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
- *
+ *
* http://www.apache.org/licenses/LICENSE-2.0
- *
+ *
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
@@ -24,25 +24,21 @@
* parent="xdoclet.DocletTask"
*
* @author <a href="mailto:Jiri.Zaloudek@ivancice.cz">Jiri Zaloudek</a> (latest modification by $Author$)
- * @version $Revision$ $Date$
- * $Log$
- * Revision 1.1 2004/12/30 09:37:27 matzew
- * added a new RenderKit for WML. Thanks to Jirí aloudek
- *
+ * @version $Revision$ $Date$
*/
-public class TagSubTask extends TemplateSubTask {
-
+public class TagSubTask extends TemplateSubTask {
+
/** Creates a new instance of TagSubTask */
public TagSubTask() {
setDestinationFile("{0}Tag.java");
setTemplateURL(getClass().getResource("/org/apache/myfaces/xdoclet/resources/tag.xdt"));
}
-
+
public void validateOptions() throws XDocletException {
super.validateOptions();
if (getDestinationFile() == null) {
- throw new XDocletException("Ant Doclet Subtaksk TagSubTaks: You have to set attribute 'destinationFile'.");
+ throw new XDocletException("Ant Doclet Subtaksk TagSubTaks: You have to set attribute 'destinationFile'.");
}
}
-
+
}
Modified: myfaces/trunk/src/xdoclet/org/apache/myfaces/xdoclet/WapFacesTagHandler.java
URL: http://svn.apache.org/viewcvs/myfaces/trunk/src/xdoclet/org/apache/myfaces/xdoclet/WapFacesTagHandler.java?rev=169651&r1=169650&r2=169651&view=diff
==============================================================================
--- myfaces/trunk/src/xdoclet/org/apache/myfaces/xdoclet/WapFacesTagHandler.java (original)
+++ myfaces/trunk/src/xdoclet/org/apache/myfaces/xdoclet/WapFacesTagHandler.java Wed May 11 09:14:23 2005
@@ -1,12 +1,12 @@
/*
* Copyright 2004 The Apache Software Foundation.
- *
+ *
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
- *
+ *
* http://www.apache.org/licenses/LICENSE-2.0
- *
+ *
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
@@ -24,23 +24,19 @@
/**
* @xdoclet.taghandler namespace="WapFaces"
* @author <a href="mailto:Jiri.Zaloudek@ivancice.cz">Jiri Zaloudek</a> (latest modification by $Author$)
- * @version $Revision$ $Date$
- * $Log$
- * Revision 1.1 2004/12/30 09:37:27 matzew
- * added a new RenderKit for WML. Thanks to Jirí aloudek
- *
+ * @version $Revision$ $Date$
*/
public class WapFacesTagHandler extends XDocletTagSupport {
private int iter = 0;
-
+
public String componentFamily() throws XDocletException {
return (getTagValue(FOR_CLASS, "wapfaces.tag", "componentFamily", null, null, false, false));
}
-
+
public String rendererType() throws XDocletException {
return (getTagValue(FOR_CLASS, "wapfaces.tag", "rendererType", null, null, false, false));
}
-
+
public String tagName() throws XDocletException {
return (getTagValue(FOR_CLASS, "wapfaces.tag", "tagName", null, null, false, false));
}
@@ -48,31 +44,31 @@
public String tagBaseClass() throws XDocletException {
return (getTagValue(FOR_CLASS, "wapfaces.tag", "tagBaseClass", null, null, false, false));
}
-
+
public String bodyContent() throws XDocletException {
return (getTagValue(FOR_CLASS, "wapfaces.tag", "bodyContent", null, null, false, false));
}
-
+
private String attributeName(){
XField field = getCurrentField();
- return(field.getName());
+ return(field.getName());
}
-
+
private String attributeType(){
XField field = getCurrentField();
- return(field.getType().getQualifiedName());
+ return(field.getType().getQualifiedName());
}
-
- /** Return initial value for attribute.
- * @return init value, if initValue isn't set reurn null
+
+ /** Return initial value for attribute.
+ * @return init value, if initValue isn't set reurn null
*/
public String attributeInitValue() throws XDocletException {
String value = getTagValue(FOR_FIELD, "wapfaces.attribute", "initValue", null, null, false, false);
-
+
if (value == null) return(attributeNullValue());
return (value);
}
-
+
/** Return the right null value according to type of property*/
public String attributeNullValue() throws XDocletException {
String type = attributeType();
@@ -87,18 +83,18 @@
if (type.equals("char")) return("\u0000");
return("null");
}
-
+
public void ifIsAttributePrimitive(String template) throws XDocletException {
if (isAttributePrimitive())
generate(template);
}
-
+
public void ifIsNotAttributePrimitive(String template) throws XDocletException {
if (!isAttributePrimitive())
generate(template);
}
-
-
+
+
private boolean isAttributePrimitive() throws XDocletException {
String type = attributeType();
if (type == null) throw new XDocletException("Missing(or wrong) attribute 'type' in property declaration.");
@@ -106,14 +102,14 @@
type.equals("int") || type.equals("long") || type.equals("float") ||
type.equals("double") || type.equals("char"))
return (true);
-
+
return(false);
}
-
+
/** Return the class name according to primitive type. If field type isn't primitive, return the type. */
public String classForType() throws XDocletException {
//if (!isAttributePrimitive()) throw new XDocletException("Method 'classForPrimitiveType' can be call only for primitive types. You can test it with method 'ifIsAttributePrimitive'.");
-
+
String type = attributeType();
try {
if (isAttributePrimitive()){
@@ -123,21 +119,21 @@
return (firstLetterToUpperCase(type));
}
return (type);
-
+
} catch (Exception ex){
throw new XDocletException(ex.getMessage());
}
}
-
+
public String isAttributeRequired() throws XDocletException {
return(String.valueOf(attributeRequired()));
}
-
+
public void ifIsAttributeRequired(String template) throws XDocletException {
if (attributeRequired())
generate(template);
}
-
+
private boolean attributeRequired() throws XDocletException {
String value = getTagValue(FOR_FIELD, "wapfaces.attribute", "required", null, "false", false, false);
@@ -147,11 +143,11 @@
return(false);
}
}
-
+
public String isRtExprValue() throws XDocletException {
return(String.valueOf(rtExprValue()));
}
-
+
private boolean rtExprValue() throws XDocletException {
String value = getTagValue(FOR_FIELD, "wapfaces.attribute", "rtexprvalue", null, "false", false, false);
@@ -166,45 +162,45 @@
if (isAttributeValueBinding())
generate(template);
}
-
+
public void ifIsNotAttributeValueBinding(String template) throws XDocletException {
if (!isAttributeValueBinding())
generate(template);
}
-
+
private boolean isAttributeValueBinding() throws XDocletException {
String value = getTagValue(FOR_FIELD, "wapfaces.attribute", "valueBinding", null, "false", false, false);
-
+
try {
return (stringToBoolean(value));
} catch (NumberFormatException ex) {
return(false);
}
}
-
+
public void ifIsNotAttributeAbstract(String template) throws XDocletException {
if (!isAttributeAbstract()) // if is not abstract
generate(template);
}
-
+
private boolean isAttributeAbstract() throws XDocletException {
String value = getTagValue(FOR_FIELD, "wapfaces.attribute", "abstract", null, "false", false, false);
-
+
try {
return (stringToBoolean(value));
} catch (NumberFormatException ex) {
return(false);
}
}
-
+
public void ifIsNotAttributeInherit(String template) throws XDocletException {
if (!isAttributeInherid()) // if is not inherit
generate(template);
}
-
+
private boolean isAttributeInherid() throws XDocletException {
String value = getTagValue(FOR_FIELD, "wapfaces.attribute", "inherit", null, "false", false, false);
-
+
try {
return (stringToBoolean(value));
} catch (NumberFormatException ex) {
@@ -216,45 +212,45 @@
if (isAttributeReplaced())
generate(template);
}
-
+
public void ifIsNotAttributeReplaced(String template) throws XDocletException{
if (!isAttributeReplaced()) // if is not attribute replaced
generate(template);
}
-
+
private boolean isAttributeReplaced() throws XDocletException {
boolean isEmpty = getReplacedAttributeName() == null || "".endsWith(getReplacedAttributeName());
-
+
return(!isEmpty);
}
public String getReplacedAttributeName() throws XDocletException {
String value = getTagValue(FOR_FIELD, "wapfaces.attribute", "replaceWith", null, null, false, false);
-
+
return(value);
}
-
+
public String getterMethodName() throws XDocletException {
String name = attributeName();
-
+
try {
return (getterPrefix() + firstLetterToUpperCase(name));
} catch (Exception ex){
throw new XDocletException(ex.getMessage());
}
}
-
+
/** returns the attribute name with first letter in upper case */
public String firstLetterToUpperCaseAttributeName() throws XDocletException {
String name = attributeName();
-
+
try {
return (firstLetterToUpperCase(name));
} catch (Exception ex){
throw new XDocletException(ex.getMessage());
}
}
-
+
public String setterMethodName() throws XDocletException {
String name = attributeName();
try {
@@ -263,15 +259,15 @@
throw new XDocletException(ex.getMessage());
}
}
-
+
public void iterateValue() {
iter = iter + 1;
}
-
+
public String iteratorValue() {
return (String.valueOf(iter));
}
-
+
public void setIterator(Properties prop) throws XDocletException {
String value = prop.getProperty("value");
try {
@@ -280,13 +276,13 @@
throw new XDocletException("You have to set property 'value' in method setIterator. 'Value' is a integer number.");
}
}
-
+
private String getterPrefix(){
if ("boolean".equals(attributeType()))
return("is");
return("get");
}
-
+
private String firstLetterToUpperCase(String str) throws Exception {
if (str != null && str.length() > 0){
str = str.substring(0, 1).toUpperCase() + str.substring(1);
@@ -294,7 +290,7 @@
}
else throw new Exception("Attribut name error. Name must have at least one character.");
}
-
+
private boolean stringToBoolean(String str){
Boolean bool = Boolean.valueOf(str);
return(bool.booleanValue());