| 1 | // XXX DEPRECATED
 | 
|---|
 | 2 | 
 | 
|---|
 | 3 | // [License]
 | 
|---|
 | 4 | // The Ariba-Underlay Copyright
 | 
|---|
 | 5 | //
 | 
|---|
 | 6 | // Copyright (c) 2008-2009, Institute of Telematics, UniversitÀt Karlsruhe (TH)
 | 
|---|
 | 7 | //
 | 
|---|
 | 8 | // Institute of Telematics
 | 
|---|
 | 9 | // UniversitÀt Karlsruhe (TH)
 | 
|---|
 | 10 | // Zirkel 2, 76128 Karlsruhe
 | 
|---|
 | 11 | // Germany
 | 
|---|
 | 12 | //
 | 
|---|
 | 13 | // Redistribution and use in source and binary forms, with or without
 | 
|---|
 | 14 | // modification, are permitted provided that the following conditions are
 | 
|---|
 | 15 | // met:
 | 
|---|
 | 16 | //
 | 
|---|
 | 17 | // 1. Redistributions of source code must retain the above copyright
 | 
|---|
 | 18 | // notice, this list of conditions and the following disclaimer.
 | 
|---|
 | 19 | // 2. Redistributions in binary form must reproduce the above copyright
 | 
|---|
 | 20 | // notice, this list of conditions and the following disclaimer in the
 | 
|---|
 | 21 | // documentation and/or other materials provided with the distribution.
 | 
|---|
 | 22 | //
 | 
|---|
 | 23 | // THIS SOFTWARE IS PROVIDED BY THE INSTITUTE OF TELEMATICS ``AS IS'' AND
 | 
|---|
 | 24 | // ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
 | 
|---|
 | 25 | // IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
 | 
|---|
 | 26 | // PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE ARIBA PROJECT OR
 | 
|---|
 | 27 | // CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
 | 
|---|
 | 28 | // EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
 | 
|---|
 | 29 | // PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
 | 
|---|
 | 30 | // PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
 | 
|---|
 | 31 | // LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
 | 
|---|
 | 32 | // NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
 | 
|---|
 | 33 | // SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
 | 
|---|
 | 34 | //
 | 
|---|
 | 35 | // The views and conclusions contained in the software and documentation
 | 
|---|
 | 36 | // are those of the authors and should not be interpreted as representing
 | 
|---|
 | 37 | // official policies, either expressed or implied, of the Institute of
 | 
|---|
 | 38 | // Telematics.
 | 
|---|
 | 39 | // [License]
 | 
|---|
 | 40 | 
 | 
|---|
 | 41 | // XXX DEPRECATED
 | 
|---|
 | 42 | 
 | 
|---|
 | 43 | #ifndef MESSAGEPROVIDER_H_
 | 
|---|
 | 44 | #define MESSAGEPROVIDER_H_
 | 
|---|
 | 45 | 
 | 
|---|
 | 46 | //#include "_namespace.h"
 | 
|---|
 | 47 | //#include "MessageReceiver.h"
 | 
|---|
 | 48 | //#include "ariba/utility/types/LinkID.h"
 | 
|---|
 | 49 | //#include "ariba/utility/types/NodeID.h"
 | 
|---|
 | 50 | //#include <vector>
 | 
|---|
 | 51 | //
 | 
|---|
 | 52 | //using std::vector;
 | 
|---|
 | 53 | //using ariba::utility::LinkID;
 | 
|---|
 | 54 | //using ariba::utility::NodeID;
 | 
|---|
 | 55 | //
 | 
|---|
 | 56 | //NAMESPACE_BEGIN
 | 
|---|
 | 57 | //
 | 
|---|
 | 58 | //
 | 
|---|
 | 59 | ///**
 | 
|---|
 | 60 | // * This class defines an interface for message providers.
 | 
|---|
 | 61 | // * Implementing classes must allow receivers to register themselves.
 | 
|---|
 | 62 | // *
 | 
|---|
 | 63 | // * @author Sebastian Mies
 | 
|---|
 | 64 | // */
 | 
|---|
 | 65 | //class MessageProvider {
 | 
|---|
 | 66 | //private:
 | 
|---|
 | 67 | //      vector<MessageReceiver*> receivers;
 | 
|---|
 | 68 | //
 | 
|---|
 | 69 | //protected:
 | 
|---|
 | 70 | //      bool sendMessageToReceivers( const Message* message );
 | 
|---|
 | 71 | //
 | 
|---|
 | 72 | //public:
 | 
|---|
 | 73 | //      /**
 | 
|---|
 | 74 | //       * Constructor.
 | 
|---|
 | 75 | //       */
 | 
|---|
 | 76 | //      MessageProvider();
 | 
|---|
 | 77 | //
 | 
|---|
 | 78 | //      /**
 | 
|---|
 | 79 | //       * Destructor.
 | 
|---|
 | 80 | //       */
 | 
|---|
 | 81 | //      ~MessageProvider();
 | 
|---|
 | 82 | //
 | 
|---|
 | 83 | //      /**
 | 
|---|
 | 84 | //       * Adds a message receiver.
 | 
|---|
 | 85 | //       *
 | 
|---|
 | 86 | //       * @param receiver The receiver.
 | 
|---|
 | 87 | //       */
 | 
|---|
 | 88 | //      void addMessageReceiver( MessageReceiver* receiver );
 | 
|---|
 | 89 | //
 | 
|---|
 | 90 | //      /**
 | 
|---|
 | 91 | //       * Removes a message receiver.
 | 
|---|
 | 92 | //       *
 | 
|---|
 | 93 | //       * @param receiver The receiver.
 | 
|---|
 | 94 | //       */
 | 
|---|
 | 95 | //      void removeMessageReceiver( MessageReceiver* receiver );
 | 
|---|
 | 96 | //};
 | 
|---|
 | 97 | //
 | 
|---|
 | 98 | //NAMESPACE_END
 | 
|---|
 | 99 | 
 | 
|---|
 | 100 | #endif /* MESSAGEPROVIDER_H_ */
 | 
|---|