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.client; 027 028 029 030import java.util.Collection; 031import java.util.SortedSet; 032import org.opends.server.admin.ManagedObjectDefinition; 033import org.opends.server.admin.PropertyException; 034import org.opends.server.admin.std.meta.EntityTagVirtualAttributeCfgDefn.ChecksumAlgorithm; 035import org.opends.server.admin.std.meta.VirtualAttributeCfgDefn.ConflictBehavior; 036import org.opends.server.admin.std.server.EntityTagVirtualAttributeCfg; 037import org.opends.server.types.AttributeType; 038 039 040 041/** 042 * A client-side interface for reading and modifying Entity Tag 043 * Virtual Attribute settings. 044 * <p> 045 * The Entity Tag Virtual Attribute ensures that all entries contain 046 * an "entity tag" or "Etag" as defined in section 3.11 of RFC 2616. 047 */ 048public interface EntityTagVirtualAttributeCfgClient extends VirtualAttributeCfgClient { 049 050 /** 051 * Get the configuration definition associated with this Entity Tag Virtual Attribute. 052 * 053 * @return Returns the configuration definition associated with this Entity Tag Virtual Attribute. 054 */ 055 ManagedObjectDefinition<? extends EntityTagVirtualAttributeCfgClient, ? extends EntityTagVirtualAttributeCfg> definition(); 056 057 058 059 /** 060 * Gets the "attribute-type" property. 061 * <p> 062 * Specifies the attribute type for the attribute whose values are 063 * to be dynamically assigned by the virtual attribute. 064 * 065 * @return Returns the value of the "attribute-type" property. 066 */ 067 AttributeType getAttributeType(); 068 069 070 071 /** 072 * Sets the "attribute-type" property. 073 * <p> 074 * Specifies the attribute type for the attribute whose values are 075 * to be dynamically assigned by the virtual attribute. 076 * 077 * @param value The value of the "attribute-type" property. 078 * @throws PropertyException 079 * If the new value is invalid. 080 */ 081 void setAttributeType(AttributeType value) throws PropertyException; 082 083 084 085 /** 086 * Gets the "checksum-algorithm" property. 087 * <p> 088 * The algorithm which should be used for calculating the entity tag 089 * checksum value. 090 * 091 * @return Returns the value of the "checksum-algorithm" property. 092 */ 093 ChecksumAlgorithm getChecksumAlgorithm(); 094 095 096 097 /** 098 * Sets the "checksum-algorithm" property. 099 * <p> 100 * The algorithm which should be used for calculating the entity tag 101 * checksum value. 102 * 103 * @param value The value of the "checksum-algorithm" property. 104 * @throws PropertyException 105 * If the new value is invalid. 106 */ 107 void setChecksumAlgorithm(ChecksumAlgorithm value) throws PropertyException; 108 109 110 111 /** 112 * Gets the "conflict-behavior" property. 113 * <p> 114 * Specifies the behavior that the server is to exhibit for entries 115 * that already contain one or more real values for the associated 116 * attribute. 117 * 118 * @return Returns the value of the "conflict-behavior" property. 119 */ 120 ConflictBehavior getConflictBehavior(); 121 122 123 124 /** 125 * Sets the "conflict-behavior" property. 126 * <p> 127 * Specifies the behavior that the server is to exhibit for entries 128 * that already contain one or more real values for the associated 129 * attribute. 130 * 131 * @param value The value of the "conflict-behavior" property. 132 * @throws PropertyException 133 * If the new value is invalid. 134 */ 135 void setConflictBehavior(ConflictBehavior value) throws PropertyException; 136 137 138 139 /** 140 * Gets the "excluded-attribute" property. 141 * <p> 142 * The list of attributes which should be ignored when calculating 143 * the entity tag checksum value. 144 * <p> 145 * Certain attributes like "ds-sync-hist" may vary between replicas 146 * due to different purging schedules and should not be included in 147 * the checksum. 148 * 149 * @return Returns the values of the "excluded-attribute" property. 150 */ 151 SortedSet<AttributeType> getExcludedAttribute(); 152 153 154 155 /** 156 * Sets the "excluded-attribute" property. 157 * <p> 158 * The list of attributes which should be ignored when calculating 159 * the entity tag checksum value. 160 * <p> 161 * Certain attributes like "ds-sync-hist" may vary between replicas 162 * due to different purging schedules and should not be included in 163 * the checksum. 164 * 165 * @param values The values of the "excluded-attribute" property. 166 * @throws PropertyException 167 * If one or more of the new values are invalid. 168 */ 169 void setExcludedAttribute(Collection<AttributeType> values) throws PropertyException; 170 171 172 173 /** 174 * Gets the "java-class" property. 175 * <p> 176 * Specifies the fully-qualified name of the virtual attribute 177 * provider class that generates the attribute values. 178 * 179 * @return Returns the value of the "java-class" property. 180 */ 181 String getJavaClass(); 182 183 184 185 /** 186 * Sets the "java-class" property. 187 * <p> 188 * Specifies the fully-qualified name of the virtual attribute 189 * provider class that generates the attribute values. 190 * 191 * @param value The value of the "java-class" property. 192 * @throws PropertyException 193 * If the new value is invalid. 194 */ 195 void setJavaClass(String value) throws PropertyException; 196 197}