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 legal-notices/CDDLv1_0.txt 010 * or http://forgerock.org/license/CDDLv1.0.html. 011 * See the License for the specific language governing permissions 012 * and limitations under the License. 013 * 014 * When distributing Covered Code, include this CDDL HEADER in each 015 * file and include the License file at legal-notices/CDDLv1_0.txt. 016 * If applicable, add the following below this CDDL HEADER, with the 017 * fields enclosed by brackets "[]" replaced with your own identifying 018 * information: 019 * Portions Copyright [yyyy] [name of copyright owner] 020 * 021 * CDDL HEADER END 022 * 023 * 024 * Copyright 2008 Sun Microsystems, Inc. 025 */ 026package org.opends.server.admin.std.server; 027 028 029 030import org.opends.server.admin.server.ConfigurationChangeListener; 031import org.opends.server.admin.std.meta.VirtualAttributeCfgDefn.ConflictBehavior; 032 033 034 035/** 036 * A server-side interface for querying Member Virtual Attribute 037 * settings. 038 * <p> 039 * The Member Virtual Attribute generates a member or uniqueMember 040 * attribute whose values are the DNs of the members of a specified 041 * virtual static group. 042 */ 043public interface MemberVirtualAttributeCfg extends VirtualAttributeCfg { 044 045 /** 046 * Gets the configuration class associated with this Member Virtual Attribute. 047 * 048 * @return Returns the configuration class associated with this Member Virtual Attribute. 049 */ 050 Class<? extends MemberVirtualAttributeCfg> configurationClass(); 051 052 053 054 /** 055 * Register to be notified when this Member Virtual Attribute is changed. 056 * 057 * @param listener 058 * The Member Virtual Attribute configuration change listener. 059 */ 060 void addMemberChangeListener(ConfigurationChangeListener<MemberVirtualAttributeCfg> listener); 061 062 063 064 /** 065 * Deregister an existing Member Virtual Attribute configuration change listener. 066 * 067 * @param listener 068 * The Member Virtual Attribute configuration change listener. 069 */ 070 void removeMemberChangeListener(ConfigurationChangeListener<MemberVirtualAttributeCfg> listener); 071 072 073 074 /** 075 * Gets the "allow-retrieving-membership" property. 076 * <p> 077 * Indicates whether to handle requests that request all values for 078 * the virtual attribute. 079 * <p> 080 * This operation can be very expensive in some cases and is not 081 * consistent with the primary function of virtual static groups, 082 * which is to make it possible to use static group idioms to 083 * determine whether a given user is a member. If this attribute is 084 * set to false, attempts to retrieve the entire set of values 085 * receive an empty set, and only attempts to determine whether the 086 * attribute has a specific value or set of values (which is the 087 * primary anticipated use for virtual static groups) are handled 088 * properly. 089 * 090 * @return Returns the value of the "allow-retrieving-membership" property. 091 */ 092 boolean isAllowRetrievingMembership(); 093 094 095 096 /** 097 * Gets the "conflict-behavior" property. 098 * <p> 099 * Specifies the behavior that the server is to exhibit for entries 100 * that already contain one or more real values for the associated 101 * attribute. 102 * 103 * @return Returns the value of the "conflict-behavior" property. 104 */ 105 ConflictBehavior getConflictBehavior(); 106 107 108 109 /** 110 * Gets the "java-class" property. 111 * <p> 112 * Specifies the fully-qualified name of the virtual attribute 113 * provider class that generates the attribute values. 114 * 115 * @return Returns the value of the "java-class" property. 116 */ 117 String getJavaClass(); 118 119}