ArrayConstructor.h [plain text]
#ifndef ArrayConstructor_h
#define ArrayConstructor_h
#include "InternalFunction.h"
namespace JSC {
class ArrayPrototype;
class ArrayConstructor : public InternalFunction {
public:
typedef InternalFunction Base;
static ArrayConstructor* create(ExecState* exec, JSGlobalObject* globalObject, Structure* structure, ArrayPrototype* arrayPrototype)
{
ArrayConstructor* constructor = new (NotNull, allocateCell<ArrayConstructor>(*exec->heap())) ArrayConstructor(globalObject, structure);
constructor->finishCreation(exec, arrayPrototype);
return constructor;
}
static const ClassInfo s_info;
static Structure* createStructure(JSGlobalData& globalData, JSGlobalObject* globalObject, JSValue prototype)
{
return Structure::create(globalData, globalObject, prototype, TypeInfo(ObjectType, StructureFlags), &s_info);
}
protected:
void finishCreation(ExecState*, ArrayPrototype*);
static const unsigned StructureFlags = OverridesGetOwnPropertySlot | InternalFunction::StructureFlags;
private:
ArrayConstructor(JSGlobalObject*, Structure*);
static bool getOwnPropertySlot(JSCell*, ExecState*, const Identifier&, PropertySlot&);
static bool getOwnPropertyDescriptor(JSObject*, ExecState*, const Identifier&, PropertyDescriptor&);
static ConstructType getConstructData(JSCell*, ConstructData&);
static CallType getCallData(JSCell*, CallData&);
};
}
#endif // ArrayConstructor_h