Main Page   Class Hierarchy   Alphabetical List   Data Structures   File List   Data Fields   Globals  

NMLmsg Class Reference

#include <nmlmsg.hh>

Inheritance diagram for NMLmsg:

Inheritance graph
[legend]
Collaboration diagram for NMLmsg:

Collaboration graph
[legend]

Public Methods

void clear ()
void update (CMS *)

Data Fields

NMLTYPE type
long size

Static Public Attributes

int automatically_clear = 1

Protected Methods

 NMLmsg (NMLTYPE t, long s)
 NMLmsg (NMLTYPE t, long s, int noclear)

Constructor & Destructor Documentation

NMLmsg::NMLmsg NMLTYPE    t,
long    s
[protected]
 

Definition at line 35 of file nmlmsg.cc.

Referenced by BBD_READ_TYPE().

00036 {
00037   type = t;
00038   size = s;
00039   if (automatically_clear)
00040     {
00041       clear ();
00042     }
00043   if (size < ((long) sizeof (NMLmsg)))
00044     {
00045       rcs_print_error ("NMLmsg: size(=%d) must be atleast %d\n", size,
00046                        sizeof (NMLmsg));
00047       size = sizeof (NMLmsg);
00048     }
00049   if (type <= 0)
00050     {
00051       rcs_print_error ("NMLmsg: type(=%d) should be greater than zero.\n",
00052                        type);
00053     }
00054 };

NMLmsg::NMLmsg NMLTYPE    t,
long    s,
int    noclear
[protected]
 

Definition at line 79 of file nmlmsg.cc.

00080 {
00081   if (automatically_clear && !noclear)
00082     {
00083       clear ();
00084     }
00085   type = t;
00086   size = s;
00087   if (size < ((long) sizeof (NMLmsg)))
00088     {
00089       rcs_print_error ("NMLmsg: size(=%d) must be atleast %d\n", size,
00090                        sizeof (NMLmsg));
00091       size = sizeof (NMLmsg);
00092     }
00093   if (type <= 0)
00094     {
00095       rcs_print_error ("NMLmsg: type(=%d) should be greater than zero.\n",
00096                        type);
00097     }
00098 };


Member Function Documentation

void NMLmsg::clear  
 

Definition at line 102 of file nmlmsg.cc.

Referenced by NMLmsg().

00103 {
00104   long temp_size;
00105   NMLTYPE temp_type;
00106   temp_size = size;
00107   temp_type = type;
00108   memset ((void *) this, 0, size);
00109   size = temp_size;
00110   type = temp_type;
00111   if (size < ((long) sizeof (NMLmsg)))
00112     {
00113       rcs_print_error ("NMLmsg: size(=%d) must be atleast %d\n", size,
00114                        sizeof (NMLmsg));
00115       size = sizeof (NMLmsg);
00116     }
00117 }

void NMLmsg::update CMS   cms
 

Reimplemented in NML_BBD_MSG, ID_REQUEST, ID_REPLY, ID_DELETE, NML_QUERY_MSG, NML_PERFORMANCE_TEST_MSG, RCS_GENERIC_CMD, CH1_INIT, CH1_HALT, CH2_INIT, CH2_HALT, CH3_INIT, CH3_HALT, CH1_STATUS, CH2_STATUS, CH3_STATUS, NML_ERROR, NML_TEXT, NML_DISPLAY, NML_OPERATOR_REQUEST, NML_OPERATOR_REPLY, RCS_OI_REQUEST_MSG, RCS_GENERIC_OI_REQUEST, RCS_OI_REPLY_MSG, RCS_GENERIC_OI_REPLY, RCS_GENERIC_STATUS, and RCS_GENERIC_WM.

Definition at line 123 of file nmlmsg.cc.

00124 {
00125   rcs_print_error ("update called for NMLmsg base class.");
00126   rcs_print_error ("(This is an error.)\n");
00127   cms->status = CMS_MISC_ERROR;
00128 }


Field Documentation

int NMLmsg::automatically_clear = 1 [static]
 

Definition at line 32 of file nmlmsg.cc.

NMLTYPE NMLmsg::type
 

Definition at line 66 of file nmlmsg.hh.

Referenced by NML_QR_CLIENT::NML_QR_CLIENT(), NML_MODULE::check_if_new_command(), NML::format_input(), NODE_LINK::get_status(), NODE::initialize_command_buffer(), nml_watch(), NODE_LINK::read_wm(), NML_QR_CLIENT::reset(), NML_MODULE::sendCommand(), NODE_LINK::send_command(), NODE::send_status_message(), NML_MODULE::setSelfCommand(), NML_MODULE::setStatChannel(), NML::write(), NML_MODULE::write_commands_to_subordinates(), NML::write_if_read(), and NML_MODULE::write_status_out().

long NMLmsg::size
 

Definition at line 67 of file nmlmsg.hh.

Referenced by OI_REPLY_QUEUE_NODE::OI_REPLY_QUEUE_NODE(), NML::format_input(), NODE::get_command_message(), NML_MODULE::modifyCommand(), NML::msg2str(), nml_perf_combined_test(), nml_perf_read_test(), nml_perf_write_test(), nml_watch(), NML_MODULE::sendCommand(), NML_MODULE::setSelfCommand(), NML_MODULE::setStatChannel(), NML::write(), NML::write_if_read(), and NML_SERVER_LOCAL_PORT::writer().


The documentation for this class was generated from the following files:
Generated on Sun Dec 2 15:58:56 2001 for rcslib by doxygen1.2.11.1 written by Dimitri van Heesch, © 1997-2001