yast2-core
Main Page
Related Pages
Namespaces
Classes
Files
Examples
File List
File Members
libycp
src
include
ycp
YCPBoolean.h
Go to the documentation of this file.
1
/*---------------------------------------------------------------------\
2
| |
3
| __ __ ____ _____ ____ |
4
| \ \ / /_ _/ ___|_ _|___ \ |
5
| \ V / _` \___ \ | | __) | |
6
| | | (_| |___) || | / __/ |
7
| |_|\__,_|____/ |_| |_____| |
8
| |
9
| core system |
10
| (C) SuSE GmbH |
11
\----------------------------------------------------------------------/
12
13
File: YCPBoolean.h
14
15
Author: Mathias Kettner <kettner@suse.de>
16
Maintainer: Thomas Roelz <tom@suse.de>
17
18
/-*/
19
// -*- c++ -*-
20
21
#ifndef YCPBoolean_h
22
#define YCPBoolean_h
23
24
25
#include "
YCPValue.h
"
26
27
34
class
YCPBooleanRep
:
public
YCPValueRep
35
{
36
bool
v
;
37
38
protected
:
39
friend
class
YCPBoolean
;
40
44
YCPBooleanRep
(
bool
v
);
45
51
YCPBooleanRep
(
const
char
*r);
52
53
public
:
58
bool
value
()
const
;
59
67
YCPOrder
compare
(
const
YCPBoolean
&)
const
;
68
73
string
toString
()
const
;
74
78
std::ostream &
toStream
(std::ostream &
str
)
const
;
79
std::ostream &
toXml
(std::ostream &
str
,
int
indent )
const
;
80
84
YCPValueType
valuetype
()
const
;
85
};
86
93
class
YCPBoolean
:
public
YCPValue
94
{
95
DEF_COMMON
(Boolean, Value);
96
97
static
YCPBoolean
*
trueboolean
;
98
static
YCPBoolean
*
falseboolean
;
99
100
public
:
101
YCPBoolean
(
bool
v);
102
YCPBoolean
(
const
char
*r) :
YCPValue
(new
YCPBooleanRep
(r)) {}
103
YCPBoolean
(
bytecodeistream
&
str
);
104
};
105
106
#endif // YCPBoolean_h
Generated on a sunny day for yast2-core by
1.8.2