1/*2 * Licensed to the Apache Software Foundation (ASF) under one or more3 * contributor license agreements. See the NOTICE file distributed with4 * this work for additional information regarding copyright ownership.5 * The ASF licenses this file to You under the Apache License, Version 2.06 * (the "License"); you may not use this file except in compliance with7 * the License. You may obtain a copy of the License at8 *9 * http://www.apache.org/licenses/LICENSE-2.010 *11 * Unless required by applicable law or agreed to in writing, software12 * distributed under the License is distributed on an "AS IS" BASIS,13 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.14 * See the License for the specific language governing permissions and15 * limitations under the License.16 */17packageorg.apache.jetspeed.security.spi.impl.ldap;
1819import java.security.Principal;
2021import org.apache.jetspeed.security.SecurityException;
2223/***24 * <p>25 * Generic DAO interface for LDAP principals.26 * </p>27 * 28 * @author <a href="mailto:mike.long@dataline.com">Mike Long </a>, <a29 * href="mailto:dlestrat@apache.org">David Le Strat</a>30 */31publicinterfaceLdapPrincipalDaoextendsLdapReadOnlyPrincipalDao32 {
33/***34 * <p>35 * Makes a new ldap entry for the specified principal.36 * </p>37 * 38 * @param principalUid The principal uid.39 * @throws SecurityException Throws a {@link SecurityException}.40 */41abstractvoid create(final String principalUid) throws SecurityException;
4243/***44 * <p>45 * Deletes a ldap entry for the specified principal.46 * </p>47 * 48 * @param principalUid The principal uid.49 * @throws SecurityException Throws a {@link SecurityException}.50 */51abstractvoid delete(final String principalUid) throws SecurityException;
5253/***54 * <p>55 * Search the ldap directory for the principal.56 * </p>57 * 58 * @param principalUid The uid value of the principal.59 * @param principalType The type of principal.60 * @return All the objects of this LDAP class type.61 */62 Principal[] find(final String principalUid, String principalType) throws SecurityException;
6364/***65 * <p>66 * Converts the uid to an ldap acceptable name.67 * </p>68 * 69 * @param uid The uid.70 * @return The converted name.71 */72 String convertUidToLdapAcceptableName(String uid);
73 }