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

Side by Side Diff: content/public/android/java/src/org/chromium/content/browser/ContentClassFactory.java

Issue 2724363004: Content class factory and generalized text selector (Closed)
Patch Set: Addressed comments Created 3 years, 9 months 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
OLDNEW
(Empty)
1 // Copyright 2017 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 package org.chromium.content.browser;
6
7 import org.chromium.base.ThreadUtils;
8 import org.chromium.ui.base.WindowAndroid;
9
10 /**
11 * A class factory for content browser layer.
12 */
13 public class ContentClassFactory {
14 private static ContentClassFactory sSingleton;
15
16 /**
17 * Sets the factory object.
18 */
19 public static void set(ContentClassFactory factory) {
20 ThreadUtils.assertOnUiThread();
21
22 sSingleton = factory;
23 }
24
25 /**
26 * Returns the factory object.
27 */
28 public static ContentClassFactory get() {
29 ThreadUtils.assertOnUiThread();
30
31 if (sSingleton == null) sSingleton = new ContentClassFactory();
32 return sSingleton;
33 }
34
35 /**
36 * Constructor.
37 */
38 protected ContentClassFactory() {}
39
40 /**
41 * Creates ContextSelectorProvider object.
42 */
43 public ContextSelectionProvider createContextSelectionProvider(
44 ContextSelectionProvider.ResultCallback callback, WindowAndroid wind owAndroid) {
45 // Implemented by a subclass.
46 return null;
47 }
48 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698