sbLocalDatabaseLibraryFactory.cpp File Reference
#include "sbLocalDatabaseLibraryFactory.h"
#include <nsIAppStartupNotifier.h>
#include <nsICategoryManager.h>
#include <nsIConverterInputStream.h>
#include <nsIFile.h>
#include <nsIIOService.h>
#include <nsILocalFile.h>
#include <nsIProperties.h>
#include <nsIPropertyBag2.h>
#include <nsIURI.h>
#include <nsIURL.h>
#include <nsIInputStream.h>
#include <nsIUnicharInputStream.h>
#include <nsIUUIDGenerator.h>
#include <nsIWritablePropertyBag2.h>
#include <sbIDatabaseResult.h>
#include <sbILibrary.h>
#include <sbILocalDatabasePropertyCache.h>
#include <sbISQLBuilder.h>
#include <DatabaseQuery.h>
#include <nsAutoPtr.h>
#include <nsComponentManagerUtils.h>
#include <nsNetUtil.h>
#include <nsServiceManagerUtils.h>
#include <nsWeakReference.h>
#include <nsXPCOMCID.h>
#include "sbLocalDatabaseCID.h"
#include "sbLocalDatabaseLibrary.h"
#include <sbSQLBuilderCID.h>
Include dependency graph for sbLocalDatabaseLibraryFactory.cpp:

Go to the source code of this file.

Macros

#define DEFAULT_LIBRARY_NAME   NS_LITERAL_STRING("defaultlibrary.db")
 
#define SB_PROPERTYBAG_CONTRACTID   "@songbirdnest.com/moz/xpcom/sbpropertybag;1"
 
#define PROPERTY_KEY_DATABASEFILE   "databaseFile"
 
#define SCHEMA_URL   "chrome://songbird/content/library/localdatabase/schema.sql"
 
#define SB_NAMEKEY_LIBRARY   "&chrome://songbird/locale/songbird.properties#servicesource.library"
 
#define PERMISSIONS_FILE   0644
 
#define PERMISSIONS_DIRECTORY   0755
 
#define CONVERTER_BUFFER_SIZE   8192
 

Functions

static nsresult CreateDirectory (nsIFile *aDirectory)
 
static PRBool IsDirectoryWritable (nsIFile *aDirectory)
 
static already_AddRefed
< nsILocalFile > 
GetDBFolder ()
 

Macro Definition Documentation

#define CONVERTER_BUFFER_SIZE   8192

Definition at line 69 of file sbLocalDatabaseLibraryFactory.cpp.

#define DEFAULT_LIBRARY_NAME   NS_LITERAL_STRING("defaultlibrary.db")

Definition at line 59 of file sbLocalDatabaseLibraryFactory.cpp.

#define PERMISSIONS_DIRECTORY   0755

Definition at line 67 of file sbLocalDatabaseLibraryFactory.cpp.

#define PERMISSIONS_FILE   0644

Definition at line 66 of file sbLocalDatabaseLibraryFactory.cpp.

#define PROPERTY_KEY_DATABASEFILE   "databaseFile"

Definition at line 61 of file sbLocalDatabaseLibraryFactory.cpp.

#define SB_NAMEKEY_LIBRARY   "&chrome://songbird/locale/songbird.properties#servicesource.library"

Definition at line 63 of file sbLocalDatabaseLibraryFactory.cpp.

#define SB_PROPERTYBAG_CONTRACTID   "@songbirdnest.com/moz/xpcom/sbpropertybag;1"

Definition at line 60 of file sbLocalDatabaseLibraryFactory.cpp.

#define SCHEMA_URL   "chrome://songbird/content/library/localdatabase/schema.sql"

Definition at line 62 of file sbLocalDatabaseLibraryFactory.cpp.

Function Documentation

static nsresult CreateDirectory ( nsIFile *  aDirectory)
static

Definition at line 72 of file sbLocalDatabaseLibraryFactory.cpp.

static already_AddRefed<nsILocalFile> GetDBFolder ( )
static

Definition at line 120 of file sbLocalDatabaseLibraryFactory.cpp.

Here is the caller graph for this function:

static PRBool IsDirectoryWritable ( nsIFile *  aDirectory)
static

Definition at line 89 of file sbLocalDatabaseLibraryFactory.cpp.