01: /*
02: * Copyright 2006 Day Management AG, Switzerland. All rights reserved.
03: */
04: package javax.jcr.nodetype;
05:
06: /**
07: * The <code>NodeDefinitionTemplate</code> interface extends
08: * <code>NodeDefinition</code> with the addition of write methods, enabling the
09: * characteristics of a child node definition to be set, after which the
10: * <code>NodeDefinitionTemplate</code> is added to a <code>NodeTypeTemplate</code>.
11: * <p/>
12: * See the corresponding <code>get<code/> methods for each attribute in
13: * <code>NodeDefinition</code> for the default values assumed when a new empty
14: * <code>NodeDefinitionTemplate</code> is created (as opposed to one extracted
15: * from an existing <code>NodeType</code>).
16: *
17: * @since JCR 2.0
18: */
19: public interface NodeDefinitionTemplate extends NodeDefinition {
20:
21: /**
22: * Sets the name of the node.
23: *
24: * @param name a <code>String</code>.
25: */
26: public void setName(String name);
27:
28: /**
29: * Sets the auto-create status of the node.
30: *
31: * @param autoCreated a <code>boolean</code>.
32: */
33: public void setAutoCreated(boolean autoCreated);
34:
35: /**
36: * Sets the mandatory status of the node.
37: *
38: * @param mandatory a <code>boolean</code>.
39: */
40: public void setMandatory(boolean mandatory);
41:
42: /**
43: * Sets the on-parent-version status of the node.
44: *
45: * @param opv an <code>int</code> constant member of <code>OnParentVersionAction</code>.
46: */
47: public void setOnParentVersion(int opv);
48:
49: /**
50: * Sets the protected status of the node.
51: *
52: * @param protectedStatus a <code>boolean</code>.
53: */
54: public void setProtected(boolean protectedStatus);
55:
56: /**
57: * Sets the required primary types of this node.
58: *
59: * @param requiredPrimaryTypes a <code>String</code> array.
60: */
61: public void setRequiredPrimaryTypes(String[] requiredPrimaryTypes);
62:
63: /**
64: * Sets the default primary type of this node.
65: *
66: * @param defaultPrimaryType a <code>String</code>.
67: */
68: public void setDefaultPrimaryType(String defaultPrimaryType);
69:
70: /**
71: * Sets the same-name sibling status of this node.
72: *
73: * @param allowSameNameSiblings a <code>boolean</code>.
74: */
75: public void setSameNameSiblings(boolean allowSameNameSiblings);
76: }
|