01: /**
02: * Copyright (C) 2001-2003 France Telecom R&D
03: *
04: * This library is free software; you can redistribute it and/or
05: * modify it under the terms of the GNU Lesser General Public
06: * License as published by the Free Software Foundation; either
07: * version 2 of the License, or (at your option) any later version.
08: *
09: * This library is distributed in the hope that it will be useful,
10: * but WITHOUT ANY WARRANTY; without even the implied warranty of
11: * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12: * Lesser General Public License for more details.
13: *
14: * You should have received a copy of the GNU Lesser General Public
15: * License along with this library; if not, write to the Free Software
16: * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
17: */package org.objectweb.util.monolog.api;
18:
19: /**
20: * This class represents a logging level. A logging level allows to
21: * classify events by their importance. This interface provides
22: * methods to compare Level instances. A level has a name.
23: *
24: * @author S.Chassande-Barrioz
25: */
26: public interface Level {
27:
28: /**
29: * This method returns true is the current level and the Level parameter are
30: * ordered.
31: */
32: boolean isComparableWith(Level o);
33:
34: /**
35: * Compares this object with the specified object for order. Returns a
36: * negative integer, zero, or a positive integer as this object is less than,
37: * equal to, or greater than the specified object.
38: */
39: int compareTo(Level o);
40:
41: /**
42: * Returns the integer value which represents the level.
43: */
44: int getIntValue();
45:
46: /**
47: * It retrieves the name of the Level
48: */
49: String getName();
50:
51: /**
52: * It assigns the name of the Level
53: */
54: void setName(String n);
55:
56: }
|