glibmm r567 - in trunk: . gio/giomm gio/src



Author: jjongsma
Date: Sun Feb  3 03:36:57 2008
New Revision: 567
URL: http://svn.gnome.org/viewvc/glibmm?rev=567&view=rev

Log:
	* gio/src/bufferedoutputstream.ccg:
	* gio/src/bufferedoutputstream.hg: add BufferedOutputStream class


Added:
   trunk/gio/src/bufferedoutputstream.ccg
   trunk/gio/src/bufferedoutputstream.hg
Modified:
   trunk/ChangeLog
   trunk/gio/giomm/   (props changed)

Added: trunk/gio/src/bufferedoutputstream.ccg
==============================================================================
--- (empty file)
+++ trunk/gio/src/bufferedoutputstream.ccg	Sun Feb  3 03:36:57 2008
@@ -0,0 +1,30 @@
+// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*-
+
+/* Copyright (C) 2008 The gtkmm Development Team
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Library General Public
+ * License as published by the Free Software Foundation; either
+ * version 2 of the License, or (at your option) any later version.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+ * Library General Public License for more details.
+ *
+ * You should have received a copy of the GNU Library General Public
+ * License along with this library; if not, write to the Free
+ * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+ */
+
+#include <gio/gio.h>
+#include "slot_async.h"
+
+namespace Gio
+{
+Glib::RefPtr<BufferedOutputStream> BufferedOutputStream::create_sized(const Glib::RefPtr<OutputStream>& base_stream, gsize size)
+{
+    return Glib::RefPtr<Gio::BufferedOutputStream>(new BufferedOutputStream(base_stream, size));
+}
+
+}   // namespace Gio

Added: trunk/gio/src/bufferedoutputstream.hg
==============================================================================
--- (empty file)
+++ trunk/gio/src/bufferedoutputstream.hg	Sun Feb  3 03:36:57 2008
@@ -0,0 +1,46 @@
+// -*- Mode: C++; indent-tabs-mode: nil; c-basic-offset: 2 -*-
+
+/* Copyright (C) 2008 The gtkmm Development Team
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Library General Public
+ * License as published by the Free Software Foundation; either
+ * version 2 of the License, or (at your option) any later version.
+ *
+ * This library is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+ * Library General Public License for more details.
+ *
+ * You should have received a copy of the GNU Library General Public
+ * License along with this library; if not, write to the Free
+ * Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
+ */
+
+#include <giomm/filteroutputstream.h>
+#include <glibmm/object.h>
+
+_DEFS(giomm,gio)
+_PINCLUDE(giomm/private/filteroutputstream_p.h)
+
+namespace Gio
+{
+
+class BufferedOutputStream : public Gio::FilterOutputStream
+{
+  _CLASS_GOBJECT(BufferedOutputStream, GBufferedOutputStream, G_BUFFERED_OUTPUT_STREAM, Gio::FilterOutputStream, GFilterOutputStream)
+protected:
+  _WRAP_CTOR(BufferedOutputStream(const Glib::RefPtr<OutputStream>& base_stream), g_buffered_output_stream_new)
+  _WRAP_CTOR(BufferedOutputStream(const Glib::RefPtr<OutputStream>& base_stream, guint size), g_buffered_output_stream_new_sized)
+public:
+  _WRAP_CREATE(const Glib::RefPtr<OutputStream>& base_stream)
+  static Glib::RefPtr<BufferedOutputStream> create_sized(const Glib::RefPtr<OutputStream>& base_stream, guint size);
+
+  _WRAP_METHOD(gsize get_buffer_size() const, g_buffered_output_stream_get_buffer_size)
+  _WRAP_METHOD(void set_buffer_size(gsize size), g_buffered_output_stream_set_buffer_size)
+
+  _WRAP_METHOD(void set_auto_grow(bool auto_grow=true), g_buffered_output_stream_set_auto_grow)
+  _WRAP_METHOD(bool get_auto_grow() const, g_buffered_output_stream_get_auto_grow)
+};
+
+} // namespace Gio



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]