1999-05-18 00:16:22 +04:00
|
|
|
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*-
|
|
|
|
*
|
1999-11-06 06:43:54 +03:00
|
|
|
* The contents of this file are subject to the Netscape Public
|
|
|
|
* License Version 1.1 (the "License"); you may not use this file
|
|
|
|
* except in compliance with the License. You may obtain a copy of
|
|
|
|
* the License at http://www.mozilla.org/NPL/
|
1999-05-18 00:16:22 +04:00
|
|
|
*
|
1999-11-06 06:43:54 +03:00
|
|
|
* Software distributed under the License is distributed on an "AS
|
|
|
|
* IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
|
|
|
|
* implied. See the License for the specific language governing
|
|
|
|
* rights and limitations under the License.
|
1999-05-18 00:16:22 +04:00
|
|
|
*
|
1999-11-06 06:43:54 +03:00
|
|
|
* The Original Code is mozilla.org code.
|
|
|
|
*
|
|
|
|
* The Initial Developer of the Original Code is Netscape
|
1999-05-18 00:16:22 +04:00
|
|
|
* Communications Corporation. Portions created by Netscape are
|
1999-11-06 06:43:54 +03:00
|
|
|
* Copyright (C) 1998,1999 Netscape Communications Corporation. All
|
|
|
|
* Rights Reserved.
|
|
|
|
*
|
|
|
|
* Contributor(s):
|
1999-05-18 00:16:22 +04:00
|
|
|
*/
|
|
|
|
|
|
|
|
#include "nsIFactory.h"
|
|
|
|
#include "nsISupports.h"
|
1999-10-13 09:55:06 +04:00
|
|
|
#include "nsIGenericFactory.h"
|
|
|
|
#include "nsIModule.h"
|
|
|
|
|
1999-05-18 00:16:22 +04:00
|
|
|
#include "nsAbBaseCID.h"
|
|
|
|
#include "pratom.h"
|
|
|
|
#include "nsIComponentManager.h"
|
|
|
|
#include "nsIServiceManager.h"
|
|
|
|
#include "rdf.h"
|
|
|
|
#include "nsCRT.h"
|
|
|
|
#include "nsCOMPtr.h"
|
|
|
|
|
|
|
|
|
|
|
|
/* Include all of the interfaces our factory can generate components for */
|
|
|
|
|
|
|
|
#include "nsDirectoryDataSource.h"
|
|
|
|
#include "nsCardDataSource.h"
|
|
|
|
#include "nsAbDirectory.h"
|
|
|
|
#include "nsAbCard.h"
|
1999-06-16 04:04:49 +04:00
|
|
|
#include "nsAddrDatabase.h"
|
1999-07-02 00:04:04 +04:00
|
|
|
#include "nsAddressBook.h"
|
1999-07-07 23:06:40 +04:00
|
|
|
#include "nsAddrBookSession.h"
|
1999-07-20 02:52:23 +04:00
|
|
|
#include "nsAbDirProperty.h"
|
1999-07-13 23:08:27 +04:00
|
|
|
#include "nsAbAutoCompleteSession.h"
|
1999-08-21 04:22:26 +04:00
|
|
|
#include "nsAbAddressCollecter.h"
|
2000-03-27 12:18:10 +04:00
|
|
|
#include "nsAddbookProtocolHandler.h"
|
|
|
|
#include "nsAddbookUrl.h"
|
1999-05-18 00:16:22 +04:00
|
|
|
|
1999-10-13 09:55:06 +04:00
|
|
|
NS_GENERIC_FACTORY_CONSTRUCTOR(nsAddressBook)
|
|
|
|
NS_GENERIC_FACTORY_CONSTRUCTOR_INIT(nsAbDirectoryDataSource,Init)
|
|
|
|
NS_GENERIC_FACTORY_CONSTRUCTOR(nsAbDirectory)
|
|
|
|
NS_GENERIC_FACTORY_CONSTRUCTOR_INIT(nsAbCardDataSource,Init)
|
|
|
|
NS_GENERIC_FACTORY_CONSTRUCTOR(nsAbCard)
|
|
|
|
NS_GENERIC_FACTORY_CONSTRUCTOR(nsAbCardProperty)
|
|
|
|
NS_GENERIC_FACTORY_CONSTRUCTOR(nsAddrDatabase)
|
|
|
|
NS_GENERIC_FACTORY_CONSTRUCTOR(nsAbDirProperty)
|
|
|
|
NS_GENERIC_FACTORY_CONSTRUCTOR(nsAddrBookSession)
|
|
|
|
NS_GENERIC_FACTORY_CONSTRUCTOR(nsAbAutoCompleteSession)
|
|
|
|
NS_GENERIC_FACTORY_CONSTRUCTOR(nsAbAddressCollecter)
|
2000-03-27 12:18:10 +04:00
|
|
|
NS_GENERIC_FACTORY_CONSTRUCTOR(nsAddbookUrl)
|
|
|
|
|
|
|
|
//NS_GENERIC_FACTORY_CONSTRUCTOR(nsAddbookProtocolHandler)
|
|
|
|
|
1999-11-02 04:53:28 +03:00
|
|
|
static nsModuleComponentInfo components[] =
|
1999-05-18 00:16:22 +04:00
|
|
|
{
|
1999-11-12 12:07:26 +03:00
|
|
|
{ "Address Book",
|
|
|
|
NS_ADDRESSBOOK_CID,
|
|
|
|
NS_ADDRESSBOOK_PROGID,
|
2000-02-26 06:52:06 +03:00
|
|
|
nsAddressBookConstructor },
|
|
|
|
{ "Address Book Startup Handler",
|
|
|
|
NS_ADDRESSBOOK_CID,
|
|
|
|
NS_ADDRESSBOOKSTARTUPHANDLER_PROGID,
|
2000-02-06 14:04:10 +03:00
|
|
|
nsAddressBookConstructor,
|
|
|
|
nsAddressBook::RegisterProc,
|
2000-02-26 06:52:06 +03:00
|
|
|
nsAddressBook::UnregisterProc },
|
1999-11-12 12:07:26 +03:00
|
|
|
{ "Address Book Directory Datasource",
|
|
|
|
NS_ABDIRECTORYDATASOURCE_CID,
|
|
|
|
NS_ABDIRECTORYDATASOURCE_PROGID,
|
|
|
|
nsAbDirectoryDataSourceConstructor },
|
|
|
|
{ "Address Book Directory",
|
|
|
|
NS_ABDIRECTORY_CID,
|
|
|
|
NS_ABDIRECTORY_PROGID,
|
|
|
|
nsAbDirectoryConstructor },
|
|
|
|
{ "Address Book Card Datasource",
|
|
|
|
NS_ABCARDDATASOURCE_CID,
|
|
|
|
NS_ABCARDDATASOURCE_PROGID,
|
|
|
|
nsAbCardDataSourceConstructor },
|
|
|
|
{ "Address Book Card",
|
|
|
|
NS_ABCARD_CID,
|
|
|
|
NS_ABCARD_PROGID,
|
|
|
|
nsAbCardConstructor },
|
|
|
|
{ "Address Database",
|
|
|
|
NS_ADDRDATABASE_CID,
|
|
|
|
NS_ADDRDATABASE_PROGID,
|
|
|
|
nsAddrDatabaseConstructor },
|
|
|
|
{ "Address Book Card Property",
|
|
|
|
NS_ABCARDPROPERTY_CID,
|
|
|
|
NS_ABCARDPROPERTY_PROGID,
|
|
|
|
nsAbCardPropertyConstructor },
|
|
|
|
{ "Address Book Directory Property",
|
|
|
|
NS_ABDIRPROPERTY_CID,
|
|
|
|
NS_ABDIRPROPERTY_PROGID,
|
|
|
|
nsAbDirPropertyConstructor },
|
|
|
|
{ "Address Book Session",
|
|
|
|
NS_ADDRBOOKSESSION_CID,
|
|
|
|
NS_ADDRBOOKSESSION_PROGID,
|
|
|
|
nsAddrBookSessionConstructor },
|
|
|
|
{ "Address Book Auto Complete Session",
|
|
|
|
NS_ABAUTOCOMPLETESESSION_CID,
|
|
|
|
NS_ABAUTOCOMPLETESESSION_PROGID,
|
|
|
|
nsAbAutoCompleteSessionConstructor },
|
|
|
|
{ "Address Book Address Collector",
|
|
|
|
NS_ABADDRESSCOLLECTER_CID,
|
|
|
|
NS_ABADDRESSCOLLECTER_PROGID,
|
2000-03-27 12:18:10 +04:00
|
|
|
nsAbAddressCollecterConstructor },
|
|
|
|
{ "The addbook URL Interface",
|
|
|
|
NS_ADDBOOKURL_CID,
|
|
|
|
NS_ADDBOOKURL_PROGID,
|
|
|
|
nsAddbookUrlConstructor },
|
|
|
|
{ "The addbook Protocol Handler",
|
|
|
|
NS_ADDBOOK_HANDLER_CID,
|
|
|
|
NS_NETWORK_PROTOCOL_PROGID_PREFIX "addbook",
|
|
|
|
nsAddbookProtocolHandler::Create }
|
1999-10-13 09:55:06 +04:00
|
|
|
};
|
|
|
|
|
1999-11-12 12:07:26 +03:00
|
|
|
NS_IMPL_NSGETMODULE("nsAbModule", components)
|