コード例 #1
0
void JSXMLHttpRequest::visitChildren(JSCell* cell, SlotVisitor& visitor)
{
    JSXMLHttpRequest* thisObject = jsCast<JSXMLHttpRequest*>(cell);
    ASSERT_GC_OBJECT_INHERITS(thisObject, info());
    COMPILE_ASSERT(StructureFlags & OverridesVisitChildren, OverridesVisitChildrenWithoutSettingFlag);
    ASSERT(thisObject->structure()->typeInfo().overridesVisitChildren());
    Base::visitChildren(thisObject, visitor);

    if (XMLHttpRequestUpload* upload = thisObject->m_impl->optionalUpload())
        visitor.addOpaqueRoot(upload);

    if (Document* responseDocument = thisObject->m_impl->optionalResponseXML())
        visitor.addOpaqueRoot(responseDocument);

    if (ArrayBuffer* responseArrayBuffer = thisObject->m_impl->optionalResponseArrayBuffer())
        visitor.addOpaqueRoot(responseArrayBuffer);

    if (Blob* responseBlob = thisObject->m_impl->optionalResponseBlob())
        visitor.addOpaqueRoot(responseBlob);

    if (thisObject->m_response)
        visitor.append(&thisObject->m_response);

    thisObject->m_impl->visitJSEventListeners(visitor);
}
コード例 #2
0
void JSWorkerGlobalScope::visitAdditionalChildren(SlotVisitor& visitor)
{
    if (WorkerLocation* location = impl().optionalLocation())
        visitor.addOpaqueRoot(location);
    if (WorkerNavigator* navigator = impl().optionalNavigator())
        visitor.addOpaqueRoot(navigator);
}
コード例 #3
0
void JSDOMQuad::visitAdditionalChildren(SlotVisitor& visitor)
{
    visitor.addOpaqueRoot(const_cast<DOMPoint*>(&wrapped().p1()));
    visitor.addOpaqueRoot(const_cast<DOMPoint*>(&wrapped().p2()));
    visitor.addOpaqueRoot(const_cast<DOMPoint*>(&wrapped().p3()));
    visitor.addOpaqueRoot(const_cast<DOMPoint*>(&wrapped().p4()));
}
コード例 #4
0
void JSXMLHttpRequest::visitAdditionalChildren(SlotVisitor& visitor)
{
    if (XMLHttpRequestUpload* upload = wrapped().optionalUpload())
        visitor.addOpaqueRoot(upload);

    if (Document* responseDocument = wrapped().optionalResponseXML())
        visitor.addOpaqueRoot(responseDocument);
}
コード例 #5
0
void JSWorkerGlobalScope::visitAdditionalChildren(SlotVisitor& visitor)
{
    if (WorkerLocation* location = wrapped().optionalLocation())
        visitor.addOpaqueRoot(location);
    if (WorkerNavigator* navigator = wrapped().optionalNavigator())
        visitor.addOpaqueRoot(navigator);
    visitor.addOpaqueRoot(wrapped().scriptExecutionContext());
}
コード例 #6
0
void JSMessageChannel::visitChildren(SlotVisitor& visitor)
{
    Base::visitChildren(visitor);

    if (MessagePort* port = m_impl->port1())
        visitor.addOpaqueRoot(port);

    if (MessagePort* port = m_impl->port2())
        visitor.addOpaqueRoot(port);
}
コード例 #7
0
void JSXMLHttpRequest::visitAdditionalChildren(SlotVisitor& visitor)
{
    if (XMLHttpRequestUpload* upload = impl().optionalUpload())
        visitor.addOpaqueRoot(upload);

    if (Document* responseDocument = impl().optionalResponseXML())
        visitor.addOpaqueRoot(responseDocument);

    if (ArrayBuffer* responseArrayBuffer = impl().optionalResponseArrayBuffer())
        visitor.addOpaqueRoot(responseArrayBuffer);

    if (Blob* responseBlob = impl().optionalResponseBlob())
        visitor.addOpaqueRoot(responseBlob);
}
コード例 #8
0
void JSWorkerContext::visitChildren(SlotVisitor& visitor)
{
    ASSERT_GC_OBJECT_INHERITS(this, &s_info);
    COMPILE_ASSERT(StructureFlags & OverridesVisitChildren, OverridesVisitChildrenWithoutSettingFlag);
    ASSERT(structure()->typeInfo().overridesVisitChildren());
    Base::visitChildren(visitor);

    if (WorkerLocation* location = impl()->optionalLocation())
        visitor.addOpaqueRoot(location);
    if (WorkerNavigator* navigator = impl()->optionalNavigator())
        visitor.addOpaqueRoot(navigator);

    impl()->visitJSEventListeners(visitor);
}
コード例 #9
0
void JSWorkerGlobalScope::visitAdditionalChildren(SlotVisitor& visitor)
{
    if (auto* location = wrapped().optionalLocation())
        visitor.addOpaqueRoot(location);
    if (auto* navigator = wrapped().optionalNavigator())
        visitor.addOpaqueRoot(navigator);
    ScriptExecutionContext& context = wrapped();
    visitor.addOpaqueRoot(&context);
    
    // Normally JSEventTargetCustom.cpp's JSEventTarget::visitAdditionalChildren() would call this. But
    // even though WorkerGlobalScope is an EventTarget, JSWorkerGlobalScope does not subclass
    // JSEventTarget, so we need to do this here.
    wrapped().visitJSEventListeners(visitor);
}
コード例 #10
0
void JSMessageChannel::visitChildren(JSCell* cell, SlotVisitor& visitor)
{
    JSMessageChannel* thisObject = jsCast<JSMessageChannel*>(cell);
    ASSERT_GC_OBJECT_INHERITS(thisObject, &s_info);
    COMPILE_ASSERT(StructureFlags & OverridesVisitChildren, OverridesVisitChildrenWithoutSettingFlag);
    ASSERT(thisObject->structure()->typeInfo().overridesVisitChildren());
    Base::visitChildren(thisObject, visitor);

    if (MessagePort* port = thisObject->m_impl->port1())
        visitor.addOpaqueRoot(port);

    if (MessagePort* port = thisObject->m_impl->port2())
        visitor.addOpaqueRoot(port);
}
コード例 #11
0
void JSWorkerGlobalScope::visitChildren(JSCell* cell, SlotVisitor& visitor)
{
    JSWorkerGlobalScope* thisObject = jsCast<JSWorkerGlobalScope*>(cell);
    ASSERT_GC_OBJECT_INHERITS(thisObject, info());
    COMPILE_ASSERT(StructureFlags & OverridesVisitChildren, OverridesVisitChildrenWithoutSettingFlag);
    ASSERT(thisObject->structure()->typeInfo().overridesVisitChildren());
    Base::visitChildren(thisObject, visitor);

    if (WorkerLocation* location = thisObject->impl()->optionalLocation())
        visitor.addOpaqueRoot(location);
    if (WorkerNavigator* navigator = thisObject->impl()->optionalNavigator())
        visitor.addOpaqueRoot(navigator);

    thisObject->impl()->visitJSEventListeners(visitor);
}
コード例 #12
0
ファイル: JSTreeWalkerCustom.cpp プロジェクト: 13W/phantomjs
void JSTreeWalker::visitChildren(SlotVisitor& visitor)
{
    Base::visitChildren(visitor);

    if (NodeFilter* filter = m_impl->filter())
        visitor.addOpaqueRoot(filter);
}
コード例 #13
0
void JSCSSRule::visitChildren(SlotVisitor& visitor)
{
    ASSERT_GC_OBJECT_INHERITS(this, &s_info);
    COMPILE_ASSERT(StructureFlags & OverridesVisitChildren, OverridesVisitChildrenWithoutSettingFlag);
    ASSERT(structure()->typeInfo().overridesVisitChildren());
    Base::visitChildren(visitor);
    visitor.addOpaqueRoot(root(impl()));
}
コード例 #14
0
void JSStyleSheet::visitChildren(JSCell* cell, SlotVisitor& visitor)
{
    JSStyleSheet* thisObject = jsCast<JSStyleSheet*>(cell);
    ASSERT_GC_OBJECT_INHERITS(thisObject, info());
    COMPILE_ASSERT(StructureFlags & OverridesVisitChildren, OverridesVisitChildrenWithoutSettingFlag);
    ASSERT(thisObject->structure()->typeInfo().overridesVisitChildren());
    Base::visitChildren(thisObject, visitor);
    visitor.addOpaqueRoot(root(&thisObject->impl()));
}
コード例 #15
0
void JSWebGLRenderingContext::visitChildren(JSCell* cell, SlotVisitor& visitor)
{
    JSWebGLRenderingContext* thisObject = static_cast<JSWebGLRenderingContext*>(cell);
    ASSERT_GC_OBJECT_INHERITS(thisObject, &s_info);
    COMPILE_ASSERT(StructureFlags & OverridesVisitChildren, OverridesVisitChildrenWithoutSettingFlag);
    ASSERT(thisObject->structure()->typeInfo().overridesVisitChildren());
    Base::visitChildren(thisObject, visitor);
    visitor.addOpaqueRoot(thisObject->impl());
}
コード例 #16
0
ファイル: JSMessagePortCustom.cpp プロジェクト: 13W/phantomjs
void JSMessagePort::visitChildren(SlotVisitor& visitor)
{
    Base::visitChildren(visitor);

    // If we have a locally entangled port, we can directly mark it as reachable. Ports that are remotely entangled are marked in-use by markActiveObjectsForContext().
    if (MessagePort* port = m_impl->locallyEntangledPort())
        visitor.addOpaqueRoot(port);

    m_impl->visitJSEventListeners(visitor);
}
コード例 #17
0
void JSSharedWorker::visitChildren(SlotVisitor& visitor)
{
    ASSERT_GC_OBJECT_INHERITS(this, &s_info);
    COMPILE_ASSERT(StructureFlags & OverridesVisitChildren, OverridesVisitChildrenWithoutSettingFlag);
    ASSERT(structure()->typeInfo().overridesVisitChildren());
    Base::visitChildren(visitor);

    if (MessagePort* port = impl()->port())
        visitor.addOpaqueRoot(port);
}
コード例 #18
0
void JSXMLHttpRequest::visitChildren(SlotVisitor& visitor)
{
    Base::visitChildren(visitor);

    if (XMLHttpRequestUpload* upload = m_impl->optionalUpload())
        visitor.addOpaqueRoot(upload);

    if (Document* responseDocument = m_impl->optionalResponseXML())
        visitor.addOpaqueRoot(responseDocument);

    if (ArrayBuffer* responseArrayBuffer = m_impl->optionalResponseArrayBuffer())
        visitor.addOpaqueRoot(responseArrayBuffer);

#if ENABLE(XHR_RESPONSE_BLOB)
    if (Blob* responseBlob = m_impl->optionalResponseBlob())
        visitor.addOpaqueRoot(responseBlob);
#endif

    m_impl->visitJSEventListeners(visitor);
}
コード例 #19
0
void JSTreeWalker::visitChildren(JSCell* cell, SlotVisitor& visitor)
{
    JSTreeWalker* thisObject = jsCast<JSTreeWalker*>(cell);
    ASSERT_GC_OBJECT_INHERITS(thisObject, info());
    COMPILE_ASSERT(StructureFlags & OverridesVisitChildren, OverridesVisitChildrenWithoutSettingFlag);
    ASSERT(thisObject->structure()->typeInfo().overridesVisitChildren());
    Base::visitChildren(thisObject, visitor);

    if (NodeFilter* filter = thisObject->m_impl->filter())
        visitor.addOpaqueRoot(filter);
}
コード例 #20
0
void JSMediaSource::visitAdditionalChildren(SlotVisitor& visitor)
{
    MediaSource* mediaSource = static_cast<MediaSource*>(&impl());
    visitor.addOpaqueRoot(mediaSource);

    // -- end boiler plate code --

    // Mark SourceBufferList
    SourceBufferList* sourceBufferList = mediaSource->sourceBuffers();
    if (sourceBufferList) {
        visitor.addOpaqueRoot(sourceBufferList);

        // Mark SourceBuffer
        for (unsigned long i = 0, len = sourceBufferList->length(); i < len; i++) {
            SourceBuffer* sourceBuffer = sourceBufferList->item(i);
            if (sourceBuffer)
                visitor.addOpaqueRoot(sourceBuffer);
        }
    }
}
コード例 #21
0
void JSVideoTrack::visitChildren(JSCell* cell, SlotVisitor& visitor)
{
    JSVideoTrack* jsVideoTrack = jsCast<JSVideoTrack*>(cell);
    ASSERT_GC_OBJECT_INHERITS(jsVideoTrack, info());
    COMPILE_ASSERT(StructureFlags & OverridesVisitChildren, OverridesVisitChildrenWithoutSettingFlag);
    ASSERT(jsVideoTrack->structure()->typeInfo().overridesVisitChildren());
    Base::visitChildren(jsVideoTrack, visitor);

    VideoTrack& videoTrack = jsVideoTrack->impl();
    visitor.addOpaqueRoot(root(&videoTrack));
}
コード例 #22
0
ファイル: JSNodeCustom.cpp プロジェクト: Xertz/EAWebKit
void JSNode::visitChildren(SlotVisitor& visitor)
{
    ASSERT_GC_OBJECT_INHERITS(this, &s_info);
    COMPILE_ASSERT(StructureFlags & OverridesVisitChildren, OverridesVisitChildrenWithoutSettingFlag);
    ASSERT(structure()->typeInfo().overridesVisitChildren());
    Base::visitChildren(visitor);

    Node* node = m_impl.get();
    node->visitJSEventListeners(visitor);

    visitor.addOpaqueRoot(root(node));
}
コード例 #23
0
ファイル: JSArrayBufferView.cpp プロジェクト: endlessm/WebKit
void JSArrayBufferView::visitChildren(JSCell* cell, SlotVisitor& visitor)
{
    JSArrayBufferView* thisObject = jsCast<JSArrayBufferView*>(cell);

    if (thisObject->hasArrayBuffer()) {
        ArrayBuffer* buffer = thisObject->buffer();
        RELEASE_ASSERT(buffer);
        visitor.addOpaqueRoot(buffer);
    }
    
    Base::visitChildren(thisObject, visitor);
}
コード例 #24
0
void JSDOMWindow::visitChildren(JSCell* cell, SlotVisitor& visitor)
{
    JSDOMWindow* thisObject = jsCast<JSDOMWindow*>(cell);
    ASSERT_GC_OBJECT_INHERITS(thisObject, &s_info);
    COMPILE_ASSERT(StructureFlags & OverridesVisitChildren, OverridesVisitChildrenWithoutSettingFlag);
    ASSERT(thisObject->structure()->typeInfo().overridesVisitChildren());
    Base::visitChildren(thisObject, visitor);

    thisObject->impl()->visitJSEventListeners(visitor);
    if (Frame* frame = thisObject->impl()->frame())
        visitor.addOpaqueRoot(frame);
}
コード例 #25
0
ファイル: JSAttrCustom.cpp プロジェクト: Xertz/EAWebKit
void JSAttr::visitChildren(SlotVisitor& visitor)
{
    ASSERT_GC_OBJECT_INHERITS(this, &s_info);
    COMPILE_ASSERT(StructureFlags & OverridesVisitChildren, OverridesVisitChildrenWithoutSettingFlag);
    ASSERT(structure()->typeInfo().overridesVisitChildren());
    Base::visitChildren(visitor);

    Element* element = impl()->ownerElement();
    if (!element)
        return;
    visitor.addOpaqueRoot(root(element));
}
コード例 #26
0
void JSAudioTrackList::visitChildren(JSCell* cell, SlotVisitor& visitor)
{
    JSAudioTrackList* jsAudioTrackList = jsCast<JSAudioTrackList*>(cell);
    ASSERT_GC_OBJECT_INHERITS(jsAudioTrackList, info());
    COMPILE_ASSERT(StructureFlags & OverridesVisitChildren, OverridesVisitChildrenWithoutSettingFlag);
    ASSERT(jsAudioTrackList->structure()->typeInfo().overridesVisitChildren());
    Base::visitChildren(jsAudioTrackList, visitor);

    AudioTrackList* audioTrackList = static_cast<AudioTrackList*>(jsAudioTrackList->impl());
    visitor.addOpaqueRoot(root(audioTrackList->element()));
    audioTrackList->visitJSEventListeners(visitor);
}
コード例 #27
0
void JSMessagePort::visitChildren(SlotVisitor& visitor)
{
    ASSERT_GC_OBJECT_INHERITS(this, &s_info);
    COMPILE_ASSERT(StructureFlags & OverridesVisitChildren, OverridesVisitChildrenWithoutSettingFlag);
    ASSERT(structure()->typeInfo().overridesVisitChildren());
    Base::visitChildren(visitor);

    // If we have a locally entangled port, we can directly mark it as reachable. Ports that are remotely entangled are marked in-use by markActiveObjectsForContext().
    if (MessagePort* port = m_impl->locallyEntangledPort())
        visitor.addOpaqueRoot(port);

    m_impl->visitJSEventListeners(visitor);
}
コード例 #28
0
void JSTextTrack::visitChildren(JSCell* cell, SlotVisitor& visitor)
{
    JSTextTrack* jsTextTrack = jsCast<JSTextTrack*>(cell);
    ASSERT_GC_OBJECT_INHERITS(jsTextTrack, &s_info);
    COMPILE_ASSERT(StructureFlags & OverridesVisitChildren, OverridesVisitChildrenWithoutSettingFlag);
    ASSERT(jsTextTrack->structure()->typeInfo().overridesVisitChildren());
    Base::visitChildren(jsTextTrack, visitor);

    TextTrack* textTrack = static_cast<TextTrack*>(jsTextTrack->impl());
    visitor.addOpaqueRoot(root(textTrack));

    textTrack->visitJSEventListeners(visitor);
}
コード例 #29
0
void JSAttr::visitChildren(JSCell* cell, SlotVisitor& visitor)
{
    JSAttr* thisObject = jsCast<JSAttr*>(cell);
    ASSERT_GC_OBJECT_INHERITS(thisObject, &s_info);
    COMPILE_ASSERT(StructureFlags & OverridesVisitChildren, OverridesVisitChildrenWithoutSettingFlag);
    ASSERT(thisObject->structure()->typeInfo().overridesVisitChildren());
    Base::visitChildren(thisObject, visitor);

    Element* element = thisObject->impl()->ownerElement();
    if (!element)
        return;
    visitor.addOpaqueRoot(root(element));
}
コード例 #30
0
ファイル: JSNodeCustom.cpp プロジェクト: Moondee/Artemis
void JSNode::visitChildren(JSCell* cell, SlotVisitor& visitor)
{
    JSNode* thisObject = jsCast<JSNode*>(cell);
    ASSERT_GC_OBJECT_INHERITS(thisObject, &s_info);
    COMPILE_ASSERT(StructureFlags & OverridesVisitChildren, OverridesVisitChildrenWithoutSettingFlag);
    ASSERT(thisObject->structure()->typeInfo().overridesVisitChildren());
    Base::visitChildren(thisObject, visitor);

    Node* node = thisObject->impl();
    node->visitJSEventListeners(visitor);

    visitor.addOpaqueRoot(root(node));
}