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: import org.apache.avalon.framework.component.Component;
22:
23: /**
24: * Generates an Notifying representation of widely used objects.
25: *
26: * @author <a href="mailto:barozzi@nicolaken.com">Nicola Ken Barozzi</a>
27: * @version CVS $Id: NotifyingBuilder.java 433543 2006-08-22 06:22:54Z crossley $
28: */
29:
30: public interface NotifyingBuilder extends Component {
31:
32: /**
33: * The role implemented by a <code>NotifyingBuilder</code>.
34: */
35: String ROLE = NotifyingBuilder.class.getName();
36:
37: /** Builds a Notifying object (SimpleNotifyingObject in this case)
38: * that tries to explain what the Object o can reveal.
39: * @param sender who sent this Object.
40: * @param o the object to use when building the SimpleNotifyingObject
41: * @return the Notifying Object that was build
42: * @see org.apache.cocoon.components.notification.Notifying
43: */
44: Notifying build(Object sender, Object o);
45:
46: /** Builds a Notifying object (SimpleNotifyingObject in this case)
47: * that explains a notification.
48: * @param sender who sent this Object.
49: * @param o the object to use when building the SimpleNotifyingObject
50: * @param type see the Notifying apidocs
51: * @param title see the Notifying apidocs
52: * @param source see the Notifying apidocs
53: * @param message see the Notifying apidocs
54: * @param description see the Notifying apidocs
55: * @param extra see the Notifying apidocs
56: * @return the Notifying Object that was build
57: * @see org.apache.cocoon.components.notification.Notifying
58: */
59: Notifying build(Object sender, Object o, String type, String title,
60: String source, String message, String description, Map extra);
61: }
|