From 29d4edb7e23e3d610394463f9c037f886fa7cfa8 Mon Sep 17 00:00:00 2001 From: RĂ¼diger Timm Date: Wed, 2 Feb 2005 12:58:59 +0000 Subject: INTEGRATION: CWS imprec01 (1.2.102); FILE MERGED 2005/01/10 13:00:47 cn 1.2.102.1: new method 'getWatcher' and 'setWatcher' implemented --- qadevOOo/runner/stats/SimpleLogWriter.java | 23 +++++++++++++++++------ 1 file changed, 17 insertions(+), 6 deletions(-) (limited to 'qadevOOo/runner/stats') diff --git a/qadevOOo/runner/stats/SimpleLogWriter.java b/qadevOOo/runner/stats/SimpleLogWriter.java index 4c37bc15bcec..1192217d7634 100644 --- a/qadevOOo/runner/stats/SimpleLogWriter.java +++ b/qadevOOo/runner/stats/SimpleLogWriter.java @@ -2,9 +2,9 @@ * * $RCSfile: SimpleLogWriter.java,v $ * - * $Revision: 1.2 $ + * $Revision: 1.3 $ * - * last change:$Date: 2003-10-06 12:41:39 $ + * last change:$Date: 2005-02-02 13:58:59 $ * * The Contents of this file are made available subject to the terms of * either of the following licenses @@ -73,6 +73,7 @@ public class SimpleLogWriter extends PrintWriter implements LogWriter { boolean logging = false; share.DescEntry entry = null; + share.Watcher ow = null; public SimpleLogWriter() { super(System.out); @@ -91,14 +92,16 @@ public class SimpleLogWriter extends PrintWriter implements LogWriter { public boolean initialize(share.DescEntry entry, boolean logging) { this.logging = logging; this.entry = entry; + return true; } public void println(String msg) { - share.Watcher ow = (share.Watcher) - entry.UserDefinedParams.get("Watcher"); - if (ow != null) { - ow.ping(); + + this.ow = (share.Watcher) entry.UserDefinedParams.get("Watcher"); + + if (this.ow != null) { + this.ow.ping(); } if (logging) { super.println("LOG> "+msg); @@ -110,4 +113,12 @@ public class SimpleLogWriter extends PrintWriter implements LogWriter { return true; } + public Object getWatcher() { + return this.ow; + } + + public void setWatcher(Object watcher) { + entry.UserDefinedParams.put("Watcher", (share.Watcher) watcher); + } + } -- cgit