Re: Custom Property Editor for String Array

2009-04-19 Thread Yancey Yeargan


For my application, I will need to allow users to enter their own  
(essentially random) e-mail addresses. The Palette component seems to  
require a pre-defined set of available options, which unfortunately  
does not meet my particular requirement. So I will continue work on my  
own custom property editor.


I discovered that the BeanEditForm guide page almost completely  
neglects to discuss PropertyEditContext objects, knowledge of which  
seem rather critical to fully understanding how to create a custom  
property editor. I found some discussion of PropertyEditContext at the  
following wiki topic.


http://wiki.apache.org/tapestry/Tapestry5HowToCreateAPropertyEditBlock

I believe I now have the general idea and will start working out the  
details by experimenting in code.I may yet have questions, but at  
least I know where I'm headed now.  Many thanks for pointing me in the  
correct direction.


Yancey




On Apr 18, 2009, at 9:27 PM, Thiago H. de Paula Figueiredo wrote:


Em Sat, 18 Apr 2009 16:48:03 -0300, Yeargan Yancey yan...@unt.edu
escreveu:


Before I go banging my head against a wall for too long, is it
possible to create a custom property editor to handle a complex  
(multi-

valued) property?


Yes! :) There's a guide here:
http://tapestry.apache.org/tapestry5/guide/beaneditform.html. If it  
is not

enough, post yourr doubts here and we'll try to help you. ;)


I am working with a directory services database via LDAP and it would
be extremely helpful if I can mange to enhance BeanEditForm and
BeanDisplay to handle LDAP entries where a property (LDAP attribute)
may have multiple values.

To be more specific, I want to create a property editor for the
String[] type. At the moment, I just want to display String[]
properties using the BeanDisplay component, but I can already foresee
a need to be able to fully edit a String[] property (including
adding / removing values from the array, using AJAX to add/remove
fields to the form).


Have you taken a look at the Palette component? It looks like it it
already implements what you need:
http://tapestry.apache.org/tapestry5/tapestry-core/ref/org/apache/tapestry5/corelib/components/Palette.html 
.

It, together with a custom DataTypeAnalyzer, one view block (for
BeanDisplay) and one edit block (for BeanEditForm/BeanEditor). The
BeanEditForm guide previously mentioned tells you how to do it.

--
Thiago H. de Paula Figueiredo
Independent Java consultant, developer, and instructor
http://www.arsmachina.com.br/thiago

-
To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org
For additional commands, e-mail: users-h...@tapestry.apache.org





smime.p7s
Description: S/MIME cryptographic signature


Re: 301 moved permanently

2009-04-17 Thread Yancey Yeargan


Take a look at the Timing filter in the default maven archetype.

Yancey


On Apr 17, 2009, at 8:08 AM, Davor Miku wrote:


Can you give me some example, please?



smime.p7s
Description: S/MIME cryptographic signature


Re: t:body

2009-03-31 Thread Yancey Yeargan


Tapestry 5.1 does handle this correctly. I checked by changing  
t:body/ to t:Body/ within the Layout.tml template of the  
quickstart example project and it worked as expected.


Yancey



On Mar 31, 2009, at 1:57 PM, Howard Lewis Ship wrote:


Please add a bug; Tapestry should not be case sensitive about this
(regardless about what the schema says). t:body and t:Body should be
equivalent.  Tapestry 5.1 may already do this correctly.

On Mon, Mar 30, 2009 at 9:28 AM, Luther Baker  
lutherba...@gmail.com wrote:
For some reason, my brain likes to keep a consistent capitalization  
strategy

...

So, I've grown accustomed to

t:Parameter
t:ActionLink
t:PageLink

and home/Index.tml, home/Index.java ... etc

I just noticed that in my latest new project, I used t:Body/ in a  
layout

template and I'm getting an error:

Exception assembling root component of page home/Index: Unable to  
resolve
'Body' to a component class name. Available component types:  
ActionLink,

AddRowLink, AjaxFormLoop, Any, BeanDisplay, BeanEditForm, BeanEditor,
Checkbox, DateField, Delegate, Errors, EventLink, ExceptionDisplay,  
Form,

FormFragment, FormInjector, Grid, GridCell, GridColumns, GridPager,
GridRows, If, Label, Layout, LinkSubmit, Loop, Output, OutputRaw,  
PageLink,
Palette, PasswordField, ProgressiveDisplay, PropertyDisplay,  
PropertyEditor,

Radio, RadioGroup, RemoveRowLink, RenderObject, Select, Submit,
SubmitNotifier, TextArea, TextField, TextOutput, Unless, Zone.

If I switch to t:body/ ... all is well.

Just thought this was interesting.

-Luther





--
Howard M. Lewis Ship

Creator Apache Tapestry and Apache HiveMind

-
To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org
For additional commands, e-mail: users-h...@tapestry.apache.org




-
To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org
For additional commands, e-mail: users-h...@tapestry.apache.org