From d9c6759f8c65dbe87bbbd4ca2f6b277cc9aa7b1b Mon Sep 17 00:00:00 2001 From: Doug MacEachern Date: Sun, 26 Jun 2005 04:01:02 +0000 Subject: [PATCH] rename status() to getStatus() --- .../java/src/net/hyperic/sigar/win32/Service.java | 15 ++++++++++++--- 1 file changed, 12 insertions(+), 3 deletions(-) diff --git a/bindings/java/src/net/hyperic/sigar/win32/Service.java b/bindings/java/src/net/hyperic/sigar/win32/Service.java index c87691df..04d3fe25 100644 --- a/bindings/java/src/net/hyperic/sigar/win32/Service.java +++ b/bindings/java/src/net/hyperic/sigar/win32/Service.java @@ -202,14 +202,23 @@ public class Service extends Win32 { waitForStart(timeout); } + /** + * @deprecated + * @see #getStatus() + */ public int status() + { + return getStatus(); + } + + public int getStatus() { return QueryServiceStatus(this.service); } public String getStatusString() { - return STATUS[status()]; + return STATUS[getStatus()]; } public void stop() throws Win32Exception @@ -233,7 +242,7 @@ public class Service extends Win32 { long start = System.currentTimeMillis(); - while ((status = status()) != SERVICE_STOPPED) { + while ((status = getStatus()) != SERVICE_STOPPED) { if (status == SERVICE_STOP_PENDING) { // The start hasn't completed yet. Keep trying up to // the timeout. @@ -262,7 +271,7 @@ public class Service extends Win32 { boolean result = true; long start = System.currentTimeMillis(); - while ((status = status()) != SERVICE_RUNNING) { + while ((status = getStatus()) != SERVICE_RUNNING) { if (status == SERVICE_START_PENDING) { // The start hasn't completed yet. Keep trying up to // the timeout.