summaryrefslogtreecommitdiff
path: root/ACE/tests/CDR_File_Test.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'ACE/tests/CDR_File_Test.cpp')
-rw-r--r--ACE/tests/CDR_File_Test.cpp59
1 files changed, 29 insertions, 30 deletions
diff --git a/ACE/tests/CDR_File_Test.cpp b/ACE/tests/CDR_File_Test.cpp
index 95352fc903d..12fd23f425b 100644
--- a/ACE/tests/CDR_File_Test.cpp
+++ b/ACE/tests/CDR_File_Test.cpp
@@ -1,22 +1,18 @@
-// $Id$
-
-// ============================================================================
-//
-// = LIBRARY
-// tests
-//
-// = FILENAME
-// CDR_File_Test.cpp
-//
-// = DESCRIPTION
-// Checks the functionality of the ACE CDR streams used for file
-// I/O.
-//
-// = AUTHORS
-// Giga Giguashvili <gregoryg@ParadigmGeo.com> and
-// Douglas C. Schmidt <schmidt@cs.wustl.edu>
-//
-// ============================================================================
+
+//=============================================================================
+/**
+ * @file CDR_File_Test.cpp
+ *
+ * $Id$
+ *
+ * Checks the functionality of the ACE CDR streams used for file
+ * I/O.
+ *
+ *
+ * @author Giga Giguashvili <gregoryg@ParadigmGeo.com> and Douglas C. Schmidt <schmidt@cs.wustl.edu>
+ */
+//=============================================================================
+
#include "test_config.h"
#include "ace/OS_Memory.h"
@@ -32,38 +28,41 @@
// FUZZ: disable check_for_streams_include
#include "ace/streams.h"
-ACE_RCSID(tests, CDR_File_Test, "$Id$")
+
#if !defined (ACE_LACKS_IOSTREAM_TOTALLY)
+/**
+ * @class CDR_Test
+ *
+ * @brief Simple class that's used to read and write CDR streams.
+ */
class CDR_Test
{
- // = TITLE
- // Simple class that's used to read and write CDR streams.
+ /// Output the state of a <CDR_Test> object to the <ostream>.
friend ostream& operator << (ostream &os, const CDR_Test &t);
- // Output the state of a <CDR_Test> object to the <ostream>.
+ /// Convert the state of this object into an <ACE_OutputCDR>.
friend void operator << (ACE_OutputCDR &os, const CDR_Test &t);
- // Convert the state of this object into an <ACE_OutputCDR>.
+ /// Convert the <ACE_InputCDR> into the state of this object.
friend void operator >> (ACE_InputCDR &is, CDR_Test &);
- // Convert the <ACE_InputCDR> into the state of this object.
public:
+ /// Default constructor.
CDR_Test (void);
- // Default constructor.
+ /// Constructor.
CDR_Test (ACE_CDR::Char o,
ACE_CDR::Short s,
ACE_CDR::Long w,
ACE_CDR::ULongLong lw,
ACE_CDR::Float f,
ACE_CDR::Double d);
- // Constructor.
+ /// Compare <rhs> for equality with <this>.
bool operator == (const CDR_Test &rhs) const;
- // Compare <rhs> for equality with <this>.
private:
ACE_CDR::Char char_;
@@ -185,9 +184,9 @@ CDR_Test::operator == (const CDR_Test &rhs) const
return false;
if (this->word8_ != rhs.word8_)
return false;
- if (this->fpoint_ != rhs.fpoint_)
+ if (!ACE::is_equal (this->fpoint_, rhs.fpoint_))
return false;
- if (this->dprec_ != rhs.dprec_)
+ if (!ACE::is_equal (this->dprec_, rhs.dprec_))
return false;
return true;
}