Struct xpcom::interfaces::nsIMozIconURI [] [src]

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

interface nsIMozIconURI : nsIURI

/**
   * nsIIconURI
   *
   * This interface derives from nsIURI, to provide additional information
   * about moz-icon URIs.
   *
   * What *is* a moz-icon URI you ask?  Well, it has the following syntax:
   *
   * moz-icon:[<valid-url> | //<file-with-extension> | //stock/<stock-icon>]?
   *            ['?'[<parameter-value-pairs>]]
   *
   * <valid-url> is a valid URL spec.
   *
   * <file-with-extension> is any filename with an extension, e.g. "dummy.html".
   * If the file you want an icon for isn't known to exist, you can use this
   * instead of a URL and just place a dummy file name with the extension or
   * content type you want.
   *
   * <stock-icon> is the name of a platform-dependant stock icon.
   *
   * Legal parameter value pairs are listed below:
   *
   *   Parameter:   size
   *   Values:      [<integer> | button | toolbar | toolbarsmall | menu |
   *                 dialog]
   *   Description: If integer, this is the desired size in square pixels of
   *                the icon
   *                Else, use the OS default for the specified keyword context.
   *
   *   Parameter:   state
   *   Values:      [normal | disabled]
   *   Description: The state of the icon.
   *
   *   Parameter:   contentType
   *   Values:      <mime-type>
   *   Description: The mime type we want an icon for. This is ignored by
   *                stock images.
   */

Methods

impl nsIMozIconURI
[src]

[src]

Cast this nsIMozIconURI to one of its base interfaces.

impl nsIMozIconURI
[src]

[src]

attribute nsIURL iconURL;

[src]

attribute nsIURL iconURL;

[src]

attribute unsigned long imageSize;

[src]

attribute unsigned long imageSize;

[src]

readonly attribute ACString stockIcon;

[src]

readonly attribute ACString iconSize;

[src]

readonly attribute ACString iconState;

[src]

attribute ACString contentType;

[src]

attribute ACString contentType;

[src]

readonly attribute ACString fileExtension;

Methods from Deref<Target = nsIURI>

[src]

Cast this nsIURI to one of its base interfaces.

[src]

/************************************************************************
     * The URI is broken down into the following principal components:
     */
/**
     * Returns a string representation of the URI. Setting the spec causes
     * the new spec to be parsed per the rules for the scheme the URI
     * currently has.  In particular, setting the spec to a URI string with a
     * different scheme will generally produce incorrect results; no one
     * outside of a protocol handler implementation should be doing that.  If
     * the URI stores information from the nsIIOService.newURI call used to
     * create it other than just the parsed string, then behavior of this
     * information on setting the spec attribute is undefined.
     *
     * Some characters may be escaped.
     */

attribute AUTF8String spec;

[src]

/************************************************************************
     * The URI is broken down into the following principal components:
     */
/**
     * Returns a string representation of the URI. Setting the spec causes
     * the new spec to be parsed per the rules for the scheme the URI
     * currently has.  In particular, setting the spec to a URI string with a
     * different scheme will generally produce incorrect results; no one
     * outside of a protocol handler implementation should be doing that.  If
     * the URI stores information from the nsIIOService.newURI call used to
     * create it other than just the parsed string, then behavior of this
     * information on setting the spec attribute is undefined.
     *
     * Some characters may be escaped.
     */

attribute AUTF8String spec;

[src]

/**
     * The prePath (eg. scheme://user:password@host:port) returns the string
     * before the path.  This is useful for authentication or managing sessions.
     *
     * Some characters may be escaped.
     */

readonly attribute AUTF8String prePath;

[src]

/**
     * The Scheme is the protocol to which this URI refers.  The scheme is
     * restricted to the US-ASCII charset per RFC3986.  Setting this is
     * highly discouraged outside of a protocol handler implementation, since
     * that will generally lead to incorrect results.
     */

attribute ACString scheme;

[src]

/**
     * The Scheme is the protocol to which this URI refers.  The scheme is
     * restricted to the US-ASCII charset per RFC3986.  Setting this is
     * highly discouraged outside of a protocol handler implementation, since
     * that will generally lead to incorrect results.
     */

attribute ACString scheme;

[src]

/**
     * The username:password (or username only if value doesn't contain a ':')
     *
     * Some characters may be escaped.
     */

attribute AUTF8String userPass;

[src]

/**
     * The username:password (or username only if value doesn't contain a ':')
     *
     * Some characters may be escaped.
     */

attribute AUTF8String userPass;

[src]

/**
     * The optional username and password, assuming the preHost consists of
     * username:password.
     *
     * Some characters may be escaped.
     */

attribute AUTF8String username;

[src]

/**
     * The optional username and password, assuming the preHost consists of
     * username:password.
     *
     * Some characters may be escaped.
     */

attribute AUTF8String username;

[src]

attribute AUTF8String password;

[src]

attribute AUTF8String password;

[src]

/**
     * The host:port (or simply the host, if port == -1).
     *
     * If this attribute is set to a value that only has a host part, the port
     * will not be reset. To reset the port as well use setHostAndPort.
     */

attribute AUTF8String hostPort;

[src]

/**
     * The host:port (or simply the host, if port == -1).
     *
     * If this attribute is set to a value that only has a host part, the port
     * will not be reset. To reset the port as well use setHostAndPort.
     */

attribute AUTF8String hostPort;

[src]

/**
     * This function will always set a host and a port. If the port part is
     * empty, the value of the port will be set to the default value.
     */

void setHostAndPort (in AUTF8String hostport);

[src]

/**
     * The host is the internet domain name to which this URI refers.  It could
     * be an IPv4 (or IPv6) address literal. Otherwise it is an ASCII or punycode
     * encoded string.
     */

attribute AUTF8String host;

[src]

/**
     * The host is the internet domain name to which this URI refers.  It could
     * be an IPv4 (or IPv6) address literal. Otherwise it is an ASCII or punycode
     * encoded string.
     */

attribute AUTF8String host;

[src]

/**
     * A port value of -1 corresponds to the protocol's default port (eg. -1
     * implies port 80 for http URIs).
     */

attribute long port;

[src]

/**
     * A port value of -1 corresponds to the protocol's default port (eg. -1
     * implies port 80 for http URIs).
     */

attribute long port;

[src]

/**
     * The path, typically including at least a leading '/' (but may also be
     * empty, depending on the protocol).
     *
     * Some characters may be escaped.
     *
     * This attribute contains query and ref parts for historical reasons.
     * Use the 'filePath' attribute if you do not want those parts included.
     */

attribute AUTF8String pathQueryRef;

[src]

/**
     * The path, typically including at least a leading '/' (but may also be
     * empty, depending on the protocol).
     *
     * Some characters may be escaped.
     *
     * This attribute contains query and ref parts for historical reasons.
     * Use the 'filePath' attribute if you do not want those parts included.
     */

attribute AUTF8String pathQueryRef;

[src]

/************************************************************************
     * An URI supports the following methods:
     */
/**
     * URI equivalence test (not a strict string comparison).
     *
     * eg. http://foo.com:80/ == http://foo.com/
     */

boolean equals (in nsIURI other);

[src]

/**
     * An optimization to do scheme checks without requiring the users of nsIURI
     * to GetScheme, thereby saving extra allocating and freeing. Returns true if
     * the schemes match (case ignored).
     */

boolean schemeIs (in string scheme);

[src]

/**
     * Clones the current URI.
     */

nsIURI clone ();

[src]

/**
     * This method resolves a relative string into an absolute URI string,
     * using this URI as the base.
     *
     * NOTE: some implementations may have no concept of a relative URI.
     */

AUTF8String resolve (in AUTF8String relativePath);

[src]

/************************************************************************
     * Additional attributes:
     */
/**
     * The URI spec with an ASCII compatible encoding.  Host portion follows
     * the IDNA draft spec.  Other parts are URL-escaped per the rules of
     * RFC2396.  The result is strictly ASCII.
     */

readonly attribute ACString asciiSpec;

[src]

/**
     * The host:port (or simply the host, if port == -1), with an ASCII compatible
     * encoding.  Host portion follows the IDNA draft spec.  The result is strictly
     * ASCII.
     */

readonly attribute ACString asciiHostPort;

[src]

/**
     * The URI host with an ASCII compatible encoding.  Follows the IDNA
     * draft spec for converting internationalized domain names (UTF-8) to
     * ASCII for compatibility with existing internet infrasture.
     */

readonly attribute ACString asciiHost;

[src]

/************************************************************************
     * Additional attribute & methods added for .ref support:
     */
/**
     * Returns the reference portion (the part after the "#") of the URI.
     * If there isn't one, an empty string is returned.
     *
     * Some characters may be escaped.
     */

attribute AUTF8String ref;

[src]

/************************************************************************
     * Additional attribute & methods added for .ref support:
     */
/**
     * Returns the reference portion (the part after the "#") of the URI.
     * If there isn't one, an empty string is returned.
     *
     * Some characters may be escaped.
     */

attribute AUTF8String ref;

[src]

/**
     * URI equivalence test (not a strict string comparison), ignoring
     * the value of the .ref member.
     *
     * eg. http://foo.com/# == http://foo.com/
     *     http://foo.com/#aaa == http://foo.com/#bbb
     */

boolean equalsExceptRef (in nsIURI other);

[src]

/**
     * Clones the current URI, clearing the 'ref' attribute in the clone.
     */

nsIURI cloneIgnoringRef ();

[src]

/**
     * Clones the current URI, replacing the 'ref' attribute in the clone with
     * the ref supplied.
     */

nsIURI cloneWithNewRef (in AUTF8String newRef);

[src]

/**
     * returns a string for the current URI with the ref element cleared.
     */

readonly attribute AUTF8String specIgnoringRef;

[src]

/**
     * Returns if there is a reference portion (the part after the "#") of the URI.
     */

readonly attribute boolean hasRef;

[src]

/************************************************************************
     * Additional attributes added for .query support:
     */
/**
     * Returns a path including the directory and file portions of a
     * URL.  For example, the filePath of "http://host/foo/bar.html#baz"
     * is "/foo/bar.html".
     *
     * Some characters may be escaped.
     */

attribute AUTF8String filePath;

[src]

/************************************************************************
     * Additional attributes added for .query support:
     */
/**
     * Returns a path including the directory and file portions of a
     * URL.  For example, the filePath of "http://host/foo/bar.html#baz"
     * is "/foo/bar.html".
     *
     * Some characters may be escaped.
     */

attribute AUTF8String filePath;

[src]

/**
     * Returns the query portion (the part after the "?") of the URL.
     * If there isn't one, an empty string is returned.
     *
     * Some characters may be escaped.
     */

attribute AUTF8String query;

[src]

/**
     * Returns the query portion (the part after the "?") of the URL.
     * If there isn't one, an empty string is returned.
     *
     * Some characters may be escaped.
     */

attribute AUTF8String query;

[src]

/**
     * If the URI has a punycode encoded hostname, this will hold the UTF8
     * representation of that hostname (if that representation doesn't contain
     * blacklisted characters, and the network.IDN_show_punycode pref is false)
     * Otherwise, if the hostname is ASCII, it will return the same as .asciiHost
     */

readonly attribute AUTF8String displayHost;

[src]

/**
     * The displayHost:port (or simply the displayHost, if port == -1).
     */

readonly attribute AUTF8String displayHostPort;

[src]

/**
     * Returns the same as calling .spec, only with a UTF8 encoded hostname
     * (if that hostname doesn't contain blacklisted characters, and
     * the network.IDN_show_punycode pref is false)
     */

readonly attribute AUTF8String displaySpec;

[src]

/**
     * Returns the same as calling .prePath, only with a UTF8 encoded hostname
     * (if that hostname doesn't contain blacklisted characters, and
     * the network.IDN_show_punycode pref is false)
     */

readonly attribute AUTF8String displayPrePath;

[src]

/**
     * Returns an nsIURIMutator that can be used to make changes to the URI.
     * After performing the setter operations on the mutator, one may call
     * mutator.finalize() to get a new immutable URI with the desired
     * properties.
     */

nsIURIMutator mutate ();

Trait Implementations

impl XpCom for nsIMozIconURI
[src]

IID: nsIID = nsID(4177420018, 24363, 17395, [133, 125, 91, 100, 209, 146, 196, 39])

[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 nsIMozIconURI
[src]

[src]

Increment the reference count.

[src]

Decrement the reference count, potentially freeing backing memory.

impl Deref for nsIMozIconURI
[src]

The resulting type after dereferencing.

[src]

Dereferences the value.