org.codehaus.groovy.tools.shell.util

## Class NoExitSecurityManager

- java.lang.Object
- - java.lang.SecurityManager
  - - org.codehaus.groovy.tools.shell.util.NoExitSecurityManager

-     public class NoExitSecurityManager
      extends java.lang.SecurityManager

  Custom security manager to `System.exit(int)` (and related) from being used.

- - ### Field Summary

    - ### Fields inherited from class java.lang.SecurityManager

      `inCheck`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `NoExitSecurityManager()`
    `NoExitSecurityManager(java.lang.SecurityManager parent)`

  - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `void` | `checkExit(int code)` Always throws `SecurityException`.
    `void` | `checkPermission(java.security.Permission perm)`

    - ### Methods inherited from class java.lang.SecurityManager

      `checkAccept, checkAccess, checkAccess, checkAwtEventQueueAccess, checkConnect, checkConnect, checkCreateClassLoader, checkDelete, checkExec, checkLink, checkListen, checkMemberAccess, checkMulticast, checkMulticast, checkPackageAccess, checkPackageDefinition, checkPermission, checkPrintJobAccess, checkPropertiesAccess, checkPropertyAccess, checkRead, checkRead, checkRead, checkSecurityAccess, checkSetFactory, checkSystemClipboardAccess, checkTopLevelWindow, checkWrite, checkWrite, classDepth, classLoaderDepth, currentClassLoader, currentLoadedClass, getClassContext, getInCheck, getSecurityContext, getThreadGroup, inClass, inClassLoader`

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Constructor Detail

    - #### NoExitSecurityManager

          public NoExitSecurityManager(java.lang.SecurityManager parent)

    - #### NoExitSecurityManager

          public NoExitSecurityManager()

  - ### Method Detail

    - #### checkPermission

          public void checkPermission(java.security.Permission perm)

      Overrides:
        `checkPermission` in class `java.lang.SecurityManager`

    - #### checkExit

          public void checkExit(int code)

      Always throws `SecurityException`.
      Overrides:
        `checkExit` in class `java.lang.SecurityManager`