22 #ifndef _BOOL_OBJECT_H_ 23 #define _BOOL_OBJECT_H_ 26 #include "function_object.h" 30 class BooleanInstanceImp :
public ObjectImp {
32 BooleanInstanceImp(ObjectImp *proto);
34 virtual const ClassInfo *classInfo()
const {
return &info; }
35 static const ClassInfo info;
44 class BooleanPrototypeImp :
public BooleanInstanceImp {
46 BooleanPrototypeImp(ExecState *exec,
47 ObjectPrototypeImp *objectProto,
48 FunctionPrototypeImp *funcProto);
57 class BooleanProtoFuncImp :
public InternalFunctionImp {
59 BooleanProtoFuncImp(ExecState *exec, FunctionPrototypeImp *funcProto,
60 int i,
int len,
const Identifier &_ident);
62 virtual bool implementsCall()
const;
63 virtual Value call(ExecState *exec, Object &thisObj,
const List &args);
65 enum { ToString, ValueOf };
75 class BooleanObjectImp :
public InternalFunctionImp {
76 friend class BooleanProtoFuncImp;
78 BooleanObjectImp(ExecState *exec, FunctionPrototypeImp *funcProto,
79 BooleanPrototypeImp *booleanProto);
81 virtual bool implementsConstruct()
const;
82 virtual Object construct(ExecState *exec,
const List &args);
84 virtual bool implementsCall()
const;
85 virtual Value call(ExecState *exec, Object &thisObj,
const List &args);