You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tapestry.apache.org by "matthew c. mead" <m-...@goof.com> on 2005/02/18 14:49:44 UTC

bug in class enhancement?

I've been using the standard pattern for login to the application and 
building a login page that takes an ICallback, performs authentication, 
and then returns to the original page.

If I make my member functions for the callback variable accessor/mutator 
abstract, define a property-specification for the property,  and let the 
enhancement handle implementing it all for me, the login page always 
gets a null value when I call getPageCallback() to make my callback.

If I create a true member variable an member functions for the 
accessor/mutator, everything works ok.

Is this a bug in the enhancement code or is it expected behavior?

Thanks!



-matt

-- 
matthew c. mead

http://www.goof.com/

Re: bug in class enhancement?

Posted by Danny Mandel <dm...@tolweb.org>.
No.  Persistent properties are stored in the HttpSession for a given 
user, so one user would not be able to see another's login attempt.  
Actually, using member variables incorrectly could possibly cause this 
behavior, so it's best to stick with property-specifications.

Danny

matthew c. mead wrote:

> Thanks for the explanation - I'll switch back to using the class 
> enhancement and make this a persistent property.
>
> Are there any implications to doing so that might cause one user to 
> get the ICallback for another user's login attempt?
>
>
> -matt
>
> Erik Hatcher wrote:
>
>> Did you make your <property-specification> persistent?  My hunch is 
>> not.   You're getting lucky that it worked with the true member 
>> variable... had a different page been pulled from the pool you'd have 
>> gotten null then too.
>>
>>     Erik
>>
>>
>> On Feb 18, 2005, at 8:49 AM, matthew c. mead wrote:
>>
>>> I've been using the standard pattern for login to the application 
>>> and building a login page that takes an ICallback, performs 
>>> authentication, and then returns to the original page.
>>>
>>> If I make my member functions for the callback variable 
>>> accessor/mutator abstract, define a property-specification for the 
>>> property,  and let the enhancement handle implementing it all for 
>>> me, the login page always gets a null value when I call 
>>> getPageCallback() to make my callback.
>>>
>>> If I create a true member variable an member functions for the 
>>> accessor/mutator, everything works ok.
>>>
>>> Is this a bug in the enhancement code or is it expected behavior?
>>>
>>> Thanks!
>>>
>>>
>>>
>>> -matt
>>>
>>> -- 
>>> matthew c. mead
>>>
>>> http://www.goof.com/
>>
>>
>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
>> For additional commands, e-mail: tapestry-user-help@jakarta.apache.org
>>
>


---------------------------------------------------------------------
To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tapestry-user-help@jakarta.apache.org


Re: bug in class enhancement?

Posted by "matthew c. mead" <m-...@goof.com>.
Thanks for the explanation - I'll switch back to using the class 
enhancement and make this a persistent property.

Are there any implications to doing so that might cause one user to get 
the ICallback for another user's login attempt?


-matt

Erik Hatcher wrote:

> Did you make your <property-specification> persistent?  My hunch is 
> not.   You're getting lucky that it worked with the true member 
> variable... had a different page been pulled from the pool you'd have 
> gotten null then too.
>
>     Erik
>
>
> On Feb 18, 2005, at 8:49 AM, matthew c. mead wrote:
>
>> I've been using the standard pattern for login to the application and 
>> building a login page that takes an ICallback, performs 
>> authentication, and then returns to the original page.
>>
>> If I make my member functions for the callback variable 
>> accessor/mutator abstract, define a property-specification for the 
>> property,  and let the enhancement handle implementing it all for me, 
>> the login page always gets a null value when I call getPageCallback() 
>> to make my callback.
>>
>> If I create a true member variable an member functions for the 
>> accessor/mutator, everything works ok.
>>
>> Is this a bug in the enhancement code or is it expected behavior?
>>
>> Thanks!
>>
>>
>>
>> -matt
>>
>> -- 
>> matthew c. mead
>>
>> http://www.goof.com/
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: tapestry-user-help@jakarta.apache.org
>

-- 
matthew c. mead

http://www.goof.com/

Re: bug in class enhancement?

Posted by Erik Hatcher <er...@ehatchersolutions.com>.
Did you make your <property-specification> persistent?  My hunch is 
not.   You're getting lucky that it worked with the true member 
variable... had a different page been pulled from the pool you'd have 
gotten null then too.

	Erik


On Feb 18, 2005, at 8:49 AM, matthew c. mead wrote:

> I've been using the standard pattern for login to the application and 
> building a login page that takes an ICallback, performs 
> authentication, and then returns to the original page.
>
> If I make my member functions for the callback variable 
> accessor/mutator abstract, define a property-specification for the 
> property,  and let the enhancement handle implementing it all for me, 
> the login page always gets a null value when I call getPageCallback() 
> to make my callback.
>
> If I create a true member variable an member functions for the 
> accessor/mutator, everything works ok.
>
> Is this a bug in the enhancement code or is it expected behavior?
>
> Thanks!
>
>
>
> -matt
>
> -- 
> matthew c. mead
>
> http://www.goof.com/


---------------------------------------------------------------------
To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tapestry-user-help@jakarta.apache.org


Re: bug in class enhancement?

Posted by "matthew c. mead" <m-...@goof.com>.
Aha!  Thanks!


-matt

Michal Maciejewski wrote:

> ICallback must be a *persitent* property
>
> Michal
>
> matthew c. mead wrote:
>
>> I've been using the standard pattern for login to the application and 
>> building a login page that takes an ICallback, performs 
>> authentication, and then returns to the original page.
>>
>> If I make my member functions for the callback variable 
>> accessor/mutator abstract, define a property-specification for the 
>> property,  and let the enhancement handle implementing it all for me, 
>> the login page always gets a null value when I call getPageCallback() 
>> to make my callback.
>>
>> If I create a true member variable an member functions for the 
>> accessor/mutator, everything works ok.
>>
>> Is this a bug in the enhancement code or is it expected behavior?
>>
>> Thanks!
>>
>>
>>
>> -matt
>>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: tapestry-user-help@jakarta.apache.org
>

-- 
matthew c. mead

http://www.goof.com/

Re: bug in class enhancement?

Posted by Michal Maciejewski <mi...@man.poznan.pl>.
ICallback must be a *persitent* property

Michal

matthew c. mead wrote:

> I've been using the standard pattern for login to the application and 
> building a login page that takes an ICallback, performs 
> authentication, and then returns to the original page.
>
> If I make my member functions for the callback variable 
> accessor/mutator abstract, define a property-specification for the 
> property,  and let the enhancement handle implementing it all for me, 
> the login page always gets a null value when I call getPageCallback() 
> to make my callback.
>
> If I create a true member variable an member functions for the 
> accessor/mutator, everything works ok.
>
> Is this a bug in the enhancement code or is it expected behavior?
>
> Thanks!
>
>
>
> -matt
>


---------------------------------------------------------------------
To unsubscribe, e-mail: tapestry-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tapestry-user-help@jakarta.apache.org