ARTS 2.5.0 (git: 9ee3ac6c)
test_xml.cc
Go to the documentation of this file.
1/* Copyright (C) 2003-2012 Oliver Lemke <olemke@core-dump.info>
2
3 This program is free software; you can redistribute it and/or
4 modify it under the terms of the GNU General Public License as
5 published by the Free Software Foundation; either version 2 of the
6 License, or (at your option) any later version.
7
8 This program is distributed in the hope that it will be useful,
9 but WITHOUT ANY WARRANTY; without even the implied warranty of
10 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
11 GNU General Public License for more details.
12
13 You should have received a copy of the GNU General Public License
14 along with this program; if not, write to the Free Software
15 Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
16 USA. */
17
18#include <iostream>
19#include "matpackI.h"
20#include "xml_io_base.h"
21
22int main(int /*argc*/, char * /*argv*/[]) {
23
24 Vector v1{1, 2, 3, 4, 5};
25 String filename{"test.xml"};
27 std::cout << v1 << '\n';
28
29 Vector v2;
30 xml_read_from_file_base(filename, v2, Verbosity());
31 std::cout << v2 << '\n';
32
33 return (0);
34}
The Vector class.
Definition: matpackI.h:876
Implementation of Matrix, Vector, and such stuff.
int main(int, char *[])
Definition: test_xml.cc:22
@ FILE_TYPE_ASCII
Definition: xml_io_base.h:41
void xml_write_to_file_base(const String &filename, const T &type, const FileType ftype, const Verbosity &verbosity)
Write data to XML file.
Definition: xml_io_base.h:311
void xml_read_from_file_base(const String &filename, T &type, const Verbosity &verbosity)
Reads data from XML file.
Definition: xml_io_base.h:243