001 /*
002 * CDDL HEADER START
003 *
004 * The contents of this file are subject to the terms of the
005 * Common Development and Distribution License, Version 1.0 only
006 * (the "License"). You may not use this file except in compliance
007 * with the License.
008 *
009 * You can obtain a copy of the license at
010 * trunk/opends/resource/legal-notices/OpenDS.LICENSE
011 * or https://OpenDS.dev.java.net/OpenDS.LICENSE.
012 * See the License for the specific language governing permissions
013 * and limitations under the License.
014 *
015 * When distributing Covered Code, include this CDDL HEADER in each
016 * file and include the License file at
017 * trunk/opends/resource/legal-notices/OpenDS.LICENSE. If applicable,
018 * add the following below this CDDL HEADER, with the fields enclosed
019 * by brackets "[]" replaced with your own identifying information:
020 * Portions Copyright [yyyy] [name of copyright owner]
021 *
022 * CDDL HEADER END
023 *
024 *
025 * Copyright 2008 Sun Microsystems, Inc.
026 */
027 package org.opends.server.admin.std.client;
028
029
030
031 import java.util.Collection;
032 import java.util.SortedSet;
033 import org.opends.server.admin.IllegalPropertyValueException;
034 import org.opends.server.admin.ManagedObjectDefinition;
035 import org.opends.server.admin.std.meta.BackendCfgDefn.WritabilityMode;
036 import org.opends.server.admin.std.server.SchemaBackendCfg;
037 import org.opends.server.types.DN;
038
039
040
041 /**
042 * A client-side interface for reading and modifying Schema Backend
043 * settings.
044 * <p>
045 * The Schema Backend provides access to the Directory Server schema
046 * information, including the attribute types, object classes,
047 * attribute syntaxes, matching rules, matching rule uses, DIT content
048 * rules, and DIT structure rules that it contains.
049 */
050 public interface SchemaBackendCfgClient extends BackendCfgClient {
051
052 /**
053 * Get the configuration definition associated with this Schema Backend.
054 *
055 * @return Returns the configuration definition associated with this Schema Backend.
056 */
057 ManagedObjectDefinition<? extends SchemaBackendCfgClient, ? extends SchemaBackendCfg> definition();
058
059
060
061 /**
062 * Gets the "java-class" property.
063 * <p>
064 * Specifies the fully-qualified name of the Java class that
065 * provides the backend implementation.
066 *
067 * @return Returns the value of the "java-class" property.
068 */
069 String getJavaClass();
070
071
072
073 /**
074 * Sets the "java-class" property.
075 * <p>
076 * Specifies the fully-qualified name of the Java class that
077 * provides the backend implementation.
078 *
079 * @param value The value of the "java-class" property.
080 * @throws IllegalPropertyValueException
081 * If the new value is invalid.
082 */
083 void setJavaClass(String value) throws IllegalPropertyValueException;
084
085
086
087 /**
088 * Gets the "schema-entry-dn" property.
089 * <p>
090 * Defines the base DNs of the subtrees in which the schema
091 * information is published in addition to the value included in the
092 * base-dn property.
093 * <p>
094 * The value provided in the base-dn property is the only one that
095 * appears in the subschemaSubentry operational attribute of the
096 * server's root DSE (which is necessary because that is a
097 * single-valued attribute) and as a virtual attribute in other
098 * entries. The schema-entry-dn attribute may be used to make the
099 * schema information available in other locations to accommodate
100 * certain client applications that have been hard-coded to expect
101 * the schema to reside in a specific location.
102 *
103 * @return Returns the values of the "schema-entry-dn" property.
104 */
105 SortedSet<DN> getSchemaEntryDN();
106
107
108
109 /**
110 * Sets the "schema-entry-dn" property.
111 * <p>
112 * Defines the base DNs of the subtrees in which the schema
113 * information is published in addition to the value included in the
114 * base-dn property.
115 * <p>
116 * The value provided in the base-dn property is the only one that
117 * appears in the subschemaSubentry operational attribute of the
118 * server's root DSE (which is necessary because that is a
119 * single-valued attribute) and as a virtual attribute in other
120 * entries. The schema-entry-dn attribute may be used to make the
121 * schema information available in other locations to accommodate
122 * certain client applications that have been hard-coded to expect
123 * the schema to reside in a specific location.
124 *
125 * @param values The values of the "schema-entry-dn" property.
126 * @throws IllegalPropertyValueException
127 * If one or more of the new values are invalid.
128 */
129 void setSchemaEntryDN(Collection<DN> values) throws IllegalPropertyValueException;
130
131
132
133 /**
134 * Gets the "show-all-attributes" property.
135 * <p>
136 * Indicates whether to treat all attributes in the schema entry as
137 * if they were user attributes regardless of their configuration.
138 * <p>
139 * This may provide compatibility with some applications that expect
140 * schema attributes like attributeTypes and objectClasses to be
141 * included by default even if they are not requested. Note that the
142 * ldapSyntaxes attribute is always treated as operational in order
143 * to avoid problems with attempts to modify the schema over
144 * protocol.
145 *
146 * @return Returns the value of the "show-all-attributes" property.
147 */
148 Boolean isShowAllAttributes();
149
150
151
152 /**
153 * Sets the "show-all-attributes" property.
154 * <p>
155 * Indicates whether to treat all attributes in the schema entry as
156 * if they were user attributes regardless of their configuration.
157 * <p>
158 * This may provide compatibility with some applications that expect
159 * schema attributes like attributeTypes and objectClasses to be
160 * included by default even if they are not requested. Note that the
161 * ldapSyntaxes attribute is always treated as operational in order
162 * to avoid problems with attempts to modify the schema over
163 * protocol.
164 *
165 * @param value The value of the "show-all-attributes" property.
166 * @throws IllegalPropertyValueException
167 * If the new value is invalid.
168 */
169 void setShowAllAttributes(boolean value) throws IllegalPropertyValueException;
170
171
172
173 /**
174 * Gets the "writability-mode" property.
175 * <p>
176 * Specifies the behavior that the backend should use when
177 * processing write operations.
178 *
179 * @return Returns the value of the "writability-mode" property.
180 */
181 WritabilityMode getWritabilityMode();
182
183
184
185 /**
186 * Sets the "writability-mode" property.
187 * <p>
188 * Specifies the behavior that the backend should use when
189 * processing write operations.
190 *
191 * @param value The value of the "writability-mode" property.
192 * @throws IllegalPropertyValueException
193 * If the new value is invalid.
194 */
195 void setWritabilityMode(WritabilityMode value) throws IllegalPropertyValueException;
196
197 }