Changeset 798 in webkit for trunk/JavaScriptCore/kjs/object_object.h
- Timestamp:
- Mar 21, 2002, 4:31:57 PM (23 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/JavaScriptCore/kjs/object_object.h
r6 r798 1 // -*- c-basic-offset: 2 -*- 1 2 /* 2 3 * This file is part of the KDE libraries … … 16 17 * License along with this library; if not, write to the Free Software 17 18 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 19 * 20 * $Id$ 18 21 */ 19 22 … … 21 24 #define _OBJECT_OBJECT_H_ 22 25 23 #include "object.h" 24 #include "function.h" 26 #include "internal.h" 25 27 26 28 namespace KJS { 27 29 28 class ObjectObject : public ConstructorImp { 30 class FunctionPrototypeImp; 31 32 /** 33 * @internal 34 * 35 * The initial value of Object.prototype (and thus all objects created 36 * with the Object constructor 37 */ 38 class ObjectPrototypeImp : public ObjectImp { 29 39 public: 30 ObjectObject(const Object &funcProto, const Object &objProto); 31 Completion execute(const List &); 32 Object construct(const List &); 40 ObjectPrototypeImp(ExecState *exec, FunctionPrototypeImp *funcProto); 33 41 }; 34 42 35 class ObjectPrototype : public ObjectImp { 43 /** 44 * @internal 45 * 46 * Class to implement all methods that are properties of the 47 * Object.prototype object 48 */ 49 class ObjectProtoFuncImp : public InternalFunctionImp { 36 50 public: 37 ObjectPrototype(); 38 bool hasProperty(const UString &p, bool recursive) const; 39 KJSO get(const UString &p) const; 51 ObjectProtoFuncImp(ExecState *exec, FunctionPrototypeImp *funcProto, 52 int i, int len); 53 54 virtual bool implementsCall() const; 55 virtual Value call(ExecState *exec, Object &thisObj, const List &args); 56 40 57 enum { ToString, ValueOf }; 58 private: 59 int id; 41 60 }; 42 61 43 class ObjectProtoFunc : public InternalFunctionImp { 62 /** 63 * @internal 64 * 65 * The initial value of the the global variable's "Object" property 66 */ 67 class ObjectObjectImp : public InternalFunctionImp { 44 68 public: 45 ObjectProtoFunc(int i); 46 Completion execute(const List &); 47 private: 48 int id; 69 70 ObjectObjectImp(ExecState *exec, 71 ObjectPrototypeImp *objProto, 72 FunctionPrototypeImp *funcProto); 73 74 virtual bool implementsConstruct() const; 75 virtual Object construct(ExecState *exec, const List &args); 76 virtual bool implementsCall() const; 77 virtual Value call(ExecState *exec, Object &thisObj, const List &args); 49 78 }; 50 79
Note:
See TracChangeset
for help on using the changeset viewer.