for now unfortunatelly we have only descriptions which placed at wiki and referenced from doc's page. And you could also check existent components. Kickstart for CDK - in progress for M1 and will be announced as far as some draft available for sure! thanks for your patience.
I'm carving my way through. My notes on working with CDK4 will be here : https://docs.google.com/Doc?docid=0AU_Xm4aXKuUrZGZobndrZndfMTBkZjVweHdndw&hl=en&authkey=CI617aML
This will be updated day by day. Comments and questions are welcome in this thread.
This is a great start to a document we really need!
Our plan is to create several wiki pages follow a similar concept. Specifically "How to checkout & build RichFaces 4.0", "Development Guidelines for RichFaces 4.0", and "Component Development with RichFaces 4.0 & the CDK".
If you are interested, and it seems like you are ;-) I think it would be great to work together on this, and get an outside perspective on areas that need updates, or that are clumsy.
I'm going to be busy at JBoss World this week, but will try to contact later in the week, or next, and I'll review. In the mean time I think it would be good to have Alex write up more of the basics with CDK.
How do I set tag namespace without faces-config.xml?
Can I mix faces-config.xml and annotations?
Why do you name some classes AbstractXXX? I see that there is AbstractAjaxFunction and it generates UIFunction. Is there no longer anything like HtmlFunction?
Why do we have renderer attribute in @JsfComponent since we have it also in template?
I have @Attribute annotated method returning Boolean (not boolean) named getIsRTL, which allows null. CDK generates getters using "isIsRTL" prefix, which causes generated class not to override all methods and what is more, it can throw nullpointers:
If state helper evaluates isRTL attribute to null then there should be no toString call !
I know that as a workaround I could pass defaultValue, but that is not flexible.
Sorry for a long delay, but I only got the time to pay attention for documentation after 4.0.Final release.
There are my points:
- build instructiona are outdated, I think it's not a part for CDK document.
- Jboss moved Maven repositories to the Nexus, urls were changed. Same for java.net.
- bom and parent are not necessary, you can use it to omit versions of JSF/RichFaces dependencies and plugins configuration. See cdk/maven-cdk-plugin/src/it projects for example.
- cdk reads constants COMPONENT_TYPE and COMPONENT_FAMILY from class, so you can skip them in annotation.
- you can use Java keywords as attribute names, it was fixed before CR2
- you can add custom dependencies where you wish. CDK relays on the standard Maven plugin only, so you free to organize your project as you wish.
- <h:scripts> substituted as @ResouceDependencies annotation.
- all scripts rendered by JSF, according to their target ( HEAD,FORM,BODY)
- If you use the single template with base class, put renderer type and base class to template. You can use annotations to assign the same template to different base class ( supposed for components like UIMessage/UIMessages )
- source locations readed form Maven pom.
- TagHandler generated if you have attribute with MethodExpression.
- listener tags generated for all events marked as @JsfEvent
- taglib namespace can be defined it faces-config extention or by package-level @Taglib
- Servlet and JSF detect mime type by file extension.
- to generate TagHandler for non-default caes, explicitly define it by @Tag attribute inside @JsfComponent, @JsfBehavior etc.
- ecss issue should be already fixed.
- clientId evaluation in JSF 2 performed my framevork, see JSF documentation.
- viewLocale evaluated on createView call.
Is there some kind of draft of the CDK4 guide? Or some hints (other than the Google doc nothes)?
A small HowTo in building own components and extending existing ones would be great. Thanks
more complete documents will be avilable really soon. Alex working on them hard.
he he.. you beat me Jay
Great. Any details about how long it will take?
Even if it the prediction is not accurate, it would help me. Just to know if it takes 1 day, 1 month or 1 year.
If I can help somehow (e.g. by testing) let me know. Thanks for the answer.
WIthin a month!
That would be AWESOME if you could review it and see if there are missing aspects. A new view point is always a good thing in that case!
At least I can try. Im am rather new to jsf and component libs, but this could also be a good test to see if a newbie understands the doc.
So let me know when you have a draft or something similar.
How can I use CDK4 without maven? To call the generate function?
Second, CDK supposed to use with any build tool - core project has no dependencies from Maven or other system. Unfortunately, I had no time to implement ANT task or something like Groul.
Watch for the wiki and blog for description how to run CDK.
The only thing that I hope to finish is running CDK as the Annotation Processor, to use it inside IDE or any Java compiler.