Jinseong Jeon | e11145f | 2018-12-13 10:57:29 -0800 | [diff] [blame] | 1 | // Copyright (c) 2018, the R8 project authors. Please see the AUTHORS file |
| 2 | // for details. All rights reserved. Use of this source code is governed by a |
| 3 | // BSD-style license that can be found in the LICENSE file. |
| 4 | package mockito_interface; |
| 5 | |
| 6 | public class InterfaceUser { |
| 7 | |
| 8 | private Interface itf; |
| 9 | |
| 10 | public InterfaceUser(Interface itf) { |
| 11 | this.itf = itf; |
| 12 | } |
| 13 | |
| 14 | void consume() { |
| 15 | itf.onEnterForeground(); |
| 16 | } |
| 17 | |
| 18 | public static void main() { |
| 19 | Implementer impl = new Implementer(); |
| 20 | InterfaceUser user = new InterfaceUser(impl); |
| 21 | user.consume(); |
| 22 | } |
| 23 | |
| 24 | } |