summaryrefslogtreecommitdiff
path: root/TAO/orbsvcs/orbsvcs/Trader/Proxy.h
blob: 67f3c2677b876df27ed1f15d5bc9407034b70533 (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
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
/* -*- C++ -*- */

// ========================================================================
// $Id$
// 
// = LIBRARY
//    orbsvcs
// 
// = FILENAME
//   Proxy.h
//
// = AUTHOR
//    Marina Spivak <marina@cs.wustl.edu>
//    Irfan Pyarali <irfan@cs.wustl.edu>
//    Seth Widoff <sbw1@cs.wustl.edu>
// 
// ========================================================================

#ifndef TAO_PROXY_H
#define TAO_PROXY_H

#include "Attributes.h"

template <class TRADER>
class TAO_Proxy : 
  public TAO_Trader_Components <POA_CosTrading::Proxy>,
  public TAO_Support_Attributes <POA_CosTrading::Proxy>
{
public:

  TAO_Proxy (TRADER &trader);

  ~TAO_Proxy (void);

  virtual CosTrading::OfferId
    export_proxy (CosTrading::Lookup_ptr target, 
		  const char *type, 
		  const CosTrading::PropertySeq& properties, 
		  CORBA::Boolean if_match_all, 
		  const char * recipe, 
		  const CosTrading::PolicySeq& policies_to_pass_on,
		  CORBA::Environment& _env) 
    TAO_THROW_SPEC ((CORBA::SystemException,
		    CosTrading::IllegalServiceType, 
		    CosTrading::UnknownServiceType, 
		    CosTrading::InvalidLookupRef, 
		    CosTrading::IllegalPropertyName, 
		    CosTrading::PropertyTypeMismatch, 
		    CosTrading::ReadonlyDynamicProperty, 
		    CosTrading::MissingMandatoryProperty, 
		    CosTrading::Proxy::IllegalRecipe, 
		    CosTrading::DuplicatePropertyName, 
		    CosTrading::DuplicatePolicyName));

  virtual void withdraw_proxy (const char *id,
			       CORBA::Environment& _env) 
    TAO_THROW_SPEC ((CORBA::SystemException, 
		    CosTrading::IllegalOfferId, 
		    CosTrading::UnknownOfferId, 
		    CosTrading::Proxy::NotProxyOfferId));

  virtual CosTrading::Proxy::ProxyInfo *
  describe_proxy (const char *id,
		  CORBA::Environment& _env) 
    TAO_THROW_SPEC ((CORBA::SystemException,
		    CosTrading::IllegalOfferId, 
		    CosTrading::UnknownOfferId, 
		    CosTrading::Proxy::NotProxyOfferId));

   // = CosTrading::TraderComponents methods. 

  virtual void list_proxies (CORBA::ULong how_many,
			     CosTrading::OfferIdSeq*& ids,
			     CosTrading::OfferIdIterator_ptr& id_itr,
			     CORBA::Environment& env)
    TAO_THROW_SPEC ((CORBA::SystemException,
		    CosTrading::NotImplemented));
				
private:
  TRADER &trader_;
};

#if defined (ACE_TEMPLATES_REQUIRE_SOURCE)
#include "Proxy.cpp"
#endif /* ACE_TEMPLATES_REQUIRE_SOURCE */


#endif /* TAO_PROXY_H */