GEOS
3.4.2
|
00001 /********************************************************************** 00002 * 00003 * GEOS - Geometry Engine Open Source 00004 * http://geos.osgeo.org 00005 * 00006 * Copyright (C) 2005-2006 Refractions Research Inc. 00007 * Copyright (C) 2001-2002 Vivid Solutions Inc. 00008 * 00009 * This is free software; you can redistribute and/or modify it under 00010 * the terms of the GNU Lesser General Public Licence as published 00011 * by the Free Software Foundation. 00012 * See the COPYING file for more information. 00013 * 00014 ********************************************************************** 00015 * 00016 * Last port: ORIGINAL WORK to be used like java.io.Writer 00017 * 00018 **********************************************************************/ 00019 00020 #ifndef GEOS_IO_WRITER_H 00021 #define GEOS_IO_WRITER_H 00022 00023 #include <geos/export.h> 00024 00025 #include <string> 00026 00027 #ifdef _MSC_VER 00028 #pragma warning(push) 00029 #pragma warning(disable: 4251) // warning C4251: needs to have dll-interface to be used by clients of class 00030 #endif 00031 00032 namespace geos { 00033 namespace io { 00034 00035 class GEOS_DLL Writer { 00036 public: 00037 Writer(); 00038 void reserve(std::size_t capacity); 00039 ~Writer(); 00040 void write(const std::string& txt); 00041 const std::string& toString(); 00042 private: 00043 std::string str; 00044 }; 00045 00046 } // namespace geos::io 00047 } // namespace geos 00048 00049 #ifdef _MSC_VER 00050 #pragma warning(pop) 00051 #endif 00052 00053 #endif // #ifndef GEOS_IO_WRITER_H