Search in sources :

Example 1 with PostponedAction

use of com.gargoylesoftware.htmlunit.javascript.PostponedAction in project htmlunit by HtmlUnit.

the class HtmlPage method initialize.

/**
 * Initialize this page.
 * @throws IOException if an IO problem occurs
 * @throws FailingHttpStatusCodeException if the server returns a failing status code AND the property
 * {@link com.gargoylesoftware.htmlunit.WebClientOptions#setThrowExceptionOnFailingStatusCode(boolean)} is set
 * to true.
 */
@Override
public void initialize() throws IOException, FailingHttpStatusCodeException {
    final WebWindow enclosingWindow = getEnclosingWindow();
    final boolean isAboutBlank = getUrl() == UrlUtils.URL_ABOUT_BLANK;
    if (isAboutBlank) {
        // a frame contains first a faked "about:blank" before its real content specified by src gets loaded
        if (enclosingWindow instanceof FrameWindow && !((FrameWindow) enclosingWindow).getFrameElement().isContentLoaded()) {
            return;
        }
        // save the URL that should be used to resolve relative URLs in this page
        if (enclosingWindow instanceof TopLevelWindow) {
            final TopLevelWindow topWindow = (TopLevelWindow) enclosingWindow;
            final WebWindow openerWindow = topWindow.getOpener();
            if (openerWindow != null && openerWindow.getEnclosedPage() != null) {
                baseUrl_ = openerWindow.getEnclosedPage().getWebResponse().getWebRequest().getUrl();
            }
        }
    }
    if (!isAboutBlank) {
        setReadyState(READY_STATE_INTERACTIVE);
        getDocumentElement().setReadyState(READY_STATE_INTERACTIVE);
    }
    executeDeferredScriptsIfNeeded();
    executeEventHandlersIfNeeded(Event.TYPE_DOM_DOCUMENT_LOADED);
    loadFrames();
    // see Node.initInlineFrameIfNeeded()
    if (!isAboutBlank) {
        if (hasFeature(FOCUS_BODY_ELEMENT_AT_START)) {
            setElementWithFocus(getBody());
        }
        setReadyState(READY_STATE_COMPLETE);
        getDocumentElement().setReadyState(READY_STATE_COMPLETE);
    }
    // frame initialization has a different order
    boolean isFrameWindow = enclosingWindow instanceof FrameWindow;
    boolean isFirstPageInFrameWindow = false;
    if (isFrameWindow) {
        isFrameWindow = ((FrameWindow) enclosingWindow).getFrameElement() instanceof HtmlFrame;
        final History hist = enclosingWindow.getHistory();
        if (hist.getLength() > 0 && UrlUtils.URL_ABOUT_BLANK == hist.getUrl(0)) {
            isFirstPageInFrameWindow = hist.getLength() <= 2;
        } else {
            isFirstPageInFrameWindow = enclosingWindow.getHistory().getLength() < 2;
        }
    }
    if (isFrameWindow && !isFirstPageInFrameWindow) {
        executeEventHandlersIfNeeded(Event.TYPE_LOAD);
    }
    for (final FrameWindow frameWindow : getFrames()) {
        if (frameWindow.getFrameElement() instanceof HtmlFrame) {
            final Page page = frameWindow.getEnclosedPage();
            if (page != null && page.isHtmlPage()) {
                ((HtmlPage) page).executeEventHandlersIfNeeded(Event.TYPE_LOAD);
            }
        }
    }
    if (!isFrameWindow) {
        executeEventHandlersIfNeeded(Event.TYPE_LOAD);
        if (!isAboutBlank && enclosingWindow.getWebClient().isJavaScriptEnabled() && hasFeature(EVENT_FOCUS_ON_LOAD)) {
            final HtmlElement body = getBody();
            if (body != null) {
                final Event event = new Event((Window) enclosingWindow.getScriptableObject(), Event.TYPE_FOCUS);
                body.fireEvent(event);
            }
        }
    }
    try {
        while (!afterLoadActions_.isEmpty()) {
            final PostponedAction action = afterLoadActions_.remove(0);
            action.execute();
        }
    } catch (final IOException e) {
        throw e;
    } catch (final Exception e) {
        throw new RuntimeException(e);
    }
    executeRefreshIfNeeded();
}
Also used : Page(com.gargoylesoftware.htmlunit.Page) SgmlPage(com.gargoylesoftware.htmlunit.SgmlPage) IOException(java.io.IOException) History(com.gargoylesoftware.htmlunit.History) ElementNotFoundException(com.gargoylesoftware.htmlunit.ElementNotFoundException) FailingHttpStatusCodeException(com.gargoylesoftware.htmlunit.FailingHttpStatusCodeException) DOMException(org.w3c.dom.DOMException) MalformedURLException(java.net.MalformedURLException) IOException(java.io.IOException) WebWindow(com.gargoylesoftware.htmlunit.WebWindow) Event(com.gargoylesoftware.htmlunit.javascript.host.event.Event) BeforeUnloadEvent(com.gargoylesoftware.htmlunit.javascript.host.event.BeforeUnloadEvent) PostponedAction(com.gargoylesoftware.htmlunit.javascript.PostponedAction) TopLevelWindow(com.gargoylesoftware.htmlunit.TopLevelWindow)

Example 2 with PostponedAction

use of com.gargoylesoftware.htmlunit.javascript.PostponedAction in project htmlunit by HtmlUnit.

the class HtmlImage method setAttributeNS.

/**
 * {@inheritDoc}
 */
@Override
protected void setAttributeNS(final String namespaceURI, final String qualifiedName, final String value, final boolean notifyAttributeChangeListeners, final boolean notifyMutationObservers) {
    final HtmlPage htmlPage = getHtmlPageOrNull();
    if (SRC_ATTRIBUTE.equals(qualifiedName) && value != ATTRIBUTE_NOT_DEFINED && htmlPage != null) {
        final String oldValue = getAttributeNS(namespaceURI, qualifiedName);
        if (!oldValue.equals(value)) {
            super.setAttributeNS(namespaceURI, qualifiedName, value, notifyAttributeChangeListeners, notifyMutationObservers);
            // onload handlers may need to be invoked again, and a new image may need to be downloaded
            onloadProcessed_ = false;
            downloaded_ = false;
            isComplete_ = false;
            width_ = -1;
            height_ = -1;
            if (imageData_ != null) {
                imageData_.close();
                imageData_ = null;
            }
            final String readyState = htmlPage.getReadyState();
            if (READY_STATE_LOADING.equals(readyState)) {
                final PostponedAction action = new PostponedAction(getPage(), "HtmlImage.setAttributeNS") {

                    @Override
                    public void execute() throws Exception {
                        doOnLoad();
                    }
                };
                htmlPage.addAfterLoadAction(action);
                return;
            }
            doOnLoad();
            return;
        }
    }
    super.setAttributeNS(namespaceURI, qualifiedName, value, notifyAttributeChangeListeners, notifyMutationObservers);
}
Also used : PostponedAction(com.gargoylesoftware.htmlunit.javascript.PostponedAction)

Example 3 with PostponedAction

use of com.gargoylesoftware.htmlunit.javascript.PostponedAction in project htmlunit by HtmlUnit.

the class HTMLCollectionFrames method postMessage.

/**
 * Posts a message.
 * @param message the object passed to the window
 * @param targetOrigin the origin this window must be for the event to be dispatched
 * @param transfer an optional sequence of Transferable objects
 * @see <a href="https://developer.mozilla.org/en-US/docs/Web/API/window.postMessage">MDN documentation</a>
 */
@JsxFunction
public void postMessage(final String message, final String targetOrigin, final Object transfer) {
    final WebWindow webWindow = getWebWindow();
    final Page page = webWindow.getEnclosedPage();
    final URL currentURL = page.getUrl();
    if (!"*".equals(targetOrigin) && !"/".equals(targetOrigin)) {
        final URL targetURL;
        try {
            targetURL = new URL(targetOrigin);
        } catch (final Exception e) {
            throw Context.throwAsScriptRuntimeEx(new Exception("SyntaxError: Failed to execute 'postMessage' on 'Window': Invalid target origin '" + targetOrigin + "' was specified (reason: " + e.getMessage() + "."));
        }
        if (getPort(targetURL) != getPort(currentURL)) {
            return;
        }
        if (!targetURL.getHost().equals(currentURL.getHost())) {
            return;
        }
        if (!targetURL.getProtocol().equals(currentURL.getProtocol())) {
            return;
        }
    }
    final MessageEvent event = new MessageEvent();
    final String origin = currentURL.getProtocol() + "://" + currentURL.getHost() + ':' + currentURL.getPort();
    event.initMessageEvent(Event.TYPE_MESSAGE, false, false, message, origin, "", this, transfer);
    event.setParentScope(this);
    event.setPrototype(getPrototype(event.getClass()));
    final JavaScriptEngine jsEngine = (JavaScriptEngine) webWindow.getWebClient().getJavaScriptEngine();
    final PostponedAction action = new PostponedAction(page, "Window.postMessage") {

        @Override
        public void execute() throws Exception {
            final ContextAction<Object> contextAction = cx -> dispatchEvent(event);
            final ContextFactory cf = jsEngine.getContextFactory();
            cf.call(contextAction);
        }
    };
    jsEngine.addPostponedAction(action);
}
Also used : DomElement(com.gargoylesoftware.htmlunit.html.DomElement) WebWindow(com.gargoylesoftware.htmlunit.WebWindow) DialogWindow(com.gargoylesoftware.htmlunit.DialogWindow) HtmlMap(com.gargoylesoftware.htmlunit.html.HtmlMap) JS_WINDOW_SELECTION_NULL_IF_INVISIBLE(com.gargoylesoftware.htmlunit.BrowserVersionFeatures.JS_WINDOW_SELECTION_NULL_IF_INVISIBLE) FF(com.gargoylesoftware.htmlunit.javascript.configuration.SupportedBrowser.FF) MediaQueryList(com.gargoylesoftware.htmlunit.javascript.host.css.MediaQueryList) EDGE(com.gargoylesoftware.htmlunit.javascript.configuration.SupportedBrowser.EDGE) StringUtils(org.apache.commons.lang3.StringUtils) JsxConstant(com.gargoylesoftware.htmlunit.javascript.configuration.JsxConstant) MouseEvent(com.gargoylesoftware.htmlunit.javascript.host.event.MouseEvent) BaseFrameElement(com.gargoylesoftware.htmlunit.html.BaseFrameElement) ContextAction(net.sourceforge.htmlunit.corejs.javascript.ContextAction) Map(java.util.Map) JS_WINDOW_CHANGE_OPENER_ONLY_WINDOW_OBJECT(com.gargoylesoftware.htmlunit.BrowserVersionFeatures.JS_WINDOW_CHANGE_OPENER_ONLY_WINDOW_OBJECT) Scriptable(net.sourceforge.htmlunit.corejs.javascript.Scriptable) JsxSetter(com.gargoylesoftware.htmlunit.javascript.configuration.JsxSetter) HTMLCollection(com.gargoylesoftware.htmlunit.javascript.host.html.HTMLCollection) EnumMap(java.util.EnumMap) DomNode(com.gargoylesoftware.htmlunit.html.DomNode) JsxGetter(com.gargoylesoftware.htmlunit.javascript.configuration.JsxGetter) SpeechSynthesis(com.gargoylesoftware.htmlunit.javascript.host.speech.SpeechSynthesis) JS_WINDOW_TOP_WRITABLE(com.gargoylesoftware.htmlunit.BrowserVersionFeatures.JS_WINDOW_TOP_WRITABLE) HtmlElement(com.gargoylesoftware.htmlunit.html.HtmlElement) HtmlInput(com.gargoylesoftware.htmlunit.html.HtmlInput) LogFactory(org.apache.commons.logging.LogFactory) AlertHandler(com.gargoylesoftware.htmlunit.AlertHandler) HtmlAnchor(com.gargoylesoftware.htmlunit.html.HtmlAnchor) HtmlEmbed(com.gargoylesoftware.htmlunit.html.HtmlEmbed) ScriptableObject(net.sourceforge.htmlunit.corejs.javascript.ScriptableObject) PromptHandler(com.gargoylesoftware.htmlunit.PromptHandler) UrlUtils(com.gargoylesoftware.htmlunit.util.UrlUtils) ArrayList(java.util.ArrayList) JavaScriptException(net.sourceforge.htmlunit.corejs.javascript.JavaScriptException) XmlPage(com.gargoylesoftware.htmlunit.xml.XmlPage) IOException(java.io.IOException) HtmlPage(com.gargoylesoftware.htmlunit.html.HtmlPage) JsxFunction(com.gargoylesoftware.htmlunit.javascript.configuration.JsxFunction) CSS2Properties(com.gargoylesoftware.htmlunit.javascript.host.css.CSS2Properties) JsxClass(com.gargoylesoftware.htmlunit.javascript.configuration.JsxClass) Performance(com.gargoylesoftware.htmlunit.javascript.host.performance.Performance) IE(com.gargoylesoftware.htmlunit.javascript.configuration.SupportedBrowser.IE) WebClient(com.gargoylesoftware.htmlunit.WebClient) JS_WINDOW_FRAMES_ACCESSIBLE_BY_ID(com.gargoylesoftware.htmlunit.BrowserVersionFeatures.JS_WINDOW_FRAMES_ACCESSIBLE_BY_ID) ElementNotFoundException(com.gargoylesoftware.htmlunit.ElementNotFoundException) StyleMedia(com.gargoylesoftware.htmlunit.javascript.host.css.StyleMedia) ScriptResult(com.gargoylesoftware.htmlunit.ScriptResult) HtmlImage(com.gargoylesoftware.htmlunit.html.HtmlImage) URL(java.net.URL) ObjectInputStream(java.io.ObjectInputStream) HtmlTextArea(com.gargoylesoftware.htmlunit.html.HtmlTextArea) HtmlObject(com.gargoylesoftware.htmlunit.html.HtmlObject) HtmlAttributeChangeEvent(com.gargoylesoftware.htmlunit.html.HtmlAttributeChangeEvent) JS_WINDOW_FRAME_BY_ID_RETURNS_WINDOW(com.gargoylesoftware.htmlunit.BrowserVersionFeatures.JS_WINDOW_FRAME_BY_ID_RETURNS_WINDOW) DataTransfer(com.gargoylesoftware.htmlunit.javascript.host.html.DataTransfer) ScriptException(com.gargoylesoftware.htmlunit.ScriptException) FF_ESR(com.gargoylesoftware.htmlunit.javascript.configuration.SupportedBrowser.FF_ESR) Selection(com.gargoylesoftware.htmlunit.javascript.host.dom.Selection) HtmlForm(com.gargoylesoftware.htmlunit.html.HtmlForm) StatusHandler(com.gargoylesoftware.htmlunit.StatusHandler) ConfirmHandler(com.gargoylesoftware.htmlunit.ConfirmHandler) Crypto(com.gargoylesoftware.htmlunit.javascript.host.crypto.Crypto) List(java.util.List) DocumentProxy(com.gargoylesoftware.htmlunit.javascript.host.html.DocumentProxy) ContextFactory(net.sourceforge.htmlunit.corejs.javascript.ContextFactory) Undefined(net.sourceforge.htmlunit.corejs.javascript.Undefined) Function(net.sourceforge.htmlunit.corejs.javascript.Function) Page(com.gargoylesoftware.htmlunit.Page) EventTarget(com.gargoylesoftware.htmlunit.javascript.host.event.EventTarget) HTMLDocument(com.gargoylesoftware.htmlunit.javascript.host.html.HTMLDocument) HtmlUnitScriptable(com.gargoylesoftware.htmlunit.javascript.HtmlUnitScriptable) HashMap(java.util.HashMap) WebWindowNotFoundException(com.gargoylesoftware.htmlunit.WebWindowNotFoundException) HtmlFrame(com.gargoylesoftware.htmlunit.html.HtmlFrame) JS_WINDOW_FORMFIELDS_ACCESSIBLE_BY_NAME(com.gargoylesoftware.htmlunit.BrowserVersionFeatures.JS_WINDOW_FORMFIELDS_ACCESSIBLE_BY_NAME) TopLevelWindow(com.gargoylesoftware.htmlunit.TopLevelWindow) BrowserVersion(com.gargoylesoftware.htmlunit.BrowserVersion) HtmlSelect(com.gargoylesoftware.htmlunit.html.HtmlSelect) SgmlPage(com.gargoylesoftware.htmlunit.SgmlPage) EcmaError(net.sourceforge.htmlunit.corejs.javascript.EcmaError) Event(com.gargoylesoftware.htmlunit.javascript.host.event.Event) JavaScriptEngine(com.gargoylesoftware.htmlunit.javascript.JavaScriptEngine) Context(net.sourceforge.htmlunit.corejs.javascript.Context) FrameWindow(com.gargoylesoftware.htmlunit.html.FrameWindow) HtmlButton(com.gargoylesoftware.htmlunit.html.HtmlButton) XMLDocument(com.gargoylesoftware.htmlunit.javascript.host.xml.XMLDocument) ScriptRuntime(net.sourceforge.htmlunit.corejs.javascript.ScriptRuntime) MalformedURLException(java.net.MalformedURLException) Type(com.gargoylesoftware.htmlunit.StorageHolder.Type) CHROME(com.gargoylesoftware.htmlunit.javascript.configuration.SupportedBrowser.CHROME) PostponedAction(com.gargoylesoftware.htmlunit.javascript.PostponedAction) WebAssert(com.gargoylesoftware.htmlunit.WebAssert) JsxConstructor(com.gargoylesoftware.htmlunit.javascript.configuration.JsxConstructor) Document(com.gargoylesoftware.htmlunit.javascript.host.dom.Document) HTMLElement(com.gargoylesoftware.htmlunit.javascript.host.html.HTMLElement) Log(org.apache.commons.logging.Log) MessageEvent(com.gargoylesoftware.htmlunit.javascript.host.event.MessageEvent) ContextFactory(net.sourceforge.htmlunit.corejs.javascript.ContextFactory) MessageEvent(com.gargoylesoftware.htmlunit.javascript.host.event.MessageEvent) XmlPage(com.gargoylesoftware.htmlunit.xml.XmlPage) HtmlPage(com.gargoylesoftware.htmlunit.html.HtmlPage) Page(com.gargoylesoftware.htmlunit.Page) SgmlPage(com.gargoylesoftware.htmlunit.SgmlPage) PostponedAction(com.gargoylesoftware.htmlunit.javascript.PostponedAction) ScriptableObject(net.sourceforge.htmlunit.corejs.javascript.ScriptableObject) HtmlObject(com.gargoylesoftware.htmlunit.html.HtmlObject) URL(java.net.URL) JavaScriptException(net.sourceforge.htmlunit.corejs.javascript.JavaScriptException) IOException(java.io.IOException) ElementNotFoundException(com.gargoylesoftware.htmlunit.ElementNotFoundException) ScriptException(com.gargoylesoftware.htmlunit.ScriptException) WebWindowNotFoundException(com.gargoylesoftware.htmlunit.WebWindowNotFoundException) MalformedURLException(java.net.MalformedURLException) WebWindow(com.gargoylesoftware.htmlunit.WebWindow) JavaScriptEngine(com.gargoylesoftware.htmlunit.javascript.JavaScriptEngine) JsxFunction(com.gargoylesoftware.htmlunit.javascript.configuration.JsxFunction)

Example 4 with PostponedAction

use of com.gargoylesoftware.htmlunit.javascript.PostponedAction in project htmlunit by HtmlUnit.

the class MessagePort method postMessage.

/**
 * Posts a message.
 * @param message the object passed to the window
 * @param transfer an optional sequence of Transferable objects
 * @see <a href="https://developer.mozilla.org/en-US/docs/Web/API/window.postMessage">MDN documentation</a>
 */
@JsxFunction
public void postMessage(final String message, final Object transfer) {
    if (port1_ != null) {
        final Window w = getWindow();
        final WebWindow webWindow = w.getWebWindow();
        final Page page = webWindow.getEnclosedPage();
        final URL currentURL = page.getUrl();
        final MessageEvent event = new MessageEvent();
        final String origin = currentURL.getProtocol() + "://" + currentURL.getHost() + ':' + currentURL.getPort();
        event.initMessageEvent(Event.TYPE_MESSAGE, false, false, message, origin, "", w, transfer);
        event.setParentScope(port1_);
        event.setPrototype(getPrototype(event.getClass()));
        final JavaScriptEngine jsEngine = (JavaScriptEngine) webWindow.getWebClient().getJavaScriptEngine();
        final PostponedAction action = new PostponedAction(page, "MessagePort.postMessage") {

            @Override
            public void execute() throws Exception {
                final ContextFactory cf = jsEngine.getContextFactory();
                cf.call(cx -> port1_.dispatchEvent(event));
            }
        };
        jsEngine.addPostponedAction(action);
    }
}
Also used : WebWindow(com.gargoylesoftware.htmlunit.WebWindow) ContextFactory(net.sourceforge.htmlunit.corejs.javascript.ContextFactory) MessageEvent(com.gargoylesoftware.htmlunit.javascript.host.event.MessageEvent) Page(com.gargoylesoftware.htmlunit.Page) PostponedAction(com.gargoylesoftware.htmlunit.javascript.PostponedAction) URL(java.net.URL) WebWindow(com.gargoylesoftware.htmlunit.WebWindow) JavaScriptEngine(com.gargoylesoftware.htmlunit.javascript.JavaScriptEngine) JsxFunction(com.gargoylesoftware.htmlunit.javascript.configuration.JsxFunction)

Example 5 with PostponedAction

use of com.gargoylesoftware.htmlunit.javascript.PostponedAction in project htmlunit by HtmlUnit.

the class MutationObserver method attributeReplaced.

/**
 * {@inheritDoc}
 */
@Override
public void attributeReplaced(final HtmlAttributeChangeEvent event) {
    final HtmlElement target = event.getHtmlElement();
    if (subtree_ || target == node_.getDomNodeOrDie()) {
        final String attributeName = event.getName();
        if (attributeFilter_ == null || attributeFilter_.contains(attributeName)) {
            final MutationRecord mutationRecord = new MutationRecord();
            final Scriptable scope = getParentScope();
            mutationRecord.setParentScope(scope);
            mutationRecord.setPrototype(getPrototype(mutationRecord.getClass()));
            mutationRecord.setAttributeName(attributeName);
            mutationRecord.setType("attributes");
            mutationRecord.setTarget(target.getScriptableObject());
            if (attributeOldValue_) {
                mutationRecord.setOldValue(event.getValue());
            }
            final Window window = getWindow();
            final HtmlPage owningPage = (HtmlPage) window.getDocument().getPage();
            final JavaScriptEngine jsEngine = (JavaScriptEngine) window.getWebWindow().getWebClient().getJavaScriptEngine();
            jsEngine.addPostponedAction(new PostponedAction(owningPage, "MutationObserver.attributeReplaced") {

                @Override
                public void execute() throws Exception {
                    final NativeArray array = new NativeArray(new Object[] { mutationRecord });
                    ScriptRuntime.setBuiltinProtoAndParent(array, scope, TopLevel.Builtins.Array);
                    jsEngine.callFunction(owningPage, function_, scope, MutationObserver.this, new Object[] { array });
                }
            });
        }
    }
}
Also used : Window(com.gargoylesoftware.htmlunit.javascript.host.Window) NativeArray(net.sourceforge.htmlunit.corejs.javascript.NativeArray) HtmlPage(com.gargoylesoftware.htmlunit.html.HtmlPage) HtmlElement(com.gargoylesoftware.htmlunit.html.HtmlElement) PostponedAction(com.gargoylesoftware.htmlunit.javascript.PostponedAction) NativeObject(net.sourceforge.htmlunit.corejs.javascript.NativeObject) ScriptableObject(net.sourceforge.htmlunit.corejs.javascript.ScriptableObject) Scriptable(net.sourceforge.htmlunit.corejs.javascript.Scriptable) HtmlUnitScriptable(com.gargoylesoftware.htmlunit.javascript.HtmlUnitScriptable) JavaScriptEngine(com.gargoylesoftware.htmlunit.javascript.JavaScriptEngine)

Aggregations

PostponedAction (com.gargoylesoftware.htmlunit.javascript.PostponedAction)15 Page (com.gargoylesoftware.htmlunit.Page)6 SgmlPage (com.gargoylesoftware.htmlunit.SgmlPage)5 WebWindow (com.gargoylesoftware.htmlunit.WebWindow)5 HtmlPage (com.gargoylesoftware.htmlunit.html.HtmlPage)5 JavaScriptEngine (com.gargoylesoftware.htmlunit.javascript.JavaScriptEngine)5 IOException (java.io.IOException)5 Scriptable (net.sourceforge.htmlunit.corejs.javascript.Scriptable)4 ScriptableObject (net.sourceforge.htmlunit.corejs.javascript.ScriptableObject)4 WebClient (com.gargoylesoftware.htmlunit.WebClient)3 HtmlUnitScriptable (com.gargoylesoftware.htmlunit.javascript.HtmlUnitScriptable)3 JsxFunction (com.gargoylesoftware.htmlunit.javascript.configuration.JsxFunction)3 Window (com.gargoylesoftware.htmlunit.javascript.host.Window)3 Event (com.gargoylesoftware.htmlunit.javascript.host.event.Event)3 MalformedURLException (java.net.MalformedURLException)3 ElementNotFoundException (com.gargoylesoftware.htmlunit.ElementNotFoundException)2 FailingHttpStatusCodeException (com.gargoylesoftware.htmlunit.FailingHttpStatusCodeException)2 TopLevelWindow (com.gargoylesoftware.htmlunit.TopLevelWindow)2 HtmlElement (com.gargoylesoftware.htmlunit.html.HtmlElement)2 MessageEvent (com.gargoylesoftware.htmlunit.javascript.host.event.MessageEvent)2