Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(726)

Side by Side Diff: chrome/common/extensions/docs/server2/server_instance.py

Issue 61393002: Docserver: Enable GitHub content providers. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: rebase Created 7 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 # Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 # Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 # Use of this source code is governed by a BSD-style license that can be 2 # Use of this source code is governed by a BSD-style license that can be
3 # found in the LICENSE file. 3 # found in the LICENSE file.
4 4
5 from api_data_source import APIDataSource 5 from api_data_source import APIDataSource
6 from api_list_data_source import APIListDataSource 6 from api_list_data_source import APIListDataSource
7 from api_models import APIModels 7 from api_models import APIModels
8 from availability_finder import AvailabilityFinder 8 from availability_finder import AvailabilityFinder
9 from compiled_file_system import CompiledFileSystem 9 from compiled_file_system import CompiledFileSystem
10 from content_providers import ContentProviders 10 from content_providers import ContentProviders
(...skipping 120 matching lines...) Expand 10 before | Expand all | Expand 10 after
131 host_fs_at_trunk, 131 host_fs_at_trunk,
132 self.ref_resolver_factory, 132 self.ref_resolver_factory,
133 [svn_constants.INTRO_PATH, svn_constants.ARTICLE_PATH]) 133 [svn_constants.INTRO_PATH, svn_constants.ARTICLE_PATH])
134 134
135 self.path_canonicalizer = PathCanonicalizer( 135 self.path_canonicalizer = PathCanonicalizer(
136 self.compiled_fs_factory, 136 self.compiled_fs_factory,
137 host_fs_at_trunk) 137 host_fs_at_trunk)
138 138
139 self.content_providers = ContentProviders( 139 self.content_providers = ContentProviders(
140 self.compiled_fs_factory, 140 self.compiled_fs_factory,
141 host_fs_at_trunk) 141 host_fs_at_trunk,
142 self.github_file_system_provider)
142 143
143 # TODO(kalman): Move all the remaining DataSources into DataSourceRegistry, 144 # TODO(kalman): Move all the remaining DataSources into DataSourceRegistry,
144 # then factor out the DataSource creation into a factory method, so that 145 # then factor out the DataSource creation into a factory method, so that
145 # the entire ServerInstance doesn't need to be passed in here. 146 # the entire ServerInstance doesn't need to be passed in here.
146 self.template_renderer = TemplateRenderer(self) 147 self.template_renderer = TemplateRenderer(self)
147 148
148 self.strings_json_path = svn_constants.STRINGS_JSON_PATH 149 self.strings_json_path = svn_constants.STRINGS_JSON_PATH
149 self.manifest_json_path = svn_constants.MANIFEST_JSON_PATH 150 self.manifest_json_path = svn_constants.MANIFEST_JSON_PATH
150 self.manifest_features_path = svn_constants.MANIFEST_FEATURES_PATH 151 self.manifest_features_path = svn_constants.MANIFEST_FEATURES_PATH
151 152
(...skipping 13 matching lines...) Expand all
165 object_store_creator = ObjectStoreCreator(start_empty=False, 166 object_store_creator = ObjectStoreCreator(start_empty=False,
166 store_type=TestObjectStore) 167 store_type=TestObjectStore)
167 host_file_system_provider = HostFileSystemProvider.ForLocal( 168 host_file_system_provider = HostFileSystemProvider.ForLocal(
168 object_store_creator) 169 object_store_creator)
169 return ServerInstance( 170 return ServerInstance(
170 object_store_creator, 171 object_store_creator,
171 CompiledFileSystem.Factory(object_store_creator), 172 CompiledFileSystem.Factory(object_store_creator),
172 TestBranchUtility.CreateWithCannedData(), 173 TestBranchUtility.CreateWithCannedData(),
173 host_file_system_provider, 174 host_file_system_provider,
174 GithubFileSystemProvider.ForEmpty()) 175 GithubFileSystemProvider.ForEmpty())
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698