summaryrefslogtreecommitdiff
path: root/codemaker
diff options
context:
space:
mode:
authorJuergen Schmidt <jsc@openoffice.org>2001-06-20 13:50:40 +0000
committerJuergen Schmidt <jsc@openoffice.org>2001-06-20 13:50:40 +0000
commit40cd280e03a8d926231adbdf57f14db65a90c086 (patch)
tree68f521636cb488a81523d015574c9dee513548c8 /codemaker
parent80a03301e115c456280064d9ad714af86828013a (diff)
#87298# insert operator<< for OString
Diffstat (limited to 'codemaker')
-rw-r--r--codemaker/inc/codemaker/global.hxx9
-rw-r--r--codemaker/source/codemaker/global.cxx17
2 files changed, 21 insertions, 5 deletions
diff --git a/codemaker/inc/codemaker/global.hxx b/codemaker/inc/codemaker/global.hxx
index b406c60f45f8..52a5a1b6acf7 100644
--- a/codemaker/inc/codemaker/global.hxx
+++ b/codemaker/inc/codemaker/global.hxx
@@ -2,9 +2,9 @@
*
* $RCSfile: global.hxx,v $
*
- * $Revision: 1.2 $
+ * $Revision: 1.3 $
*
- * last change: $Author: jsc $ $Date: 2001-03-13 12:04:21 $
+ * last change: $Author: jsc $ $Date: 2001-06-20 14:49:22 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@@ -139,6 +139,11 @@ public:
sal_Int32 getSize();
::rtl::OString getName() { return m_name; }
+
+ // friend functions
+ friend ostream &operator<<(ostream& o, ::rtl::OString*);
+ friend ostream &operator<<(ostream& o, const ::rtl::OString&);
+
protected:
::rtl::OString m_name;
};
diff --git a/codemaker/source/codemaker/global.cxx b/codemaker/source/codemaker/global.cxx
index 455691e3052c..21a594e9bae0 100644
--- a/codemaker/source/codemaker/global.cxx
+++ b/codemaker/source/codemaker/global.cxx
@@ -2,9 +2,9 @@
*
* $RCSfile: global.cxx,v $
*
- * $Revision: 1.8 $
+ * $Revision: 1.9 $
*
- * last change: $Author: pl $ $Date: 2001-05-10 20:07:30 $
+ * last change: $Author: jsc $ $Date: 2001-06-20 14:50:40 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@@ -338,7 +338,7 @@ FileStream::~FileStream()
sal_Bool FileStream::isValid()
{
-#if defined(SAL_UNX) || defined(SAL_OS2)
+#if defined(SAL_UNX) || defined(SAL_OS2) || !defined(D__STL_NO_NEW_IOSTREAMS)
#if STLPORT_VERSION < 400
if(rdbuf()->fd() < 0)
#else
@@ -381,3 +381,14 @@ sal_Int32 FileStream::getSize()
return size;
}
+ostream &operator <<(ostream& o, OString* s)
+{
+ o << s->getStr();
+ return o;
+}
+
+ostream &operator <<(ostream& o, const OString& s)
+{
+ o << s.getStr();
+ return o;
+}