001/*
002 * The contents of this file are subject to the terms of the Common Development and
003 * Distribution License (the License). You may not use this file except in compliance with the
004 * License.
005 *
006 * You can obtain a copy of the License at legal/CDDLv1.0.txt. See the License for the
007 * specific language governing permission and limitations under the License.
008 *
009 * When distributing Covered Software, include this CDDL Header Notice in each file and include
010 * the License file at legal/CDDLv1.0.txt. If applicable, add the following below the CDDL
011 * Header, with the fields enclosed by brackets [] replaced by your own identifying
012 * information: "Portions Copyright [year] [name of copyright owner]".
013 *
014 * Copyright 2008 Sun Microsystems, Inc.
015 */
016package org.forgerock.opendj.server.config.server;
017
018
019
020import java.util.SortedSet;
021import org.forgerock.opendj.config.server.ConfigurationChangeListener;
022import org.forgerock.opendj.ldap.DN;
023import org.forgerock.opendj.ldap.schema.AttributeType;
024import org.forgerock.opendj.server.config.meta.PluginCfgDefn.PluginType;
025
026
027
028/**
029 * A server-side interface for querying Seven Bit Clean Plugin
030 * settings.
031 * <p>
032 * The Seven Bit Clean Plugin ensures that values for a specified set
033 * of attributes are 7-bit clean.
034 */
035public interface SevenBitCleanPluginCfg extends PluginCfg {
036
037  /**
038   * Gets the configuration class associated with this Seven Bit Clean Plugin.
039   *
040   * @return Returns the configuration class associated with this Seven Bit Clean Plugin.
041   */
042  Class<? extends SevenBitCleanPluginCfg> configurationClass();
043
044
045
046  /**
047   * Register to be notified when this Seven Bit Clean Plugin is changed.
048   *
049   * @param listener
050   *          The Seven Bit Clean Plugin configuration change listener.
051   */
052  void addSevenBitCleanChangeListener(ConfigurationChangeListener<SevenBitCleanPluginCfg> listener);
053
054
055
056  /**
057   * Deregister an existing Seven Bit Clean Plugin configuration change listener.
058   *
059   * @param listener
060   *          The Seven Bit Clean Plugin configuration change listener.
061   */
062  void removeSevenBitCleanChangeListener(ConfigurationChangeListener<SevenBitCleanPluginCfg> listener);
063
064
065
066  /**
067   * Gets the "attribute-type" property.
068   * <p>
069   * Specifies the name or OID of an attribute type for which values
070   * should be checked to ensure that they are 7-bit clean.
071   *
072   * @return Returns an unmodifiable set containing the values of the "attribute-type" property.
073   */
074  SortedSet<AttributeType> getAttributeType();
075
076
077
078  /**
079   * Gets the "base-dn" property.
080   * <p>
081   * Specifies the base DN below which the checking is performed.
082   * <p>
083   * Any attempt to update a value for one of the configured
084   * attributes below this base DN must be 7-bit clean for the
085   * operation to be allowed.
086   *
087   * @return Returns an unmodifiable set containing the values of the "base-dn" property.
088   */
089  SortedSet<DN> getBaseDN();
090
091
092
093  /**
094   * Gets the "java-class" property.
095   * <p>
096   * Specifies the fully-qualified name of the Java class that
097   * provides the plug-in implementation.
098   *
099   * @return Returns the value of the "java-class" property.
100   */
101  String getJavaClass();
102
103
104
105  /**
106   * Gets the "plugin-type" property.
107   * <p>
108   * Specifies the set of plug-in types for the plug-in, which
109   * specifies the times at which the plug-in is invoked.
110   *
111   * @return Returns an unmodifiable set containing the values of the "plugin-type" property.
112   */
113  SortedSet<PluginType> getPluginType();
114
115}