An interface to allow different users of nsILDAPAutoCompleteSession to format each nsILDAPMessage into an nsIAutoCompleteItem as it sees fit.
|Possible states that can be passed in aState to formatException|
Returns an nsIAutoCompleteItem generated from the data in the given nsILDAPMessage.
- message: message to be formatted
nsIAutoCompleteItem formatException ( PRInt32 state , nsresult errorCode )
This method formats an error condition into an nsIAutoCompleteItem for display to the user. Specifically, the state that the session was in when the error occured (aState) is formatted into a general error message which is put in the value attribute of the item, and the specific error (aErrorCode) is formatted into another message which is put in an nsISupportsString in the param attribute of the item.
- state: state of autocomplete session when error occurred
- errorCode: specific error encountered
- newly generated item
Gets a list of all the LDAP attributes that should be requested from the LDAP server when a lookup is done. This avoids wasting server time, bandwidth, and client time processing unused attributes.
Note that this is only required to be called by the nsILDAPAutoCompleteSession implementation when the nsILDAPAutoCompleteSession::formatter IDL attribute is set. . So if for some reason, the LDAP attributes to be returned by searches has to change (eg because the user changed a preference), the nsILDAPAutoCompleteSession::formatter IDL attribute should be re-set to the same object to force a new getAttributes() call.
- count: number of attributes in the array
- attrs: list of LDAP attributes to request
This interface is the type of the following properties:
Reference documentation is generated from Mozilla's source.