Looking at it again, I don't need to extend TreeTag. I do need the values 
returned by 
TreeTag.getComponentType() and TreeTag.getRendererType(). Then I have to 
specify the 
component and renderer in my app's faces-config.xml:

  <component>
    <component-type>org.apache.myfaces.HtmlTree2</component-type>
    <component-class>org.objectsource.ui.UITree</component-class>
  </component>
  .
  .
  .
  <renderer>
    <component-family>org.apache.myfaces.HtmlTree2</component-family>
    <renderer-type>org.apache.myfaces.HtmlTree2</renderer-type>
    
<renderer-class>org.apache.myfaces.custom.tree2.HtmlTreeRenderer</renderer-class>
  </renderer>

Although the renderer descriptor is verbatim from the myfaces faces-config.xml 
when I 
didn't have it in my app's faces-config.xml nothing was rendered.


--
Rob

@objectsource.org

>I'm not sure that you need to subclass TreeTag.  Are you referring to
>the getComponentType and getRendererType methods?  Those just return
>the value of
>org.apache.myfaces.HtmlTree2.  You should be able to map a different
>component/renderer combination through your own faces-config.xml.

>sean

On Wed, 30 Mar 2005 15:47:54 -0500, Rob Decker <[EMAIL PROTECTED]> wrote:
>> I'm trying to extend the HtmlTree class of Tree2. It seems to me that at a 
>> minimum I
>> also have to to extend TreeTag so my subclass is associated with the tag in 
>> the jsp
>> page. Since I'm not changing the tag definition at all, is there a way to
>> specify "extends from" in a tld? I notice that myfaces uses shared 
>> attributes. Is
>> there some similar mechanism available for extending tags?
>> 
>> --
>> Rob
>> 
>> @objectsource.org
>> 
>>

Reply via email to