Do you want to go now -----Original Message----- From: Michael McGrady [mailto:[EMAIL PROTECTED] Sent: Friday, August 06, 2004 2:26 PM To: Struts Users Mailing List Subject: Re: GOING GOING GONE DYNAMIC
I don't know what a "copy of a reference" (which should just be a number indicating where to find the object) would be, Erik. I do know what a copy of an object would be. I am not thinking of changing the reference to a different object but giving the reference itself a different object. E.g. ActionForm method(ActionForm actionForm) { // set the same reference. ActionForm af = actionForm; // now reset the form with that reference af = DynamicActionFormFactory.getBlankForm(name,type,fields); return af; } This make sense to you? Michael McGrady At 02:15 PM 8/6/2004, you wrote: >Java passes a *copy* of the reference (thus, Java always passes parameters >using call-by-value), not the actual reference. So, changing the passed-in >reference from within the method to refer to a different object will not >cause a change in the reference of the guy who called the method -- his >reference will still refer to the old (unchanged) object. However, since >the passed-in reference refers to the same object as the caller's >reference, you can modify the object itself via your reference and the >caller will see the changes. So you could invoke setParameter, etc., on >the ActionMapping provided . . . > >It's a matter of syntax really, you can still accomplish what you are >talking about. > >Erik > > > >Michael McGrady wrote: > >>At 01:44 PM 8/6/2004, you wrote: >> >>>If I understand you correctly... >>>Same issue.... it's passed into the execute method, and therefore you >>>can't change it, only it's internals, so you would have to do the same >>>thing there. >>> >>>I'm talking specifically in the execute method, which is where I think >>>you're trying to create the form. >> >> >>I'm perhaps confused, then, Jim. My understanding is that Java never >>passes more than the reference, so why could we not change the mapping >>and the form in execute? Why cannot we, in other words, take the >>reference and reinitialize it to a different ActionForm, ActionMapping, >>or whatever? >> >>Michael McGrady >> >> >> >> >>--------------------------------------------------------------------- >>To unsubscribe, e-mail: [EMAIL PROTECTED] >>For additional commands, e-mail: [EMAIL PROTECTED] >> > >--------------------------------------------------------------------- >To unsubscribe, e-mail: [EMAIL PROTECTED] >For additional commands, e-mail: [EMAIL PROTECTED] > > --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] ************************************************************************ If you have received this e-mail in error, please delete it and notify the sender as soon as possible. The contents of this e-mail may be confidential and the unauthorized use, copying, or dissemination of it and any attachments to it, is prohibited. Internet communications are not secure and Hyperion does not, therefore, accept legal responsibility for the contents of this message nor for any damage caused by viruses. The views expressed here do not necessarily represent those of Hyperion. For more information about Hyperion, please visit our Web site at www.hyperion.com --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]