01: /*
02: * Licensed to the Apache Software Foundation (ASF) under one or more
03: * contributor license agreements. See the NOTICE file distributed with
04: * this work for additional information regarding copyright ownership.
05: * The ASF licenses this file to You under the Apache License, Version 2.0
06: * (the "License"); you may not use this file except in compliance with
07: * the License. You may obtain a copy of the License at
08: *
09: * http://www.apache.org/licenses/LICENSE-2.0
10: *
11: * Unless required by applicable law or agreed to in writing, software
12: * 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 and
15: * limitations under the License.
16: */
17: package org.apache.cocoon.components.notification;
18:
19: import java.util.Map;
20:
21: /**
22: * Interface for Objects that can notify something.
23: *
24: * @author <a href="mailto:barozzi@nicolaken.com">Nicola Ken Barozzi</a>
25: * @version CVS $Id: Notifying.java 433543 2006-08-22 06:22:54Z crossley $
26: */
27:
28: public interface Notifying {
29:
30: /*
31: * Proposed types of notifications
32: */
33: String UNKNOWN_NOTIFICATION = "unknown";
34: String DEBUG_NOTIFICATION = "debug";
35: String INFO_NOTIFICATION = "info";
36: String WARN_NOTIFICATION = "warn";
37: String ERROR_NOTIFICATION = "error";
38: String FATAL_NOTIFICATION = "fatal";
39:
40: /*
41: * Proposed extra descriptions
42: */
43: String EXTRA_LOCATION = "location";
44: String EXTRA_LINE = "line";
45: String EXTRA_COLUMN = "column";
46: String EXTRA_REQUESTURI = "request-uri";
47: String EXTRA_CAUSE = "cause";
48: String EXTRA_STACKTRACE = "stacktrace";
49: String EXTRA_FULLTRACE = "full exception chain stacktrace";
50:
51: /**
52: * Gets the Type of the Notifying object
53: */
54: String getType();
55:
56: /**
57: * Gets the Title of the Notifying object
58: */
59: String getTitle();
60:
61: /**
62: * Gets the Source of the Notifying object
63: */
64: String getSource();
65:
66: /**
67: * Gets the Sender of the Notifying object
68: */
69: String getSender();
70:
71: /**
72: * Gets the Message of the Notifying object
73: */
74: String getMessage();
75:
76: /**
77: * Gets the Description of the Notifying object
78: */
79: String getDescription();
80:
81: /**
82: * Gets the ExtraDescriptions of the Notifying object
83: */
84: Map getExtraDescriptions();
85: }
|