Package org.codehaus.gmavenplus.util
Class NoExitSecurityManager
- java.lang.Object
-
- java.lang.SecurityManager
-
- org.codehaus.gmavenplus.util.NoExitSecurityManager
-
public class NoExitSecurityManager extends java.lang.SecurityManagerCustom security manager toSystem.exit(int)(and related) from being used.- Since:
- 1.2
-
-
Field Summary
Fields Modifier and Type Field Description private java.lang.SecurityManagerparentThe parent SecurityManager.
-
Constructor Summary
Constructors Constructor Description NoExitSecurityManager()Construct a new NoExitSecurityManager, using the System SecurityManager as the parent.NoExitSecurityManager(java.lang.SecurityManager newParent)Construct a new NoExitSecurityManager from the parent.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidcheckExit(int code)Always throwsSecurityException.voidcheckPermission(java.security.Permission permission)Check the given Permission.-
Methods inherited from class java.lang.SecurityManager
checkAccept, checkAccess, checkAccess, checkConnect, checkConnect, checkCreateClassLoader, checkDelete, checkExec, checkLink, checkListen, checkMulticast, checkMulticast, checkPackageAccess, checkPackageDefinition, checkPermission, checkPrintJobAccess, checkPropertiesAccess, checkPropertyAccess, checkRead, checkRead, checkRead, checkSecurityAccess, checkSetFactory, checkWrite, checkWrite, getClassContext, getSecurityContext, getThreadGroup
-
-
-
-
Constructor Detail
-
NoExitSecurityManager
public NoExitSecurityManager(java.lang.SecurityManager newParent)
Construct a new NoExitSecurityManager from the parent.- Parameters:
newParent- the parent to set
-
NoExitSecurityManager
public NoExitSecurityManager()
Construct a new NoExitSecurityManager, using the System SecurityManager as the parent.
-
-
Method Detail
-
checkPermission
public void checkPermission(java.security.Permission permission)
Check the given Permission.- Overrides:
checkPermissionin classjava.lang.SecurityManager- Parameters:
permission- the Permission to check
-
checkExit
public void checkExit(int code)
Always throwsSecurityException.- Overrides:
checkExitin classjava.lang.SecurityManager- Parameters:
code- the exit code that is completely ignored
-
-