public void Invoke(string operation, bool idempotent, bool oneway, IReadOnlyDictionary <string, string>?context, bool synchronous) { try { Proxy.IceReference.Protocol.CheckSupported(); IsIdempotent = idempotent; IsOneway = oneway; context ??= ProxyAndCurrentContext(); Observer = ObserverHelper.GetInvocationObserver(Proxy, operation, context); switch (Proxy.IceReference.InvocationMode) { case InvocationMode.BatchOneway: case InvocationMode.BatchDatagram: { Debug.Assert(false); // not implemented break; } } Invoke(synchronous); } catch (Exception ex) { Abort(ex); } }
public void Prepare(string operation, bool idempotent, bool oneway, IReadOnlyDictionary <string, string>?context) { Debug.Assert(Os != null); Proxy.IceReference.GetProtocol().CheckSupported(); IsIdempotent = idempotent; IsOneway = oneway; context ??= ProxyAndCurrentContext(); Observer = ObserverHelper.GetInvocationObserver(Proxy, operation, context); switch (Proxy.IceReference.GetMode()) { case Ice.InvocationMode.Twoway: case Ice.InvocationMode.Oneway: case Ice.InvocationMode.Datagram: { Os.WriteSpan(Ice1Definitions.RequestHeader.AsSpan()); break; } case Ice.InvocationMode.BatchOneway: case Ice.InvocationMode.BatchDatagram: { Debug.Assert(false); // not implemented break; } } Reference rf = Proxy.IceReference; rf.GetIdentity().IceWrite(Os); // // For compatibility with the old FacetPath. // string facet = rf.GetFacet(); if (facet == null || facet.Length == 0) { Os.WriteStringSeq(System.Array.Empty <string>()); } else { Os.WriteStringSeq(new string[] { facet }); } Os.WriteString(operation); Os.Write(idempotent ? OperationMode.Idempotent : OperationMode.Normal); Ice.ContextHelper.Write(Os, context); }
// Called by IceInvokeAsync internal void Invoke(string operation, IReadOnlyDictionary <string, string>?context, bool synchronous) { context ??= ProxyAndCurrentContext(); Observer = ObserverHelper.GetInvocationObserver(Proxy, operation, context); Invoke(synchronous); }