rustorb-dds 0.3.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,8 @@
1
+ # frozen_string_literal: true
2
+
3
+ module DDS
4
+ # The version of the gem rustorb-dds (that of rustorb-dds).
5
+ VERSION = "0.3.0"
6
+ # The version of rustorb/dds.h the extension is built for.
7
+ ABI_VERSION = 1
8
+ end
@@ -0,0 +1,32 @@
1
+ # frozen_string_literal: true
2
+
3
+ # rustorb-dds for Ruby: DDS (DDS 1.4, DDS-XTypes 1.3, RTPS 2.5) on
4
+ # rustorb-dds through its C ABI, with an API after the C++ PSM
5
+ # (DDS-PSM-Cxx 1.0) in Ruby's names. Types come from rustorb-idl -bruby
6
+ # -Wbdds_only (or -Wbdds). See docs/ruby.md of rustorb-dds.
7
+ #
8
+ # require "rustorb/dds"
9
+ # require_relative "HelloWorld_dds"
10
+ #
11
+ # dp = DDS::Domain::DomainParticipant.new(0)
12
+ # topic = DDS::Topic::Topic.new(dp, "HelloWorldTopic", HelloWorld::Greeting)
13
+ # writer = DDS::Pub::DataWriter.new(DDS::Pub::Publisher.new(dp), topic)
14
+ # writer.write(HelloWorld::Greeting.new(1, "hello"))
15
+ #
16
+ # Licensed under MIT OR Apache-2.0, like the rest of rustorb-dds.
17
+
18
+ require_relative "dds/version"
19
+ require_relative "dds/core"
20
+ require_relative "dds/rustorb_dds_ext"
21
+ require_relative "dds/native"
22
+ require_relative "dds/types"
23
+ require_relative "dds/qos"
24
+ require_relative "dds/pub"
25
+ require_relative "dds/sub"
26
+ require_relative "dds/topic"
27
+ require_relative "dds/domain"
28
+
29
+ DDS::Native.setup(DDS::Core::ERRORS)
30
+ if DDS::Native.abi_version != DDS::ABI_VERSION
31
+ raise LoadError, "librustorb_dds_ffi has ABI #{DDS::Native.abi_version}, the gem needs #{DDS::ABI_VERSION}"
32
+ end