User: vharcq
Date: 02/04/17 16:02:30
Modified: core/src/xdoclet/ejb/tags EjbRefTagsHandler.java
HomeTagsHandler.java
Log:
Important patch!
I split currentTag in one for class tag and one for method tag
I check if it is set in getTagValue (the biggest method around)
This is to solve in once problems like having
@ejb:permission role-name="a,b" on class and/or method
or having
* @ejb.finder
* signature="Collection findByCode(String code)"
* query="SELECT OBJECT(p) FROM LANGUAGE as p WHERE p.id = ?1"
* @ejb.finder
* signature "Collection findByCode(java.lang.String a, java.lang.String b)"
* query="SELECT OBJECT(p) FROM LANGUAGE as p WHERE p.id = ?1 AND p.id = ?2"
Plus all tags that merge forAllClass and forAllMethod
Plus all tags that have in a forAllMethod on a tag/param a lookup on another
(tag)/(param)
It passes samples and unit tests
Revision Changes Path
1.10 +3 -2 xdoclet/core/src/xdoclet/ejb/tags/EjbRefTagsHandler.java
Index: EjbRefTagsHandler.java
===================================================================
RCS file: /cvsroot/xdoclet/xdoclet/core/src/xdoclet/ejb/tags/EjbRefTagsHandler.java,v
retrieving revision 1.9
retrieving revision 1.10
diff -u -w -r1.9 -r1.10
--- EjbRefTagsHandler.java 17 Apr 2002 20:32:20 -0000 1.9
+++ EjbRefTagsHandler.java 17 Apr 2002 23:02:30 -0000 1.10
@@ -79,11 +79,11 @@
for( int i = 0; i < tags.length; i++ )
{
- setCurrentTag( tags[i] );
+ setCurrentClassTag( tags[i] );
storeReferringClassId();
- String ejbName = getCurrentTag().attributeValue(
"ejb-name" );
+ String ejbName = getCurrentClassTag().attributeValue(
"ejb-name" );
if( !already.contains( ejbName ) )
{
@@ -93,6 +93,7 @@
popCurrentClass();
}
+ setCurrentClassTag( null );
referringClassId = null;
}
if( superclasses == true )
1.35 +5 -4 xdoclet/core/src/xdoclet/ejb/tags/HomeTagsHandler.java
Index: HomeTagsHandler.java
===================================================================
RCS file: /cvsroot/xdoclet/xdoclet/core/src/xdoclet/ejb/tags/HomeTagsHandler.java,v
retrieving revision 1.34
retrieving revision 1.35
diff -u -w -r1.34 -r1.35
--- HomeTagsHandler.java 17 Apr 2002 20:32:20 -0000 1.34
+++ HomeTagsHandler.java 17 Apr 2002 23:02:30 -0000 1.35
@@ -27,7 +27,7 @@
/**
* @author Ara Abrahamian ([EMAIL PROTECTED])
* @created Oct 15, 2001
- * @version $Revision: 1.34 $
+ * @version $Revision: 1.35 $
*/
public class HomeTagsHandler extends EjbTagsHandler
{
@@ -713,7 +713,7 @@
*/
public void forAllHomeMethods( String template, Properties attributes ) throws
XDocletException
{
- Category cat = Log.getCategory( HomeTagsHandler.class, "forAllFinders"
);
+ Category cat = Log.getCategory( HomeTagsHandler.class,
"forAllHomeMethods" );
boolean superclasses = TypeConversionUtil.stringToBoolean(
attributes.getProperty( "superclasses" ), false );
String type = attributes.getProperty( "type" );
String tagType = attributes.getProperty( "tagName" );
@@ -922,7 +922,7 @@
fbpkFound = true;
}
- setCurrentTag( tags[i] );
+ setCurrentClassTag( tags[i] );
setCurrentSignature( signature );
StringBuffer exc = new StringBuffer();
@@ -986,7 +986,8 @@
}
}
- setCurrentTag( null );
+ setCurrentClassTag( null );
+ setCurrentMethodTag( null );
setCurrentSignature( null );
setCurrentExceptions( null );
setCurrentMethod( null );
_______________________________________________
Xdoclet-devel mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/xdoclet-devel