From d95ff6f7b84272d516e276b09a3729b8323539bc Mon Sep 17 00:00:00 2001 From: Doug MacEachern Date: Wed, 26 Mar 2008 17:47:40 +0000 Subject: [PATCH] check Service. first --- .../src/org/hyperic/sigar/win32/Service.java | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/bindings/java/src/org/hyperic/sigar/win32/Service.java b/bindings/java/src/org/hyperic/sigar/win32/Service.java index 0c1d9975..79121239 100644 --- a/bindings/java/src/org/hyperic/sigar/win32/Service.java +++ b/bindings/java/src/org/hyperic/sigar/win32/Service.java @@ -420,6 +420,14 @@ public class Service extends Win32 { System.out.println(service.getStatusString()); return; } + else if ((args.length == 1) && (args[0].startsWith("Service."))) { + Sigar sigar = new Sigar(); + try { + services = Service.getServiceNames(sigar, args[0]); + } finally { + sigar.close(); + } + } else if ((args.length == 1) && (args[0].endsWith(EXE_EXT))) { services = getServiceConfigs(args[0]); for (int i=0; i