001/** 002 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS HEADER. 003 * 004 * Copyright (c) 2005 Sun Microsystems Inc. All Rights Reserved 005 * 006 * The contents of this file are subject to the terms 007 * of the Common Development and Distribution License 008 * (the License). You may not use this file except in 009 * compliance with the License. 010 * 011 * You can obtain a copy of the License at 012 * https://opensso.dev.java.net/public/CDDLv1.0.html or 013 * opensso/legal/CDDLv1.0.txt 014 * See the License for the specific language governing 015 * permission and limitations under the License. 016 * 017 * When distributing Covered Code, include this CDDL 018 * Header Notice in each file and include the License file 019 * at opensso/legal/CDDLv1.0.txt. 020 * If applicable, add the following below the CDDL Header, 021 * with the fields enclosed by brackets [] replaced by 022 * your own identifying information: 023 * "Portions Copyrighted [year] [name of copyright owner]" 024 * 025 * $Id: ServiceListener.java,v 1.5 2009/01/28 05:35:03 ww203982 Exp $ 026 * 027 */ 028 029package com.sun.identity.sm; 030 031import com.sun.identity.shared.ldap.controls.LDAPPersistSearchControl; 032 033/** 034 * The interface <code>ServiceListener</code> needs to be implemented by 035 * applications in order to receive service data change notifications. The 036 * method <code>schemaChanged()</code> is invoked when a service schema data 037 * has been changed. The method <code>globalConfigChanged()</code> and 038 * <code>organizationConfigChanged()</code> are invoked when the service 039 * configuration data has been changed. 040 * 041 * @supported.all.api 042 */ 043public interface ServiceListener { 044 045 /** 046 * The change type specifies that the entry has been added. 047 */ 048 public static final int ADDED = LDAPPersistSearchControl.ADD; 049 050 /** 051 * The change type specifies that the entry has been removed. 052 */ 053 public static final int REMOVED = LDAPPersistSearchControl.DELETE; 054 055 /** 056 * The change type specifies that the entry has been modified. 057 */ 058 public static final int MODIFIED = LDAPPersistSearchControl.MODIFY; 059 060 /** 061 * This method will be invoked when a service's schema has been changed. 062 * 063 * @param serviceName 064 * name of the service 065 * @param version 066 * version of the service 067 */ 068 public void schemaChanged(String serviceName, String version); 069 070 /** 071 * This method will be invoked when a service's global configuration data 072 * has been changed. The parameter <code>groupName</code> denote the name 073 * of the configuration grouping (e.g. default) and 074 * <code>serviceComponent</code> denotes the service's sub-component that 075 * changed (e.g. <code>/NamedPolicy</code>, <code>/Templates</code>). 076 * 077 * @param serviceName 078 * name of the service. 079 * @param version 080 * version of the service. 081 * @param groupName 082 * name of the configuration grouping. 083 * @param serviceComponent 084 * name of the service components that changed. 085 * @param type 086 * change type, i.e., ADDED, REMOVED or MODIFIED. 087 */ 088 public void globalConfigChanged(String serviceName, String version, 089 String groupName, String serviceComponent, int type); 090 091 /** 092 * This method will be invoked when a service's organization configuration 093 * data has been changed. The parameters <code>orgName</code>, 094 * <code>groupName</code> and <code>serviceComponent</code> denotes the 095 * organization name, configuration grouping name and service's 096 * sub-component that are changed respectively. 097 * 098 * @param serviceName 099 * name of the service 100 * @param version 101 * version of the service 102 * @param orgName 103 * organization name as DN 104 * @param groupName 105 * name of the configuration grouping 106 * @param serviceComponent 107 * the name of the service components that changed 108 * @param type 109 * change type, i.e., ADDED, REMOVED or MODIFIED 110 */ 111 public void organizationConfigChanged(String serviceName, String version, 112 String orgName, String groupName, String serviceComponent, 113 int type); 114}
Copyright © 2010-2017, ForgeRock All Rights Reserved.