New tests.
[mono.git] / mcs / class / System.ServiceModel.Discovery / System.ServiceModel.Discovery / DiscoveryClient.cs
1 using System;
2 using System.Collections.Generic;
3 using System.Collections.ObjectModel;
4 using System.ComponentModel;
5 using System.ServiceModel;
6 using System.ServiceModel.Channels;
7 using System.ServiceModel.Description;
8 using System.ServiceModel.Dispatcher;
9
10 namespace System.ServiceModel.Discovery
11 {
12         [MonoTODO]
13         public sealed class DiscoveryClient : ICommunicationObject, IDisposable
14         {
15                 public DiscoveryClient ()
16                 {
17                 }
18
19                 public DiscoveryClient (DiscoveryEndpoint discoveryEndpoint)
20                 {
21                 }
22
23                 public DiscoveryClient (string endpointConfigurationName)
24                 {
25                 }
26
27                 public ChannelFactory ChannelFactory { get; private set; }
28                 public ClientCredentials ClientCredentials { get; private set; }
29                 public ServiceEndpoint Endpoint { get; private set; }
30                 public IClientChannel InnerChannel { get; private set; }
31
32                 CommunicationState ICommunicationObject.State {
33                         get { return InnerChannel.State; }
34                 }
35
36                 public event EventHandler<FindCompletedEventArgs> FindCompleted;
37                 public event EventHandler<FindProgressChangedEventArgs> FindProgressChanged;
38                 public event EventHandler<AnnouncementEventArgs> ProxyAvailable;
39                 public event EventHandler<ResolveCompletedEventArgs> ResolveCompleted;
40
41                 event EventHandler ICommunicationObject.Closed {
42                         add { InnerChannel.Closed += value; }
43                         remove { InnerChannel.Closed -= value; }
44                 }
45                 event EventHandler ICommunicationObject.Closing {
46                         add { InnerChannel.Closing += value; }
47                         remove { InnerChannel.Closing -= value; }
48                 }
49                 event EventHandler ICommunicationObject.Faulted {
50                         add { InnerChannel.Faulted += value; }
51                         remove { InnerChannel.Faulted -= value; }
52                 }
53                 event EventHandler ICommunicationObject.Opened {
54                         add { InnerChannel.Opened += value; }
55                         remove { InnerChannel.Opened -= value; }
56                 }
57                 event EventHandler ICommunicationObject.Opening {
58                         add { InnerChannel.Opening += value; }
59                         remove { InnerChannel.Opening -= value; }
60                 }
61
62                 public void CancelAsync (object userState)
63                 {
64                         throw new NotImplementedException ();
65                 }
66
67                 public void Close ()
68                 {
69                         throw new NotImplementedException ();
70                 }
71
72                 public FindResponse Find (FindCriteria criteria)
73                 {
74                         throw new NotImplementedException ();
75                 }
76
77                 public void FindAsync (FindCriteria criteria)
78                 {
79                         throw new NotImplementedException ();
80                 }
81
82                 public void FindAsync (FindCriteria criteria, object userState)
83                 {
84                         throw new NotImplementedException ();
85                 }
86
87                 public void Open ()
88                 {
89                         throw new NotImplementedException ();
90                 }
91
92                 public ResolveResponse Resolve (ResolveCriteria criteria)
93                 {
94                         throw new NotImplementedException ();
95                 }
96
97                 public void ResolveAsync (ResolveCriteria criteria)
98                 {
99                         throw new NotImplementedException ();
100                 }
101
102                 public void ResolveAsync (ResolveCriteria criteria, object userState)
103                 {
104                         throw new NotImplementedException ();
105                 }
106
107                 // explicit interface impl.
108
109                 void ICommunicationObject.Open ()
110                 {
111                         InnerChannel.Open ();
112                 }
113
114                 void ICommunicationObject.Open (TimeSpan timeout)
115                 {
116                         InnerChannel.Open (timeout);
117                 }
118
119                 void ICommunicationObject.Close ()
120                 {
121                         InnerChannel.Close ();
122                 }
123
124                 void ICommunicationObject.Close (TimeSpan timeout)
125                 {
126                         InnerChannel.Close (timeout);
127                 }
128
129                 IAsyncResult ICommunicationObject.BeginOpen (AsyncCallback callback, object state)
130                 {
131                         return InnerChannel.BeginOpen (callback, state);
132                 }
133
134                 IAsyncResult ICommunicationObject.BeginOpen (TimeSpan timeout, AsyncCallback callback, object state)
135                 {
136                         return InnerChannel.BeginOpen (timeout, callback, state);
137                 }
138
139                 IAsyncResult ICommunicationObject.BeginClose (AsyncCallback callback, object state)
140                 {
141                         return InnerChannel.BeginClose (callback, state);
142                 }
143
144                 IAsyncResult ICommunicationObject.BeginClose (TimeSpan timeout, AsyncCallback callback, object state)
145                 {
146                         return InnerChannel.BeginClose (timeout, callback, state);
147                 }
148
149                 void ICommunicationObject.EndOpen (IAsyncResult result)
150                 {
151                         InnerChannel.EndOpen (result);
152                 }
153
154                 void ICommunicationObject.EndClose (IAsyncResult result)
155                 {
156                         InnerChannel.EndClose (result);
157                 }
158
159                 void ICommunicationObject.Abort ()
160                 {
161                         InnerChannel.Abort ();
162                 }
163
164                 void IDisposable.Dispose ()
165                 {
166                         InnerChannel.Dispose ();
167                 }
168         }
169 }