activemq-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From tab...@apache.org
Subject svn commit: r599962 - in /activemq/activemq-cpp/decaf/trunk/src/main/decaf/nio: DoubleBuffer.cpp DoubleBuffer.h
Date Fri, 30 Nov 2007 21:08:11 GMT
Author: tabish
Date: Fri Nov 30 13:08:08 2007
New Revision: 599962

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

Starting the NIO implementation

Start DoubleBuffer class

Added:
    activemq/activemq-cpp/decaf/trunk/src/main/decaf/nio/DoubleBuffer.cpp   (with props)
    activemq/activemq-cpp/decaf/trunk/src/main/decaf/nio/DoubleBuffer.h   (with props)

Added: activemq/activemq-cpp/decaf/trunk/src/main/decaf/nio/DoubleBuffer.cpp
URL: http://svn.apache.org/viewvc/activemq/activemq-cpp/decaf/trunk/src/main/decaf/nio/DoubleBuffer.cpp?rev=599962&view=auto
==============================================================================
--- activemq/activemq-cpp/decaf/trunk/src/main/decaf/nio/DoubleBuffer.cpp (added)
+++ activemq/activemq-cpp/decaf/trunk/src/main/decaf/nio/DoubleBuffer.cpp Fri Nov 30 13:08:08
2007
@@ -0,0 +1,34 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#include "DoubleBuffer.h"
+
+#include <decaf/lang/Double.h>
+#include <decaf/lang/Math.h>
+
+using namespace std;
+using namespace decaf;
+using namespace decaf::nio;
+using namespace decaf::lang;
+using namespace decaf::lang::exceptions;
+
+////////////////////////////////////////////////////////////////////////////////
+DoubleBuffer::DoubleBuffer( std::size_t capacity )
+ :  Buffer( capacity ) {
+
+}
+

Propchange: activemq/activemq-cpp/decaf/trunk/src/main/decaf/nio/DoubleBuffer.cpp
------------------------------------------------------------------------------
    svn:eol-style = native

Added: activemq/activemq-cpp/decaf/trunk/src/main/decaf/nio/DoubleBuffer.h
URL: http://svn.apache.org/viewvc/activemq/activemq-cpp/decaf/trunk/src/main/decaf/nio/DoubleBuffer.h?rev=599962&view=auto
==============================================================================
--- activemq/activemq-cpp/decaf/trunk/src/main/decaf/nio/DoubleBuffer.h (added)
+++ activemq/activemq-cpp/decaf/trunk/src/main/decaf/nio/DoubleBuffer.h Fri Nov 30 13:08:08
2007
@@ -0,0 +1,52 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+#ifndef _DECAF_NIO_DOUBLEBUFFER_H_
+#define _DECAF_NIO_DOUBLEBUFFER_H_
+
+#include <decaf/nio/Buffer.h>
+#include <decaf/lang/Comparable.h>
+#include <decaf/lang/exceptions/NullPointerException.h>
+#include <decaf/lang/exceptions/IndexOutOfBoundsException.h>
+#include <decaf/nio/BufferUnderflowException.h>
+#include <decaf/nio/BufferOverflowException.h>
+#include <decaf/nio/ReadOnlyBufferException.h>
+
+namespace decaf{
+namespace nio{
+
+    class DoubleBuffer : public Buffer,
+                         public lang::Comparable<DoubleBuffer> {
+    protected:
+
+        /**
+        * Creates a DoubleBuffer object that has its backing array allocated internally
+        * and is then owned and deleted when this object is deleted.  The array is
+        * initially created with all elements initialized to zero.
+        * @param capacity - size and limit of the Buffer in doubles
+        */
+        DoubleBuffer( std::size_t capacity );
+
+    public:
+
+        virtual ~DoubleBuffer() {}
+
+    };
+
+}}
+
+#endif /*_DECAF_NIO_DOUBLEBUFFER_H_*/

Propchange: activemq/activemq-cpp/decaf/trunk/src/main/decaf/nio/DoubleBuffer.h
------------------------------------------------------------------------------
    svn:eol-style = native



Mime
View raw message