activemq-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From tab...@apache.org
Subject svn commit: r486199 - /incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/cms/BytesMessage.h
Date Tue, 12 Dec 2006 15:51:07 GMT
Author: tabish
Date: Tue Dec 12 07:51:06 2006
New Revision: 486199

URL: http://svn.apache.org/viewvc?view=rev&rev=486199
Log:
http://issues.apache.org/activemq/browse/AMQCPP-16

Filling in more of the planned BytesMessage interface.

Modified:
    incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/cms/BytesMessage.h

Modified: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/cms/BytesMessage.h
URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/cms/BytesMessage.h?view=diff&rev=486199&r1=486198&r2=486199
==============================================================================
--- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/cms/BytesMessage.h (original)
+++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/cms/BytesMessage.h Tue Dec
12 07:51:06 2006
@@ -66,7 +66,16 @@
          * @throws CMSException
          */
         //virtual bool readBoolean() throw ( cms::CMSException ) = 0;
-      
+        
+        /**
+         * Writes a boolean to the bytes message stream as a 1-byte value. 
+         * The value true is written as the value (byte)1; the value false 
+         * is written as the value (byte)0.
+         * @param value - boolean to write to the stream
+         * @throws CMSException
+         */
+        //virtual void writeBoolean( const bool value ) throw cms::CMSException ) = 0;
+
         /**
          * Reads a Byte from the Bytes message stream
          * @returns unsigned char value from stream
@@ -75,6 +84,13 @@
         //virtual unsigned char readByte() throw ( cms::CMSException ) = 0;
 
         /**
+         * Writes a byte to the bytes message stream as a 1-byte value
+         * @param value - byte to write to the stream
+         * @throws CMSException
+         */
+        virtual void writeByte( const unsigned char value ) throw cms::CMSException ) = 0;
+
+        /**
          * Reads a byte array from the bytes message stream.
          *
          * If the length of vector value is less than the number of bytes
@@ -97,6 +113,14 @@
         //    throw ( cms::CMSException ) = 0;
 
         /**
+         * Writes a byte array to the bytes message stream using the vector
+         * size as the number of bytes to write.
+         * @param value - bytes to write to the stream
+         * @throws CMSException
+         */
+        //virtual void writeBytes( const std::vector<unsigned char>& value ) throw
cms::CMSException ) = 0;
+
+        /**
          * Reads a portion of the bytes message stream.
          * 
          * If the length of array value is less than the number of bytes 
@@ -125,6 +149,18 @@
         //    throw ( cms::CMSException ) = 0;
 
         /**
+         * Writes a portion of a byte array to the bytes message stream.
+         * size as the number of bytes to write.
+         * @param value - bytes to write to the stream
+         * @param offset - the initial offset within the byte array
+         * @param length - the number of bytes to use
+         * @throws CMSException
+         */
+//        virtual void writeBytes( const unsigned char* value,
+//                                 unsigned int offset,
+//                                 unsigned int length ) throw cms::CMSException ) = 0;
+
+        /**
          * Reads a Char from the Bytes message stream
          * @returns char value from stream
          * @throws CMSException
@@ -132,13 +168,27 @@
         //virtual char readChar() throw ( cms::CMSException ) = 0;
 
         /**
-         * Reads a 64 bit float from the Bytes message stream
+         * Writes a char to the bytes message stream as a 1-byte value
+         * @param value - char to write to the stream
+         * @throws CMSException
+         */
+        //virtual void writeChar( const char value ) throw cms::CMSException ) = 0;
+
+        /**
+         * Reads a 32 bit float from the Bytes message stream
          * @returns double value from stream
          * @throws CMSException
          */
         //virtual float readFloat() throw ( cms::CMSException ) = 0;
 
         /**
+         * Writes a float to the bytes message stream as a 4 byte value
+         * @param value - float to write to the stream
+         * @throws CMSException
+         */
+        //virtual void writeFloat( const float value ) throw cms::CMSException ) = 0;
+
+        /**
          * Reads a 64 bit double from the Bytes message stream
          * @returns double value from stream
          * @throws CMSException
@@ -146,6 +196,13 @@
         //virtual double readDouble() throw ( cms::CMSException ) = 0;
 
         /**
+         * Writes a double to the bytes message stream as a 8 byte value
+         * @param value - double to write to the stream
+         * @throws CMSException
+         */
+        //virtual void writeDouble( const double value ) throw cms::CMSException ) = 0;
+
+        /**
          * Reads a 16 bit signed short from the Bytes message stream
          * @returns short value from stream
          * @throws CMSException
@@ -153,6 +210,13 @@
         //virtual short readShort() throw ( cms::CMSException ) = 0;
 
         /**
+         * Writes a signed short to the bytes message stream as a 2 byte value
+         * @param value - signed short to write to the stream
+         * @throws CMSException
+         */
+        //virtual void writeShort( const short value ) throw cms::CMSException ) = 0;
+
+        /**
          * Reads a 16 bit unsigned short from the Bytes message stream
          * @returns unsigned short value from stream
          * @throws CMSException
@@ -160,6 +224,13 @@
         //virtual unsigned short readUnsignedShort() throw ( cms::CMSException ) = 0;
 
         /**
+         * Writes a unsigned short to the bytes message stream as a 2 byte value
+         * @param value - unsigned short to write to the stream
+         * @throws CMSException
+         */
+        //virtual void writeUnsignedShort( const unsigned short value ) throw cms::CMSException
) = 0;
+
+        /**
          * Reads a 32 bit signed intger from the Bytes message stream
          * @returns int value from stream
          * @throws CMSException
@@ -167,11 +238,11 @@
         //virtual int readInt() throw ( cms::CMSException ) = 0;
 
         /**
-         * Reads an ASCII String from the Bytes message stream
-         * @returns String from stream
+         * Writes a signed int to the bytes message stream as a 4 byte value
+         * @param value - signed int to write to the stream
          * @throws CMSException
          */
-        //virtual std::string readString() throw ( cms::CMSException ) = 0;
+        //virtual void writeInt( const int value ) throw cms::CMSException ) = 0;
 
         /**
          * Reads a 64 bit long from the Bytes message stream
@@ -179,6 +250,27 @@
          * @throws CMSException
          */
         //virtual long long readLong() throw ( cms::CMSException ) = 0;
+
+        /**
+         * Writes a long long to the bytes message stream as a 8 byte value
+         * @param value - signed long long to write to the stream
+         * @throws CMSException
+         */
+        //virtual void writeLong( const long long value ) throw cms::CMSException ) = 0;
+
+        /**
+         * Reads an ASCII String from the Bytes message stream
+         * @returns String from stream
+         * @throws CMSException
+         */
+        //virtual std::string readString() throw ( cms::CMSException ) = 0;
+
+        /**
+         * Writes an ASCII String to the Bytes message stream
+         * @param value - String to write to the stream
+         * @throws CMSException
+         */
+        //virtual void readString( const std::string& value ) throw ( cms::CMSException
) = 0;
 
    };
 }



Mime
View raw message