Gary,

that looks similar to that what Hans Bergsten described
in his book / article regarding XML file and custom ViewHandler

article is online:
http://www.onjava.com/pub/a/onjava/2004/06/09/jsf.html
(second page contains that issue)

-Matthias

> -----Original Message-----
> From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] 
> Sent: Friday, January 21, 2005 4:43 PM
> To: Struts Developers List
> Subject: Re: WML RenderKit (was RE: Adding mobile tags to 
> Struts Faces)
> 
> 
> I guess that this is slightly off the subject but I've 
> noticed that many of the features that Shale promises to 
> offer are related to infrastructure.  I would like to present 
> an idea to see if there is any interest.  It is something 
> that I've been playing with.  I wish I could say that it was 
> original but it is similar to nonjsp example that comes with 
> the faces sdk.  The big difference is that reads the 
> definitions at startup so inheritance can be resolved. Please 
> consider:
> 
> <f:view>
>       <BODY>
>          <P>Place content here.</P>
>          <h:form id="xform">
>             <sh:xsubview elementId="addressPanel"/>   
>          </h:form>
>       </BODY>
> </f:view>
> 
> 
> <?xml version="1.0" encoding="UTF-8"?>
> <view>
>   <displayElement elementId="outputText" 
> componentType="javax.faces.HtmlOutputText"/>
>   <displayElement elementId="inputText" 
> componentType="javax.faces.HtmlInputText"/>
>   <displayElement elementId="outputLabel" 
> componentType="javax.faces.HtmlOutputLabel"/>
>   <displayElement elementId="outputFormat" 
> componentType="javax.faces.HtmlOutputFormat"/>
>   <displayElement elementId="commandButton" 
> componentType="javax.faces.HtmlCommandButton"/>
>   <displayElement elementId="panelGrid" 
> componentType="javax.faces.HtmlPanelGrid" />
> 
>   <displayElement elementId="cityStateZipPanel" extends="panelGrid">
>     <attributes>
>       <set name="columns" value="4" />
>     </attributes>
> 
>     <element renderId="1" elementId="outputLabel"> 
>       <attributes>
>         <set name="value" value="City/State/Zip:" />          
>       </attributes>
>     </element>                                
>     <element renderId="2" elementId="inputText"> 
>       <attributes>
>        <set name="value" value="#{address.city}" />           
>        <set name="size" value="2" />
>       </attributes>
>     </element>
>     <element renderId="3" elementId="inputText"> 
>       <attributes>
>          <set name="value" value="#{address.state}" />
>          <set name="maxlength" value="2" />
>          <set name="size" value="2" />
>       </attributes>
>     </element>
>     <element renderId="4" elementId="inputText"> 
>        <attributes>
>          <set name="value" value="#{address.zip}" />
>        <set name="maxlength" value="9" />
>        <set name="size" value="5" />
>        </attributes>
>     </element>
>   </displayElement>
> 
>               
>   <displayElement elementId="streetInput" extends="inputText">
>     <attributes>
>       <set name="size" value="35" />
>       <set name="maxlength" value="50" />
>     </attributes>
>   </displayElement>
>       
>   <displayElement elementId="address12Panel" extends="panelGrid">
>     <attributes>
>       <set name="columns" value="2" />
>     </attributes>
> 
>     <element renderId="1" elementId="outputLabel"> 
>       <attributes>
>         <set name="value" value="Address 1:" />               
>       </attributes>
>     </element>                                
>     <element renderId="2" elementId="streetInput"> 
>        <attributes>
>          <set name="value" value="#{address.address1}" />             
>        </attributes>
>     </element>
>     <element renderId="3" elementId="outputLabel"> 
>       <attributes>
>         <set name="value" value="Address 2:" />               
>       </attributes>
>       </element>                              
>       <element renderId="4" elementId="streetInput"> 
>         <attributes>
>           <set name="value" value="#{address.address2}" />            
>         </attributes>
>       </element>
> 
>   </displayElement>
>       
>   <displayElement elementId="addressPanel" extends="panelGrid">
>     <attributes>
>        <set name="columns" value="1" />
>     </attributes>
> 
>    <element renderId="1" elementId="address12Panel"/> 
>    <element renderId="2" elementId="cityStateZipPanel"/> 
>               
>    <element renderId="3" elementId="commandButton"> 
>       <attributes>
>         <set name="value" value="Save" />             
>         <set name="action" isLateBinding="true" 
> value="#{address.save}"  />           
>       </attributes>
>    </element>
>                                       
>   </displayElement>                           
>               
> </view>
> 
> Sorry for the length but I wanted to give a big enough sample 
> to show the potential reuse.  I was thinking that this might 
> work well with ViewController binding in Shale.  A 
> substitution layer could be put on top of the expression 
> language to get even more reuse of visual components used 
> across multiple pages.
> 
> <set name="action" isLateBinding="true" 
> value="[EMAIL PROTECTED]"  /> 
> 
> It might be too brittle.  This seems to work well with tags 
> that have corresponding components.  I am not sure how the 
> converters, validators, resource bundles and some of the 
> other core tags fit into something like this.  
>   
> 
> Gary  
> 
> 
> > Michael,
> > 
> > sure this thread is old, but I just remember
> > by reading your Shale post :)
> > 
> > However, a WML RenderKit is now available in Apache
> > MyFaces.
> > 
> > Perhaps you'll take a look at it.
> > TLD:
> > http://incubator.apache.org/myfaces/tlddoc/
> > 
> > files incl. examlpe: 
> > http://cvs.apache.org/dist/incubator/myfaces/builds/
> > 
> > Regards,
> > Matthias
> > 
> > > -----Original Message-----
> > > From: Michael Rassmussen [mailto:[EMAIL PROTECTED]
> > > Sent: Tuesday, July 06, 2004 3:33 PM
> > > To: Struts Developers List
> > > Subject: Re: Adding mobile tags to Struts Faces
> > > 
> > > 
> > > I am not...but I would like to in the near future.
> > > 
> > > On Tue, 6 Jul 2004 07:41:56 +0200, Matthias Wessendorf
> > > <[EMAIL PROTECTED]> wrote:
> > > > Michael,
> > > > 
> > > > are you working on a WML-RenderKit ?
> > > > 
> > > > perhaps you can add this feature to MyFaces?
> > > > (www.myfaces.org)
> > > > 
> > > > it is now under Apache2.0-license,
> > > > since its incubation to apache
> > > > (http://wiki.apache.org/incubator/MyFacesProposal)
> > > > 
> > > > cheers,
> > > > 
> > > > 
> > > > 
> > > > > -----Original Message-----
> > > > > From: Craig McClanahan [mailto:[EMAIL PROTECTED]
> > > > > Sent: Tuesday, July 06, 2004 2:40 AM
> > > > > To: Struts Developers List
> > > > > Subject: Re: Adding mobile tags to Struts Faces
> > > > >
> > > > >
> > > > > Michael Rasmussen wrote:
> > > > >
> > > > > >Sorry if this comes thru as an HTML post.  This is my first
> > > > > post to the
> > > > > >list.  Let me know if it is a problem.
> > > > > >
> > > > > >I have been using struts for a while now and really 
> like it.  I
> > > > > >have also used asp.net and really like some of the 
> features in
> > > > > the ms framework.
> > > > > >
> > > > > >I am excited at the prospect of JSF bringing these 
> features to
> > > > > >JSP/Java. One thing I really think is missing is support 
> > > for mobile
> > > > > >profiles.  (Cell
> > > > > >phones/wap/pda's) I think struts faces would be a great
> > > > > place to try to put
> > > > > >some of that together.  I am interested in doing this and
> > > > > wondering how to
> > > > > >go about getting set up and if there are others
> > > interested. Michael
> > > > > >
> > > > > 
> > > 
> >-------------------------------------------------------------------
> > > > > >--
> > > > > >To unsubscribe, e-mail: 
> [EMAIL PROTECTED] For 
> > > > > >additional commands, e-mail: [EMAIL PROTECTED]
> > > > > >
> > > > > >
> > > > > Michael,
> > > > >
> > > > > This response is very late (I've been too busy for words
> > > lately).
> > > > > But I would recommend that mobile profiles as you 
> describe would 
> > > > > make a good candidate for a stand-alone library of pure 
> > > > > JavaServer Faces components
> > > > > and renderers ... they need not be tied to Struts, as they
> > > > > would be if
> > > > > included in struts-faces directly.  The only thing that 
> > > should be in
> > > > > struts-faces (IMHO) is bindings to tie the two frameworks 
> > > > > together, plus a few tags to make the transition easier for 
> > > > > existing Struts based apps
> > > > > -- and one could easily argue that even those should be
> > > > > separated from
> > > > > the core integration library.
> > > > >
> > > > > Craig McClanahan
> > > > >
> > > > >
> > > > > 
> > > 
> --------------------------------------------------------------------
> > > > > -
> > > > > 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]
> > > 
> > 
> > 
> > 
> ---------------------------------------------------------------------
> > 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]

Reply via email to