MBDyn-1.7.3
Main Page
Modules
Namespaces
Classes
Files
File List
File Members
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Friends
Macros
Groups
input.cc
Go to the documentation of this file.
1
/* $Header: /var/cvs/mbdyn/mbdyn/mbdyn-1.0/libraries/libmbutil/input.cc,v 1.20 2017/01/12 14:44:04 masarati Exp $ */
2
/*
3
* MBDyn (C) is a multibody analysis code.
4
* http://www.mbdyn.org
5
*
6
* Copyright (C) 1996-2017
7
*
8
* Pierangelo Masarati <masarati@aero.polimi.it>
9
* Paolo Mantegazza <mantegazza@aero.polimi.it>
10
*
11
* Dipartimento di Ingegneria Aerospaziale - Politecnico di Milano
12
* via La Masa, 34 - 20156 Milano, Italy
13
* http://www.aero.polimi.it
14
*
15
* Changing this copyright notice is forbidden.
16
*
17
* This program is free software; you can redistribute it and/or modify
18
* it under the terms of the GNU General Public License as published by
19
* the Free Software Foundation (version 2 of the License).
20
*
21
*
22
* This program is distributed in the hope that it will be useful,
23
* but WITHOUT ANY WARRANTY; without even the implied warranty of
24
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
25
* GNU General Public License for more details.
26
*
27
* You should have received a copy of the GNU General Public License
28
* along with this program; if not, write to the Free Software
29
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
30
*/
31
32
/* Input */
33
34
#include "mbconfig.h"
/* This goes first in every *.c,*.cc file */
35
36
#include "
input.h
"
37
38
/* InputStream - begin */
39
40
/* Costruttore - inizializza il filtro con un reference ad un istream */
41
InputStream::InputStream
(std::istream& in)
42
: iStrm(in), uLineNumber(1)
43
{
44
NO_OP
;
45
}
46
47
/* Distruttore banale */
48
InputStream::~InputStream
(
void
) {
49
NO_OP
;
50
}
51
52
InputStream
&
operator >>
(
InputStream
& in,
int
& i)
53
{
54
in.
iStrm
>> i;
55
return
in;
56
}
57
58
InputStream
&
operator >>
(
InputStream
& in,
long
int
& i)
59
{
60
in.
iStrm
>> i;
61
return
in;
62
}
63
64
InputStream
&
operator >>
(
InputStream
& in,
short
int
& i)
65
{
66
in.
iStrm
>> i;
67
return
in;
68
}
69
70
InputStream
&
operator >>
(
InputStream
& in,
unsigned
int
& i)
71
{
72
in.
iStrm
>> i;
73
return
in;
74
}
75
76
InputStream
&
operator >>
(
InputStream
& in,
unsigned
long
int
& i)
77
{
78
in.
iStrm
>> i;
79
return
in;
80
}
81
82
InputStream
&
operator >>
(
InputStream
& in,
unsigned
short
int
& i)
83
{
84
in.
iStrm
>> i;
85
return
in;
86
}
87
88
InputStream
&
operator >>
(
InputStream
& in,
char
& i)
89
{
90
in.
iStrm
>> i;
91
return
in;
92
}
93
94
InputStream
&
operator >>
(
InputStream
& in,
float
& i)
95
{
96
in.
iStrm
>> i;
97
return
in;
98
}
99
100
InputStream
&
operator >>
(
InputStream
& in,
double
& i)
101
{
102
in.
iStrm
>> i;
103
return
in;
104
}
105
106
#if 0
107
InputStream
&
operator >>
(
InputStream
& in,
long
double
& i)
108
{
109
in.
iStrm
>> i;
110
return
in;
111
}
112
#endif
113
114
/* InputStream - end */
115
input.h
InputStream::~InputStream
~InputStream(void)
Definition:
input.cc:48
InputStream
Definition:
input.h:44
NO_OP
#define NO_OP
Definition:
myassert.h:74
InputStream::InputStream
InputStream(std::istream &in)
Definition:
input.cc:41
operator>>
InputStream & operator>>(InputStream &in, int &i)
Definition:
input.cc:52
InputStream::iStrm
std::istream & iStrm
Definition:
input.h:56
libraries
libmbutil
input.cc
Generated on Fri Apr 13 2018 10:19:33 for MBDyn-1.7.3 by
1.8.7