From b4101f54249ba1d661ffbc26c620bd249a2f4018 Mon Sep 17 00:00:00 2001 From: Matthew Jason Benson Date: Tue, 8 May 2007 22:30:20 +0000 Subject: [PATCH] constructor with passed-in ProjectComponent and default loglevel git-svn-id: https://svn.apache.org/repos/asf/ant/core/trunk@536358 13f79535-47bb-0310-9956-ffa450edef68 --- .../apache/tools/ant/taskdefs/LogOutputStream.java | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/src/main/org/apache/tools/ant/taskdefs/LogOutputStream.java b/src/main/org/apache/tools/ant/taskdefs/LogOutputStream.java index af9dd4d1c..b2c34684d 100644 --- a/src/main/org/apache/tools/ant/taskdefs/LogOutputStream.java +++ b/src/main/org/apache/tools/ant/taskdefs/LogOutputStream.java @@ -37,6 +37,16 @@ public class LogOutputStream extends LineOrientedOutputStream { private ProjectComponent pc; private int level = Project.MSG_INFO; + /** + * Create a new LogOutputStream for the specified ProjectComponent. + * + * @param pc the project component for whom to log + * @since Ant 1.7.1 + */ + public LogOutputStream(ProjectComponent pc) { + this.pc = pc; + } + /** * Creates a new instance of this class. * @@ -55,7 +65,7 @@ public class LogOutputStream extends LineOrientedOutputStream { * @since Ant 1.6.3 */ public LogOutputStream(ProjectComponent pc, int level) { - this.pc = pc; + this(pc); this.level = level; }