RTI Connext .NET API (legacy)
Version 6.1.2
|
<<interface>> <<generic>> A type-safe, ordered collection of elements. The type of these elements is referred to in this documentation as Foo
.
More...
#include <managed_sequence.h>
Public Member Functions | |
FooSeq () | |
Create a sequence with a maximum of 0. More... | |
FooSeq (System::Int32 new_max) | |
Create a sequence with the given maximum. More... | |
FooSeq (FooSeq^ src) | |
Create a sequence by copying from an existing sequence. More... | |
Public Member Functions inherited from DDS::Sequence< Foo^ > | |
System::Boolean | ensure_length (System::Int32 length, System::Int32 max) |
Set the sequence to the desired length, and resize the sequence if necessary. More... | |
virtual void | set_at (System::Int32 i, Foo^ val) |
Set the i-th element of the sequence. More... | |
void | loan (array< Foo^ >^ buffer, System::Int32 new_length) |
Loan a contiguous buffer to this sequence. More... | |
void | from_array (array< Foo^ >^ arr) |
Copy elements from an array of elements, resizing the sequence if necessary. The original contents of the sequence (if any) are replaced. More... | |
void | to_array (array< Foo^ >^ arr) |
Copy elements to an array of elements. The original contents of the array (if any) are replaced. More... | |
System::Boolean | copy_from (Sequence< Foo^ >^ src_seq) |
Copy elements from another sequence, resizing the sequence if necessary. More... | |
Additional Inherited Members | |
Properties inherited from DDS::Sequence< Foo^ > | |
System::Int32 | length [get, set] |
The logical length of this sequence. More... | |
virtual System::Int32 | maximum [get, set] |
The current maximum number of elements that can be stored in this sequence. More... | |
array< Foo^ >^ | buffer [get] |
Return the contiguous buffer of the sequence. More... | |
System::Boolean | has_ownership [get] |
Return the value of the owned flag. More... | |
<<interface>> <<generic>> A type-safe, ordered collection of elements. The type of these elements is referred to in this documentation as Foo
.
For users who define data types in OMG IDL, this type corresponds to the IDL express sequence
<Foo>
.
For any user-data type Foo
that an application defines for the purpose of data-distribution with RTI Connext, a FooSeq
is generated. We refer to an IDL sequence
<Foo>
asFooSeq
.
The state of a sequence is described by the properties 'maximum', 'length' and 'owned'.
If owned == true, the sequence has ownership on the buffer. It is then responsible for destroying the buffer when the sequence is destroyed.
If the owned == false, the sequence does not have ownership on the buffer. This implies that the sequence is loaning the buffer. The sequence cannot be destroyed until the loan is returned.
FooSeq::FooSeq | ( | ) |
Create a sequence with a maximum of 0.
This is a constructor for the sequence. The constructor will allocate no memory.
This constructor will be used when the application creates a sequence using one of the following:
In C#:
In C++/CLI:
FooSeq::FooSeq | ( | System::Int32 | new_max | ) |
Create a sequence with the given maximum.
This is a constructor for the sequence. The constructor will automatically allocate memory to hold new_max elements of type Foo.
This constructor will be used when the application creates a sequence using one of the following:
In C#:
In C++/CLI:
new_max | Must be >= 0. Otherwise the sequence will be initialized to a new_max=0. |
FooSeq::FooSeq | ( | FooSeq^ | src | ) |
Create a sequence by copying from an existing sequence.
This is a constructor for the sequence. The constructor will automatically allocate memory to hold foo_seq::maximum() elements of type Foo and will copy the current contents of foo_seq into the new sequence.
This constructor will be used when the application creates a sequence using one of the following:
In C#:
In C++/CLI: