Struct xpcom::interfaces::nsIURIClassifier
[−]
[src]
#[repr(C)]pub struct nsIURIClassifier { /* fields omitted */ }
interface nsIURIClassifier : nsISupports
/**
* The URI classifier service checks a URI against lists of phishing
* and malware sites.
*/
Methods
impl nsIURIClassifier
[src]
pub fn coerce<T: nsIURIClassifierCoerce>(&self) -> &T
[src]
Cast this nsIURIClassifier
to one of its base interfaces.
impl nsIURIClassifier
[src]
pub unsafe fn Classify(
&self,
aPrincipal: *const nsIPrincipal,
aEventTarget: *const nsIEventTarget,
aTrackingProtectionEnabled: bool,
aCallback: *const nsIURIClassifierCallback,
_retval: *mut bool
) -> nsresult
[src]
&self,
aPrincipal: *const nsIPrincipal,
aEventTarget: *const nsIEventTarget,
aTrackingProtectionEnabled: bool,
aCallback: *const nsIURIClassifierCallback,
_retval: *mut bool
) -> nsresult
/**
* Classify a Principal using its URI.
*
* @param aPrincipal
* The principal that should be checked by the URI classifier.
*
* @param nsIEventTarget
* Event target for constructing actor in content process.
* The event target should be tied to Docgroup/Tabgroup by
* using EventTargetFor
*
* @param aTrackingProtectionEnabled
* Whether or not to classify the given URI against tracking
* protection lists
*
* @param aCallback
* The URI classifier will call this callback when the URI has been
* classified.
*
* @return <code>false</code> if classification is not necessary. The
* callback will not be called.
* <code>true</code> if classification will be performed. The
* callback will be called.
*/
boolean classify (in nsIPrincipal aPrincipal, in nsIEventTarget aEventTarget, in boolean aTrackingProtectionEnabled, in nsIURIClassifierCallback aCallback);
pub unsafe fn AsyncClassifyLocalWithTables(
&self,
aURI: *const nsIURI,
aTables: &nsACString,
aCallback: *const nsIURIClassifierCallback
) -> nsresult
[src]
&self,
aURI: *const nsIURI,
aTables: &nsACString,
aCallback: *const nsIURIClassifierCallback
) -> nsresult
/**
* Asynchronously classify a URI with a comma-separated string
* containing the given tables. This does not make network requests.
* The callback does NOT totally follow nsIURIClassifierCallback's
* semantics described above. Only |aList| will be meaningful, which
* is a comma separated list of table names. (same as what classifyLocal
* returns.)
*/
void asyncClassifyLocalWithTables (in nsIURI aURI, in ACString aTables, in nsIURIClassifierCallback aCallback);
pub unsafe fn ClassifyLocal(
&self,
aURI: *const nsIURI,
aTables: &nsACString,
_retval: &mut nsACString
) -> nsresult
[src]
&self,
aURI: *const nsIURI,
aTables: &nsACString,
_retval: &mut nsACString
) -> nsresult
/**
* Same as above, but returns a comma separated list of table names.
* This is an internal interface used only for testing purposes.
*/
ACString classifyLocal (in nsIURI aURI, in ACString aTables);
pub unsafe fn SendThreatHitReport(
&self,
aChannel: *const nsIChannel,
aProvider: &nsACString,
aList: &nsACString,
aFullHash: &nsACString
) -> nsresult
[src]
&self,
aChannel: *const nsIChannel,
aProvider: &nsACString,
aList: &nsACString,
aFullHash: &nsACString
) -> nsresult
/**
* Report to the provider that a Safe Browsing warning was shown.
*
* @param aChannel
* Channel for which the URL matched something on the threat list.
* @param aProvider
* Provider to notify.
* @param aList
* List where the full hash was found.
* @param aFullHash
* Full URL hash that triggered the warning.
*/
void sendThreatHitReport (in nsIChannel aChannel, in ACString aProvider, in ACString aList, in ACString aFullHash);
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 nsIURIClassifier
[src]
const IID: nsIID
IID: nsIID = nsID(1499865292, 30435, 16691, [157, 144, 54, 14, 89, 167, 148, 207])
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 nsIURIClassifier
[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 nsIURIClassifier
[src]
type Target = nsISupports
The resulting type after dereferencing.
fn deref(&self) -> &nsISupports
[src]
Dereferences the value.