# -*- Mode: python; indent-tabs-mode: nil; tab-width: 40 -*-
# vim: set filetype=python:
# This Source Code Form is subject to the terms of the Mozilla Public
# License, v. 2.0. If a copy of the MPL was not distributed with this
# file, You can obtain one at http://mozilla.org/MPL/2.0/.

Classes = [
    {
        'name': 'History',
        'cid': '{0937a705-91a6-417a-8292-b22eb10da86c}',
        'contract_ids': ['@mozilla.org/browser/history;1'],
        'singleton': True,
        'type': 'mozilla::places::History',
        'headers': ['mozilla/places/History.h'],
        'constructor': 'mozilla::places::History::GetSingleton',
    },
    {
        'cid': '{e8b8bdb7-c96c-4d82-9c6f-2b3c585ec7ea}',
        'contract_ids': ['@mozilla.org/network/protocol;1?name=cached-favicon'],
        'type': 'nsCachedFaviconProtocolHandler',
        'headers': ['/toolkit/components/places/nsCachedFaviconProtocolHandler.h'],
        'protocol_config': {
            'scheme': 'cached-favicon',
            'flags': [
                'URI_NORELATIVE',
                'URI_NOAUTH',
                'URI_DANGEROUS_TO_LOAD',
                'URI_IS_LOCAL_RESOURCE',
            ],
        },
    },
    {
        'cid': '{984e3259-9266-49cf-b605-60b022a00756}',
        'contract_ids': ['@mozilla.org/browser/favicon-service;1'],
        'singleton': True,
        'type': 'nsFaviconService',
        'headers': ['/toolkit/components/places/nsFaviconService.h'],
        'constructor': 'nsFaviconService::GetSingleton',
    },
    {
        'cid': '{9de95a0c-39a4-4d64-9a53-17940dd7cabb}',
        'contract_ids': ['@mozilla.org/browser/nav-bookmarks-service;1'],
        'singleton': True,
        'type': 'nsNavBookmarks',
        'headers': ['/toolkit/components/places/nsNavBookmarks.h'],
        'constructor': 'nsNavBookmarks::GetSingleton',
    },
    {
        'cid': '{88cecbb7-6c63-4b3b-8cd4-84f3b8228c69}',
        'contract_ids': ['@mozilla.org/browser/nav-history-service;1'],
        'singleton': True,
        'type': 'nsNavHistory',
        'headers': ['/toolkit/components/places/nsNavHistory.h'],
        'constructor': 'nsNavHistory::GetSingleton',
        'categories': {'vacuum-participant': 'Places'},
    },

    {
        'cid': '{bbc23860-2553-479d-8b78-94d9038334f7}',
        'contract_ids': ['@mozilla.org/browser/tagging-service;1'],
        'esModule': 'resource://gre/modules/TaggingService.sys.mjs',
        'constructor': 'TaggingService',
    },
    {
        'cid': '{1dcc23b0-d4cb-11dc-9ad6-479d56d89593}',
        'contract_ids': ['@mozilla.org/autocomplete/search;1?name=places-tag-autocomplete'],
        'esModule': 'resource://gre/modules/TaggingService.sys.mjs',
        'constructor': 'TagAutoCompleteSearch',
    },

    {
        'cid': '{705a423f-2f69-42f3-b9fe-1517e0dee56f}',
        'contract_ids': ['@mozilla.org/places/expiration;1'],
        'esModule': 'resource://gre/modules/PlacesExpiration.sys.mjs',
        'constructor': 'nsPlacesExpiration',
        'categories': {'places-init-complete': 'nsPlacesExpiration'},
    },

    {
        'cid': '{d38926e0-29c1-11eb-8588-0800200c9a66}',
        'contract_ids': ['@mozilla.org/places/databaseUtilsIdleMaintenance;1'],
        'esModule': 'resource://gre/modules/PlacesDBUtils.sys.mjs',
        'constructor': 'PlacesDBUtilsIdleMaintenance',
        'categories': {'idle-daily': 'PlacesDBUtilsIdleMaintenance'},
    },

    {
        'cid': '{60a1f7c6-4ff9-4a42-84d3-5a185faa6f32}',
        'contract_ids': ['@mozilla.org/network/protocol;1?name=page-icon'],
        'singleton': True,
        'type': 'mozilla::places::PageIconProtocolHandler',
        'headers': ['mozilla/places/PageIconProtocolHandler.h'],
        'constructor': 'mozilla::places::PageIconProtocolHandler::GetSingleton',
        'protocol_config': {
            'scheme': 'page-icon',
            'flags': [
                'URI_STD',
                'URI_IS_UI_RESOURCE',
                'URI_IS_LOCAL_RESOURCE',
                'URI_NORELATIVE',
                'URI_NOAUTH',
            ],
        },
    },

    {
        'cid': '{7d47b41d-7cc5-4882-b293-d8f3f3b48b46}',
        'contract_ids': ['@mozilla.org/browser/synced-bookmarks-merger;1'],
        'type': 'mozISyncedBookmarksMerger',
        'headers': ['mozilla/places/SyncedBookmarksMirror.h'],
        'constructor': 'mozilla::places::NewSyncedBookmarksMerger',
    },

    {
        'name': 'PlacesPreviewsHelper',
        'cid': '{bd0a4d3b-ff26-4d4d-9a62-a513e1c1bf92}',
        'contract_ids': ['@mozilla.org/places/previews-helper;1'],
        'esModule': 'resource://gre/modules/PlacesPreviews.sys.mjs',
        'constructor': 'PlacesPreviewsHelperService',
    },

    {
        'cid': '{1141fd31-4c1a-48eb-8f1a-2f05fad94085}',
        'contract_ids': ['@mozilla.org/places/frecency-recalculator;1'],
        'esModule': 'resource://gre/modules/PlacesFrecencyRecalculator.sys.mjs',
        'constructor': 'PlacesFrecencyRecalculator',
        'categories': {'places-init-complete': 'PlacesFrecencyRecalculator'},
    },
]
