Reputation: 6936
I am developing a Java Control using this tutorial. For it I need to create MyJavaControl.xsp-config
and edit it. This link details out the file format of xsp-config
file and its various tags.
I would like to know is there a complete DTD available anywhere for xsp-config
file? The reason I need the DTD is so that I can include in DOCTYPE
of XML giving content assist in Domino Designer.
Upvotes: 1
Views: 208
Reputation: 6936
I created a DTD using the definitions given in XPages configuration file format. The DTD is NOT complete and would have incomplete elements for sure. If you come across any feel free to edit the answer or leave a comment.
<!ELEMENT faces-config ((application | factory | component | converter | managed-bean | navigation-rule | referenced-bean | render-kit | lifecycle | validator | complex-type | composite-component | group | faces-config-extension )*)>
<!ELEMENT faces-config-extension ANY>
<!ELEMENT component (description*, display-name*, icon*, component-type, component-class, facet*, group-type-ref*, attribute*, property*, component-extension*)>
<!ELEMENT component-extension ANY>
<!ELEMENT facet (description*, display-name*, icon*, facet-name, facet-extension*)>
<!ELEMENT facet-extension ANY>
<!ELEMENT base-component-type (#PCDATA)>
<!ELEMENT component-class (#PCDATA)>
<!ELEMENT component-type (#PCDATA)>
<!ELEMENT group-type-ref (#PCDATA)>
<!ELEMENT tag-name (#PCDATA)>
<!ELEMENT property (description*, display-name*, icon*, property-name, property-class, default-value?, suggested-value?, property-extension*)>
<!ELEMENT property-extension ANY>
<!ELEMENT attribute (description*, display-name*, icon*, attribute-name, attribute-class, default-value?, suggested-value?, attribute-extension*)>
<!ELEMENT attribute-extension ANY>
<!ELEMENT allow-load-time-binding (#PCDATA)>
<!ELEMENT allow-non-binding (#PCDATA)>
<!ELEMENT allow-run-time-binding (#PCDATA)>
<!ELEMENT collection-property (#PCDATA)>
<!ELEMENT container-class (#PCDATA)>
<!ELEMENT localizable (#PCDATA)>
<!ELEMENT method-binding-property (#PCDATA)>
<!ELEMENT method-param (method-param-name, method-param-class) >
<!ELEMENT method-param-name (#PCDATA)>
<!ELEMENT method-param-class (#PCDATA)>
<!ELEMENT method-return-type (#PCDATA)>
<!ELEMENT property-add-method (#PCDATA)>
<!ELEMENT property-class (#PCDATA)>
<!ELEMENT property-item-class (#PCDATA)>
<!ELEMENT property-name (#PCDATA)>
<!ELEMENT required (#PCDATA)>
<!ELEMENT tag-attribute (#PCDATA)>
<!ELEMENT complex-type (description*, display-name*, icon*, complex-id, complex-class, group-type-ref*, property*, complex-extension*)>
<!ELEMENT complex-extension ANY>
<!ELEMENT converter (description*, display-name*, icon*, (converter-id | converter-for-class), converter-class, group-type-ref*, attribute*, property*, converter-extension*)>
<!ELEMENT converter-extension ANY>
<!ELEMENT validator (description*, display-name*, icon*, validator-id, validator-class, group-type-ref*, attribute*, property*, validator-extension*)>
<!ELEMENT validator-extension ANY>
<!ELEMENT base-complex-id (#PCDATA)>
<!ELEMENT base-converter-id (#PCDATA)>
<!ELEMENT base-validator-id (#PCDATA)>
<!ELEMENT complex-class (#PCDATA)>
<!ELEMENT complex-id (#PCDATA)>
<!ELEMENT converter-id (#PCDATA)>
<!ELEMENT default-property (#PCDATA)>
<!ELEMENT validator-id (#PCDATA)>
<!ELEMENT composite-component (description*, display-name*, icon*, component-type, composite-name, composite-file, facet*, group-type-ref*, attribute*, property*, property-type*, composite-extension*)>
<!ELEMENT composite-extension ANY>
<!ELEMENT property-type (description*, display-name*, icon*, property-name, property*, property-type*, property-extension*)>
<!ELEMENT group (description*, display-name*, icon*, group-type, group-type-ref*, property*, group-extension*)>
<!ELEMENT group-extension ANY>
<!ELEMENT render-kit (description*, display-name*, icon*, render-kit-id?, render-kit-class?, renderer*, render-kit-extension?)>
<!ELEMENT render-kit-extension ANY>
<!ELEMENT renderer (description*, display-name*, icon*, component-family, renderer-type, renderer-class, facet*, attribute*, renderer-extension*)>
<!ELEMENT renderer-extension ANY>
<!ELEMENT base-render-kit-id (#PCDATA)>
<!ELEMENT component-family (#PCDATA)>
<!ELEMENT composite-file (#PCDATA)>
<!ELEMENT composite-name (#PCDATA)>
<!ELEMENT group-type (#PCDATA)>
<!ELEMENT render-kit-alias (#PCDATA)>
<!ELEMENT renderer-type (#PCDATA)>
<!ELEMENT icon (small-icon?, large-icon?)>
<!ELEMENT small-icon (#PCDATA)>
<!ELEMENT large-icon (#PCDATA)>
<!-- Added 8 July 2013 -->
<!ELEMENT designer-extension (category, selected-event, event, visible, subcategory, in-palette, generate-id, render-markup, is-deprecated)>
<!ELEMENT category (#PCDATA)>
<!ELEMENT selected-event (#PCDATA)>
<!ELEMENT event (#PCDATA)>
<!ELEMENT visible (true|false)>
<!ELEMENT subcategory (#PCDATA)>
<!ELEMENT in-palette (true|false)>
<!ELEMENT generate-id (true|false)>
<!ELEMENT render-markup (#PCDATA)>
<!ELEMENT is-deprecated (true|false)>
Save the above code in a DTD file and include it in your xsp-config
using below code:
<!DOCTYPE faces-config PUBLIC
"-//Sun Microsystems, Inc.//DTD JavaServer Faces Config 1.0//EN"
"D:\DTDs\xspconfig.dtd">
Upvotes: 0
Reputation: 740
According to http://www-10.lotus.com/ldd/ddwiki.nsf/dx/XPages_configuration_file_format the xsp-config format is based on JSF's existing faces-config format. So, you can use http://java.sun.com/dtd/web-facesconfig_1_1.dtd for validation.
If you create your components, but don't want to have them visible in Domino Designer controls palette, then you should be safe to use JSF 1.1 DTD
Upvotes: 1