01: package org.obe.client.api.repository;
02:
03: import org.obe.client.api.tool.Parameter;
04: import org.obe.xpdl.model.data.ExternalReference;
05: import org.xml.sax.EntityResolver;
06:
07: /**
08: * Describes a W3C XForms user interface.
09: *
10: * @author Adrian Price
11: */
12: public final class XFormMetaData extends ToolAgentMetaData {
13: private static final long serialVersionUID = -4411143403128681197L;
14: private static final String IMPL_CLASS = "org.obe.runtime.tool.XForm";
15: private static final String[] IMPL_CTOR_SIG = {
16: XFormMetaData.class.getName(),
17: Parameter.class.getName() + "[]" };
18: private String _template; // The XForm template (or its name).
19: private boolean _file; // true if _template is a file name.
20:
21: public XFormMetaData() {
22: }
23:
24: public XFormMetaData(String id, String displayName,
25: String description, String docUrl, String author,
26: String template, boolean file) {
27:
28: super (id, displayName, description, docUrl, author, false);
29: _template = template;
30: _file = file;
31: }
32:
33: public String getTemplate() {
34: return _template != null ? _template : _type == null
35: || !allowInheritance ? null : ((XFormMetaData) _type)
36: .getTemplate();
37: }
38:
39: public void setTemplate(String template) {
40: _template = template;
41: }
42:
43: public boolean isFile() {
44: return _file;
45: }
46:
47: public boolean getFile() {
48: return _file;
49: }
50:
51: public void setFile(boolean file) {
52: _file = file;
53: }
54:
55: protected String getImplClass() {
56: return IMPL_CLASS;
57: }
58:
59: protected String[] getImplCtorSig() {
60: return IMPL_CTOR_SIG;
61: }
62:
63: public ToolAgentMetaData introspect(ExternalReference extRef,
64: EntityResolver entityResolver) {
65:
66: // There's no easy, reliable way to recognize an XForm reference.
67: return null;
68: }
69: }
|