You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@activemq.apache.org by nm...@apache.org on 2007/01/21 02:03:46 UTC
svn commit: r498226 [1/2] - in
/incubator/activemq/activemq-cpp/trunk/activemq-cpp: ./ src/examples/
src/main/ src/main/activemq/concurrent/ src/main/activemq/connector/
src/main/activemq/connector/openwire/commands/
src/main/activemq/connector/openwir...
Author: nmittler
Date: Sat Jan 20 17:03:42 2007
New Revision: 498226
URL: http://svn.apache.org/viewvc?view=rev&rev=498226
Log:
[AMQCPP-49] Updates throughout the source code to fix warnings from -Wall
Modified:
incubator/activemq/activemq-cpp/trunk/activemq-cpp/configure.ac
incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/examples/main.cpp
incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/Makefile.am
incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/concurrent/Mutex.h
incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/concurrent/ThreadPool.cpp
incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/ConnectorException.h
incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/commands/ActiveMQBytesMessage.h
incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/commands/ActiveMQMapMessage.h
incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/commands/ActiveMQMessage.cpp
incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/commands/ActiveMQTextMessage.h
incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/commands/BaseDataStructure.h
incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/commands/BooleanExpression.h
incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/commands/BrokerError.h
incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/BaseDataStreamMarshaller.cpp
incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/PrimitiveMapMarshaller.cpp
incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/v2/ConnectionControlMarshaller.cpp
incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/v2/IntegerResponseMarshaller.cpp
incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/v2/ReplayCommandMarshaller.cpp
incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/v2/ResponseMarshaller.cpp
incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/stomp/StompConnector.cpp
incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/stomp/StompConnectorException.h
incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/stomp/StompSelector.h
incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/stomp/StompSessionManager.cpp
incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/stomp/commands/AbstractCommand.h
incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/stomp/marshal/MarshalException.h
incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/exceptions/ActiveMQException.h
incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/exceptions/IllegalArgumentException.h
incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/exceptions/IllegalMonitorStateException.h
incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/exceptions/IllegalStateException.h
incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/exceptions/IndexOutOfBoundsException.h
incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/exceptions/InterruptedException.h
incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/exceptions/InvalidStateException.h
incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/exceptions/NoSuchElementException.h
incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/exceptions/NullPointerException.h
incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/exceptions/RuntimeException.h
incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/exceptions/UnsupportedOperationException.h
incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/io/BlockingByteArrayInputStream.cpp
incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/io/BlockingByteArrayInputStream.h
incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/io/BufferedInputStream.cpp
incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/io/BufferedInputStream.h
incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/io/ByteArrayInputStream.cpp
incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/io/ByteArrayInputStream.h
incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/io/DataInputStream.cpp
incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/io/DataInputStream.h
incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/io/DataOutputStream.cpp
incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/io/DataOutputStream.h
incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/io/EOFException.h
incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/io/IOException.h
incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/io/InputStream.h
incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/logger/LogManager.cpp
incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/logger/LogRecord.h
incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/logger/LogWriter.cpp
incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/logger/Logger.cpp
incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/network/SocketException.h
incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/network/SocketInputStream.cpp
incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/network/SocketInputStream.h
incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/transport/BrokerError.h
incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/transport/CommandIOException.h
incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/transport/IOTransport.cpp
incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/transport/IOTransport.h
incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/transport/IOTransportFactory.cpp
incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/transport/IOTransportFactory.h
incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/transport/TransportFactoryMap.cpp
incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/transport/TransportFactoryMap.h
incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/transport/TransportFilter.h
incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/util/Config.h
incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/test-integration/integration/various/SimpleRollbackTest.cpp
incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/test-integration/main.cpp
incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/test/activemq/concurrent/MutexTest.h
incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/test/activemq/concurrent/ThreadPoolTest.h
incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/test/activemq/concurrent/ThreadTest.h
incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/test/activemq/connector/ConnectorFactoryMapRegistrarTest.h
incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/test/activemq/connector/ConnectorFactoryMapTest.h
incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/test/activemq/connector/stomp/StompConnectorTest.h
incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/test/activemq/connector/stomp/StompFrameTest.h
incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/test/activemq/connector/stomp/commands/BytesMessageCommandTest.h
incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/test/activemq/connector/stomp/commands/MessageCommandTest.h
incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/test/activemq/connector/stomp/commands/TextMessageCommandTest.h
incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/test/activemq/core/ActiveMQConnectionTest.h
incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/test/activemq/core/ActiveMQSessionTest.h
incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/test/activemq/exceptions/ActiveMQExceptionTest.h
incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/test/activemq/io/BufferedInputStreamTest.h
incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/test/activemq/io/BufferedOutputStreamTest.h
incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/test/activemq/io/DataInputStreamTest.h
incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/test/activemq/io/DataOutputStreamTest.h
incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/test/activemq/network/SocketTest.h
incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/test/activemq/transport/DummyTransport.h
incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/test/activemq/transport/IOTransportTest.h
incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/test/activemq/transport/ResponseCorrelatorTest.h
incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/test/activemq/transport/TransportFactoryMapRegistrarTest.h
incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/test/activemq/transport/TransportFactoryMapTest.h
incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/test/main.cpp
Modified: incubator/activemq/activemq-cpp/trunk/activemq-cpp/configure.ac
URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/configure.ac?view=diff&rev=498226&r1=498225&r2=498226
==============================================================================
--- incubator/activemq/activemq-cpp/trunk/activemq-cpp/configure.ac (original)
+++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/configure.ac Sat Jan 20 17:03:42 2007
@@ -85,16 +85,22 @@
AM_PATH_CPPUNIT(1.10.2, cppunit=yes, cppunit=no; AC_MSG_RESULT([no. Unit and Integration tests disabled]))
AM_CONDITIONAL(BUILD_CPPUNIT_TESTS, test x$cppunit = xyes)
+# Define globals for all platforms
+CXXFLAGS="$CXXFLAGS -fstrict-aliasing -Wstrict-aliasing=2 -W -Wall"
+#-Wno-unused-parameter
+
+LIBS="$LIBS"
+
case "${host_os}" in
*darwin* ) ## Mac OS X configuration
- CXXFLAGS="$CXXFLAGS -fstrict-aliasing -Wstrict-aliasing=2"
- LIBS=""
+ CXXFLAGS="$CXXFLAGS"
+ LIBS="$LIBS"
;;
*cygwin* ) ## Cygwin configuration
# LIBS="-lwinmm -lm";
- CXXFLAGS="$CXXFLAGS -fstrict-aliasing -Wstrict-aliasing=2"
+ CXXFLAGS="$CXXFLAGS"
LIBS="$LIBS -lm -lpthread -luuid -lrpcrt4"
;;
@@ -102,7 +108,7 @@
AC_CHECK_LIB(pthread, pthread_create,[have_pthread="yes"],
AC_MSG_ERROR([libpthread not found!]))
- CXXFLAGS="$CXXFLAGS -fstrict-aliasing -Wstrict-aliasing=2"
+ CXXFLAGS="$CXXFLAGS"
LIBS="$LIBS -lm -lpthread -luuid -lsocket -lrt"
;;
@@ -111,7 +117,7 @@
AC_CHECK_LIB(pthread, pthread_create,[have_pthread="yes"],
AC_MSG_ERROR([libpthread not found!]))
- CXXFLAGS="$CXXFLAGS -fstrict-aliasing -Wstrict-aliasing=2"
+ CXXFLAGS="$CXXFLAGS"
LIBS="$LIBS -lm -lpthread -luuid"
esac
Modified: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/examples/main.cpp
URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/examples/main.cpp?view=diff&rev=498226&r1=498225&r2=498226
==============================================================================
--- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/examples/main.cpp (original)
+++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/examples/main.cpp Sat Jan 20 17:03:42 2007
@@ -21,6 +21,7 @@
#include <activemq/concurrent/Runnable.h>
#include <activemq/core/ActiveMQConnectionFactory.h>
#include <activemq/util/Integer.h>
+#include <activemq/util/Config.h>
#include <cms/Connection.h>
#include <cms/Session.h>
#include <cms/TextMessage.h>
@@ -221,7 +222,7 @@
// If something bad happens you see it here as this class is also been
// registered as an ExceptionListener with the connection.
- virtual void onException( const CMSException& ex ) {
+ virtual void onException( const CMSException& ex ACTIVEMQ_ATTRIBUTE_UNUSED) {
printf("JMS Exception occured. Shutting down client.\n");
}
@@ -264,7 +265,7 @@
}
};
-int main(int argc, char* argv[]) {
+int main(int argc ACTIVEMQ_ATTRIBUTE_UNUSED, char* argv[] ACTIVEMQ_ATTRIBUTE_UNUSED) {
std::cout << "=====================================================\n";
std::cout << "Starting the example:" << std::endl;
Modified: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/Makefile.am
URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/Makefile.am?view=diff&rev=498226&r1=498225&r2=498226
==============================================================================
--- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/Makefile.am (original)
+++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/Makefile.am Sat Jan 20 17:03:42 2007
@@ -66,6 +66,7 @@
activemq/transport/IOTransport.cpp \
activemq/transport/TransportFactoryMap.cpp \
activemq/transport/TcpTransportFactory.cpp \
+ activemq/transport/TransportFilter.cpp \
activemq/util/StringTokenizer.cpp \
activemq/util/Guid.cpp \
activemq/util/Date.cpp \
Modified: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/concurrent/Mutex.h
URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/concurrent/Mutex.h?view=diff&rev=498226&r1=498225&r2=498226
==============================================================================
--- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/concurrent/Mutex.h (original)
+++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/concurrent/Mutex.h Sat Jan 20 17:03:42 2007
@@ -219,10 +219,10 @@
int returnValue = 0;
if(millisecs != WAIT_INFINITE)
{
- timeval now = {};
+ timeval now = {0,0};
gettimeofday(&now, NULL);
- timespec wait = {};
+ timespec wait = {0,0};
wait.tv_sec = now.tv_sec + (millisecs / 1000);
wait.tv_nsec = (now.tv_usec * 1000) + ((millisecs % 1000) * 1000000);
Modified: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/concurrent/ThreadPool.cpp
URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/concurrent/ThreadPool.cpp?view=diff&rev=498226&r1=498225&r2=498226
==============================================================================
--- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/concurrent/ThreadPool.cpp (original)
+++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/concurrent/ThreadPool.cpp Sat Jan 20 17:03:42 2007
@@ -17,6 +17,7 @@
#include <activemq/concurrent/ThreadPool.h>
#include <activemq/concurrent/Concurrent.h>
#include <activemq/exceptions/IllegalArgumentException.h>
+#include <activemq/util/Config.h>
#ifdef min
#undef min
@@ -270,7 +271,7 @@
}
////////////////////////////////////////////////////////////////////////////////
-void ThreadPool::onTaskStarted( PooledThread* thread )
+void ThreadPool::onTaskStarted( PooledThread* thread ACTIVEMQ_ATTRIBUTE_UNUSED)
{
try
{
@@ -299,7 +300,7 @@
}
////////////////////////////////////////////////////////////////////////////////
-void ThreadPool::onTaskCompleted( PooledThread* thread )
+void ThreadPool::onTaskCompleted( PooledThread* thread ACTIVEMQ_ATTRIBUTE_UNUSED)
{
try
{
@@ -317,7 +318,7 @@
////////////////////////////////////////////////////////////////////////////////
void ThreadPool::onTaskException(
PooledThread* thread,
- exceptions::ActiveMQException& ex)
+ exceptions::ActiveMQException& ex ACTIVEMQ_ATTRIBUTE_UNUSED)
{
//LOGCMS_DEBUG(logger, "ThreadPool::onTaskException: ");
Modified: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/ConnectorException.h
URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/ConnectorException.h?view=diff&rev=498226&r1=498225&r2=498226
==============================================================================
--- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/ConnectorException.h (original)
+++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/ConnectorException.h Sat Jan 20 17:03:42 2007
@@ -38,7 +38,9 @@
* Copy Constructor
* @param ex the exception to copy
*/
- ConnectorException( const exceptions::ActiveMQException& ex ){
+ ConnectorException( const exceptions::ActiveMQException& ex )
+ : exceptions::ActiveMQException()
+ {
*(ActiveMQException*)this = ex;
}
@@ -46,7 +48,9 @@
* Copy Constructor
* @param ex the exception to copy, which is an instance of this type
*/
- ConnectorException( const ConnectorException& ex ){
+ ConnectorException( const ConnectorException& ex )
+ : exceptions::ActiveMQException()
+ {
*(exceptions::ActiveMQException*)this = ex;
}
@@ -59,6 +63,7 @@
ConnectorException( const char* file,
const int lineNumber,
const char* msg, ... )
+ : exceptions::ActiveMQException()
{
va_list vargs;
va_start( vargs, msg );
Modified: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/commands/ActiveMQBytesMessage.h
URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/commands/ActiveMQBytesMessage.h?view=diff&rev=498226&r1=498225&r2=498226
==============================================================================
--- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/commands/ActiveMQBytesMessage.h (original)
+++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/commands/ActiveMQBytesMessage.h Sat Jan 20 17:03:42 2007
@@ -24,6 +24,7 @@
#endif
#include <activemq/connector/openwire/commands/ActiveMQMessage.h>
+#include <activemq/util/Config.h>
#include <cms/BytesMessage.h>
#include <vector>
#include <string>
@@ -300,7 +301,7 @@
* Sets the Destination for this message
* @param destination - Destination Object
*/
- virtual void setCMSDestination( const cms::Destination* destination ) {
+ virtual void setCMSDestination( const cms::Destination* destination ACTIVEMQ_ATTRIBUTE_UNUSED) {
// this->setDestination( destination );
}
@@ -330,7 +331,7 @@
* Sets the CMS Message Id for this message
* @param id - time value
*/
- virtual void setCMSMessageId( const std::string& id ) {}
+ virtual void setCMSMessageId( const std::string& id ACTIVEMQ_ATTRIBUTE_UNUSED) {}
/**
* Gets the Priority Value for this Message
@@ -360,7 +361,7 @@
* Sets the Redelivered Flag for this message
* @param redelivered - boolean redelivered value
*/
- virtual void setCMSRedelivered( bool redelivered ) {}
+ virtual void setCMSRedelivered( bool redelivered ACTIVEMQ_ATTRIBUTE_UNUSED) {}
/**
* Gets the CMS Reply To Address for this Message
Modified: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/commands/ActiveMQMapMessage.h
URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/commands/ActiveMQMapMessage.h?view=diff&rev=498226&r1=498225&r2=498226
==============================================================================
--- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/commands/ActiveMQMapMessage.h (original)
+++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/commands/ActiveMQMapMessage.h Sat Jan 20 17:03:42 2007
@@ -24,6 +24,7 @@
#endif
#include <activemq/connector/openwire/commands/ActiveMQMessage.h>
+#include <activemq/util/Config.h>
#include <cms/MapMessage.h>
#include <vector>
#include <string>
@@ -300,7 +301,7 @@
* Sets the Destination for this message
* @param destination - Destination Object
*/
- virtual void setCMSDestination( const cms::Destination* destination ) {
+ virtual void setCMSDestination( const cms::Destination* destination ACTIVEMQ_ATTRIBUTE_UNUSED ) {
// this->setDestination( destination );
}
@@ -330,7 +331,7 @@
* Sets the CMS Message Id for this message
* @param id - time value
*/
- virtual void setCMSMessageId( const std::string& id ) {}
+ virtual void setCMSMessageId( const std::string& id ACTIVEMQ_ATTRIBUTE_UNUSED ) {}
/**
* Gets the Priority Value for this Message
@@ -360,7 +361,7 @@
* Sets the Redelivered Flag for this message
* @param redelivered - boolean redelivered value
*/
- virtual void setCMSRedelivered( bool redelivered ) {}
+ virtual void setCMSRedelivered( bool redelivered ACTIVEMQ_ATTRIBUTE_UNUSED ) {}
/**
* Gets the CMS Reply To Address for this Message
Modified: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/commands/ActiveMQMessage.cpp
URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/commands/ActiveMQMessage.cpp?view=diff&rev=498226&r1=498225&r2=498226
==============================================================================
--- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/commands/ActiveMQMessage.cpp (original)
+++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/commands/ActiveMQMessage.cpp Sat Jan 20 17:03:42 2007
@@ -16,6 +16,7 @@
*/
#include <activemq/connector/openwire/commands/ActiveMQMessage.h>
#include <activemq/connector/openwire/OpenWireFormat.h>
+#include <activemq/util/Config.h>
using namespace std;
using namespace activemq;
@@ -37,7 +38,7 @@
}
////////////////////////////////////////////////////////////////////////////////
-void ActiveMQMessage::beforeMarshall( OpenWireFormat* wireFormat )
+void ActiveMQMessage::beforeMarshall( OpenWireFormat* wireFormat ACTIVEMQ_ATTRIBUTE_UNUSED )
{
// marshalledProperties.clear();
// if( !properties.empty() )
Modified: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/commands/ActiveMQTextMessage.h
URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/commands/ActiveMQTextMessage.h?view=diff&rev=498226&r1=498225&r2=498226
==============================================================================
--- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/commands/ActiveMQTextMessage.h (original)
+++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/commands/ActiveMQTextMessage.h Sat Jan 20 17:03:42 2007
@@ -24,6 +24,7 @@
#endif
#include <activemq/connector/openwire/commands/ActiveMQMessage.h>
+#include <activemq/util/Config.h>
#include <cms/TextMessage.h>
#include <vector>
#include <string>
@@ -300,7 +301,7 @@
* Sets the Destination for this message
* @param destination - Destination Object
*/
- virtual void setCMSDestination( const cms::Destination* destination ) {
+ virtual void setCMSDestination( const cms::Destination* destination ACTIVEMQ_ATTRIBUTE_UNUSED ) {
// this->setDestination(
// dynamic_cast<const ActiveMQDestination*>( destination ) );
}
@@ -331,7 +332,7 @@
* Sets the CMS Message Id for this message
* @param id - time value
*/
- virtual void setCMSMessageId( const std::string& id ) {}
+ virtual void setCMSMessageId( const std::string& id ACTIVEMQ_ATTRIBUTE_UNUSED ) {}
/**
* Gets the Priority Value for this Message
@@ -361,7 +362,7 @@
* Sets the Redelivered Flag for this message
* @param redelivered - boolean redelivered value
*/
- virtual void setCMSRedelivered( bool redelivered ) {}
+ virtual void setCMSRedelivered( bool redelivered ACTIVEMQ_ATTRIBUTE_UNUSED ) {}
/**
* Gets the CMS Reply To Address for this Message
Modified: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/commands/BaseDataStructure.h
URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/commands/BaseDataStructure.h?view=diff&rev=498226&r1=498225&r2=498226
==============================================================================
--- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/commands/BaseDataStructure.h (original)
+++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/commands/BaseDataStructure.h Sat Jan 20 17:03:42 2007
@@ -19,6 +19,7 @@
#define _ACTIVEMQ_CONNECTOR_OPENWIRE_COMMANDS_BASEDATASTRUCTURE_H_
#include <activemq/connector/openwire/commands/DataStructure.h>
+#include <activemq/util/Config.h>
namespace activemq{
namespace connector{
@@ -48,25 +49,25 @@
* Perform any processing needed before an marshal
* @param wireformat - the OpenWireFormat object in use.
*/
- virtual void beforeMarshall( OpenWireFormat* wireFormat ) {}
+ virtual void beforeMarshall( OpenWireFormat* wireFormat ACTIVEMQ_ATTRIBUTE_UNUSED) {}
/**
* Perform any processing needed after an unmarshal
* @param wireformat - the OpenWireFormat object in use.
*/
- virtual void afterMarshall( OpenWireFormat* wireFormat ) {}
+ virtual void afterMarshall( OpenWireFormat* wireFormat ACTIVEMQ_ATTRIBUTE_UNUSED) {}
/**
* Perform any processing needed before an unmarshal
* @param wireformat - the OpenWireFormat object in use.
*/
- virtual void beforeUnmarshall( OpenWireFormat* wireFormat ) {}
+ virtual void beforeUnmarshall( OpenWireFormat* wireFormat ACTIVEMQ_ATTRIBUTE_UNUSED) {}
/**
* Perform any processing needed after an unmarshal
* @param wireformat - the OpenWireFormat object in use.
*/
- virtual void afterUnmarshall( OpenWireFormat* wireFormat ) {}
+ virtual void afterUnmarshall( OpenWireFormat* wireFormat ACTIVEMQ_ATTRIBUTE_UNUSED) {}
/**
* Called to set the data to this object that will contain the objects
@@ -74,8 +75,8 @@
* @param wireFormat - the wireformat object to control unmarshaling
* @param data - vector of object binary data
*/
- virtual void setMarshalledForm( OpenWireFormat* wireFormat,
- const std::vector<char>& data ) {}
+ virtual void setMarshalledForm( OpenWireFormat* wireFormat ACTIVEMQ_ATTRIBUTE_UNUSED,
+ const std::vector<char>& data ACTIVEMQ_ATTRIBUTE_UNUSED) {}
/**
* Called to get the data to this object that will contain the objects
@@ -83,7 +84,7 @@
* @param wireFormat - the wireformat object to control unmarshaling
* @return buffer that holds the objects data.
*/
- virtual std::vector<unsigned char> getMarshalledForm( OpenWireFormat* wireFormat ) {
+ virtual std::vector<unsigned char> getMarshalledForm( OpenWireFormat* wireFormat ACTIVEMQ_ATTRIBUTE_UNUSED) {
return std::vector<unsigned char>();
}
Modified: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/commands/BooleanExpression.h
URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/commands/BooleanExpression.h?view=diff&rev=498226&r1=498225&r2=498226
==============================================================================
--- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/commands/BooleanExpression.h (original)
+++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/commands/BooleanExpression.h Sat Jan 20 17:03:42 2007
@@ -19,6 +19,7 @@
#define _ACTIVEMQ_CONNECTOR_OPENWIRE_COMMANDS_BOOLEANEXPRESSION_H_
#include <activemq/connector/openwire/commands/BaseDataStructure.h>
+#include <activemq/util/Config.h>
namespace activemq{
namespace connector{
@@ -44,7 +45,7 @@
* members, overwriting any existing data.
* @return src - Source Object
*/
- virtual void copyDataStructure( const DataStructure* src ) {}
+ virtual void copyDataStructure( const DataStructure* src ACTIVEMQ_ATTRIBUTE_UNUSED) {}
};
Modified: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/commands/BrokerError.h
URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/commands/BrokerError.h?view=diff&rev=498226&r1=498225&r2=498226
==============================================================================
--- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/commands/BrokerError.h (original)
+++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/commands/BrokerError.h Sat Jan 20 17:03:42 2007
@@ -49,7 +49,7 @@
BrokerError() {}
virtual ~BrokerError() {
- for( int i = 0; i < stackTraceElements.size(); ++i ) {
+ for( unsigned int i = 0; i < stackTraceElements.size(); ++i ) {
delete stackTraceElements[i];
}
}
@@ -92,7 +92,7 @@
this->setMessage( srcErr->getMessage() );
this->setExceptionClass( srcErr->getExceptionClass() );
- for( int i = 0; i < srcErr->getStackTraceElements().size(); ++i ) {
+ for( unsigned int i = 0; i < srcErr->getStackTraceElements().size(); ++i ) {
if( srcErr->getStackTraceElements()[i] != NULL ) {
StackTraceElement* element = new StackTraceElement;
*element = *( srcErr->getStackTraceElements()[i] );
Modified: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/BaseDataStreamMarshaller.cpp
URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/BaseDataStreamMarshaller.cpp?view=diff&rev=498226&r1=498225&r2=498226
==============================================================================
--- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/BaseDataStreamMarshaller.cpp (original)
+++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/BaseDataStreamMarshaller.cpp Sat Jan 20 17:03:42 2007
@@ -26,6 +26,7 @@
#include <activemq/exceptions/ActiveMQException.h>
#include <activemq/util/Long.h>
#include <activemq/util/Integer.h>
+#include <activemq/util/Config.h>
using namespace std;
using namespace activemq;
@@ -324,7 +325,7 @@
}
////////////////////////////////////////////////////////////////////////////////
-int BaseDataStreamMarshaller::tightMarshalLong1( OpenWireFormat* wireFormat,
+int BaseDataStreamMarshaller::tightMarshalLong1( OpenWireFormat* wireFormat ACTIVEMQ_ATTRIBUTE_UNUSED,
long long value,
utils::BooleanStream* bs )
throw ( io::IOException ) {
@@ -366,7 +367,7 @@
}
////////////////////////////////////////////////////////////////////////////////
-void BaseDataStreamMarshaller::tightMarshalLong2( OpenWireFormat* wireFormat,
+void BaseDataStreamMarshaller::tightMarshalLong2( OpenWireFormat* wireFormat ACTIVEMQ_ATTRIBUTE_UNUSED,
long long value,
io::DataOutputStream* dataOut,
utils::BooleanStream* bs )
@@ -395,7 +396,7 @@
////////////////////////////////////////////////////////////////////////////////
long long BaseDataStreamMarshaller::tightUnmarshalLong(
- OpenWireFormat* wireFormat,
+ OpenWireFormat* wireFormat ACTIVEMQ_ATTRIBUTE_UNUSED,
io::DataInputStream* dataIn,
utils::BooleanStream* bs )
throw ( io::IOException ) {
@@ -424,7 +425,7 @@
}
////////////////////////////////////////////////////////////////////////////////
-void BaseDataStreamMarshaller::looseMarshalLong( OpenWireFormat* wireFormat,
+void BaseDataStreamMarshaller::looseMarshalLong( OpenWireFormat* wireFormat ACTIVEMQ_ATTRIBUTE_UNUSED,
long long value,
io::DataOutputStream* dataOut )
throw ( io::IOException ) {
@@ -439,7 +440,7 @@
////////////////////////////////////////////////////////////////////////////////
long long BaseDataStreamMarshaller::looseUnmarshalLong(
- OpenWireFormat* wireFormat,
+ OpenWireFormat* wireFormat ACTIVEMQ_ATTRIBUTE_UNUSED,
io::DataInputStream* dataIn )
throw ( io::IOException ) {
@@ -725,7 +726,7 @@
////////////////////////////////////////////////////////////////////////////////
std::vector<unsigned char> BaseDataStreamMarshaller::tightUnmarshalConstByteArray(
io::DataInputStream* dataIn,
- utils::BooleanStream* bs,
+ utils::BooleanStream* bs ACTIVEMQ_ATTRIBUTE_UNUSED,
int size )
throw ( io::IOException ) {
Modified: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/PrimitiveMapMarshaller.cpp
URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/PrimitiveMapMarshaller.cpp?view=diff&rev=498226&r1=498225&r2=498226
==============================================================================
--- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/PrimitiveMapMarshaller.cpp (original)
+++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/PrimitiveMapMarshaller.cpp Sat Jan 20 17:03:42 2007
@@ -21,6 +21,7 @@
#include <activemq/io/ByteArrayOutputStream.h>
#include <activemq/io/DataInputStream.h>
#include <activemq/io/DataOutputStream.h>
+#include <activemq/util/Config.h>
using namespace activemq;
using namespace activemq::io;
@@ -96,8 +97,8 @@
}
///////////////////////////////////////////////////////////////////////////////
-void PrimitiveMapMarshaller::marshalPrimitive( io::DataOutputStream* dataOut,
- util::PrimitiveMap::ValueNode& value )
+void PrimitiveMapMarshaller::marshalPrimitive( io::DataOutputStream* dataOut ACTIVEMQ_ATTRIBUTE_UNUSED,
+ util::PrimitiveMap::ValueNode& value ACTIVEMQ_ATTRIBUTE_UNUSED)
throw ( cms::CMSException ) {
try {
@@ -185,9 +186,9 @@
}
///////////////////////////////////////////////////////////////////////////////
-void PrimitiveMapMarshaller::unmarshalPrimitive( io::DataInputStream* dataIn,
- const std::string& key,
- util::PrimitiveMap& map )
+void PrimitiveMapMarshaller::unmarshalPrimitive( io::DataInputStream* dataIn ACTIVEMQ_ATTRIBUTE_UNUSED,
+ const std::string& key ACTIVEMQ_ATTRIBUTE_UNUSED,
+ util::PrimitiveMap& map ACTIVEMQ_ATTRIBUTE_UNUSED)
throw ( cms::CMSException ) {
try {
Modified: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/v2/ConnectionControlMarshaller.cpp
URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/v2/ConnectionControlMarshaller.cpp?view=diff&rev=498226&r1=498225&r2=498226
==============================================================================
--- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/v2/ConnectionControlMarshaller.cpp (original)
+++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/v2/ConnectionControlMarshaller.cpp Sat Jan 20 17:03:42 2007
@@ -79,8 +79,8 @@
BaseCommandMarshaller::tightMarshal2( wireFormat, dataStructure, dataOut, bs );
- ConnectionControl* info =
- dynamic_cast<ConnectionControl*>( dataStructure );
+ /*ConnectionControl* info =
+ dynamic_cast<ConnectionControl*>( dataStructure );*/
bs->readBoolean();
bs->readBoolean();
bs->readBoolean();
Modified: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/v2/IntegerResponseMarshaller.cpp
URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/v2/IntegerResponseMarshaller.cpp?view=diff&rev=498226&r1=498225&r2=498226
==============================================================================
--- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/v2/IntegerResponseMarshaller.cpp (original)
+++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/v2/IntegerResponseMarshaller.cpp Sat Jan 20 17:03:42 2007
@@ -57,8 +57,8 @@
///////////////////////////////////////////////////////////////////////////////
int IntegerResponseMarshaller::tightMarshal1( OpenWireFormat* wireFormat, DataStructure* dataStructure, BooleanStream* bs ) throw( io::IOException ){
- IntegerResponse* info =
- dynamic_cast<IntegerResponse*>( dataStructure );
+ /*IntegerResponse* info =
+ dynamic_cast<IntegerResponse*>( dataStructure );*/
int rc = ResponseMarshaller::tightMarshal1( wireFormat, dataStructure, bs );
Modified: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/v2/ReplayCommandMarshaller.cpp
URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/v2/ReplayCommandMarshaller.cpp?view=diff&rev=498226&r1=498225&r2=498226
==============================================================================
--- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/v2/ReplayCommandMarshaller.cpp (original)
+++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/v2/ReplayCommandMarshaller.cpp Sat Jan 20 17:03:42 2007
@@ -58,8 +58,8 @@
///////////////////////////////////////////////////////////////////////////////
int ReplayCommandMarshaller::tightMarshal1( OpenWireFormat* wireFormat, DataStructure* dataStructure, BooleanStream* bs ) throw( io::IOException ){
- ReplayCommand* info =
- dynamic_cast<ReplayCommand*>( dataStructure );
+ /*ReplayCommand* info =
+ dynamic_cast<ReplayCommand*>( dataStructure );*/
int rc = BaseCommandMarshaller::tightMarshal1( wireFormat, dataStructure, bs );
Modified: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/v2/ResponseMarshaller.cpp
URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/v2/ResponseMarshaller.cpp?view=diff&rev=498226&r1=498225&r2=498226
==============================================================================
--- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/v2/ResponseMarshaller.cpp (original)
+++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/openwire/marshal/v2/ResponseMarshaller.cpp Sat Jan 20 17:03:42 2007
@@ -57,8 +57,8 @@
///////////////////////////////////////////////////////////////////////////////
int ResponseMarshaller::tightMarshal1( OpenWireFormat* wireFormat, DataStructure* dataStructure, BooleanStream* bs ) throw( io::IOException ){
- Response* info =
- dynamic_cast<Response*>( dataStructure );
+ /*Response* info =
+ dynamic_cast<Response*>( dataStructure );*/
int rc = BaseCommandMarshaller::tightMarshal1( wireFormat, dataStructure, bs );
Modified: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/stomp/StompConnector.cpp
URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/stomp/StompConnector.cpp?view=diff&rev=498226&r1=498225&r2=498226
==============================================================================
--- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/stomp/StompConnector.cpp (original)
+++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/stomp/StompConnector.cpp Sat Jan 20 17:03:42 2007
@@ -37,6 +37,7 @@
#include <activemq/connector/stomp/StompProducerInfo.h>
#include <activemq/connector/stomp/StompTransactionInfo.h>
#include <activemq/util/Integer.h>
+#include <activemq/util/Config.h>
using namespace std;
using namespace activemq;
@@ -363,7 +364,7 @@
////////////////////////////////////////////////////////////////////////////////
cms::Topic* StompConnector::createTopic( const std::string& name,
- SessionInfo* session )
+ SessionInfo* session ACTIVEMQ_ATTRIBUTE_UNUSED)
throw ( ConnectorException )
{
try
@@ -378,7 +379,7 @@
////////////////////////////////////////////////////////////////////////////////
cms::Queue* StompConnector::createQueue( const std::string& name,
- SessionInfo* session )
+ SessionInfo* session ACTIVEMQ_ATTRIBUTE_UNUSED)
throw ( ConnectorException )
{
try
@@ -393,7 +394,7 @@
////////////////////////////////////////////////////////////////////////////////
cms::TemporaryTopic* StompConnector::createTemporaryTopic(
- SessionInfo* session )
+ SessionInfo* session ACTIVEMQ_ATTRIBUTE_UNUSED)
throw ( ConnectorException )
{
try
@@ -409,7 +410,7 @@
////////////////////////////////////////////////////////////////////////////////
cms::TemporaryQueue* StompConnector::createTemporaryQueue(
- SessionInfo* session )
+ SessionInfo* session ACTIVEMQ_ATTRIBUTE_UNUSED)
throw ( ConnectorException )
{
try
@@ -491,7 +492,7 @@
////////////////////////////////////////////////////////////////////////////////
void StompConnector::acknowledge( const SessionInfo* session,
const cms::Message* message,
- AckType ackType = ConsumedAck )
+ AckType ackType ACTIVEMQ_ATTRIBUTE_UNUSED)
throw ( ConnectorException )
{
try
@@ -559,7 +560,7 @@
////////////////////////////////////////////////////////////////////////////////
void StompConnector::commit( TransactionInfo* transaction,
- SessionInfo* session )
+ SessionInfo* session ACTIVEMQ_ATTRIBUTE_UNUSED)
throw ( ConnectorException )
{
try
@@ -579,7 +580,7 @@
////////////////////////////////////////////////////////////////////////////////
void StompConnector::rollback( TransactionInfo* transaction,
- SessionInfo* session )
+ SessionInfo* session ACTIVEMQ_ATTRIBUTE_UNUSED)
throw ( ConnectorException )
{
try
@@ -599,7 +600,7 @@
////////////////////////////////////////////////////////////////////////////////
cms::Message* StompConnector::createMessage(
- SessionInfo* session,
+ SessionInfo* session ACTIVEMQ_ATTRIBUTE_UNUSED,
TransactionInfo* transaction )
throw ( ConnectorException )
{
@@ -623,7 +624,7 @@
////////////////////////////////////////////////////////////////////////////////
cms::BytesMessage* StompConnector::createBytesMessage(
- SessionInfo* session,
+ SessionInfo* session ACTIVEMQ_ATTRIBUTE_UNUSED,
TransactionInfo* transaction )
throw ( ConnectorException )
{
@@ -647,7 +648,7 @@
////////////////////////////////////////////////////////////////////////////////
cms::TextMessage* StompConnector::createTextMessage(
- SessionInfo* session,
+ SessionInfo* session ACTIVEMQ_ATTRIBUTE_UNUSED,
TransactionInfo* transaction )
throw ( ConnectorException )
{
@@ -671,8 +672,8 @@
////////////////////////////////////////////////////////////////////////////////
cms::MapMessage* StompConnector::createMapMessage(
- SessionInfo* session,
- TransactionInfo* transaction )
+ SessionInfo* session ACTIVEMQ_ATTRIBUTE_UNUSED,
+ TransactionInfo* transaction ACTIVEMQ_ATTRIBUTE_UNUSED )
throw ( ConnectorException )
{
try
@@ -687,7 +688,7 @@
}
////////////////////////////////////////////////////////////////////////////////
-void StompConnector::unsubscribe( const std::string& name )
+void StompConnector::unsubscribe( const std::string& name ACTIVEMQ_ATTRIBUTE_UNUSED )
throw ( ConnectorException )
{
try
@@ -766,7 +767,7 @@
////////////////////////////////////////////////////////////////////////////////
void StompConnector::onTransportException(
- transport::Transport* source,
+ transport::Transport* source ACTIVEMQ_ATTRIBUTE_UNUSED,
const exceptions::ActiveMQException& ex )
{
try
Modified: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/stomp/StompConnectorException.h
URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/stomp/StompConnectorException.h?view=diff&rev=498226&r1=498225&r2=498226
==============================================================================
--- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/stomp/StompConnectorException.h (original)
+++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/stomp/StompConnectorException.h Sat Jan 20 17:03:42 2007
@@ -39,7 +39,9 @@
* Copy Constructor
* @param ex the exception to copy
*/
- StompConnectorException( const exceptions::ActiveMQException& ex ){
+ StompConnectorException( const exceptions::ActiveMQException& ex )
+ : connector::ConnectorException()
+ {
*( ActiveMQException* )this = ex;
}
@@ -47,7 +49,9 @@
* Copy Constructor
* @param ex the exception to copy, which is an instance of this type
*/
- StompConnectorException( const StompConnectorException& ex ){
+ StompConnectorException( const StompConnectorException& ex )
+ : connector::ConnectorException()
+ {
*( exceptions::ActiveMQException* )this = ex;
}
@@ -60,6 +64,7 @@
StompConnectorException( const char* file,
const int lineNumber,
const char* msg, ... )
+ : connector::ConnectorException()
{
va_list vargs;
va_start( vargs, msg );
Modified: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/stomp/StompSelector.h
URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/stomp/StompSelector.h?view=diff&rev=498226&r1=498225&r2=498226
==============================================================================
--- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/stomp/StompSelector.h (original)
+++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/stomp/StompSelector.h Sat Jan 20 17:03:42 2007
@@ -20,6 +20,7 @@
#include <cms/Message.h>
#include <string>
+#include <activemq/util/Config.h>
namespace activemq{
namespace connector{
@@ -35,8 +36,8 @@
class StompSelector{
public:
- static bool isSelected( const std::string& selector,
- cms::Message* msg )
+ static bool isSelected( const std::string& selector ACTIVEMQ_ATTRIBUTE_UNUSED,
+ cms::Message* msg ACTIVEMQ_ATTRIBUTE_UNUSED)
{
return true;
}
Modified: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/stomp/StompSessionManager.cpp
URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/stomp/StompSessionManager.cpp?view=diff&rev=498226&r1=498225&r2=498226
==============================================================================
--- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/stomp/StompSessionManager.cpp (original)
+++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/stomp/StompSessionManager.cpp Sat Jan 20 17:03:42 2007
@@ -109,7 +109,7 @@
////////////////////////////////////////////////////////////////////////////////
void StompSessionManager::removeSession(
- connector::SessionInfo* session )
+ connector::SessionInfo* session ACTIVEMQ_ATTRIBUTE_UNUSED)
throw ( exceptions::ActiveMQException )
{
// NO-op
Modified: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/stomp/commands/AbstractCommand.h
URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/stomp/commands/AbstractCommand.h?view=diff&rev=498226&r1=498225&r2=498226
==============================================================================
--- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/stomp/commands/AbstractCommand.h (original)
+++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/stomp/commands/AbstractCommand.h Sat Jan 20 17:03:42 2007
@@ -22,6 +22,7 @@
#include <activemq/exceptions/NullPointerException.h>
#include <activemq/util/Integer.h>
#include <activemq/util/Long.h>
+#include <activemq/util/Config.h>
namespace activemq{
namespace connector{
@@ -158,7 +159,7 @@
* Set if this Message requires a Response
* @param required true if response is required
*/
- virtual void setResponseRequired( const bool required ) {
+ virtual void setResponseRequired( const bool required ACTIVEMQ_ATTRIBUTE_UNUSED) {
}
/**
Modified: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/stomp/marshal/MarshalException.h
URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/stomp/marshal/MarshalException.h?view=diff&rev=498226&r1=498225&r2=498226
==============================================================================
--- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/stomp/marshal/MarshalException.h (original)
+++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/connector/stomp/marshal/MarshalException.h Sat Jan 20 17:03:42 2007
@@ -40,7 +40,9 @@
* Copy Constructor
* @param ex the exception to copy
*/
- MarshalException( const exceptions::ActiveMQException& ex ){
+ MarshalException( const exceptions::ActiveMQException& ex )
+ : exceptions::ActiveMQException()
+ {
*(ActiveMQException*)this = ex;
}
@@ -48,7 +50,9 @@
* Copy Constructor
* @param ex the exception to copy, which is an instance of this type
*/
- MarshalException( const MarshalException& ex ){
+ MarshalException( const MarshalException& ex )
+ : exceptions::ActiveMQException()
+ {
*(exceptions::ActiveMQException*)this = ex;
}
@@ -60,6 +64,7 @@
*/
MarshalException(const char* file, const int lineNumber,
const char* msg, ...)
+ : exceptions::ActiveMQException()
{
va_list vargs ;
va_start(vargs, msg) ;
Modified: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/exceptions/ActiveMQException.h
URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/exceptions/ActiveMQException.h?view=diff&rev=498226&r1=498225&r2=498226
==============================================================================
--- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/exceptions/ActiveMQException.h (original)
+++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/exceptions/ActiveMQException.h Sat Jan 20 17:03:42 2007
@@ -47,12 +47,14 @@
/**
* Default Constructor
*/
- ActiveMQException(void) {}
+ ActiveMQException() {}
/**
* Copy Constructor
*/
- ActiveMQException( const ActiveMQException& ex ){
+ ActiveMQException( const ActiveMQException& ex )
+ : cms::CMSException()
+ {
*this = ex;
}
Modified: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/exceptions/IllegalArgumentException.h
URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/exceptions/IllegalArgumentException.h?view=diff&rev=498226&r1=498225&r2=498226
==============================================================================
--- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/exceptions/IllegalArgumentException.h (original)
+++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/exceptions/IllegalArgumentException.h Sat Jan 20 17:03:42 2007
@@ -38,14 +38,18 @@
* Conversion Constructor from some other ActiveMQException
* @param An exception that should become this type of Exception
*/
- IllegalArgumentException( const ActiveMQException& ex ){
+ IllegalArgumentException( const ActiveMQException& ex )
+ : ActiveMQException()
+ {
*(ActiveMQException*)this = ex;
}
/**
* Copy Constructor
*/
- IllegalArgumentException( const IllegalArgumentException& ex ){
+ IllegalArgumentException( const IllegalArgumentException& ex )
+ : ActiveMQException()
+ {
*(ActiveMQException*)this = ex;
}
@@ -60,6 +64,7 @@
*/
IllegalArgumentException(const char* file, const int lineNumber,
const char* msg, ...)
+ : ActiveMQException()
{
va_list vargs ;
va_start(vargs, msg) ;
Modified: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/exceptions/IllegalMonitorStateException.h
URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/exceptions/IllegalMonitorStateException.h?view=diff&rev=498226&r1=498225&r2=498226
==============================================================================
--- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/exceptions/IllegalMonitorStateException.h (original)
+++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/exceptions/IllegalMonitorStateException.h Sat Jan 20 17:03:42 2007
@@ -33,20 +33,24 @@
/**
* Default Constructor
*/
- IllegalMonitorStateException(void) {};
+ IllegalMonitorStateException() {};
/**
* Conversion Constructor from some other ActiveMQException
* @param An exception that should become this type of Exception
*/
- IllegalMonitorStateException(const ActiveMQException& ex){
+ IllegalMonitorStateException(const ActiveMQException& ex)
+ : ActiveMQException()
+ {
*(ActiveMQException*)this = ex;
}
/**
* Copy Constructor
*/
- IllegalMonitorStateException(const IllegalMonitorStateException& ex){
+ IllegalMonitorStateException(const IllegalMonitorStateException& ex)
+ : ActiveMQException()
+ {
*(ActiveMQException*)this = ex;
}
@@ -76,11 +80,11 @@
* to preserve the type of the original exception as well as the message.
* All subclasses should override.
*/
- virtual ActiveMQException* clone(void) const{
+ virtual ActiveMQException* clone() const{
return new IllegalMonitorStateException(*this);
}
- virtual ~IllegalMonitorStateException(void) {}
+ virtual ~IllegalMonitorStateException() {}
};
Modified: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/exceptions/IllegalStateException.h
URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/exceptions/IllegalStateException.h?view=diff&rev=498226&r1=498225&r2=498226
==============================================================================
--- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/exceptions/IllegalStateException.h (original)
+++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/exceptions/IllegalStateException.h Sat Jan 20 17:03:42 2007
@@ -33,20 +33,24 @@
/**
* Default Constructor
*/
- IllegalStateException(void) {};
+ IllegalStateException() {};
/**
* Conversion Constructor from some other ActiveMQException
* @param An exception that should become this type of Exception
*/
- IllegalStateException(const ActiveMQException& ex){
+ IllegalStateException(const ActiveMQException& ex)
+ : ActiveMQException()
+ {
*(ActiveMQException*)this = ex;
}
/**
* Copy Constructor
*/
- IllegalStateException(const IllegalStateException& ex){
+ IllegalStateException(const IllegalStateException& ex)
+ : ActiveMQException()
+ {
*(ActiveMQException*)this = ex;
}
@@ -60,8 +64,9 @@
* @param list of primitives that are formatted into the message
*/
IllegalStateException( const char* file,
- const int lineNumber,
- const char* msg, ...)
+ const int lineNumber,
+ const char* msg, ...)
+ : ActiveMQException()
{
va_list vargs;
va_start(vargs, msg);
@@ -76,11 +81,11 @@
* to preserve the type of the original exception as well as the message.
* All subclasses should override.
*/
- virtual ActiveMQException* clone(void) const{
+ virtual ActiveMQException* clone() const{
return new IllegalStateException(*this);
}
- virtual ~IllegalStateException(void) {}
+ virtual ~IllegalStateException() {}
};
Modified: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/exceptions/IndexOutOfBoundsException.h
URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/exceptions/IndexOutOfBoundsException.h?view=diff&rev=498226&r1=498225&r2=498226
==============================================================================
--- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/exceptions/IndexOutOfBoundsException.h (original)
+++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/exceptions/IndexOutOfBoundsException.h Sat Jan 20 17:03:42 2007
@@ -38,14 +38,18 @@
* Conversion Constructor from some other ActiveMQException
* @param An exception that should become this type of Exception
*/
- IndexOutOfBoundsException( const ActiveMQException& ex ){
+ IndexOutOfBoundsException( const ActiveMQException& ex )
+ : ActiveMQException()
+ {
*(ActiveMQException*)this = ex;
}
/**
* Copy Constructor
*/
- IndexOutOfBoundsException( const IndexOutOfBoundsException& ex ){
+ IndexOutOfBoundsException( const IndexOutOfBoundsException& ex )
+ : ActiveMQException()
+ {
*(ActiveMQException*)this = ex;
}
@@ -60,6 +64,7 @@
*/
IndexOutOfBoundsException(const char* file, const int lineNumber,
const char* msg, ...)
+ : ActiveMQException()
{
va_list vargs ;
va_start(vargs, msg) ;
Modified: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/exceptions/InterruptedException.h
URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/exceptions/InterruptedException.h?view=diff&rev=498226&r1=498225&r2=498226
==============================================================================
--- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/exceptions/InterruptedException.h (original)
+++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/exceptions/InterruptedException.h Sat Jan 20 17:03:42 2007
@@ -32,20 +32,24 @@
/**
* Default Constructor
*/
- InterruptedException(void) {};
+ InterruptedException() {};
/**
* Conversion Constructor from some other ActiveMQException
* @param An exception that should become this type of Exception
*/
- InterruptedException(const ActiveMQException& ex){
+ InterruptedException(const ActiveMQException& ex)
+ : ActiveMQException()
+ {
*(ActiveMQException*)this = ex;
}
/**
* Copy Constructor
*/
- InterruptedException(const InterruptedException& ex){
+ InterruptedException(const InterruptedException& ex)
+ : ActiveMQException()
+ {
*(ActiveMQException*)this = ex;
}
@@ -61,6 +65,7 @@
InterruptedException( const char* file,
const int lineNumber,
const char* msg, ... )
+ : ActiveMQException()
{
va_list vargs;
va_start(vargs, msg);
@@ -75,11 +80,11 @@
* to preserve the type of the original exception as well as the message.
* All subclasses should override.
*/
- virtual ActiveMQException* clone(void) const{
+ virtual ActiveMQException* clone() const{
return new InterruptedException(*this);
}
- virtual ~InterruptedException(void) {}
+ virtual ~InterruptedException() {}
};
Modified: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/exceptions/InvalidStateException.h
URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/exceptions/InvalidStateException.h?view=diff&rev=498226&r1=498225&r2=498226
==============================================================================
--- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/exceptions/InvalidStateException.h (original)
+++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/exceptions/InvalidStateException.h Sat Jan 20 17:03:42 2007
@@ -33,20 +33,24 @@
/**
* Default Constructor
*/
- InvalidStateException(void) {}
+ InvalidStateException() {}
/**
* Conversion Constructor from some other ActiveMQException
* @param An exception that should become this type of Exception
*/
- InvalidStateException(const ActiveMQException& ex){
+ InvalidStateException(const ActiveMQException& ex)
+ : ActiveMQException()
+ {
*(ActiveMQException*)this = ex;
}
/**
* Copy Constructor
*/
- InvalidStateException( const InvalidStateException& ex ){
+ InvalidStateException( const InvalidStateException& ex )
+ : ActiveMQException()
+ {
*(ActiveMQException*)this = ex;
}
@@ -62,6 +66,7 @@
InvalidStateException( const char* file,
const int lineNumber,
const char* msg, ... )
+ : ActiveMQException()
{
va_list vargs;
va_start( vargs, msg );
@@ -76,11 +81,11 @@
* to preserve the type of the original exception as well as the message.
* All subclasses should override.
*/
- virtual ActiveMQException* clone(void) const{
+ virtual ActiveMQException* clone() const{
return new InvalidStateException(*this);
}
- virtual ~InvalidStateException(void) {}
+ virtual ~InvalidStateException() {}
};
Modified: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/exceptions/NoSuchElementException.h
URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/exceptions/NoSuchElementException.h?view=diff&rev=498226&r1=498225&r2=498226
==============================================================================
--- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/exceptions/NoSuchElementException.h (original)
+++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/exceptions/NoSuchElementException.h Sat Jan 20 17:03:42 2007
@@ -33,20 +33,24 @@
/**
* Default Constructor
*/
- NoSuchElementException(void) {};
+ NoSuchElementException() {};
/**
* Conversion Constructor from some other ActiveMQException
* @param An exception that should become this type of Exception
*/
- NoSuchElementException( const ActiveMQException& ex ){
+ NoSuchElementException( const ActiveMQException& ex )
+ : ActiveMQException()
+ {
*(ActiveMQException*)this = ex;
}
/**
* Copy Constructor
*/
- NoSuchElementException( const NoSuchElementException& ex ){
+ NoSuchElementException( const NoSuchElementException& ex )
+ : ActiveMQException()
+ {
*(ActiveMQException*)this = ex;
}
@@ -62,6 +66,7 @@
NoSuchElementException( const char* file,
const int lineNumber,
const char* msg, ... )
+ : ActiveMQException()
{
va_list vargs;
va_start( vargs, msg );
@@ -76,11 +81,11 @@
* to preserve the type of the original exception as well as the message.
* All subclasses should override.
*/
- virtual ActiveMQException* clone(void) const{
+ virtual ActiveMQException* clone() const{
return new NoSuchElementException(*this);
}
- virtual ~NoSuchElementException(void) {}
+ virtual ~NoSuchElementException() {}
};
Modified: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/exceptions/NullPointerException.h
URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/exceptions/NullPointerException.h?view=diff&rev=498226&r1=498225&r2=498226
==============================================================================
--- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/exceptions/NullPointerException.h (original)
+++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/exceptions/NullPointerException.h Sat Jan 20 17:03:42 2007
@@ -32,20 +32,24 @@
/**
* Default Constructor
*/
- NullPointerException(void) {};
+ NullPointerException() {};
/**
* Conversion Constructor from some other ActiveMQException
* @param An exception that should become this type of Exception
*/
- NullPointerException( const ActiveMQException& ex ){
+ NullPointerException( const ActiveMQException& ex )
+ : ActiveMQException()
+ {
*(ActiveMQException*)this = ex;
}
/**
* Copy Constructor
*/
- NullPointerException(const NullPointerException& ex){
+ NullPointerException(const NullPointerException& ex)
+ : ActiveMQException()
+ {
*(ActiveMQException*)this = ex;
}
@@ -61,6 +65,7 @@
NullPointerException( const char* file,
const int lineNumber,
const char* msg, ... )
+ : ActiveMQException()
{
va_list vargs;
va_start( vargs, msg );
@@ -75,11 +80,11 @@
* to preserve the type of the original exception as well as the message.
* All subclasses should override.
*/
- virtual ActiveMQException* clone(void) const{
+ virtual ActiveMQException* clone() const{
return new NullPointerException( *this );
}
- virtual ~NullPointerException(void) {}
+ virtual ~NullPointerException() {}
};
Modified: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/exceptions/RuntimeException.h
URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/exceptions/RuntimeException.h?view=diff&rev=498226&r1=498225&r2=498226
==============================================================================
--- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/exceptions/RuntimeException.h (original)
+++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/exceptions/RuntimeException.h Sat Jan 20 17:03:42 2007
@@ -34,20 +34,24 @@
/**
* Default Constructor
*/
- RuntimeException(void) {};
+ RuntimeException() {};
/**
* Conversion Constructor from some other ActiveMQException
* @param An exception that should become this type of Exception
*/
- RuntimeException( const ActiveMQException& ex ){
+ RuntimeException( const ActiveMQException& ex )
+ : ActiveMQException()
+ {
*(ActiveMQException*)this = ex;
}
/**
* Copy Constructor
*/
- RuntimeException( const RuntimeException& ex ){
+ RuntimeException( const RuntimeException& ex )
+ : ActiveMQException()
+ {
*(ActiveMQException*)this = ex;
}
@@ -63,6 +67,7 @@
RuntimeException( const char* file,
const int lineNumber,
const char* msg, ... )
+ : ActiveMQException()
{
va_list vargs;
va_start(vargs, msg);
@@ -77,11 +82,11 @@
* to preserve the type of the original exception as well as the message.
* All subclasses should override.
*/
- virtual ActiveMQException* clone(void) const{
+ virtual ActiveMQException* clone() const{
return new RuntimeException( *this );
}
- virtual ~RuntimeException(void) {}
+ virtual ~RuntimeException() {}
};
Modified: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/exceptions/UnsupportedOperationException.h
URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/exceptions/UnsupportedOperationException.h?view=diff&rev=498226&r1=498225&r2=498226
==============================================================================
--- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/exceptions/UnsupportedOperationException.h (original)
+++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/exceptions/UnsupportedOperationException.h Sat Jan 20 17:03:42 2007
@@ -32,20 +32,24 @@
/**
* Default Constructor
*/
- UnsupportedOperationException(void) {};
+ UnsupportedOperationException() {};
/**
* Conversion Constructor from some other ActiveMQException
* @param An exception that should become this type of Exception
*/
- UnsupportedOperationException( const ActiveMQException& ex ){
+ UnsupportedOperationException( const ActiveMQException& ex )
+ : ActiveMQException()
+ {
*(ActiveMQException*)this = ex;
}
/**
* Copy Constructor
*/
- UnsupportedOperationException( const UnsupportedOperationException& ex ){
+ UnsupportedOperationException( const UnsupportedOperationException& ex )
+ : ActiveMQException()
+ {
*(ActiveMQException*)this = ex;
}
@@ -61,6 +65,7 @@
UnsupportedOperationException( const char* file,
const int lineNumber,
const char* msg, ... )
+ : ActiveMQException()
{
va_list vargs;
va_start( vargs, msg );
Modified: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/io/BlockingByteArrayInputStream.cpp
URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/io/BlockingByteArrayInputStream.cpp?view=diff&rev=498226&r1=498225&r2=498226
==============================================================================
--- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/io/BlockingByteArrayInputStream.cpp (original)
+++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/io/BlockingByteArrayInputStream.cpp Sat Jan 20 17:03:42 2007
@@ -129,3 +129,21 @@
return 0;
}
+
+////////////////////////////////////////////////////////////////////////////////
+int BlockingByteArrayInputStream::skip( int num )
+throw ( io::IOException, exceptions::UnsupportedOperationException ){
+
+ int ix = 0;
+
+ synchronized( this ){
+
+ // Increment the pos until we'v skipped the desired num
+ // or we've hit the end of the buffer.
+ for( ; ix < num && !closing && pos != buffer.end(); ++ix, ++pos) {}
+ }
+
+ return ix;
+}
+
+
Modified: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/io/BlockingByteArrayInputStream.h
URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/io/BlockingByteArrayInputStream.h?view=diff&rev=498226&r1=498225&r2=498226
==============================================================================
--- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/io/BlockingByteArrayInputStream.h (original)
+++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/io/BlockingByteArrayInputStream.h Sat Jan 20 17:03:42 2007
@@ -182,6 +182,24 @@
* @throws IOException if an error occurs.
*/
virtual void close() throw (cms::CMSException);
+
+ /**
+ * Skips over and discards n bytes of data from this input stream. The
+ * skip method may, for a variety of reasons, end up skipping over some
+ * smaller number of bytes, possibly 0. This may result from any of a
+ * number of conditions; reaching end of file before n bytes have been
+ * skipped is only one possibility. The actual number of bytes skipped
+ * is returned. If n is negative, no bytes are skipped.
+ * <p>
+ * The skip method of InputStream creates a byte array and then
+ * repeatedly reads into it until n bytes have been read or the end
+ * of the stream has been reached. Subclasses are encouraged to
+ * provide a more efficient implementation of this method.
+ * @param num - the number of bytes to skip
+ * @returns total butes skipped
+ * @throws IOException if an error occurs
+ */
+ virtual int skip( int num ) throw ( io::IOException, exceptions::UnsupportedOperationException );
};
Modified: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/io/BufferedInputStream.cpp
URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/io/BufferedInputStream.cpp?view=diff&rev=498226&r1=498225&r2=498226
==============================================================================
--- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/io/BufferedInputStream.cpp (original)
+++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/io/BufferedInputStream.cpp Sat Jan 20 17:03:42 2007
@@ -130,6 +130,45 @@
}
////////////////////////////////////////////////////////////////////////////////
+int BufferedInputStream::skip( int num )
+throw ( IOException, exceptions::UnsupportedOperationException ){
+
+ try{
+ // If there's no data left, reset to pointers to the beginning of the
+ // buffer.
+ normalizeBuffer();
+
+ // loop until we've skipped the desired number of bytes
+ int totalSkipped = 0;
+ while( totalSkipped < num ){
+
+ // Get the remaining bytes to copy.
+ int bytesToSkip = min( tail-head, num-totalSkipped );
+
+ // Increment the head position.
+ head += bytesToSkip;
+
+ // If the buffer is now empty, reset the positions to the
+ // head of the buffer.
+ normalizeBuffer();
+
+ // If we still haven't satisified the request,
+ // read more data.
+ if( totalSkipped < num ){
+
+ // Buffer as much data as we can.
+ bufferData();
+ }
+ }
+
+ // Return the total number of bytes read.
+ return totalSkipped;
+ }
+ AMQ_CATCH_RETHROW( IOException )
+ AMQ_CATCHALL_THROW( IOException )
+}
+
+////////////////////////////////////////////////////////////////////////////////
void BufferedInputStream::bufferData() throw ( IOException ){
try{
Modified: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/io/BufferedInputStream.h
URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/io/BufferedInputStream.h?view=diff&rev=498226&r1=498225&r2=498226
==============================================================================
--- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/io/BufferedInputStream.h (original)
+++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/io/BufferedInputStream.h Sat Jan 20 17:03:42 2007
@@ -103,6 +103,24 @@
*/
virtual int read( unsigned char* buffer, int bufferSize )
throw ( IOException );
+
+ /**
+ * Skips over and discards n bytes of data from this input stream. The
+ * skip method may, for a variety of reasons, end up skipping over some
+ * smaller number of bytes, possibly 0. This may result from any of a
+ * number of conditions; reaching end of file before n bytes have been
+ * skipped is only one possibility. The actual number of bytes skipped
+ * is returned. If n is negative, no bytes are skipped.
+ * <p>
+ * The skip method of InputStream creates a byte array and then
+ * repeatedly reads into it until n bytes have been read or the end
+ * of the stream has been reached. Subclasses are encouraged to
+ * provide a more efficient implementation of this method.
+ * @param num - the number of bytes to skip
+ * @returns total butes skipped
+ * @throws IOException if an error occurs
+ */
+ virtual int skip( int num ) throw ( io::IOException, exceptions::UnsupportedOperationException );
private:
Modified: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/io/ByteArrayInputStream.cpp
URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/io/ByteArrayInputStream.cpp?view=diff&rev=498226&r1=498225&r2=498226
==============================================================================
--- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/io/ByteArrayInputStream.cpp (original)
+++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/io/ByteArrayInputStream.cpp Sat Jan 20 17:03:42 2007
@@ -107,3 +107,16 @@
return ix;
}
+
+////////////////////////////////////////////////////////////////////////////////
+int ByteArrayInputStream::skip( int num )
+throw ( IOException, exceptions::UnsupportedOperationException ){
+
+ int ix = 0;
+
+ // Increment the position until we've skipped the desired number
+ // or we've hit the end of the buffer.
+ for( ; ix < num && pos != activeBuffer->end(); ++ix, ++pos) {}
+
+ return ix;
+}
Modified: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/io/ByteArrayInputStream.h
URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/io/ByteArrayInputStream.h?view=diff&rev=498226&r1=498225&r2=498226
==============================================================================
--- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/io/ByteArrayInputStream.h (original)
+++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/io/ByteArrayInputStream.h Sat Jan 20 17:03:42 2007
@@ -199,6 +199,24 @@
* array.
*/
virtual void reset() throw (cms::CMSException);
+
+ /**
+ * Skips over and discards n bytes of data from this input stream. The
+ * skip method may, for a variety of reasons, end up skipping over some
+ * smaller number of bytes, possibly 0. This may result from any of a
+ * number of conditions; reaching end of file before n bytes have been
+ * skipped is only one possibility. The actual number of bytes skipped
+ * is returned. If n is negative, no bytes are skipped.
+ * <p>
+ * The skip method of InputStream creates a byte array and then
+ * repeatedly reads into it until n bytes have been read or the end
+ * of the stream has been reached. Subclasses are encouraged to
+ * provide a more efficient implementation of this method.
+ * @param num - the number of bytes to skip
+ * @returns total butes skipped
+ * @throws IOException if an error occurs
+ */
+ virtual int skip( int num ) throw ( io::IOException, exceptions::UnsupportedOperationException );
};
Modified: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/io/DataInputStream.cpp
URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/io/DataInputStream.cpp?view=diff&rev=498226&r1=498225&r2=498226
==============================================================================
--- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/io/DataInputStream.cpp (original)
+++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/io/DataInputStream.cpp Sat Jan 20 17:03:42 2007
@@ -315,7 +315,8 @@
}
////////////////////////////////////////////////////////////////////////////////
-int DataInputStream::skipBytes( int num ) throw( io::IOException ) {
+int DataInputStream::skip( int num )
+throw( io::IOException, exceptions::UnsupportedOperationException ) {
try {
int total = 0;
int cur = 0;
Modified: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/io/DataInputStream.h
URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/io/DataInputStream.h?view=diff&rev=498226&r1=498225&r2=498226
==============================================================================
--- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/io/DataInputStream.h (original)
+++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/io/DataInputStream.h Sat Jan 20 17:03:42 2007
@@ -334,7 +334,7 @@
* @param num - number of bytes to skip
* @return the total number of bytes skipped
*/
- virtual int skipBytes( int num ) throw( io::IOException );
+ virtual int skip( int num ) throw( io::IOException, exceptions::UnsupportedOperationException );
};
Modified: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/io/DataOutputStream.cpp
URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/io/DataOutputStream.cpp?view=diff&rev=498226&r1=498225&r2=498226
==============================================================================
--- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/io/DataOutputStream.cpp (original)
+++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/io/DataOutputStream.cpp Sat Jan 20 17:03:42 2007
@@ -17,6 +17,7 @@
#include "DataOutputStream.h"
#include <activemq/util/Endian.h>
+#include <activemq/util/Config.h>
using namespace activemq;
using namespace activemq::io;
@@ -193,6 +194,12 @@
}
AMQ_CATCH_RETHROW( IOException )
AMQ_CATCHALL_THROW( IOException )
+}
+
+////////////////////////////////////////////////////////////////////////////////
+void DataOutputStream::writeChars( const std::string& value ACTIVEMQ_ATTRIBUTE_UNUSED)
+throw ( IOException ) {
+ /* do nothing */
}
////////////////////////////////////////////////////////////////////////////////
Modified: incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/io/DataOutputStream.h
URL: http://svn.apache.org/viewvc/incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/io/DataOutputStream.h?view=diff&rev=498226&r1=498225&r2=498226
==============================================================================
--- incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/io/DataOutputStream.h (original)
+++ incubator/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/io/DataOutputStream.h Sat Jan 20 17:03:42 2007
@@ -197,7 +197,7 @@
* @param value the value to write.
* @throws IOException
*/
- virtual void writeChars( const std::string& value ) throw ( IOException ) {};
+ virtual void writeChars( const std::string& value ) throw ( IOException );
/**
* Writes out the string to the underlying output stream as a