Class NoExitSecurityManager

  • public class NoExitSecurityManager
    extends java.lang.SecurityManager
    This is intended as a replacement for the default system manager. The goal is to intercept System.exit calls and make it throw an exception instead so that a System.exit in a task does not fully terminate Ant.
    See Also:
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void checkExit​(int status)
      Override SecurityManager#checkExit.
      void checkPermission​( perm)
      Override SecurityManager#checkPermission.
      • 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
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • NoExitSecurityManager

        public NoExitSecurityManager()
    • Method Detail

      • checkExit

        public void checkExit​(int status)
        Override SecurityManager#checkExit. This throws an ExitException(status) exception.
        checkExit in class java.lang.SecurityManager
        status - the exit status
      • checkPermission

        public void checkPermission​( perm)
        Override SecurityManager#checkPermission. This does nothing.
        checkPermission in class java.lang.SecurityManager
        perm - the requested permission.