summaryrefslogtreecommitdiff
path: root/ACE/TAO/DevGuideExamples/ValueTypes/Messenger/Message_i.h
blob: f4dac3f034d0e5db4a9c0864950bd3b3725c90db (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
// $Id$

#ifndef MESSAGE_I_H
#define MESSAGE_I_H

#include "MessengerC.h"

#include "tao/Valuetype/ValueFactory.h"

class MessageImpl : public virtual OBV_Message,
                    public virtual CORBA::DefaultValueRefCountBase
{
public:
  MessageImpl();

  MessageImpl(
    const char* address,
    const char* user,
    const char* subject,
    const char* txt
    );

  virtual ::Message::AddrList* getAddresses();
  virtual void addAddress(const char*);

  virtual char* user();
  virtual void user(const char*);

  virtual char* subject();
  virtual void subject(const char*);

  virtual char* text();
  virtual void text(const char*);

  virtual void print();
protected:
  virtual ~MessageImpl();
};

class MessageFactory
  : public virtual CORBA::ValueFactoryBase
{
public:
  static void register_new_factory(CORBA::ORB& orb);
private:
  virtual CORBA::ValueBase* create_for_unmarshal();
};

#endif