Ignore:
Timestamp:
Mar 21, 2002, 4:31:57 PM (23 years ago)
Author:
mjs
Message:

Merged changes from LABYRINTH_KDE_3_MERGE branch.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/JavaScriptCore/kjs/bool_object.h

    r6 r798  
     1// -*- c-basic-offset: 2 -*-
    12/*
    23 *  This file is part of the KDE libraries
     
    1617 *  License along with this library; if not, write to the Free Software
    1718 *  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
     19 *
     20 *  $Id$
    1821 */
    1922
     
    2124#define _BOOL_OBJECT_H_
    2225
    23 #include "object.h"
    24 #include "function.h"
     26#include "internal.h"
     27#include "function_object.h"
    2528
    2629namespace KJS {
    2730
    28   class BooleanObject : public ConstructorImp {
     31  class BooleanInstanceImp : public ObjectImp {
    2932  public:
    30     BooleanObject(const KJSO& funcProto, const KJSO &booleanProto);
    31     Completion execute(const List &);
    32     Object construct(const List &);
     33    BooleanInstanceImp(const Object &proto);
     34
     35    virtual const ClassInfo *classInfo() const { return &info; }
     36    static const ClassInfo info;
    3337  };
    3438
    35   class BooleanPrototype : public ObjectImp {
     39  /**
     40   * @internal
     41   *
     42   * The initial value of Boolean.prototype (and thus all objects created
     43   * with the Boolean constructor
     44   */
     45  class BooleanPrototypeImp : public BooleanInstanceImp {
    3646  public:
    37     BooleanPrototype(const Object& proto);
    38     virtual KJSO get(const UString &p) const;
    39     enum { ToString, ValueOf };
     47    BooleanPrototypeImp(ExecState *exec,
     48                        ObjectPrototypeImp *objectProto,
     49                        FunctionPrototypeImp *funcProto);
    4050  };
    4151
    42   class BooleanProtoFunc : public InternalFunctionImp {
     52  /**
     53   * @internal
     54   *
     55   * Class to implement all methods that are properties of the
     56   * Boolean.prototype object
     57   */
     58  class BooleanProtoFuncImp : public InternalFunctionImp {
    4359  public:
    44     BooleanProtoFunc(int i);
    45     Completion execute(const List &);
     60    BooleanProtoFuncImp(ExecState *exec,
     61                        FunctionPrototypeImp *funcProto, int i, int len);
     62
     63    virtual bool implementsCall() const;
     64    virtual Value call(ExecState *exec, Object &thisObj, const List &args);
     65
     66    enum { ToString, ValueOf };
    4667  private:
    4768    int id;
     69  };
     70
     71  /**
     72   * @internal
     73   *
     74   * The initial value of the the global variable's "Boolean" property
     75   */
     76  class BooleanObjectImp : public InternalFunctionImp {
     77    friend class BooleanProtoFuncImp;
     78  public:
     79    BooleanObjectImp(ExecState *exec, FunctionPrototypeImp *funcProto,
     80                     BooleanPrototypeImp *booleanProto);
     81
     82    virtual bool implementsConstruct() const;
     83    virtual Object construct(ExecState *exec, const List &args);
     84
     85    virtual bool implementsCall() const;
     86    virtual Value call(ExecState *exec, Object &thisObj, const List &args);
    4887  };
    4988
Note: See TracChangeset for help on using the changeset viewer.