01: /******************************************************************************
02: * Copyright (C) Lars Ivar Almli. All rights reserved. *
03: * ---------------------------------------------------------------------------*
04: * This file is part of MActor. *
05: * *
06: * MActor is free software; you can redistribute it and/or modify *
07: * it under the terms of the GNU General Public License as published by *
08: * the Free Software Foundation; either version 2 of the License, or *
09: * (at your option) any later version. *
10: * *
11: * MActor is distributed in the hope that it will be useful, *
12: * but WITHOUT ANY WARRANTY; without even the implied warranty of *
13: * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
14: * GNU General Public License for more details. *
15: * *
16: * You should have received a copy of the GNU General Public License *
17: * along with MActor; if not, write to the Free Software *
18: * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA *
19: ******************************************************************************/package org.mactor.brokers;
20:
21: /**
22: * Defines a messsage subscriber
23: *
24: * @author Lars Ivar Almli
25: */
26: public interface MessageSubscriber {
27: /**
28: * Invoked by the message broker when a message has been received (and
29: * accepted by the)
30: *
31: * @param message
32: * @return null or a response message - when dealing with synchrounous
33: * protcols (the output from the message_respond node inside the message_receive node..).
34: */
35: Message onMessage(Message message);
36: }
|