nsIPlacesImportExportService Interface Reference

import"nsIPlacesImportExportService.idl";

Inheritance diagram for nsIPlacesImportExportService:
[legend]
Collaboration diagram for nsIPlacesImportExportService:
[legend]

Public Member Functions

void importHTMLFromFile (in nsILocalFile aFile, in boolean aIsInitialImport)
 
void importHTMLFromFileToFolder (in nsILocalFile aFile, in PRInt64 aFolder, in boolean aIsInitialImport)
 
void exportHTMLToFile (in nsILocalFile aFile)
 
void backupBookmarksFile ()
 

Detailed Description

The PlacesImportExport interface provides methods for importing and exporting Places data.

Definition at line 49 of file nsIPlacesImportExportService.idl.

Member Function Documentation

void nsIPlacesImportExportService::backupBookmarksFile ( )

Backup the bookmarks.html file.

void nsIPlacesImportExportService::exportHTMLToFile ( in nsILocalFile  aFile)

Saves the current bookmarks hierarchy to a bookmarks.html file.

void nsIPlacesImportExportService::importHTMLFromFile ( in nsILocalFile  aFile,
in boolean  aIsInitialImport 
)

Loads the given bookmarks.html file and replaces it with the current bookmarks hierarchy (if aIsInitialImport is true) or appends it (if aIsInitialImport is false).

Three nsIObserverService notifications are fired as a result of the import. "bookmarks-restore-begin" is fired just before the import is started. "bookmarks-restore-success" is fired right after the bookmarks are successfully imported. "bookmarks-restore-failed" is fired right after a failure occurs when importing the bookmarks. Observers will be passed through their data parameters either "html" if aIsInitialImport is false or "html-initial" if aIsInitialImport is true. The observer subject will be null.

void nsIPlacesImportExportService::importHTMLFromFileToFolder ( in nsILocalFile  aFile,
in PRInt64  aFolder,
in boolean  aIsInitialImport 
)

Loads the given bookmarks.html file and puts it in the given folder

Three nsIObserverService notifications are fired as a result of the import. "bookmarks-restore-begin" is fired just before the import is started. "bookmarks-restore-success" is fired right after the bookmarks are successfully imported. "bookmarks-restore-failed" is fired right after a failure occurs when importing the bookmarks. Observers will be passed through their data parameters either "html" if aIsInitialImport is false or "html-initial" if aIsInitialImport is true. The observer subject will be an nsISupportsPRInt64 whose value is aFolder.


The documentation for this interface was generated from the following file: