public void send_request(ClientRequestInfo ri) { object testEntryBeginAsObject = ri.get_slot(m_slotId); if (testEntryBeginAsObject != null) { int testEntryBegin = (int)testEntryBeginAsObject; TestServiceContext contextEntry = new TestServiceContext(); contextEntry.TestEntry = testEntryBegin; ServiceContext context = new ServiceContext(1000, m_codec.encode(contextEntry)); ri.add_request_service_context(context, true); } }
/// <summary> /// <see cref="omg.org.PortableInterceptor.ClientRequestInterceptor.send_request"></see> /// </summary> public void send_request(ClientRequestInfo ri) { ClientRequestInfoImpl internalInfo = (ClientRequestInfoImpl)ri; // need access to connection information if ((internalInfo.ConnectionDesc.Connection.IsInitiatedLocal()) && // initiated in this appdomain (internalInfo.ConnectionDesc.ConnectionManager.SupportBiDir())) { GiopBidirectionalConnectionManager biDirConManager = (GiopBidirectionalConnectionManager)internalInfo.ConnectionDesc.ConnectionManager; ListenPoint[] listenPointsEntry = ConvertToListenPoints(biDirConManager.GetOwnListenPoints()); BiDirIIOPServiceContext contextEntry = new BiDirIIOPServiceContext(listenPointsEntry); ServiceContext svcContext = new ServiceContext(BI_DIR_IIOP.ConstVal, m_codec.encode_value(contextEntry)); ri.add_request_service_context(svcContext, true); biDirConManager.SetupConnectionForBidirReception(internalInfo.ConnectionDesc); } }
public void send_request(ClientRequestInfo ri) { if (MustNonInterceptCall(ri)) { return; } m_invokedOnOutPath = true; TestServiceContext contextEntry = new TestServiceContext(); contextEntry.TestEntry = m_contextEntryBegin; ServiceContext context = new ServiceContext(1000, m_codec.encode(contextEntry)); ri.add_request_service_context(context, true); try { TaggedComponent taggedComponentEnc = ri.get_effective_component(1000); omg.org.CORBA.TypeCode typeCode = omg.org.CORBA.OrbServices.GetSingleton().create_tc_for_type(typeof(TestComponent)); m_taggedComponent = m_codec.decode_value(taggedComponentEnc.component_data, typeCode); } catch (BAD_PARAM) { m_taggedComponent = null; } }