|
|
| version 1.223, 2015/11/16 18:27:15 | version 1.225, 2016/05/18 17:47:22 |
|---|---|
| Line 31 public: | Line 31 public: |
| // global variable | // global variable |
| DECLARE_CLASS_VAR(string, new MString, 0); | DECLARE_CLASS_VAR(string, new MString); |
| // void class, inherited from string and thus should be inited afterwards | // void class, inherited from string and thus should be inited afterwards |
| Line 42 public: | Line 42 public: |
| // void global variable should be after string global variable | // void global variable should be after string global variable |
| DECLARE_CLASS_VAR(void, new MVoid, 0); | DECLARE_CLASS_VAR(void, new MVoid); |
| // defines for statics | // defines for statics |
| Line 792 static void _unescape(Request& r, Method | Line 792 static void _unescape(Request& r, Method |
| } | } |
| } | } |
| static void _contains(Request& r, MethodParams& params) { | |
| // empty or whitespace string is hash compatible | |
| GET_SELF(r, VString).get_element(params.as_string(0, "key must be string")); | |
| // ignoring result as it allways null | |
| r.write_no_lang(VBool::get(false)); | |
| } | |
| // constructor | // constructor |
| MString::MString(): Methoded("string") { | MString::MString(): Methoded("string") { |
| Line 877 MString::MString(): Methoded("string") { | Line 884 MString::MString(): Methoded("string") { |
| // ^string:unescape[js|uri;escaped;$.charset[...]] | // ^string:unescape[js|uri;escaped;$.charset[...]] |
| add_native_method("unescape", Method::CT_STATIC, _unescape, 2, 3); | add_native_method("unescape", Method::CT_STATIC, _unescape, 2, 3); |
| // ^string.contains[key] for hash compatibility | |
| add_native_method("contains", Method::CT_DYNAMIC, _contains, 1, 1); | |
| } | } |