Esempio n. 1
0
JSValue jsWorkerLocationHostname(ExecState* exec, JSValue slotBase, const Identifier&)
{
    JSWorkerLocation* castedThis = static_cast<JSWorkerLocation*>(asObject(slotBase));
    UNUSED_PARAM(exec);
    WorkerLocation* imp = static_cast<WorkerLocation*>(castedThis->impl());
    JSValue result = jsString(exec, imp->hostname());
    return result;
}
Esempio n. 2
0
static v8::Handle<v8::Value> hostnameAttrGetter(v8::Local<v8::String> name, const v8::AccessorInfo& info)
{
    INC_STATS("DOM.WorkerLocation.hostname._get");
    WorkerLocation* imp = V8WorkerLocation::toNative(info.Holder());
    return v8String(imp->hostname());
}
static v8::Handle<v8::Value> hostnameAttrGetter(v8::Local<v8::String> name, const v8::AccessorInfo& info)
{
    WorkerLocation* imp = V8WorkerLocation::toNative(info.Holder());
    return v8String(imp->hostname(), info.GetIsolate());
}