/** * Constructor is only called by DDS.DomainParticipantFactory. */ internal DomainParticipant(IntPtr gapiPtr) : base(gapiPtr) { listenerHelper = new DomainParticipantListenerHelper(); BuiltinTopicRegisterTypeSupport(this); CopyInstanceHandleAttr = CopyInstanceHandle; }
/** * Constructor is only called by DDS.DomainParticipantFactory. */ internal DomainParticipant(IntPtr gapiPtr) : base(gapiPtr) { listenerHelper = new DomainParticipantListenerHelper(); BuiltinTopicRegisterTypeSupport(this); CopyInstanceHandleAttr = CopyInstanceHandle; }
public IDomainParticipant CreateParticipant( DomainId domainId, IDomainParticipantListener listener, StatusKind mask) { IDomainParticipant participant = null; string className = null; if (listener != null) { OpenSplice.Gapi.gapi_domainParticipantListener gapiListener; DomainParticipantListenerHelper listenerHelper = new DomainParticipantListenerHelper(); listenerHelper.Listener = listener; listenerHelper.CreateListener(out gapiListener); using (DomainParticipantListenerMarshaler listenerMarshaler = new DomainParticipantListenerMarshaler(ref gapiListener)) { // Invoke the corresponding gapi function. IntPtr gapiParticipant = OpenSplice.Gapi.DomainParticipantFactory.create_participant( GapiPeer, domainId, OpenSplice.Gapi.NativeConstants.GapiParticipantQosDefault, listenerMarshaler.GapiPtr, mask, IntPtr.Zero, IntPtr.Zero, IntPtr.Zero, className); if (gapiParticipant != IntPtr.Zero) { participant = new OpenSplice.DomainParticipant(gapiParticipant, listenerHelper); } } } else { // Invoke the corresponding gapi function. IntPtr gapiParticipant = OpenSplice.Gapi.DomainParticipantFactory.create_participant( GapiPeer, domainId, OpenSplice.Gapi.NativeConstants.GapiParticipantQosDefault, IntPtr.Zero, mask, IntPtr.Zero, IntPtr.Zero, IntPtr.Zero, className); if (gapiParticipant != IntPtr.Zero) { participant = new OpenSplice.DomainParticipant(gapiParticipant); } } if (participant != null) { DomainParticipantFactoryQos dpfQos = null; ReturnCode result = GetQos(ref dpfQos); if (result == ReturnCode.Ok) { if (dpfQos.EntityFactory.AutoenableCreatedEntities) { participant.Enable(); } } } return participant; }
/** * Constructor is only called by DDS.DomainParticipantFactory. */ internal DomainParticipant(IntPtr gapiPtr, DomainParticipantListenerHelper listenerHelper) : base(gapiPtr) { this.listenerHelper = listenerHelper; BuiltinTopicRegisterTypeSupport(this); }
/** * Constructor is only called by DDS.DomainParticipantFactory. */ internal DomainParticipant(IntPtr gapiPtr, DomainParticipantListenerHelper listenerHelper) : base(gapiPtr) { this.listenerHelper = listenerHelper; BuiltinTopicRegisterTypeSupport(this); }
/** * Constructor is only called by DDS.DomainParticipantFactory. */ internal DomainParticipant(IntPtr gapiPtr) : base(gapiPtr) { listenerHelper = new DomainParticipantListenerHelper(); BuiltinTopicRegisterTypeSupport(this); }