Swamy Nathan

Ranch Hand
+ Follow
since May 16, 2004
Merit badge: grant badges
For More
Cows and Likes
Cows
Total received
0
In last 30 days
0
Total given
0
Likes
Total received
0
Received in last 30 days
0
Total given
0
Given in last 30 days
0
Forums and Threads
Scavenger Hunt
expand Ranch Hand Scavenger Hunt
expand Greenhorn Scavenger Hunt

Recent posts by Swamy Nathan

I found a work around my extending the Java ant task.



This is a work around am interested in a better approach.
17 years ago
Hi,

I need to write a custom ant task that executes code which depends on some jvmargs.

I need to nest in the task the following
<jvmarg value="-Dkey=value" />

What all do I need to do for this.

I went thru the source code of Java task but not very clear.
17 years ago
I am about to get my feet wet with LDAP coding in Java.

Has anyone used the Directory Server SDK by Netscape for LDAP. It lloks like a good tool. My fear is that it has not been updated in what looks like a long while.

Otherwise using JNDI and java if one wants to do all the same things without using the SDK is that possible?
17 years ago
I have a dynavalidator bean.
My valiadator works fine when the field types I specify in my validation.xml are
1. Simple Strings,
2. Simple String[]
3. A simple String field of a nested bean.
4. A simple String[] field of a nested bean.
5. A String field if a nested beanArray.

===>I am having trouble when the field is a String[] inside a nested bean array.







I give below the xml for reference






<form-bean name="bundlesForm" type="org.apache.struts.validator.DynaValidatorForm">
<form-property name="name" type="java.lang.String" />
<form-property name="simpleArray" type="java.lang.String[]" size="3" />
<form-property name="subform1" type="package1.Subform" />
<form-property name="subformarr" type="package1.Subform[]" size="2" />
</form-bean>

SubForm bean has foloowing fields:-
name="field1" type="java.lang.String"
name="field2" type="java.lang.String[]"

Here is a form from my validation.xml

<form name="bundlesForm">
<field property="name" depends="required">
<msg name="required" key="You have forgotten to enter the name." resource="false" />
</field>

<field property="simpleArray" depends="required">
<arg key="bundlesForm.error.simpleArray1" />
</field>
<field property="simpleArray" indexedListProperty="simpleArray" depends="required,integer">
<arg key="bundlesForm.error.simpleArray" />
</field>

<field property="subform1.field1" depends="required,integer">
<arg key="bundlesForm.error.subform1.field1" />
</field>
<field property="subform1.field2" depends="required">
<arg key="bundlesForm.error.subform1.field2x" />
</field>

<field property="subform1.field2" indexedListProperty="subform1.field2" depends="required,integer">
<arg key="bundlesForm.error.subform1.field2" />
</field>
<field property="subformarr" depends="required">
<arg key="bundlesForm.error.subformarr" />
</field>
<field property="field1" indexedListProperty="subformarr" depends="required,integer">
<arg key="bundlesForm.error.subformarr.field1" />
</field>
<field property="field2" indexedListProperty="subformarr" depends="required,integer">
<arg key="bundlesForm.error.subformarr.field2" />
</field>
</form>
18 years ago
stopOnFirstError is about Javascript I think.

I was looking at a scenario where I have a a string array defined as a field in a dynavalidator form with a size of say 3.

In my jsp I use logic:iterate and show 3 textboxes.
I show the error messages for each text box indexed field also.

Unfortunately it shows only the errors encountered in the first problematic indexed field. Subsequent indexed fields are not being validated.
18 years ago
How do you write a dynavalidatorform that has a field which is itself a dynavalidator form and must be validated also.
18 years ago
I thin you need to explain the flow more in detail
18 years ago
That worked.
But I have another problem.

Lets say I did not fill up all 3 rows.

It just indicates the problem for the first row in my jsp.

When I do a system.out on the action errors object i find it contains only 1 error for strArray[0].strArray and nothing for [1], [2]
[ September 24, 2005: Message edited by: Swamy Nathan ]
18 years ago
The whole approsach is too messy.

There are TWO other simpler approaches.

The simplest would be to declare another class in same package as the action servlet and access the protected map variable from there.
[ September 24, 2005: Message edited by: Swamy Nathan ]
18 years ago
Should it not be as folows?
<input name="user[0].name" value=""/> <input name="user[0].email" value=""/> <br /> <input name="user[1].name" value=""/> <input name="user[1].email" value=""/>
18 years ago
I am using a dynavalidator form with a field of type java.lang.String[]

I needed to set a dependency of type required & date on each row.

How do I do this without modifying / extending the commons beans validator framework ?

I am using the iterate logic tag and displaying 3 textboxes.

My dyna form bean has a size attribute of 3.

I think the problem is that the textboxes get name attribute (in rendered html)- dyanformfield[0].dyanformfield, dyanformfield[1].dyanformfield etc but the form field is not a bean just a string in a string array.
[ September 24, 2005: Message edited by: Swamy Nathan ]
18 years ago
1. Which is the most uptodate UML certification? (Dont want to learn some certification that would be retired in 6 months.)
2. What are the different mock tests available?
3. Which books to read?
Which is the UML certification to go for?
Are there any training materials namely books and free mock tests?
Is theer any HF UML book scheduled?