01: package com.icesoft.faces.facelets;
02:
03: import com.sun.facelets.tag.TagDecorator;
04: import com.sun.facelets.tag.Tag;
05:
06: /**
07: * @author Mark Collette
08: * @since 1.6
09: */
10: public class UIXhtmlTagDecorator implements TagDecorator {
11: public UIXhtmlTagDecorator() {
12: super ();
13: }
14:
15: /**
16: * @see TagDecorator#decorate(com.sun.facelets.tag.Tag)
17: */
18: public Tag decorate(Tag tag) {
19: //System.out.println("UIXhtmlTagDecorator.decorate() tag: " + tag + " tag-ns: " + tag.getNamespace());
20: if (tag.getNamespace() == null
21: || tag.getNamespace().length() == 0) {
22: Tag newTag = new Tag(tag.getLocation(),
23: UIXhtmlTagLibrary.NAMESPACE, tag.getLocalName(),
24: tag.getQName(), tag.getAttributes());
25: //System.out.println("UIXhtmlTagDecorator.decorate() newTag: " + newTag);
26: return newTag;
27: }
28: return null;
29: }
30: }
|