1
/* $Id: UsagePrinter.java,v 1.16 2004/08/15 12:39:30 eric Exp $
1
/* $Id: UsagePrinter.java,v 1.19 2005/06/11 13:21:35 eric Exp $
3
3
* ProGuard -- shrinking, optimization, and obfuscation of Java class files.
5
* Copyright (c) 2002-2004 Eric Lafortune (eric@graphics.cornell.edu)
5
* Copyright (c) 2002-2005 Eric Lafortune (eric@graphics.cornell.edu)
7
7
* This program is free software; you can redistribute it and/or modify it
8
8
* under the terms of the GNU General Public License as published by the Free
50
51
* Creates a new UsagePrinter that prints to <code>System.out</code>.
52
* @param usageMarker the usage marker that was used to mark the classes
51
54
* @param printUsedItems a flag that indicates whether only unused items
52
* should be printed, or alternatively, only used items.
55
* should be printed, or alternatively, only used items.
54
public UsagePrinter(boolean printUnusedItems)
57
public UsagePrinter(UsageMarker usageMarker,
58
boolean printUnusedItems)
56
this(printUnusedItems, System.out);
60
this(usageMarker, printUnusedItems, System.out);
61
65
* Creates a new UsagePrinter that prints to the given stream.
66
* @param usageMarker the usage marker that was used to mark the classes
62
68
* @param printUsedItems a flag that indicates whether only unused items
63
* should be printed, or alternatively, only used items.
69
* should be printed, or alternatively, only used items.
64
70
* @param printStream the stream to which to print
66
public UsagePrinter(boolean printUnusedItems, PrintStream printStream)
72
public UsagePrinter(UsageMarker usageMarker,
73
boolean printUnusedItems,
74
PrintStream printStream)
76
this.usageMarker = usageMarker;
68
77
this.printUnusedItems = printUnusedItems;
69
78
this.ps = printStream;