src/ls-ascii-helper.h
author Benjamin Lindner <lindnerb@users.sourceforge.net>
Wed Mar 18 15:23:14 2009 +0100 (2009-03-18)
changeset 7685 34b75a47e712
permissions -rw-r--r--
fix leaving stray '\r' in stream when reading from CRLF data file
* * *
fix CRLF issues with text-mode reading in windows when loading ascii data
lindnerb@7685
     1
/*
lindnerb@7685
     2
lindnerb@7685
     3
Copyright (C) 2003, 2005, 2006, 2007 John W. Eaton
lindnerb@7685
     4
lindnerb@7685
     5
This file is part of Octave.
lindnerb@7685
     6
lindnerb@7685
     7
Octave is free software; you can redistribute it and/or modify it
lindnerb@7685
     8
under the terms of the GNU General Public License as published by the
lindnerb@7685
     9
Free Software Foundation; either version 3 of the License, or (at your
lindnerb@7685
    10
option) any later version.
lindnerb@7685
    11
lindnerb@7685
    12
Octave is distributed in the hope that it will be useful, but WITHOUT
lindnerb@7685
    13
ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
lindnerb@7685
    14
FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
lindnerb@7685
    15
for more details.
lindnerb@7685
    16
lindnerb@7685
    17
You should have received a copy of the GNU General Public License
lindnerb@7685
    18
along with Octave; see the file COPYING.  If not, see
lindnerb@7685
    19
<http://www.gnu.org/licenses/>.
lindnerb@7685
    20
lindnerb@7685
    21
*/
lindnerb@7685
    22
lindnerb@7685
    23
#if !defined (octave_ls_ascii_helper_h)
lindnerb@7685
    24
#define octave_ls_ascii_helper_h 1
lindnerb@7685
    25
lindnerb@7685
    26
#include <iosfwd>
lindnerb@7685
    27
#include <string>
lindnerb@7685
    28
lindnerb@7685
    29
#include "oct-dlldefs.h"
lindnerb@7685
    30
lindnerb@7685
    31
extern OCTINTERP_API void
lindnerb@7685
    32
skip_until_newline( std::istream& is, bool keep_newline = false );
lindnerb@7685
    33
lindnerb@7685
    34
extern OCTINTERP_API void
lindnerb@7685
    35
skip_preceeding_newline( std::istream& is );
lindnerb@7685
    36
lindnerb@7685
    37
extern OCTINTERP_API std::string
lindnerb@7685
    38
read_until_newline( std::istream& is, bool keep_newline = false );
lindnerb@7685
    39
lindnerb@7685
    40
#endif  // !defined (octave_ls_ascii_helper_h)