Struct xpcom::interfaces::nsIURLParser
[−]
[src]
#[repr(C)]pub struct nsIURLParser { /* fields omitted */ }
interface nsIURLParser : nsISupports
/**
* nsIURLParser specifies the interface to an URL parser that attempts to
* follow the definitions of RFC 2396.
*/
Methods
impl nsIURLParser
[src]
pub fn coerce<T: nsIURLParserCoerce>(&self) -> &T
[src]
Cast this nsIURLParser
to one of its base interfaces.
impl nsIURLParser
[src]
pub unsafe fn ParseURL(
&self,
spec: *const c_char,
specLen: int32_t,
schemePos: *mut uint32_t,
schemeLen: *mut int32_t,
authorityPos: *mut uint32_t,
authorityLen: *mut int32_t,
pathPos: *mut uint32_t,
pathLen: *mut int32_t
) -> nsresult
[src]
&self,
spec: *const c_char,
specLen: int32_t,
schemePos: *mut uint32_t,
schemeLen: *mut int32_t,
authorityPos: *mut uint32_t,
authorityLen: *mut int32_t,
pathPos: *mut uint32_t,
pathLen: *mut int32_t
) -> nsresult
/**
* The string to parse in the following methods may be given as a null
* terminated string, in which case the length argument should be -1.
*
* Out parameters of the following methods are all optional (ie. the caller
* may pass-in a NULL value if the corresponding results are not needed).
* Signed out parameters may hold a value of -1 if the corresponding result
* is not part of the string being parsed.
*
* The parsing routines attempt to be as forgiving as possible.
*/
/**
* ParseSpec breaks the URL string up into its 3 major components: a scheme,
* an authority section (hostname, etc.), and a path.
*
* spec = <scheme>://<authority><path>
*/
void parseURL (in string spec, in long specLen, out unsigned long schemePos, out long schemeLen, out unsigned long authorityPos, out long authorityLen, out unsigned long pathPos, out long pathLen);
pub unsafe fn ParseAuthority(
&self,
authority: *const c_char,
authorityLen: int32_t,
usernamePos: *mut uint32_t,
usernameLen: *mut int32_t,
passwordPos: *mut uint32_t,
passwordLen: *mut int32_t,
hostnamePos: *mut uint32_t,
hostnameLen: *mut int32_t,
port: *mut int32_t
) -> nsresult
[src]
&self,
authority: *const c_char,
authorityLen: int32_t,
usernamePos: *mut uint32_t,
usernameLen: *mut int32_t,
passwordPos: *mut uint32_t,
passwordLen: *mut int32_t,
hostnamePos: *mut uint32_t,
hostnameLen: *mut int32_t,
port: *mut int32_t
) -> nsresult
/**
* ParseAuthority breaks the authority string up into its 4 components:
* username, password, hostname, and hostport.
*
* auth = <username>:<password>@<hostname>:<port>
*/
void parseAuthority (in string authority, in long authorityLen, out unsigned long usernamePos, out long usernameLen, out unsigned long passwordPos, out long passwordLen, out unsigned long hostnamePos, out long hostnameLen, out long port);
pub unsafe fn ParseUserInfo(
&self,
userinfo: *const c_char,
userinfoLen: int32_t,
usernamePos: *mut uint32_t,
usernameLen: *mut int32_t,
passwordPos: *mut uint32_t,
passwordLen: *mut int32_t
) -> nsresult
[src]
&self,
userinfo: *const c_char,
userinfoLen: int32_t,
usernamePos: *mut uint32_t,
usernameLen: *mut int32_t,
passwordPos: *mut uint32_t,
passwordLen: *mut int32_t
) -> nsresult
/**
* userinfo = <username>:<password>
*/
void parseUserInfo (in string userinfo, in long userinfoLen, out unsigned long usernamePos, out long usernameLen, out unsigned long passwordPos, out long passwordLen);
pub unsafe fn ParseServerInfo(
&self,
serverinfo: *const c_char,
serverinfoLen: int32_t,
hostnamePos: *mut uint32_t,
hostnameLen: *mut int32_t,
port: *mut int32_t
) -> nsresult
[src]
&self,
serverinfo: *const c_char,
serverinfoLen: int32_t,
hostnamePos: *mut uint32_t,
hostnameLen: *mut int32_t,
port: *mut int32_t
) -> nsresult
/**
* serverinfo = <hostname>:<port>
*/
void parseServerInfo (in string serverinfo, in long serverinfoLen, out unsigned long hostnamePos, out long hostnameLen, out long port);
pub unsafe fn ParsePath(
&self,
path: *const c_char,
pathLen: int32_t,
filepathPos: *mut uint32_t,
filepathLen: *mut int32_t,
queryPos: *mut uint32_t,
queryLen: *mut int32_t,
refPos: *mut uint32_t,
refLen: *mut int32_t
) -> nsresult
[src]
&self,
path: *const c_char,
pathLen: int32_t,
filepathPos: *mut uint32_t,
filepathLen: *mut int32_t,
queryPos: *mut uint32_t,
queryLen: *mut int32_t,
refPos: *mut uint32_t,
refLen: *mut int32_t
) -> nsresult
/**
* ParsePath breaks the path string up into its 3 major components: a file path,
* a query string, and a reference string.
*
* path = <filepath>?<query>#<ref>
*/
void parsePath (in string path, in long pathLen, out unsigned long filepathPos, out long filepathLen, out unsigned long queryPos, out long queryLen, out unsigned long refPos, out long refLen);
pub unsafe fn ParseFilePath(
&self,
filepath: *const c_char,
filepathLen: int32_t,
directoryPos: *mut uint32_t,
directoryLen: *mut int32_t,
basenamePos: *mut uint32_t,
basenameLen: *mut int32_t,
extensionPos: *mut uint32_t,
extensionLen: *mut int32_t
) -> nsresult
[src]
&self,
filepath: *const c_char,
filepathLen: int32_t,
directoryPos: *mut uint32_t,
directoryLen: *mut int32_t,
basenamePos: *mut uint32_t,
basenameLen: *mut int32_t,
extensionPos: *mut uint32_t,
extensionLen: *mut int32_t
) -> nsresult
/**
* ParseFilePath breaks the file path string up into: the directory portion,
* file base name, and file extension.
*
* filepath = <directory><basename>.<extension>
*/
void parseFilePath (in string filepath, in long filepathLen, out unsigned long directoryPos, out long directoryLen, out unsigned long basenamePos, out long basenameLen, out unsigned long extensionPos, out long extensionLen);
pub unsafe fn ParseFileName(
&self,
filename: *const c_char,
filenameLen: int32_t,
basenamePos: *mut uint32_t,
basenameLen: *mut int32_t,
extensionPos: *mut uint32_t,
extensionLen: *mut int32_t
) -> nsresult
[src]
&self,
filename: *const c_char,
filenameLen: int32_t,
basenamePos: *mut uint32_t,
basenameLen: *mut int32_t,
extensionPos: *mut uint32_t,
extensionLen: *mut int32_t
) -> nsresult
/**
* filename = <basename>.<extension>
*/
void parseFileName (in string filename, in long filenameLen, out unsigned long basenamePos, out long basenameLen, out unsigned long extensionPos, out long extensionLen);
Methods from Deref<Target = nsISupports>
pub fn coerce<T: nsISupportsCoerce>(&self) -> &T
[src]
Cast this nsISupports
to one of its base interfaces.
pub unsafe fn QueryInterface(
&self,
uuid: &nsIID,
result: *mut *mut c_void
) -> nsresult
[src]
&self,
uuid: &nsIID,
result: *mut *mut c_void
) -> nsresult
void QueryInterface (in nsIIDRef uuid, [iid_is (uuid), retval] out nsQIResult result);
pub unsafe fn AddRef(&self) -> nsrefcnt
[src]
[noscript,notxpcom] nsrefcnt AddRef ();
pub unsafe fn Release(&self) -> nsrefcnt
[src]
[noscript,notxpcom] nsrefcnt Release ();
Trait Implementations
impl XpCom for nsIURLParser
[src]
const IID: nsIID
IID: nsIID = nsID(2026230175, 62930, 18226, [141, 61, 213, 167, 215, 19, 59, 192])
fn query_interface<T: XpCom>(&self) -> Option<RefPtr<T>>
[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 nsIURLParser
[src]
unsafe fn addref(&self)
[src]
Increment the reference count.
unsafe fn release(&self)
[src]
Decrement the reference count, potentially freeing backing memory.
impl Deref for nsIURLParser
[src]
type Target = nsISupports
The resulting type after dereferencing.
fn deref(&self) -> &nsISupports
[src]
Dereferences the value.