Struct xpcom::interfaces::nsIStandardURL [] [src]

#[repr(C)]
pub struct nsIStandardURL { /* fields omitted */ }

interface nsIStandardURL : nsIMutable

/**
 * nsIStandardURL defines the interface to an URL with the standard
 * file path format common to protocols like http, ftp, and file.
 * It supports initialization from a relative path and provides
 * some customization on how URLs are normalized.
 */

Methods

impl nsIStandardURL
[src]

[src]

Cast this nsIStandardURL to one of its base interfaces.

impl nsIStandardURL
[src]

URLTYPE_STANDARD: i64 = 1
/**
     * blah:foo/bar    => blah://foo/bar
     * blah:/foo/bar   => blah:///foo/bar
     * blah://foo/bar  => blah://foo/bar
     * blah:///foo/bar => blah:///foo/bar
     */

URLTYPE_AUTHORITY: i64 = 2
/**
     * blah:foo/bar    => blah://foo/bar
     * blah:/foo/bar   => blah://foo/bar
     * blah://foo/bar  => blah://foo/bar
     * blah:///foo/bar => blah://foo/bar
     */

URLTYPE_NO_AUTHORITY: i64 = 3
/**
     * blah:foo/bar    => blah:///foo/bar
     * blah:/foo/bar   => blah:///foo/bar
     * blah://foo/bar  => blah://foo/bar
     * blah:///foo/bar => blah:///foo/bar
     */

[src]

/**
     * Initialize a standard URL.
     *
     * @param aUrlType       - one of the URLTYPE_ flags listed above.
     * @param aDefaultPort   - if the port parsed from the URL string matches
     *                         this port, then the port will be removed from the
     *                         canonical form of the URL.
     * @param aSpec          - URL string.
     * @param aOriginCharset - the charset from which this URI string
     *                         originated.  this corresponds to the charset
     *                         that should be used when communicating this
     *                         URI to an origin server, for example.  if
     *                         null, then provide aBaseURI implements this
     *                         interface, the origin charset of aBaseURI will
     *                         be assumed, otherwise defaulting to UTF-8 (i.e.,
     *                         no charset transformation from aSpec).
     * @param aBaseURI       - if null, aSpec must specify an absolute URI.
     *                         otherwise, aSpec will be resolved relative
     *                         to aBaseURI.
     */

void init (in unsigned long aUrlType, in long aDefaultPort, in AUTF8String aSpec, in string aOriginCharset, in nsIURI aBaseURI);

[src]

/**
     * Set the default port.
     *
     * Note: If this object is already using its default port (i.e. if it has
     * mPort == -1), then it will now implicitly be using the new default port.
     *
     * @param aNewDefaultPort - if the URI has (or is later given) a port that
     *                          matches this default, then we won't include a
     *                          port number in the canonical form of the URL.
     */

void setDefaultPort (in long aNewDefaultPort);

Methods from Deref<Target = nsIMutable>

[src]

Cast this nsIMutable to one of its base interfaces.

[src]

/**
     * Control whether or not this object can be modified.  If the flag is
     * false, no modification is allowed.  Once the flag has been set to false,
     * it cannot be reset back to true -- attempts to do so throw
     * NS_ERROR_INVALID_ARG.
     */

attribute boolean mutable;

[src]

/**
     * Control whether or not this object can be modified.  If the flag is
     * false, no modification is allowed.  Once the flag has been set to false,
     * it cannot be reset back to true -- attempts to do so throw
     * NS_ERROR_INVALID_ARG.
     */

attribute boolean mutable;

Trait Implementations

impl XpCom for nsIStandardURL
[src]

IID: nsIID = nsID(3132976330, 60391, 17193, [150, 124, 214, 185, 227, 60, 170, 129])

[src]

Perform a QueryInterface call on this object, attempting to dynamically cast it to the requested interface type. Returns Some(RefPtr) if the cast succeeded, and None otherwise. Read more

impl RefCounted for nsIStandardURL
[src]

[src]

Increment the reference count.

[src]

Decrement the reference count, potentially freeing backing memory.

impl Deref for nsIStandardURL
[src]

The resulting type after dereferencing.

[src]

Dereferences the value.