KeyedBytes Class Reference
[KeyedOctets Built-in Type]

Built-in type consisting of a variable-length array of opaque bytes and a string that is the key. More...

Inheritance diagram for KeyedBytes:

Copyable

List of all members.

Public Member Functions

 KeyedBytes ()
 Default Constructor.
 KeyedBytes (KeyedBytes src)
 Copy constructor.
 KeyedBytes (int size)
 Constructor that specifies the allocated sizes.
Object copy_from (Object src)
 Copy value of a data type from source.

Public Attributes

String key
 Instance key associated with the specified value.
int length
 Number of bytes to serialize.
int offset
 Offset from which to start serializing bytes .
byte[] value
 com.rti.dds.type.builtin.Bytes array value.


Detailed Description

Built-in type consisting of a variable-length array of opaque bytes and a string that is the key.

Constructor & Destructor Documentation

KeyedBytes (  ) 

Default Constructor.

The default constructor initializes the newly created object with empty key, null value, zero length, and zero offset.

KeyedBytes ( KeyedBytes  src  ) 

Copy constructor.

Parameters:
src <<in>> Object to copy from.
Exceptions:
NullPointerException if src is null.

KeyedBytes ( int  size  ) 

Constructor that specifies the allocated sizes.

After this method is called, key is initialized with the empty string and length and offset are set to zero.

Parameters:
size <<in>> Size of the allocated bytes array.
Exceptions:
IllegalArgumentException if size is negative


Member Function Documentation

Object copy_from ( Object  src  ) 

Copy value of a data type from source.

Copy data into this object from another. This copy is intended to be a deep copy, so that all data members (recursively) are copied (not just resetting Object references).

This operation returns the object that is copied if copy is successful.

Parameters:
src <<in>> The Object which contains the data to be copied.
Returns:
Generally, return this but special cases (such as Enum) exist.
Exceptions:
NullPointerException If src is null.
ClassCastException If src is not the same type as this.

Implements Copyable.


Member Data Documentation

String key

Instance key associated with the specified value.

int length

Number of bytes to serialize.

int offset

Offset from which to start serializing bytes .

The first position of the bytes array has offset 0.

byte [] value


RTI Connext Java API Version 4.5f Copyright © 17 Mar 2012 Real-Time Innovations, Inc