[prev in list] [next in list] [prev in thread] [next in thread] 

List:       berlin-cvs
Subject:    [Fresco-changes] Fresco/Prague/include/Prague/Filter bzbuf.hh,1.3,1.4 cbuf.hh,1.2,1.3 xdrbuf.hh,1.3,
From:       Stefan Seefeld <stefan () fresco ! org>
Date:       2003-07-15 3:50:46
[Download RAW message or body]

Update of /cvs/fresco/Fresco/Prague/include/Prague/Filter
In directory purcel:/tmp/cvs-serv9086/Prague/include/Prague/Filter

Modified Files:
	bzbuf.hh cbuf.hh xdrbuf.hh 
Log Message:
little compatibility fixes

Index: bzbuf.hh
===================================================================
RCS file: /cvs/fresco/Fresco/Prague/include/Prague/Filter/bzbuf.hh,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -d -r1.3 -r1.4
--- bzbuf.hh	23 Sep 2000 19:15:46 -0000	1.3
+++ bzbuf.hh	15 Jul 2003 03:50:43 -0000	1.4
@@ -1,8 +1,8 @@
 /*$Id$
  *
- * This source file is a part of the Berlin Project.
- * Copyright (C) 1999 Stefan Seefeld <stefan@berlin-consortium.org> 
- * http://www.berlin-consortium.org
+ * This source file is a part of the Fresco Project.
+ * Copyright (C) 1999 Stefan Seefeld <stefan@fresco.org> 
+ * http://www.fresco.org
  *
  * This library is free software; you can redistribute it and/or
  * modify it under the terms of the GNU Library General Public
@@ -22,7 +22,7 @@
 #ifndef _bzbuf_hh
 #define _bzbuf_hh
 
-#include <streambuf.h>
+#include <streambuf>
 #include <cstdio>
 extern "C" 
 {
@@ -36,28 +36,28 @@
  *
  * @Description {filter using bzip2 library}
  */
-class bzbuf : public streambuf, private bz_stream
+class bzbuf : public std::streambuf, private bz_stream
 {
 public:
-  typedef char          char_type;
-  typedef streampos     pos_type;
-  typedef streamoff     off_type;
-  typedef int           int_type;
-  bzbuf(streambuf *, int);
+  typedef char           char_type;
+  typedef std::streampos pos_type;
+  typedef std::streamoff off_type;
+  typedef int            int_type;
+  bzbuf(std::streambuf *, int);
   virtual ~bzbuf();
   virtual int sync();
 protected:
   virtual int_type underflow();
   virtual int_type uflow();
   virtual int_type overflow(int = EOF);
-  char_type  *cbase() const { return comp;}
-  char_type  *ecptr() const { return comp + BUFSIZ;}
+  char_type  *cbase() const { return my_comp;}
+  char_type  *ecptr() const { return my_comp + BUFSIZ;}
   char_type  *cin() const { return next_in + avail_in;}
-  char_type  *cout() const { return pout;}
+  char_type  *cout() const { return my_pout;}
 private:
-  char_type *comp;
-  char_type *pout;
-  streambuf *back;
+  char_type      *my_comp;
+  char_type      *my_pout;
+  std::streambuf *my_back;
 };
 
 };

Index: cbuf.hh
===================================================================
RCS file: /cvs/fresco/Fresco/Prague/include/Prague/Filter/cbuf.hh,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -d -r1.2 -r1.3
--- cbuf.hh	25 Mar 2002 15:34:16 -0000	1.2
+++ cbuf.hh	15 Jul 2003 03:50:43 -0000	1.3
@@ -1,7 +1,8 @@
-/*+P
- * This file is part of OffiX,
- * a C++ API for the X Window System and Unix
- * Copyright (C) 1995-98  Stefan Seefeld
+/*$Id$
+ *
+ * This source file is a part of the Fresco Project.
+ * Copyright (C) 1999 Stefan Seefeld <stefan@fresco.org> 
+ * http://www.fresco.org
  *
  * This library is free software; you can redistribute it and/or
  * modify it under the terms of the GNU Library General Public
@@ -19,49 +20,48 @@
  * MA 02139, USA.
  -P*/
 /* $Id$ */
-#ifndef _cbuf_h
-#define _cbuf_h
+#ifndef _cbuf_hh
+#define _cbuf_hh
 
-#include <streambuf.h>
+#include <streambuf>
 
 /* @Class {cbuf : public streambuf}
  *
  * @Description {suppress comments from input}
  */
-class cbuf: public streambuf
+class cbuf: public std::streambuf
 {
 public:
-  cbuf(streambuf *sb, char c = '#') :sbuf(sb), comment(c), newline(true) {}
+  cbuf(std::streambuf *sb, char c = '#') : my_sbuf(sb), my_comment(c), my_newline(true) {}
 protected:
-  int sync() { return sbuf->sync();}
+  int sync() { return my_sbuf->sync();}
   inline int uflow();
-  int sungetc() { return sbuf->sungetc();}
+  int sungetc() { return my_sbuf->sungetc();}
 private:
   cbuf(cbuf const &);
   void operator= (cbuf const &);
-  streambuf *sbuf;
-  const char comment;
-  bool newline;
+  std::streambuf *my_sbuf;
+  const char      my_comment;
+  bool            my_newline;
 };
 
 inline int cbuf::uflow()
 {
-  int c = sbuf->sbumpc();
-  if (c == '\n') newline = true;
-  else if (c == comment)
+  int c = my_sbuf->sbumpc();
+  if (c == '\n') my_newline = true;
+  else if (c == my_comment)
     {
       do // for all lines starting with <comment>
 	{
-	  do c = sbuf->sbumpc();
+	  do c = my_sbuf->sbumpc();
 	  while (c != EOF && c != '\n'); // for all letters of the line
-	  if (newline && c == '\n') c = sbuf->sbumpc();
+	  if (my_newline && c == '\n') c = my_sbuf->sbumpc();
 	}
-      while (c == comment);
-      if (c == '\n') newline = true;
+      while (c == my_comment);
+      if (c == '\n') my_newline = true;
     }
-  else newline = false;
-//   std::cerr << (char)c << std::endl;
+  else my_newline = false;
   return c;
 }
 
-#endif /* _cbuf_h */
+#endif

Index: xdrbuf.hh
===================================================================
RCS file: /cvs/fresco/Fresco/Prague/include/Prague/Filter/xdrbuf.hh,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -d -r1.3 -r1.4
--- xdrbuf.hh	23 Sep 2000 19:15:47 -0000	1.3
+++ xdrbuf.hh	15 Jul 2003 03:50:43 -0000	1.4
@@ -1,8 +1,8 @@
 /*$Id$
  *
- * This source file is a part of the Berlin Project.
- * Copyright (C) 1999 Stefan Seefeld <stefan@berlin-consortium.org> 
- * http://www.berlin-consortium.org
+ * This source file is a part of the Fresco Project.
+ * Copyright (C) 1999 Stefan Seefeld <stefan@fresco.org> 
+ * http://www.fresco.org
  *
  * this code is based on binio from Dietmar Kuehl:
  *
@@ -24,19 +24,19 @@
  * Free Software Foundation, Inc., 675 Mass Ave, Cambridge,
  * MA 02139, USA.
  */
-#ifndef _xdrbuf_h
-#define _xdrbuf_h
+#ifndef _xdrbuf_hh
+#define _xdrbuf_hh
 
-#include <streambuf.h>
+#include <streambuf>
 #include <rpc/rpc.h>
 #include <rpc/xdr.h>
 
 namespace Prague
 {
 
-extern void xdrbuf_create(XDR *xdrs, streambuf *sb, xdr_op op);
-extern void xdrbuf_reseat(XDR *xdrs, streambuf *sb);
+extern void xdrbuf_create(XDR *xdrs, std::streambuf *sb, xdr_op op);
+extern void xdrbuf_reseat(XDR *xdrs, std::streambuf *sb);
 
 };
 
-#endif /* xdrbuf_h */
+#endif


_______________________________________________
Fresco-changes mailing list
Fresco-changes@fresco.org
http://lists.fresco.org/cgi-bin/listinfo/fresco-changes
[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic