Nuxeo Enterprise Platform 5.3

com.anwrt.ooserver.daemon
Class OSAbstractLayer

java.lang.Object
  extended by com.anwrt.ooserver.daemon.OSAbstractLayer

public class OSAbstractLayer
extends Object

An abstract layer that is useful for some system calls

Author:
Jounayd Id Salah

Field Summary
static int OS_UNIXCOMPATIBLE
           
static int OS_UNKNOWN
           
static int OS_WINDOWS
           
 
Constructor Summary
OSAbstractLayer()
           
 
Method Summary
static String concatPaths(String path1, String path2)
          example : path1 = "C:/Program Files" path2 = "directory" result = "C:/Program Files/directory" separators are '/' or '\'
 boolean isProcessAlive(int pid)
          not working
 void kill(String processName)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

OS_UNKNOWN

public static final int OS_UNKNOWN
See Also:
Constant Field Values

OS_WINDOWS

public static final int OS_WINDOWS
See Also:
Constant Field Values

OS_UNIXCOMPATIBLE

public static final int OS_UNIXCOMPATIBLE
See Also:
Constant Field Values
Constructor Detail

OSAbstractLayer

public OSAbstractLayer()
                throws Exception
Throws:
Exception
Method Detail

kill

public void kill(String processName)
          throws IOException
Parameters:
processName -
Throws:
IOException

isProcessAlive

public boolean isProcessAlive(int pid)
not working

Parameters:
pid -

concatPaths

public static String concatPaths(String path1,
                                 String path2)
example : path1 = "C:/Program Files" path2 = "directory" result = "C:/Program Files/directory" separators are '/' or '\'

Parameters:
path1 - a string ended by a separator or not
path2 - any string (should not start by a separator)
Returns:
The result of the concatenation of path1 and path2

Nuxeo Enterprise Platform 5.3

Copyright © 2010 Nuxeo SAS. All Rights Reserved.