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.client; 017 018 019 020import java.util.Collection; 021import java.util.SortedSet; 022import org.forgerock.opendj.config.ManagedObjectDefinition; 023import org.forgerock.opendj.config.PropertyException; 024import org.forgerock.opendj.server.config.meta.ErrorLogPublisherCfgDefn.DefaultSeverity; 025import org.forgerock.opendj.server.config.server.ErrorLogPublisherCfg; 026 027 028 029/** 030 * A client-side interface for reading and modifying Error Log 031 * Publisher settings. 032 * <p> 033 * Error Log Publishers are responsible for distributing error log 034 * messages from the error logger to a destination. 035 */ 036public interface ErrorLogPublisherCfgClient extends LogPublisherCfgClient { 037 038 /** 039 * Get the configuration definition associated with this Error Log Publisher. 040 * 041 * @return Returns the configuration definition associated with this Error Log Publisher. 042 */ 043 ManagedObjectDefinition<? extends ErrorLogPublisherCfgClient, ? extends ErrorLogPublisherCfg> definition(); 044 045 046 047 /** 048 * Gets the "default-severity" property. 049 * <p> 050 * Specifies the default severity levels for the logger. 051 * 052 * @return Returns the values of the "default-severity" property. 053 */ 054 SortedSet<DefaultSeverity> getDefaultSeverity(); 055 056 057 058 /** 059 * Sets the "default-severity" property. 060 * <p> 061 * Specifies the default severity levels for the logger. 062 * 063 * @param values The values of the "default-severity" property. 064 * @throws PropertyException 065 * If one or more of the new values are invalid. 066 */ 067 void setDefaultSeverity(Collection<DefaultSeverity> values) throws PropertyException; 068 069 070 071 /** 072 * Gets the "java-class" property. 073 * <p> 074 * The fully-qualified name of the Java class that provides the 075 * Error Log Publisher implementation. 076 * 077 * @return Returns the value of the "java-class" property. 078 */ 079 String getJavaClass(); 080 081 082 083 /** 084 * Sets the "java-class" property. 085 * <p> 086 * The fully-qualified name of the Java class that provides the 087 * Error Log Publisher implementation. 088 * 089 * @param value The value of the "java-class" property. 090 * @throws PropertyException 091 * If the new value is invalid. 092 */ 093 void setJavaClass(String value) throws PropertyException; 094 095 096 097 /** 098 * Gets the "override-severity" property. 099 * <p> 100 * Specifies the override severity levels for the logger based on 101 * the category of the messages. 102 * <p> 103 * Each override severity level should include the category and the 104 * severity levels to log for that category, for example, 105 * core=error,info,warning. Valid categories are: core, extensions, 106 * protocol, config, log, util, schema, plugin, jeb, backend, tools, 107 * task, access-control, admin, sync, version, quicksetup, 108 * admin-tool, dsconfig, user-defined. Valid severities are: all, 109 * error, info, warning, notice, debug. 110 * 111 * @return Returns the values of the "override-severity" property. 112 */ 113 SortedSet<String> getOverrideSeverity(); 114 115 116 117 /** 118 * Sets the "override-severity" property. 119 * <p> 120 * Specifies the override severity levels for the logger based on 121 * the category of the messages. 122 * <p> 123 * Each override severity level should include the category and the 124 * severity levels to log for that category, for example, 125 * core=error,info,warning. Valid categories are: core, extensions, 126 * protocol, config, log, util, schema, plugin, jeb, backend, tools, 127 * task, access-control, admin, sync, version, quicksetup, 128 * admin-tool, dsconfig, user-defined. Valid severities are: all, 129 * error, info, warning, notice, debug. 130 * 131 * @param values The values of the "override-severity" property. 132 * @throws PropertyException 133 * If one or more of the new values are invalid. 134 */ 135 void setOverrideSeverity(Collection<String> values) throws PropertyException; 136 137}