|
|
| version 1.6, 2013/07/29 15:02:16 | version 1.9, 2016/11/01 23:10:39 |
|---|---|
| Line 1 | Line 1 |
| /** @file | /** @file |
| Parser: @b int parser class. | Parser: @b int parser class. |
| Copyright (c) 2001-2012 Art. Lebedev Studio (http://www.artlebedev.com) | Copyright (c) 2001-2015 Art. Lebedev Studio (http://www.artlebedev.com) |
| Author: Alexandr Petrosian <paf@design.ru> (http://paf.design.ru) | Author: Alexandr Petrosian <paf@design.ru> (http://paf.design.ru) |
| */ | */ |
| Line 28 public: | Line 28 public: |
| // global variable | // global variable |
| DECLARE_CLASS_VAR(bool, new MBool, 0); | DECLARE_CLASS_VAR(bool, new MBool); |
| // methods | // methods |
| static void _int(Request& r, MethodParams&) { | static void _int(Request& r, MethodParams&) { |
| VBool& vbool=GET_SELF(r, VBool); | VBool& vbool=GET_SELF(r, VBool); |
| r.write_no_lang(*new VInt(vbool.as_bool())); | r.write(*new VInt(vbool.as_bool())); |
| } | } |
| static void _double(Request& r, MethodParams&) { | static void _double(Request& r, MethodParams&) { |
| VBool& vbool=GET_SELF(r, VBool); | VBool& vbool=GET_SELF(r, VBool); |
| r.write_no_lang(*new VDouble(vbool.as_bool())); | r.write(*new VDouble(vbool.as_bool())); |
| } | } |
| static void _bool(Request& r, MethodParams&) { | static void _bool(Request& r, MethodParams&) { |
| r.write_no_lang(GET_SELF(r, VBool)); | r.write(GET_SELF(r, VBool)); |
| } | } |
| // constructor | // constructor |