use MOONLIGHT symbol
authorJb Evain <jbevain@gmail.com>
Tue, 16 Mar 2010 10:55:58 +0000 (10:55 -0000)
committerJb Evain <jbevain@gmail.com>
Tue, 16 Mar 2010 10:55:58 +0000 (10:55 -0000)
svn path=/trunk/mcs/; revision=153654

mcs/class/System.ServiceModel/System.ServiceModel.Channels/ChangeLog
mcs/class/System.ServiceModel/System.ServiceModel.Channels/HttpRequestChannel.cs
mcs/class/System.ServiceModel/System.ServiceModel.Channels/HttpTransportBindingElement.cs
mcs/class/System.ServiceModel/System.ServiceModel.Description/ChangeLog
mcs/class/System.ServiceModel/System.ServiceModel.Description/ClientCredentials.cs
mcs/class/System.ServiceModel/System.ServiceModel.Description/ContractDescription.cs
mcs/class/System.ServiceModel/System.ServiceModel.Description/IEndpointBehavior.cs
mcs/class/System.ServiceModel/System.ServiceModel/ChangeLog
mcs/class/System.ServiceModel/System.ServiceModel/ClientBase.cs
mcs/class/System.ServiceModel/System.ServiceModel/ClientRuntimeChannel.cs

index 863e71e8d3852c0ad9c274c1079b7331da285cb1..64872d110e6bd4599901497acf324955b3d7f8bf 100755 (executable)
@@ -1,3 +1,8 @@
+2010-03-16  Jb Evain  <jbevain@novell.com>
+
+       * HttpRequestChannel.cs, HttpTransportBindingElement.cs: use
+       MOONLIGHT symbol to disambiguate MonoTouch and Moonlight code.
+
 2010-03-09  Atsushi Enomoto  <atsushi@ximian.com>
 
        * HttpListenerManager.cs : For ASP.NET, use correct GenericIdentity
index 8e700f3c0c3c8092a708a112407d485565ab9fe5..9a3768e7594a46c731520eb08d953d33bbc6c97f 100644 (file)
@@ -93,7 +93,7 @@ namespace System.ServiceModel.Channels
                                ((HttpWebRequest) web_request).CookieContainer = cmgr.CookieContainer;
 #endif
 
-#if !NET_2_1 || MONOTOUCH // until we support NetworkCredential like SL4 will do.
+#if !MOONLIGHT // until we support NetworkCredential like SL4 will do.
                        // client authentication (while SL3 has NetworkCredential class, it is not implemented yet. So, it is non-SL only.)
                        var httpbe = (HttpTransportBindingElement) source.Transport;
                        string authType = null;
@@ -377,7 +377,7 @@ w.Close ();
                                        // FIXME: Do we need to use the timeout? If so, what happens when the timeout is reached.
                                        // Is the current request cancelled and an exception thrown? If so we need to pass the
                                        // exception to the Complete () method and allow the result to complete 'normally'.
-#if NET_2_1 || MONOTOUCH
+#if NET_2_1
                                        // neither Moonlight nor MonoTouch supports contexts (WaitOne default to false)
                                        bool result = wait.WaitOne (Timeout);
 #else
index 977243d1430feb7d9842729f1feb1eb22e31ce16..3c229390d63e4a7d4d813490b9adc300bd40b69b 100644 (file)
@@ -47,7 +47,7 @@ namespace System.ServiceModel.Channels
                string realm = String.Empty;
                TransferMode transfer_mode;
                IDefaultCommunicationTimeouts timeouts;
-#if !NET_2_1 || MONOTOUCH
+#if !MOONLIGHT
                AuthenticationSchemes auth_scheme =
                        AuthenticationSchemes.Anonymous;
                AuthenticationSchemes proxy_auth_scheme =
@@ -75,13 +75,13 @@ namespace System.ServiceModel.Channels
                        transfer_mode = other.transfer_mode;
                        // FIXME: it does not look safe
                        timeouts = other.timeouts;
-#if !NET_2_1 || MONOTOUCH
+#if !MOONLIGHT
                        auth_scheme = other.auth_scheme;
                        proxy_auth_scheme = other.proxy_auth_scheme;
 #endif
                }
 
-#if !NET_2_1 || MONOTOUCH
+#if !MOONLIGHT
                public AuthenticationSchemes AuthenticationScheme {
                        get { return auth_scheme; }
                        set { auth_scheme = value; }
index 26fc249386885115773e4da9b2d69a930963391d..22fe4681da31977237e7ea9b236e76dfd1643eea 100644 (file)
@@ -1,3 +1,9 @@
+2010-03-16  Jb Evain  <jbevain@novell.com>
+
+       * ClientCredentials.cs, ContractDescription.cs,
+       IEndpointBehavior.cs: use MOONLIGHT symbol to disambiguate
+       MonoTouch and Moonlight code.
+
 2010-03-15  Atsushi Enomoto  <atsushi@ximian.com>
 
        * ServiceEndpointCollection.cs : those overrides are rather to check
index fad6fbdd2600d092bcebf9e98f9c839136e23785..7e2c785cdfad07c19fc8c9744aff41acc90d568c 100644 (file)
@@ -140,7 +140,7 @@ namespace System.ServiceModel.Description
                }
 #endif
 
-#if !NET_2_1 || MONOTOUCH
+#if !MOONLIGHT
                void IEndpointBehavior.AddBindingParameters (ServiceEndpoint endpoint,
                        BindingParameterCollection parameters)
                {
index b7fd634fe5464d86da7063822cf8c4ec1090a2a8..6af33369c8a94c8eeb523857158052e8bdb69c94 100644 (file)
@@ -153,7 +153,7 @@ namespace System.ServiceModel.Description
                        foreach (OperationDescription od in Operations) {
                                if (!proxy.Operations.Contains (od.Name))
                                        PopulateClientOperation (proxy, od);
-#if !NET_2_1 || MONOTOUCH
+#if !MOONLIGHT
                                foreach (IOperationBehavior ob in od.Behaviors)
                                        ob.ApplyClientBehavior (od, proxy.Operations [od.Name]);
 #endif
index 1ba9d63f7e5c8d61102a060632a79c453981b05a..436dd438dc7b6c709e2eff6fd620305fe0812178 100644 (file)
@@ -33,7 +33,7 @@ namespace System.ServiceModel.Description
 {
        public interface IEndpointBehavior
        {
-#if !NET_2_1 || MONOTOUCH
+#if !MOONLIGHT
                void AddBindingParameters (ServiceEndpoint endpoint,
                        BindingParameterCollection parameters);
 #if !NET_2_1
index cd6ccd2586d6acdc9c2c47d708d33474356495bb..d6d4115d687c889857a7cbfb36e20a4cbb5fa62f 100755 (executable)
@@ -1,3 +1,8 @@
+2010-03-16  Jb Evain  <jbevain@novell.com>
+
+       * ClientBase.cs, ClientRuntimeChannel.cs: use MOONLIGHT symbol to
+       disambiguate MonoTouch and Moonlight code.
+
 2010-03-15  Atsushi Enomoto  <atsushi@ximian.com>
 
        * ServiceHostBase.cs : do not reject endpoints with an identical
index 6281ba53bc8055100db54360d4a5b68ee5ed6170..d9e98a1856700aeeaee3c63f3cc801deaa1a8686 100644 (file)
@@ -39,13 +39,13 @@ namespace System.ServiceModel
 {
        [MonoTODO ("It somehow rejects classes, but dunno how we can do that besides our code wise.")]
        public abstract class ClientBase<TChannel> :
-#if !NET_2_1 || MONOTOUCH
+#if !MOONLIGHT
                IDisposable,
 #endif
                ICommunicationObject where TChannel : class
        {
                static InstanceContext initialContxt = new InstanceContext (null);
-#if NET_2_1 && !MONOTOUCH
+#if MOONLIGHT
                static readonly PropertyInfo dispatcher_main_property;
                static readonly MethodInfo dispatcher_begin_invoke_method;
 
@@ -222,7 +222,7 @@ namespace System.ServiceModel
 
                void RunCompletedCallback (SendOrPostCallback callback, InvokeAsyncCompletedEventArgs args)
                {
-#if !NET_2_1 || MONOTOUCH
+#if !MOONLIGHT
                        callback (args);
 #else
                        object dispatcher = dispatcher_main_property.GetValue (null, null);
@@ -276,7 +276,7 @@ namespace System.ServiceModel
                }
                IAsyncResult begin_async_result;
 
-#if !NET_2_1 || MONOTOUCH
+#if !MOONLIGHT
                void IDisposable.Dispose ()
                {
                        Close ();
@@ -402,7 +402,7 @@ namespace System.ServiceModel
                                }
                        }
 
-#if !NET_2_1 || MONOTOUCH
+#if !MOONLIGHT
                        protected object Invoke (string methodName, object [] args)
                        {
                                var cd = endpoint.Contract;
index ffd858cd25669de9beb921a6eabaaf1e58f6923b..a77327aa9b7640dd81c38f77723f58cf48d65465 100644 (file)
@@ -166,7 +166,7 @@ namespace System.ServiceModel.MonoInternal
                                }
                        }
 
-#if !NET_2_1 || MONOTOUCH
+#if !MOONLIGHT
                        public override bool WaitOne (int millisecondsTimeout, bool exitContext)
                        {
                                return WaitHandle.WaitAll (ResultWaitHandles, millisecondsTimeout, exitContext);