/*
  WARNING: THIS FILE IS AUTO-GENERATED. DO NOT MODIFY.

  This file was generated from test.idl using "rtiddsgen".
  The rtiddsgen tool is part of the RTI Data Distribution Service distribution.
  For more information, type 'rtiddsgen -help' at a command shell
  or consult the RTI Data Distribution Service manual.
*/

#pragma once

#include "test.h"


class DDSDataWriter;
class DDSDataReader;
    
// ---------------------------------------------------------------------------
// TestData_tTypeSupport
// ---------------------------------------------------------------------------

ref class TestData_tPlugin;

/* A collection of useful methods for dealing with objects of type
 * TestData_t.
 */
public ref class TestData_tTypeSupport
        : public DDS::TypedTypeSupport<TestData_t^> {
    // --- Type name: --------------------------------------------------------
  public:
    static System::String^ TYPENAME = "TestData_t";


    // --- Public Methods: ---------------------------------------------------
  public:
    /* Get the default name of this type.
     *
     * An application can choose to register a type under any name, so
     * calling this method is strictly optional.
     */
    static System::String^ get_type_name();

    /* Register this type with the given participant under the given logical
     * name. This type must be registered before a Topic can be created that
     * uses it.
     */
    static void register_type(
            DDS::DomainParticipant^ participant,
            System::String^ type_name);

    /* Unregister this type from the given participant, where it was
     * previously registered under the given name. No further Topic creation
     * using this type will be possible.
     *
     * Unregistration allows some middleware resources to be reclaimed.
     */
    static void unregister_type(
            DDS::DomainParticipant^ participant,
            System::String^ type_name);

    /* Create an instance of the TestData_t type.
     */
    static TestData_t^ create_data();

    /* If instances of the TestData_t type require any
     * explicit finalization, perform it now on the given sample.
     */
    static void delete_data(TestData_t^ data);

    /* Write the contents of the data sample to standard out.
     */
    static void print_data(TestData_t^ a_data);

    /* Perform a deep copy of the contents of one data sample over those of
     * another, overwriting it.
     */
    static void copy_data(
        TestData_t^ dst_data,
        TestData_t^ src_data);


    // --- Implementation: ---------------------------------------------------
    /* The following code is for the use of the middleware infrastructure.
     * Applications are not expected to call it directly.
     */
public:
    virtual DDS::DataReader^ create_datareaderI(
        System::IntPtr impl) override;
    virtual DDS::DataWriter^ create_datawriterI(
        System::IntPtr impl) override;

private:
    static TestData_tTypeSupport^ get_instance();

    TestData_tTypeSupport();

private:
    static TestData_tTypeSupport^ _singleton;
    TestData_tPlugin^ _type_plugin;
};


// ---------------------------------------------------------------------------
// TestData_tDataReader
// ---------------------------------------------------------------------------

/**
 * A reader for the TestData_t type.
 */
public ref class TestData_tDataReader :
        public DDS::TypedDataReader<TestData_t^> {
    /* The following code is for the use of the middleware infrastructure.
     * Applications are not expected to call it directly.
     */
  internal:
    TestData_tDataReader(System::IntPtr impl);
};


// ---------------------------------------------------------------------------
// TestData_tDataWriter
// ---------------------------------------------------------------------------

/**
 * A writer for the TestData_t user type.
 */
public ref class TestData_tDataWriter :
        public DDS::TypedDataWriter<TestData_t^> {
    /* The following code is for the use of the middleware infrastructure.
     * Applications are not expected to call it directly.
     */
  internal:
    TestData_tDataWriter(System::IntPtr impl);
};
