org.kde.koala
Class URLArgs

java.lang.Object
  extended by org.kde.koala.URLArgs
All Implemented Interfaces:
org.kde.qt.QtSupport

public class URLArgs
extends java.lang.Object
implements org.kde.qt.QtSupport

URLArgs is a set of arguments bundled into a structure, to allow specifying how a URL should be opened by openURL(). In other words, this is like arguments to openURL(), but without have to change the signature of openURL() (since openURL is a generic KParts method). The parts (with a browser extension) who care about urlargs will use those arguments, others will ignore them. This can also be used the other way round, when a part asks for a URL to be opened (with openURLRequest or createNewWindow).


Constructor Summary
  URLArgs()
           
  URLArgs(boolean reload, int xOffset, int yOffset)
           
  URLArgs(boolean reload, int xOffset, int yOffset, java.lang.String serviceType)
           
protected URLArgs(java.lang.Class dummy)
           
  URLArgs(URLArgs args)
           
 
Method Summary
 java.lang.String contentType()
          KHTML-specific field, header defining the type of the POST data.
 boolean doPost()
          KHTML-specific field, whether to do a POST instead of a GET, for the next openURL.
 boolean forcesNewWindow()
          Whether the URL specifies to be opened in a new window
 boolean lockHistory()
           
 boolean newTab()
           
 boolean redirectedRequest()
           
 void setContentType(java.lang.String contentType)
          KHTML-specific field, header defining the type of the POST data.
 void setDoPost(boolean enable)
          KHTML-specific field, whether to do a POST instead of a GET, for the next openURL.
 void setForcesNewWindow(boolean forcesNewWindow)
          Set whether the URL specifies to be opened in a new window
 void setLockHistory(boolean lock)
          Whether to lock the history when opening the next URL.
 void setNewTab(boolean newTab)
          Whether the URL should be opened in a new tab instead in a new window.
 void setRedirectedRequest(boolean redirected)
          Set the redirect flag to indicate URL is a result of either a META redirect or HTTP redirect.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

URLArgs

protected URLArgs(java.lang.Class dummy)

URLArgs

public URLArgs()

URLArgs

public URLArgs(URLArgs args)

URLArgs

public URLArgs(boolean reload,
               int xOffset,
               int yOffset,
               java.lang.String serviceType)

URLArgs

public URLArgs(boolean reload,
               int xOffset,
               int yOffset)
Method Detail

setContentType

public void setContentType(java.lang.String contentType)
KHTML-specific field, header defining the type of the POST data.


contentType

public java.lang.String contentType()
KHTML-specific field, header defining the type of the POST data.


setDoPost

public void setDoPost(boolean enable)
KHTML-specific field, whether to do a POST instead of a GET, for the next openURL.


doPost

public boolean doPost()
KHTML-specific field, whether to do a POST instead of a GET, for the next openURL.


setLockHistory

public void setLockHistory(boolean lock)
Whether to lock the history when opening the next URL. This is used during e.g. a redirection, to avoid a new entry in the history.


lockHistory

public boolean lockHistory()

setNewTab

public void setNewTab(boolean newTab)
Whether the URL should be opened in a new tab instead in a new window.


newTab

public boolean newTab()

redirectedRequest

public boolean redirectedRequest()
Returns:
true if the request was a result of a META refresh/redirect request or HTTP redirect.

setRedirectedRequest

public void setRedirectedRequest(boolean redirected)
Set the redirect flag to indicate URL is a result of either a META redirect or HTTP redirect.

Parameters:
redirected - @short Set the redirect flag to indicate URL is a result of either a META redirect or HTTP redirect.

setForcesNewWindow

public void setForcesNewWindow(boolean forcesNewWindow)
Set whether the URL specifies to be opened in a new window


forcesNewWindow

public boolean forcesNewWindow()
Whether the URL specifies to be opened in a new window