Hello. I am developing my first Jsf components.
I want to develop a table browser which should include a table, the
navigator, some fields to filter, a title, an icon, etc.
Of course, I would like to reuse the components from tomahawk.
As a proof of concept I have started developing a simple component, a
new HtmlLabelOutput which will render any text, with optional
style/styleClass if the "for" field is required.
I can easy develop it using a new component whit for new attributes
(requiredRendered, requiredStyle, requiredClass, requiredText) and a
custom render.
Once it works, I am trying to use a new way to do it, using component
composition.
In jsp, use something like this:
<t:outputLabel ...>
<h:outputText styleClass="[requiredClass]" style="[requiredStyle]"
value="[requiredText]" rendered="[requiredRendered]">
</t:outputLabel>
And what I want would be:
<my:outputLabel ... requiredClass="[requiredClass]"
requiredStyle="[requiredStyle]"
requiredText="[requiredText]"
requiredRendered="[requiredRendered]">
I remember this is a proof of concept, to understand (if it is possible)
how to make a composite component, so I would like using HtmlOutputText
in my component to render the text.
Is there a way to do something like this? I am playing a bit with it,
but results are not too good.