• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 // Copyright (c) 2017, 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 minification;
5 
6 public class Minification {
7 
main(String[] args)8   public static void main(String[] args) {
9     SubClassA subClassA = new SubClassA();
10     exerciseA(subClassA);
11     SubSubClassAB subSubClassAB = new SubSubClassAB();
12     exerciseA(subSubClassAB);
13     exerciseB(subSubClassAB);
14     SubClassB subClassB = new SubClassB();
15     exerciseB(subClassB);
16     SubClassC subClassC = new SubClassC();
17     exerciseB(subClassC);
18     exerciseC(subClassC);
19     ClassD classD = new ClassD();
20     exerciseD(classD);
21   }
22 
exerciseA(InterfaceA thing)23   private static void exerciseA(InterfaceA thing) {
24     thing.functionFromIntToInt(thing.uniqueLittleMethodInA());
25   }
26 
exerciseB(InterfaceB thing)27   private static void exerciseB(InterfaceB thing) {
28     thing.functionFromIntToInt(thing.uniqueLittleMethodInB());
29   }
30 
exerciseC(InterfaceC thing)31   private static void exerciseC(InterfaceC thing) {
32     thing.functionFromIntToInt(thing.uniqueLittleMethodInC());
33   }
34 
exerciseD(InterfaceD thing)35   private static void exerciseD(InterfaceD thing) {
36     thing.anotherFunctionFromIntToInt(42);
37     thing.functionFromIntToInt(42);
38   }
39 }
40