KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > com > sun > enterprise > management > ext > logging > LogMBeanIntf


1 /*
2  * The contents of this file are subject to the terms
3  * of the Common Development and Distribution License
4  * (the License). You may not use this file except in
5  * compliance with the License.
6  *
7  * You can obtain a copy of the license at
8  * https://glassfish.dev.java.net/public/CDDLv1.0.html or
9  * glassfish/bootstrap/legal/CDDLv1.0.txt.
10  * See the License for the specific language governing
11  * permissions and limitations under the License.
12  *
13  * When distributing Covered Code, include this CDDL
14  * Header Notice in each file and include the License file
15  * at glassfish/bootstrap/legal/CDDLv1.0.txt.
16  * If applicable, add the following below the CDDL Header,
17  * with the fields enclosed by brackets [] replaced by
18  * you own identifying information:
19  * "Portions Copyrighted [year] [name of copyright owner]"
20  *
21  * Copyright 2006 Sun Microsystems, Inc. All rights reserved.
22  */

23  
24 package com.sun.enterprise.management.ext.logging;
25
26 import java.util.List JavaDoc;
27 import java.util.Map JavaDoc;
28 import java.util.ArrayList JavaDoc;
29 import java.util.Date JavaDoc;
30 import java.util.Properties JavaDoc;
31 import java.util.logging.Level JavaDoc;
32
33 import javax.management.AttributeList JavaDoc;
34 import javax.management.NotificationEmitter JavaDoc;
35
36
37 /**
38     Interface of class com.sun.enterprise.server.logging.LogMBean.
39  */

40 interface LogMBeanIntf extends NotificationEmitter JavaDoc
41 {
42     public List JavaDoc getLoggerNames();
43
44     public List JavaDoc getLoggerNamesUnder( String JavaDoc loggerName );
45     public String JavaDoc getLogLevel( String JavaDoc loggerName );
46     public void setLogLevel( String JavaDoc loggerName, String JavaDoc level );
47     public void setLogLevelForModule( String JavaDoc module, String JavaDoc level );
48
49     public AttributeList JavaDoc getLogRecordsUsingQuery(
50         String JavaDoc logFilename,
51         Long JavaDoc fromRecord,
52         Boolean JavaDoc next,
53         Boolean JavaDoc forward,
54         Integer JavaDoc requestedCount,
55         Date JavaDoc fromDate,
56         Date JavaDoc toDate,
57         String JavaDoc logLevel,
58         Boolean JavaDoc onlyLevel,
59         List JavaDoc listOfModules,
60         Properties JavaDoc nameValueMap) ;
61     
62     public String JavaDoc[] getArchivedLogfiles();
63     public void rotateNow();
64     public void rotateAccessLog();
65
66     public String JavaDoc getLogFilesDirectory();
67     
68     public ArrayList JavaDoc getDiagnosticCausesForMessageId( String JavaDoc messageID );
69     public ArrayList JavaDoc getDiagnosticChecksForMessageId( String JavaDoc messageID );
70     public String JavaDoc getDiagnosticURIForMessageId( String JavaDoc messageID );
71     
72     /**
73      * @return a list of Map objects. Each map object contains
74      * the tuple [TimeStamp, SevereCount, WarningCount].
75      */

76     public List JavaDoc<Map JavaDoc<String JavaDoc,Object JavaDoc>> getErrorInformation();
77     
78     /**
79      * @return a list of Map objects. Each map object contains
80      * the tuple [ModuleId, SevereCount|WarningCount].
81      */

82     public Map JavaDoc<String JavaDoc,Integer JavaDoc> getErrorDistribution( long timeStamp, Level JavaDoc level);
83     
84     public void setKeepErrorStatisticsForIntervals(int numberOfIntervals);
85     public int getKeepErrorStatisticsForIntervals();
86
87     public void setErrorStatisticsIntervalDuration(long minutes);
88     public long getErrorStatisticsIntervalDuration();
89
90 };
Popular Tags