Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Newer
Older
100644 56 lines (47 sloc) 1.942 kb
0c910b8 @NotFound start reorganizing components
authored
1 #ifndef INCLUDE_WINXEDXX_OBJECT_H
2 #define INCLUDE_WINXEDXX_OBJECT_H
3
4 // winxedxx_object.h
21f52be @NotFound more reorganization
authored
5 // (C) 2011 Julián Albo "NotFound"
0c910b8 @NotFound start reorganizing components
authored
6
7 namespace WinxedXX
8 {
9
788ce11 @NotFound unify reference counting
authored
10 class WxxObject : public WxxRefcounted
0c910b8 @NotFound start reorganizing components
authored
11 {
12 public:
13 virtual int is_null() const = 0;
011c83d @NotFound class_name method in internal classes and better message on method no…
authored
14 virtual std::string class_name() const = 0;
0c910b8 @NotFound start reorganizing components
authored
15 virtual int instanceof(const std::string &type) = 0;
16 virtual int get_bool() = 0;
17 virtual int get_integer() = 0;
18 virtual double get_number() = 0;
19 virtual int elements() = 0;
20 virtual std::string get_string() = 0;
68c48f9 @NotFound improve a bit is_equal and fix it for Integer-Integer
authored
21 virtual int is_equal(const WxxObject &to) = 0;
0c910b8 @NotFound start reorganizing components
authored
22 virtual WxxObject & set(int value) = 0;
23 virtual WxxObject & set(double value) = 0;
24 virtual WxxObject & set(const char *s) = 0;
25 virtual WxxObject & set(const std::string &s) = 0;
6f2c030 @NotFound var preincrement and WxxInteger::increment
authored
26 virtual void increment() = 0;
5e6ce74 @NotFound operator pre -- and decrement in Integer
authored
27 virtual void decrement() = 0;
0c910b8 @NotFound start reorganizing components
authored
28 virtual std::string get_string_keyed(int i) = 0;
29 virtual WxxObjectPtr get_pmc_keyed(int i) = 0;
30 virtual WxxObjectPtr get_pmc_keyed(const std::string &s) = 0;
31 virtual WxxObjectPtr get_pmc_keyed(const char *s) = 0;
32 virtual void set_pmc_keyed(int i, const WxxObjectPtr &value) = 0;
000b8f1 @NotFound implement 'exists'
authored
33 virtual int exists(const std::string &key) = 0;
0c910b8 @NotFound start reorganizing components
authored
34 virtual WxxObjectPtr & set_pmc_keyed(const std::string &s, const WxxObjectPtr &value) = 0;
35 virtual WxxObjectPtr & get_attr_str(const std::string &s) = 0;
36 virtual void set_attr_str(const std::string &s, const WxxObjectPtr &value) = 0;
37 virtual WxxObjectPtr get_iter() = 0;
38 virtual WxxObjectPtr shift_pmc() = 0;
39
40 virtual WxxObjectPtr operator()(WxxObjectArray &args) = 0;
41 virtual WxxObjectPtr call_method(const std::string &methname, WxxObjectArray &args) = 0;
42 virtual void print() = 0;
43 virtual void print(WxxObjectPtr obj) = 0;
44 };
45
21f52be @NotFound more reorganization
authored
46 WxxObjectPtr wxx_getstdin();
47 WxxObjectPtr wxx_getstdout();
48 WxxObjectPtr wxx_getstderr();
097f8b8 @NotFound declare wxx_spawnw
authored
49 WxxObjectPtr wxx_spawnw(WxxObjectPtr obj);
21f52be @NotFound more reorganization
authored
50
0c910b8 @NotFound start reorganizing components
authored
51 } // namespace WinxedXX
52
53 #endif
54
55 // End of winxedxx_object.h
Something went wrong with that request. Please try again.