Commit c0a8e2b6 authored by Xing Liu's avatar Xing Liu Committed by Commit Bot

Chime: Add an empty base class for downstream compile.

The Chime DFM is built with two classes in chromium upstream and clank
downstream that directly implement the ChimeModuleEntry auto generated
interface.

This creates an issue that we can't add new method to the interface.
It also causes the revert of:
https://chromium-review.googlesource.com/c/chromium/src/+/2487816

This CL introduces an empty base class that implements ChimeModuleEntry.
So downstream can extend the base class to avoid compiling failure. This
approach is similar to AppHooks.java. Downstream impl class will extend
this new base class soon.

Bug: 1136305
Change-Id: I5c028f0fd95a04904adc8cadbbc9c5dbb1083c04
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2500251Reviewed-by: default avatarMin Qin <qinmin@chromium.org>
Reviewed-by: default avatarDavid Trainor <dtrainor@chromium.org>
Commit-Queue: Xing Liu <xingliu@chromium.org>
Cr-Commit-Position: refs/heads/master@{#821859}
parent 7811575c
......@@ -11,7 +11,4 @@ import org.chromium.base.annotations.UsedByReflection;
* implementation lives in downstream.
*/
@UsedByReflection("ChimeModule")
public class ChimeModuleEntryImpl implements ChimeModuleEntry {
@Override
public void register() {}
}
public class ChimeModuleEntryImpl extends ChimeModuleBase {}
......@@ -5,8 +5,10 @@
import("//build/config/android/rules.gni")
android_library("java") {
sources =
[ "java/src/org/chromium/chrome/modules/chime/ChimeModuleEntry.java" ]
sources = [
"java/src/org/chromium/chrome/modules/chime/ChimeModuleBase.java",
"java/src/org/chromium/chrome/modules/chime/ChimeModuleEntry.java",
]
deps = [
"//base:base_java",
......
// Copyright 2020 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
package org.chromium.chrome.modules.chime;
/**
* An empty base class for {@link ChimeModuleEntry}. The main purpose of this class is to make both
* chromium upstream and clank downstream compile at the same time for the DFM module interface
* {@link ChimeModuleEntry}.
*/
public class ChimeModuleBase implements ChimeModuleEntry {
@Override
public void register() {}
}
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment