1. --  (c) Copyright, Real-Time Innovations, $Date:: 2012-02-16 #$ 
  2. --  All rights reserved. 
  3. -- 
  4. --  No duplications, whole or partial, manual or electronic, may be made 
  5. --  without express written permission.  Any such copies, or 
  6. --  revisions thereof, must display this notice unaltered. 
  7. --  This code contains trade secrets of Real-Time Innovations, Inc. 
  8.  
  9. pragma Ada_05; 
  10.  
  11. pragma Style_Checks ("NM32766"); 
  12.  
  13. with DDS.Domain_Entity_Impl; 
  14. with DDS.Publisher; 
  15. limited with DDS.DomainParticipant; 
  16. with DDS.PublisherListener; 
  17. with DDS.Topic; 
  18. with DDS.DataWriter; 
  19. with DDS.DataWriterListener; 
  20.  
  21. with Ada.Unchecked_Deallocation; 
  22. with RTIDDS.Low_Level.reda.worker_impl_h; 
  23.  
  24. package DDS.Publisher_Impl is 
  25.  
  26.    type Ref is limited new DDS.Domain_Entity_Impl.Ref and DDS.Publisher.Ref with null record; 
  27.    type Ref_Access is access all Ref'Class; 
  28.  
  29.    -- 
  30.  
  31.    function Create_DataWriter 
  32.      (Self       : not null access Ref; 
  33.       A_Topic    : in DDS.Topic.Ref_Access; 
  34.       Qos        : in DDS.DataWriterQos; 
  35.       A_Listener : in DDS.DataWriterListener.Ref_Access; 
  36.       Mask       : in DDS.StatusMask) 
  37.      return DDS.DataWriter.Ref_Access; 
  38.  
  39.    function Create_DataWriter_With_Profile 
  40.      (Self         : not null access Ref; 
  41.       A_Topic    : in DDS.Topic.Ref_Access; 
  42.       Library_Name : in DDS.String; 
  43.       profile_name : in DDS.String; 
  44.       A_Listener : in DDS.DataWriterListener.Ref_Access; 
  45.       Mask         : in DDS.StatusMask := STATUS_MASK_NONE) 
  46.       return DDS.DataWriter.Ref_Access; 
  47.  
  48.    function Create_DataWriter_With_Profile 
  49.      (Self         : not null access Ref; 
  50.       A_Topic    : in DDS.Topic.Ref_Access; 
  51.       Library_Name : in Standard.String; 
  52.       profile_name : in Standard.String; 
  53.       A_Listener : in DDS.DataWriterListener.Ref_Access; 
  54.       Mask         : in DDS.StatusMask := STATUS_MASK_NONE) 
  55.       return DDS.DataWriter.Ref_Access; 
  56.  
  57.  
  58.    procedure Delete_DataWriter 
  59.      (Self         : not null access Ref; 
  60.       A_DataWriter : in out DDS.DataWriter.Ref_Access); 
  61.  
  62.    function Lookup_DataWriter 
  63.      (Self       : not null access Ref; 
  64.       Topic_Name : in DDS.String_Ptr) 
  65.      return DDS.DataWriter.Ref_Access; 
  66.  
  67.    procedure Delete_Contained_Entities 
  68.      (Self : not null access Ref); 
  69.  
  70.    procedure Set_Qos 
  71.      (Self : not null access Ref; 
  72.       Qos  : in DDS.PublisherQos); 
  73.  
  74.    procedure Set_Qos_With_Profile 
  75.      (Self          : not null access Ref; 
  76.       library_name  : in String; 
  77.       profile_name  : in String); 
  78.  
  79.    procedure Set_Qos_With_Profile 
  80.      (Self          : not null access Ref; 
  81.       library_name  : in Standard.String; 
  82.       profile_name  : in Standard.String); 
  83.  
  84.    procedure Get_Qos 
  85.      (Self : not null access Ref; 
  86.       Qos  : in out DDS.PublisherQos); 
  87.  
  88.    procedure Set_Listener 
  89.      (Self       : not null access Ref; 
  90.       A_Listener : in DDS.PublisherListener.Ref_Access; 
  91.       Mask       : in DDS.StatusMask); 
  92.  
  93.    function Get_Listener 
  94.      (Self : not null access Ref) 
  95.       return DDS.PublisherListener.Ref_Access; 
  96.  
  97.    procedure Suspend_Publications 
  98.      (Self : not null access Ref); 
  99.  
  100.    procedure Resume_Publications 
  101.      (Self : not null access Ref); 
  102.  
  103.    procedure Begin_Coherent_Changes 
  104.      (Self : not null access Ref); 
  105.  
  106.    procedure End_Coherent_Changes 
  107.      (Self : not null access Ref); 
  108.  
  109.    procedure Wait_For_Acknowledgments 
  110.      (Self     : not null access Ref; 
  111.       Max_Wait : in DDS.Duration_T); 
  112.  
  113.    procedure Wait_For_Asynchronous_Publishing 
  114.      (Self     : not null  access Ref; 
  115.       Max_Wait : in DDS.Duration_T); 
  116.  
  117.    function Get_Participant 
  118.      (Self : not null access Ref) 
  119.       return access DDS.DomainParticipant.Ref'Class; 
  120.  
  121.    procedure Set_Default_DataWriter_Qos 
  122.      (Self : not null access Ref; 
  123.       Qos  : in DDS.DataWriterQos); 
  124.  
  125.    procedure Set_Default_DataWriter_Qos_With_Profile 
  126.      (Self     : not null access Ref; 
  127.       libName  : DDS.String; 
  128.       profName : DDS.String); 
  129.    procedure Set_Default_DataWriter_Qos_With_Profile 
  130.      (Self     : not null access Ref; 
  131.       libName  : Standard.String; 
  132.       profName : Standard.String); 
  133.  
  134.    procedure Get_Default_DataWriter_Qos 
  135.      (Self : not null access Ref; 
  136.       Qos  : in out DDS.DataWriterQos); 
  137.  
  138.    procedure Copy_From_Topic_Qos 
  139.      (Self             : not null access Ref; 
  140.       A_DataWriter_Qos : in out DDS.DataWriterQos; 
  141.       A_Topic_Qos      : in DDS.TopicQos); 
  142.  
  143.    procedure Set_Default_Profile 
  144.      (Self          : not null access Ref; 
  145.       library_name  : DDS.String; 
  146.       profile_name  : DDS.String); 
  147.  
  148.    procedure Set_Default_Library 
  149.      (Self          : not null access Ref; 
  150.       library_name   : DDS.String); 
  151.  
  152.    function Get_Default_Library 
  153.      (Self : not null access Ref) 
  154.       return DDS.String; 
  155.  
  156.    function Get_Default_Profile 
  157.      (Self : not null access Ref) 
  158.       return DDS.String; 
  159.  
  160.    function Get_Default_Profile_Library 
  161.      (Self : not null access Ref) 
  162.       return DDS.String; 
  163.  
  164.    -- Impl only 
  165.  
  166.    procedure Free (This : in out Ref_Access); 
  167.  
  168.    function CreateI (C_Participant : in System.Address; 
  169.                      Qos           : in DDS.PublisherQos; 
  170.                      A_Listener    : in DDS.PublisherListener.Ref_Access; 
  171.                      Mask          : in DDS.StatusMask) 
  172.                     return DDS.Publisher.Ref_Access; 
  173.  
  174.    function Create_WrapperI (C_Publisher : in System.Address) 
  175.                              return Ref_Access; 
  176.  
  177.    function Get_FacadeI (C_Publisher : System.Address) 
  178.                         return Ref_Access; 
  179.  
  180.    procedure Finalize_Callback 
  181.      (arg1 : System.Address; 
  182.       arg2 : System.Address; 
  183.       arg3 : access RTIDDS.Low_Level.reda.worker_impl_h.REDAWorker); 
  184.    pragma Convention (C, Finalize_Callback); 
  185.  
  186. private 
  187.  
  188.    procedure Free_Impl is new Ada.Unchecked_Deallocation (Ref'Class, Ref_Access); 
  189.    procedure Free_Mem (This : in out Ref_Access) renames Free_Impl; 
  190.  
  191. end DDS.Publisher_Impl;